-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Changes generated by 7576ee27e663fe49910aea2d74830697f42b468d
This commit was automatically created from gocardless/gocardless-dotnet-template@7576ee2 by the `push-files` action. Workflow run: https://github.com/gocardless/gocardless-dotnet-template/actions/runs/8836016263
- Loading branch information
1 parent
c7811a2
commit 323a1fb
Showing
9 changed files
with
99 additions
and
92 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,6 +6,7 @@ | |
using GoCardless.Resources; | ||
using GoCardless.Services; | ||
using NUnit.Framework; | ||
using NUnit.Framework.Legacy; | ||
using FluentAssertions; | ||
|
||
namespace GoCardless.Tests | ||
|
@@ -34,12 +35,12 @@ public async Task ShouldGetBlock() | |
TestHelpers.AssertResponseCanSerializeBackToFixture(resp, responseFixture); | ||
|
||
GoCardless.Resources.Block block = resp.Block; | ||
Assert.AreEqual(block.Id, "BLC456"); | ||
Assert.AreEqual(block.BlockType, "email"); | ||
Assert.AreEqual(block.ReasonType, "no_intent_to_pay"); | ||
Assert.AreEqual(block.ResourceReference, "[email protected]"); | ||
Assert.AreEqual(block.Active, true); | ||
Assert.AreEqual(block.CreatedAt.Value.ToString("o"), "2021-03-25T17:26:28.3050000+00:00"); | ||
ClassicAssert.AreEqual(block.Id, "BLC456"); | ||
ClassicAssert.AreEqual(block.BlockType, "email"); | ||
ClassicAssert.AreEqual(block.ReasonType, "no_intent_to_pay"); | ||
ClassicAssert.AreEqual(block.ResourceReference, "[email protected]"); | ||
ClassicAssert.AreEqual(block.Active, true); | ||
ClassicAssert.AreEqual(block.CreatedAt.Value.ToString("o"), "2021-03-25T17:26:28.3050000+00:00"); | ||
} | ||
|
||
[Test] | ||
|
@@ -61,14 +62,14 @@ public async Task ShouldBlockByRef() | |
resp.Meta.Cursors.After.Should().BeNull(); | ||
|
||
IReadOnlyList<GoCardless.Resources.Block> blocks = resp.Blocks; | ||
Assert.AreEqual(blocks[0].Id, "BLC123"); | ||
Assert.AreEqual(blocks[0].BlockType, "email"); | ||
Assert.AreEqual(blocks[0].ReasonType, "no_intent_to_pay"); | ||
Assert.AreEqual(blocks[0].ResourceReference, "[email protected]"); | ||
Assert.AreEqual(blocks[1].Id, "BLC456"); | ||
Assert.AreEqual(blocks[1].BlockType, "bank_account"); | ||
Assert.AreEqual(blocks[1].ReasonType, "no_intent_to_pay"); | ||
Assert.AreEqual(blocks[1].ResourceReference, "BA123"); | ||
ClassicAssert.AreEqual(blocks[0].Id, "BLC123"); | ||
ClassicAssert.AreEqual(blocks[0].BlockType, "email"); | ||
ClassicAssert.AreEqual(blocks[0].ReasonType, "no_intent_to_pay"); | ||
ClassicAssert.AreEqual(blocks[0].ResourceReference, "[email protected]"); | ||
ClassicAssert.AreEqual(blocks[1].Id, "BLC456"); | ||
ClassicAssert.AreEqual(blocks[1].BlockType, "bank_account"); | ||
ClassicAssert.AreEqual(blocks[1].ReasonType, "no_intent_to_pay"); | ||
ClassicAssert.AreEqual(blocks[1].ResourceReference, "BA123"); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.