Skip to main content

✅ Lucifer reflection respects depth limit

CategoryAbility
StatusPassing
Testtests/test_abilities_complex.py::TestLuciferDamageReflection::test_lucifer_reflection_respects_depth_limit

Two Lucifers in same lane — reflection could chain infinitely.

Preconditions

  • Lane 0: P1's Lucifer A (#088) — 0 damage

  • Lane 0: P2's Lucifer B (#088) — 0 damage (different owner so they see each other)

Action

  • Fire DAMAGE_RECEIVED for Lucifer A, value=2
result = fire_event(state, event)

Expected Postconditions

  • Engine does NOT infinite loop (depth limit enforces MAX_TRIGGER_DEPTH=10)

  • Result is a valid GameState (no exception raised)

Assertions

assert result is not None, "fire_event must return a valid state even in chain scenarios."