Files
Paradise/code/tests/attack_chain/test_attack_chain_cult_dagger.dm
T
warriorstar-orionandGitHub 33eaf8ae42 Create interaction test harness. (#27643)
* Create interaction test harness.

* retrofit tests, add janicart attack chain tests

* extract puppeteer to separate file

* move puppeteer creation to constructor
2024-12-23 00:20:49 +00:00

18 lines
823 B
Plaintext

/datum/game_test/attack_chain_cult_dagger/Run()
var/datum/test_puppeteer/cultist = new(src)
var/datum/test_puppeteer/target = cultist.spawn_puppet_nearby()
cultist.puppet.mind.add_antag_datum(/datum/antagonist/cultist)
cultist.spawn_obj_in_hand(/obj/item/melee/cultblade/dagger)
cultist.set_intent("harm")
cultist.click_on(target)
TEST_ASSERT(target.check_attack_log("Attacked with ritual dagger"), "non-cultist missing dagger attack log")
TEST_ASSERT_NOTEQUAL(target.puppet.health, target.puppet.getMaxHealth(), "cultist attacking non-cultist with dagger caused no damage")
target.rejuvenate()
target.puppet.mind.add_antag_datum(/datum/antagonist/cultist)
cultist.click_on(target)
TEST_ASSERT_EQUAL(target.puppet.health, target.puppet.getMaxHealth(), "cultist attacking cultist with dagger caused damage")