2023-03-01 22:06:38 +01:00
|
|
|
|
using JpnCardsPokemon.Sdk.Utils.QueryFilter;
|
|
|
|
|
using JpnCardsPokemon.Tests.Classes;
|
2023-03-01 17:29:39 +01:00
|
|
|
|
|
2023-03-01 22:06:38 +01:00
|
|
|
|
namespace JpnCardsPokemon.Tests;
|
2023-03-01 17:29:39 +01:00
|
|
|
|
|
|
|
|
|
public class CardTests : ApiTestClass
|
|
|
|
|
{
|
|
|
|
|
[Test]
|
|
|
|
|
public async Task TestFetchCards()
|
|
|
|
|
{
|
2023-03-01 21:48:01 +01:00
|
|
|
|
var cards = await Client.FetchCardsAsync(new CardQueryFilterBuilder { Name = "morpeko" });
|
|
|
|
|
Assert.IsNotEmpty(cards);
|
2023-03-01 17:29:39 +01:00
|
|
|
|
}
|
2023-03-03 15:24:06 +01:00
|
|
|
|
|
|
|
|
|
[Test]
|
|
|
|
|
public async Task TestGetPrices()
|
|
|
|
|
{
|
|
|
|
|
// Radiant charizard from Go may have prices in different conditions
|
|
|
|
|
var card = (await Client.FetchCardsAsync(new CardQueryFilterBuilder { Uuid = 48495360 })).FirstOrDefault();
|
|
|
|
|
Assert.IsNotNull(card);
|
|
|
|
|
Assert.IsNotEmpty(card.Prices);
|
|
|
|
|
|
|
|
|
|
// Zubat, common from Dark Phantasma may have prices for different versions (regular + reverse holo)
|
|
|
|
|
card = (await Client.FetchCardsAsync(new CardQueryFilterBuilder { Uuid = 95800678 })).FirstOrDefault();
|
|
|
|
|
Assert.IsNotNull(card);
|
|
|
|
|
Assert.IsNotEmpty(card.Prices);
|
|
|
|
|
}
|
2023-03-01 17:29:39 +01:00
|
|
|
|
}
|