mirror of
https://github.com/Droid-Deck/DroidDeck.git
synced 2026-11-23 06:46:02 +00:00
fix: take the Agent's empty answer for an uninstalled game as gone
Once Blizzard's Agent has removed a game it answers GET /game/<uid> with an empty object, not installed false, so a finished uninstall read as a failure and opened Battle.net.
This commit is contained in:
1 parent
c48297e0d1
commit
3b6b304f55
2 files changed
+6
-2
No files matched your search
@@ -1210,6 +1210,9 @@ class AgentJobTest(Harness):
|
||||
self.files = {".game": json.dumps({"error": 2})}
|
||||
self.assertEqual(BNET["agent_job"](self.root, "uninstall", "gryphon", poll=0), 1)
|
||||
self.assertEqual(self.lines[-1][0], "ERROR")
|
||||
self.files = {".game": json.dumps({})}
|
||||
self.assertEqual(BNET["agent_job"](self.root, "uninstall", "gryphon", poll=0), 0)
|
||||
self.assertEqual(self.lines[-1], ("DONE", json.dumps({"uninstalled": "gryphon"})))
|
||||
|
||||
def test_without_battle_net_nothing_starts(self):
|
||||
self.assertEqual(BNET["agent_job"](self.root, "install", "gryphon", "gryphon", str(self.tmp / "g"), "enUS", "USA", "US", poll=0), 3)
|
||||
|
||||
Reference in new issue
Block a user