def test_write_data(self): game = GitCrystalsCmd() G.change_location_file('Git Crystal') game.load_data() G.change_location_file('Mountain Gate') game.write_data() file_data = JsonData(G.repodir, "location") self.assertEqual(file_data.data['location'], 'Git Crystal')
def test_load_data(self): game = GitCrystalsCmd() G.change_location_file('Git Crystal') game.load_data() expected = 'Git Crystal' self.assertEqual(game.player.location, expected)