Test for Shell Bell interaction

This commit is contained in:
frutescens 2024-11-16 15:32:49 -08:00
parent 73d198256f
commit 907498286f
1 changed files with 21 additions and 1 deletions

View File

@ -195,7 +195,8 @@ describe("Abilities - Sheer Force", () => {
game.override
.ability(Abilities.SHEER_FORCE)
.moveset([ Moves.RELIC_SONG ])
.enemyMoveset([ Moves.SPLASH ]);
.enemyMoveset([ Moves.SPLASH ])
.enemyLevel(100);
await game.classicMode.startBattle([ Species.MELOETTA ]);
const playerPokemon = game.scene.getPlayerPokemon();
@ -206,5 +207,24 @@ describe("Abilities - Sheer Force", () => {
expect(formKeyStart).toBe(playerPokemon?.getFormKey());
});
it("Sheer Force should disable healing from Shell Bell", async () => {
game.override
.ability(Abilities.SHEER_FORCE)
.moveset([ Moves.TACKLE ])
.enemySpecies(Species.GEODUDE)
.enemyMoveset([ Moves.TACKLE ])
.enemyLevel(100)
.startingHeldItems([{ name: "SHELL_BELL", count: 1 }]);
await game.classicMode.startBattle([ Species.SHUCKLE ]);
const playerPokemon = game.scene.getPlayerPokemon();
game.move.select(Moves.TACKLE);
await game.setTurnOrder([ BattlerIndex.ENEMY, BattlerIndex.PLAYER ]);
await game.phaseInterceptor.to("MoveEndPhase");
const postAttackHp = playerPokemon?.hp;
await game.phaseInterceptor.to("TurnEndPhase");
expect(playerPokemon?.hp).toBe(postAttackHp);
});
//TODO King's Rock Interaction Unit Test
});