public void FindCardById() { int ventriloquyCardId = 10418; ArtifactClient client = new ArtifactClient(); Card card = client.GetCard(ventriloquyCardId); Assert.IsNotNull(card); }
public void FindCardByName() { string cardName = "Phantom assassin"; ArtifactClient client = new ArtifactClient(); Card c = client.GetCard(cardName); Assert.IsNotNull(c); Assert.AreEqual(cardName.ToLower(), c.Names.English.ToLower()); }
public void GetCardArtUrl() { ArtifactClient client = new ArtifactClient(); Card c = client.GetCard("venomancer"); if (c == null) { Assert.Fail(); //Failed because GetCard(name) fails } Enums.ArtType type = Enums.ArtType.Large; string idUrl = client.GetCardArtUrl(c.Id, type); string nameUrl = client.GetCardArtUrl(c.Names.English, type); Assert.IsFalse(string.IsNullOrEmpty(idUrl)); Assert.IsFalse(string.IsNullOrEmpty(nameUrl)); Assert.AreEqual(idUrl, nameUrl); }