purify test
This commit is contained in:
parent
9ec1d2974e
commit
2ddfcd0a96
@ -1,5 +1,4 @@
|
||||
# FIXME
|
||||
last round of animations skipped cause no skill phase to add new vec
|
||||
check silence skill multiplier
|
||||
|
||||
game ready not auto starting resolve phase
|
||||
|
||||
@ -1705,6 +1705,37 @@ mod tests {
|
||||
}));
|
||||
}
|
||||
|
||||
|
||||
#[test]
|
||||
fn purify_test() {
|
||||
let mut game = create_2v2_test_game();
|
||||
let source_player_id = game.players[0].id;
|
||||
let target_player_id = game.players[1].id;
|
||||
let source = game.players[0].constructs[0].id;
|
||||
let target = game.players[1].constructs[0].id;
|
||||
|
||||
game.resolve(Cast::new(source, source_player_id, target, Skill::Decay));
|
||||
|
||||
// 3 for Decayed =/
|
||||
assert!(game.players[1].constructs[0].effects.len() == 3);
|
||||
|
||||
game.resolve(Cast::new(target, target_player_id, target, Skill::Purify));
|
||||
|
||||
assert!(game.players[1].constructs[0].effects.len() == 1);
|
||||
|
||||
let last = game.resolutions.len() - 1;
|
||||
let resolutions = &game.resolutions[last];
|
||||
|
||||
assert!(resolutions.iter().any(|r| match r.event {
|
||||
Event::Effect { construct, effect, duration: _, display: _ } =>
|
||||
construct == target && effect == Effect::Pure,
|
||||
_ => false,
|
||||
}));
|
||||
|
||||
// Check for healing here
|
||||
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn invert_test() {
|
||||
let mut game = create_2v2_test_game();
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user