var assert = require('assert');
var battle;

describe('Contrary', function () {
	afterEach(function () {
		battle.destroy();
	});

	it('should invert relative stat changes', function () {
		this.timeout(0);
		battle = BattleEngine.Battle.construct();
		battle.join('p1', 'Guest 1', 1, [{species: "Spinda", ability: 'contrary', moves: ['superpower']}]);
		battle.join('p2', 'Guest 2', 1, [{species: "Dragonite", ability: 'multiscale',  moves: ['dragondance']}]);
		battle.commitDecisions();
		assert.strictEqual(battle.p1.active[0].boosts['atk'], 1);
		assert.strictEqual(battle.p1.active[0].boosts['def'], 1);
	});

	it('should not invert absolute stat changes', function () {
		battle = BattleEngine.Battle.construct();
		battle.join('p1', 'Guest 1', 1, [{species: "Serperior", ability: 'contrary', moves: ['leechseed']}]);
		battle.join('p2', 'Guest 2', 1, [{species: "Growlithe", ability: 'intimidate', moves: ['topsyturvy']}]);
		battle.commitDecisions();
		assert.strictEqual(battle.p1.active[0].boosts['atk'], -1);
	});
});

@@ -1018,13 +1018,825 @@
 1);%0A%09%7D);
+%0A%0A%09it('should invert Belly Drum maximizing Attack', function () %7B%0A%09%09battle = BattleEngine.Battle.construct();%0A%09%09battle.join('p1', 'Guest 1', 1, %5B%7Bspecies: %22Spinda%22, ability: 'contrary', moves: %5B'bellydrum'%5D%7D%5D);%0A%09%09battle.join('p2', 'Guest 2', 1, %5B%7Bspecies: %22Dragonite%22, ability: 'multiscale',  moves: %5B'dragondance'%5D%7D%5D);%0A%09%09battle.commitDecisions();%0A%09%09assert.strictEqual(battle.p1.active%5B0%5D.boosts%5B'atk'%5D, -6);%0A%09%7D);%0A%0A%09it('should be suppressed by Mold Breaker', function () %7B%0A%09%09battle = BattleEngine.Battle.construct();%0A%09%09battle.join('p1', 'Guest 1', 1, %5B%7Bspecies: %22Spinda%22, ability: 'contrary', moves: %5B'tackle'%5D%7D%5D);%0A%09%09battle.join('p2', 'Guest 2', 1, %5B%7Bspecies: %22Dragonite%22, ability: 'moldbreaker',  moves: %5B'growl'%5D%7D%5D);%0A%09%09battle.commitDecisions();%0A%09%09assert.strictEqual(battle.p1.active%5B0%5D.boosts%5B'atk'%5D, -1);%0A%09%7D);
 %0A%7D);%0A

Add Contrary tests for Mold Breaker and Belly Drum