fix(web): finalize quick battle and commission procurement for 2.0.9
This commit is contained in:
@@ -415,8 +415,9 @@ class SimulatorTests(unittest.TestCase):
|
||||
req = request(players=[monster(species=1001020)]) # actual skill 10
|
||||
report = ExperimentalBattleRuntime().inspect(req)
|
||||
self.assertTrue(report["supported"])
|
||||
self.assertTrue(any(d["code"] == "unsupported_skill" and "10" in d["message"] for d in report["diagnostics"]))
|
||||
self.assertTrue(any("Skill 10" in x for x in report["ignored_mechanics"]))
|
||||
self.assertTrue(any(d["code"] == "aggregate_skill" and "10" in d["message"] for d in report["diagnostics"]))
|
||||
self.assertTrue(any("bounded expected" in x for x in report["assumptions"]))
|
||||
self.assertTrue(any(d["code"] == "unsupported_skill" for d in simulate(req)["diagnostics"]))
|
||||
|
||||
def test_controllers_triggers_and_non_elimination_are_rejected(self):
|
||||
for key, value in (("controller", [{"type": "monMaker"}]),
|
||||
@@ -476,11 +477,13 @@ class WorkerTests(unittest.TestCase):
|
||||
self.assertEqual(result["outcome"], "win")
|
||||
self.assertEqual(result["battle_data"]["battlePosition"], req["battle_position"])
|
||||
|
||||
def test_fixed_module_subprocess_equals_direct_model(self):
|
||||
def test_fixed_module_subprocess_uses_quick_model_by_default(self):
|
||||
from ranch_assistant.battle_quick import simulate_quick
|
||||
req = request()
|
||||
with patch("socket.socket", side_effect=AssertionError("No network")):
|
||||
result = ExperimentalBattleRuntime().run(req)
|
||||
self.assertEqual(result, simulate(req))
|
||||
self.assertEqual(result, simulate_quick(req))
|
||||
self.assertEqual(result["simulation_method"], "aggregate_hp_dps")
|
||||
|
||||
def test_worker_entrypoint_does_not_import_gui_or_production_engine(self):
|
||||
completed = subprocess.run([sys.executable, "-c",
|
||||
|
||||
Reference in New Issue
Block a user