mirror of
https://github.com/pagefaultgames/pokerogue.git
synced 2025-08-19 05:49:32 +02:00
Add test for Roar, remove test for Acupressure
This commit is contained in:
parent
931025d3d2
commit
463f86fb83
@ -96,15 +96,22 @@ describe("Moves - Metronome", () => {
|
|||||||
expect(rightOpp.getStatStage(Stat.SPDEF)).toBe(0);
|
expect(rightOpp.getStatStage(Stat.SPDEF)).toBe(0);
|
||||||
});
|
});
|
||||||
|
|
||||||
// it("should be able to target itself or its ally with Acupressure", { repeats: 20 }, async () => {
|
it("should cause opponent to flee, and not crash for Roar", async () => {
|
||||||
// game.override.battleType("double");
|
await game.classicMode.startBattle();
|
||||||
// await game.classicMode.startBattle([ Species.REGIELEKI, Species.RATTATA ]);
|
const player = game.scene.getPlayerPokemon()!;
|
||||||
// vi.spyOn(leftPlayer, "randSeedInt").mockReturnValue(Moves.ACUPRESSURE);
|
vi.spyOn(player, "randSeedInt").mockReturnValue(Moves.ROAR);
|
||||||
|
|
||||||
// // game.move.select(Moves.METRONOME);
|
const enemyPokemon = game.scene.getEnemyPokemon()!;
|
||||||
// // game.move.select(Moves.SPLASH, 1);
|
|
||||||
// // await game.phaseInterceptor.to("MoveEffectPhase");
|
game.move.select(Moves.METRONOME);
|
||||||
// // await game.move.forceHit();
|
await game.phaseInterceptor.to("MoveEffectPhase");
|
||||||
// // await game.toNextTurn();
|
await game.move.forceHit();
|
||||||
// });
|
await game.phaseInterceptor.to("BerryPhase");
|
||||||
|
|
||||||
|
const isVisible = enemyPokemon.visible;
|
||||||
|
const hasFled = enemyPokemon.switchOutStatus;
|
||||||
|
expect(!isVisible && hasFled).toBe(true);
|
||||||
|
|
||||||
|
await game.phaseInterceptor.to("BattleEndPhase");
|
||||||
|
});
|
||||||
});
|
});
|
||||||
|
Loading…
Reference in New Issue
Block a user