File size: 1,110 Bytes
5c2ed06
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
'use strict';

const assert = require('./../../assert');
const common = require('./../../common');

let battle;

describe('Assault Vest', () => {
	afterEach(() => {
		battle.destroy();
	});

	it('should disable the use of Status moves', () => {
		battle = common.createBattle();
		battle.setPlayer('p1', { team: [{ species: 'Abra', ability: 'synchronize', moves: ['teleport'] }] });
		battle.setPlayer('p2', { team: [{ species: 'Abra', ability: 'synchronize', item: 'assaultvest', moves: ['teleport'] }] });
		assert.cantMove(() => battle.makeChoices('move teleport', 'move teleport'), 'Abra', 'Teleport');
	});

	it('should not prevent the use of Status moves', () => {
		battle = common.createBattle();
		battle.setPlayer('p1', { team: [{ species: 'Lopunny', ability: 'klutz', item: 'assaultvest', moves: ['trick'] }] });
		battle.setPlayer('p2', { team: [{ species: 'Abra', ability: 'synchronize', item: 'ironball', moves: ['calmmind'] }] });
		battle.makeChoices('move trick', 'move calmmind');
		assert.statStage(battle.p2.active[0], 'spa', 1);
		assert.statStage(battle.p2.active[0], 'spd', 1);
	});
});