From 9fd74649bf3bde70c385245a975c65fbf412fac3 Mon Sep 17 00:00:00 2001 From: Dylan Stephano-Shachter Date: Wed, 25 Sep 2019 07:10:10 +0300 Subject: [PATCH] scryfall seems to now give a list frame_effects rather than a single frame_effect --- scrython/cards/cards_object.py | 8 ++++---- unittests/TestCards.py | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/scrython/cards/cards_object.py b/scrython/cards/cards_object.py index 71896c8..ece7a8b 100644 --- a/scrython/cards/cards_object.py +++ b/scrython/cards/cards_object.py @@ -419,15 +419,15 @@ class CardsObject(FoundationObject): return self.scryfallJson['frame'] - def frame_effect(self): + def frame_effects(self): """The card's frame effect, if any. (miracle, nyxtouched, etc.) Returns: - string: The card's frame effect. + list: The card's frame effects. """ - super(CardsObject, self)._checkForKey('frame_effect') + super(CardsObject, self)._checkForKey('frame_effects') - return self.scryfallJson['frame_effect'] + return self.scryfallJson['frame_effects'] def full_art(self): """Returns True if the card is considered full art diff --git a/unittests/TestCards.py b/unittests/TestCards.py index daeff35..bc163f4 100644 --- a/unittests/TestCards.py +++ b/unittests/TestCards.py @@ -240,8 +240,8 @@ class TestSearch(unittest.TestCase): def test_tcgplayer_id(self): self.assertIsInstance(non_online_card.tcgplayer_id(), int) - def test_frame_effect(self): - self.assertIsInstance(transform.frame_effect(), str) + def test_frame_effects(self): + self.assertIsInstance(transform.frame_effects(), list) def test_games(self): self.assertIsInstance(non_online_card.games(), list)