pokemon-showdown/test/sim/moves/judgment.js
André Bastos Dias 7d92a7e14e
Some checks failed
Node.js CI / build (18.x) (push) Has been cancelled
Normalize test code formatting (#12029)
2026-05-11 21:13:30 -05:00

30 lines
929 B
JavaScript

'use strict';
const assert = require('./../../assert');
const common = require('./../../common');
let battle;
describe(`Judgment`, () => {
afterEach(() => battle.destroy());
it(`should adapt its type to a held Plate`, () => {
battle = common.createBattle([[
{ species: "Arceus", ability: 'Honey Gather', item: 'spookyplate', moves: ['judgment'] },
], [
{ species: "Spiritomb", ability: 'stancechange', moves: ['calmmind'] },
]]);
assert.hurts(battle.p2.active[0], () => battle.makeChoices('move judgment', 'move calmmind'));
});
it(`should not adapt its type to a held Z Crystal`, () => {
battle = common.createBattle([[
{ species: "Arceus", ability: 'Honey Gather', item: 'ghostiumz', moves: ['judgment'] },
], [
{ species: "Spiritomb", ability: 'stancechange', moves: ['calmmind'] },
]]);
battle.makeChoices('move judgment', 'move calmmind');
assert.fullHP(battle.p2.active[0]);
});
});