Selaa lähdekoodia

Added more integration tests for steam endpoint data

David Leonard 10 vuotta sitten
vanhempi
commit
594f73ef9a
1 muutettua tiedostoa jossa 8 lisäystä ja 1 poistoa
  1. 8 1
      hackathon_starter/hackathon/tests.py

+ 8 - 1
hackathon_starter/hackathon/tests.py

@@ -30,7 +30,14 @@ class HackathonViewsTestCase(TestCase):
 	def testSteamImg(self):
 		resp = self.client.get('/hackathon/steam/')
 		for dict in resp.context:
-			self.assertTrue('name' in dict)
+			if 'img_logo_url' in dict:
+				self.assertTrue('img_logo_url' in dict)
+
+	def testSteamAppID(self):
+		resp = self.client.get('/hackathon/steam/')
+		for dict in resp.context:
+			if 'appid' in dict:
+				self.assertTrue('appid' in dict)
 
 
 	def testQuandlDowJones(self):