def _get_test_files(): """ Used to generate the details_response.json file. """ with open('.key.json') as f: key = json.load(f)['steam'] h = API(key) hist = h.get_match_history(account_id=76561198025007092) with open('history_response.json', 'w') as f: json.dump(hist.resp, f) dr = h.get_match_details(547519680) with open('details_response.json', 'w') as f: json.dump(dr.resp, f)
def setUp(self): with open('.key.json') as f: key = json.load(f)['steam'] self.h = API(key)