forked from github/server
failing test for a new bug: empty dummy units get stuck in faction.units after recruiting.
This commit is contained in:
parent
34149b9fab
commit
18fcba3ed6
1 changed files with 13 additions and 0 deletions
|
@ -1139,3 +1139,16 @@ function test_prefix()
|
|||
u1.faction.locale = "en"
|
||||
assert_not_nil(u1:show():find("archelf"))
|
||||
end
|
||||
|
||||
function test_recruit()
|
||||
local r = region.create(0, 0, "plain")
|
||||
local f = faction.create("noreply@eressea.de", "human", "de")
|
||||
local u = unit.create(f, r, 1)
|
||||
|
||||
u:add_item("money", 1000)
|
||||
set_order(u, "REKRUTIERE 5")
|
||||
process_orders()
|
||||
for u in f.units do
|
||||
assert_equal(6, u.number)
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue