Skip to content

Commit

Permalink
#4
Browse files Browse the repository at this point in the history
  • Loading branch information
matmiranda committed Aug 18, 2023
1 parent 5059128 commit ffa7ed8
Show file tree
Hide file tree
Showing 4 changed files with 42 additions and 52 deletions.
2 changes: 1 addition & 1 deletion PagBank/Model/Card.cs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ public class Card
[JsonPropertyName("store"), JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
public bool? Store { get; set; }
[JsonPropertyName("token_data"), JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
public TokenData? Token_data { get; set; }
public TokenData? TokenData { get; set; }
[JsonPropertyName("id"), JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
public string? Id { get; set; }
[JsonPropertyName("encrypted"), JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
Expand Down
40 changes: 0 additions & 40 deletions PagBankTest/MockResponse/CriarConta_Buyer.json

This file was deleted.

6 changes: 0 additions & 6 deletions PagBankTest/PagBankTest.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,4 @@
<ProjectReference Include="..\PagBank\PagBank.csproj" />
</ItemGroup>

<ItemGroup>
<None Update="MockResponse\CriarConta_Buyer.json">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
</ItemGroup>

</Project>
46 changes: 41 additions & 5 deletions PagBankTest/UnitTest.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ namespace PagBankTest
public class Tests
{
[Test]
public async Task ExemploBasicoSandBox()
public async Task ExemploBasicoSandBox()
{
var client = new PagBankClient();
client.WithBaseUrl(BaseUrl.Sandbox);
Expand Down Expand Up @@ -104,18 +104,47 @@ public async Task MockExemploBasico()
Capture = true,
Card = new Card
{
ExpMonth = "",
ExpMonth = 0,
SecuritCode = "",
Store = true,
ExpYear = "",
ExpYear = 0,
Holder = new Holder
{
Name = ""
},
Number = ""
Number = "",
TokenData = new TokenData
{
AssuranceLevel = 0,
Cryptogram = "",
EcommerceDomain = "",
RequestorId = "",
Wallet = ""
}
},
Installments = 0,
Type = ""
Type = "",
Boleto = new Boleto
{
DueDate = "",
Holder = new Holder { },
InstructionLines = new InstructionLines
{
Line1 = "",
Line2 = ""
}
},
AuthenticationMethod = new AuthenticationMethod
{
Cavv = "",
DstransId = "",
Eci = "",
Td = "",
Type = "",
Version = "",
Xid = ""
},
SoftDescriptor = ""
},
ReferenceId = ""
}
Expand Down Expand Up @@ -232,6 +261,13 @@ public async Task MockExemploBasico()
{
Date = DateTime.Now,
UserIp = ""
},
QrCodes = new List<QrCodes>
{
new QrCodes
{
Amount = new Amount { },
ExpirationDate = "" }
}
};

Expand Down

0 comments on commit ffa7ed8

Please sign in to comment.