@@ -12,9 +12,9 @@ discard block |
||
| 12 | 12 | use Th3Mouk\PokemonGoIVCalculator\Exceptions\PokemonNotFound; |
| 13 | 13 | use Th3Mouk\PokemonGoIVCalculator\Extractors\Pokedex; |
| 14 | 14 | |
| 15 | -describe('Pokedex', function () { |
|
| 16 | - describe('get(pikachu)', function () { |
|
| 17 | - it("Should return a pokemon object of Pikachu", function () { |
|
| 15 | +describe('Pokedex', function() { |
|
| 16 | + describe('get(pikachu)', function() { |
|
| 17 | + it("Should return a pokemon object of Pikachu", function() { |
|
| 18 | 18 | $pokemon = (new Pokedex())->get('pikachu'); |
| 19 | 19 | |
| 20 | 20 | $assert = new Assert(); |
@@ -26,11 +26,11 @@ discard block |
||
| 26 | 26 | }); |
| 27 | 27 | }); |
| 28 | 28 | |
| 29 | - describe('get(unknowedPkm)', function () { |
|
| 30 | - it("Should throws a PokemonNotFound exception", function () { |
|
| 29 | + describe('get(unknowedPkm)', function() { |
|
| 30 | + it("Should throws a PokemonNotFound exception", function() { |
|
| 31 | 31 | $assert = new Assert(); |
| 32 | 32 | |
| 33 | - $assert->throws(function () { |
|
| 33 | + $assert->throws(function() { |
|
| 34 | 34 | (new Pokedex())->get('unknowedPkm'); |
| 35 | 35 | }, PokemonNotFound::class); |
| 36 | 36 | }); |
@@ -12,9 +12,9 @@ discard block |
||
| 12 | 12 | use Peridot\Leo\Interfaces\Assert; |
| 13 | 13 | use Th3Mouk\PokemonGoIVCalculator\Extractors\LevelExtractor; |
| 14 | 14 | |
| 15 | -describe('LevelExtractor', function () { |
|
| 16 | - describe('getGameMasterJson()', function () { |
|
| 17 | - it("Should return raw array result", function () { |
|
| 15 | +describe('LevelExtractor', function() { |
|
| 16 | + describe('getGameMasterJson()', function() { |
|
| 17 | + it("Should return raw array result", function() { |
|
| 18 | 18 | $raw = (new LevelExtractor())->getGameMasterJson(); |
| 19 | 19 | |
| 20 | 20 | $assert = new Assert(); |
@@ -24,8 +24,8 @@ discard block |
||
| 24 | 24 | }); |
| 25 | 25 | }); |
| 26 | 26 | |
| 27 | - describe('getGameMasterJsonCollection()', function () { |
|
| 28 | - it("Should return a non empty Illuminate\Collection", function () { |
|
| 27 | + describe('getGameMasterJsonCollection()', function() { |
|
| 28 | + it("Should return a non empty Illuminate\Collection", function() { |
|
| 29 | 29 | $collection = (new LevelExtractor())->getGameMasterJsonCollection(); |
| 30 | 30 | |
| 31 | 31 | $assert = new Assert(); |
@@ -34,8 +34,8 @@ discard block |
||
| 34 | 34 | }); |
| 35 | 35 | }); |
| 36 | 36 | |
| 37 | - describe('getDustFiltered(200)', function () { |
|
| 38 | - it("Should return a non empty Illuminate\Collection", function () { |
|
| 37 | + describe('getDustFiltered(200)', function() { |
|
| 38 | + it("Should return a non empty Illuminate\Collection", function() { |
|
| 39 | 39 | $collection = (new LevelExtractor())->getDustFiltered(200); |
| 40 | 40 | |
| 41 | 41 | $assert = new Assert(); |
@@ -44,8 +44,8 @@ discard block |
||
| 44 | 44 | }); |
| 45 | 45 | }); |
| 46 | 46 | |
| 47 | - describe('getDustFiltered(1)', function () { |
|
| 48 | - it("Should return an empty Illuminate\Collection", function () { |
|
| 47 | + describe('getDustFiltered(1)', function() { |
|
| 48 | + it("Should return an empty Illuminate\Collection", function() { |
|
| 49 | 49 | $collection = (new LevelExtractor())->getDustFiltered(1); |
| 50 | 50 | |
| 51 | 51 | $assert = new Assert(); |
@@ -12,9 +12,9 @@ discard block |
||
| 12 | 12 | use Peridot\Leo\Interfaces\Assert; |
| 13 | 13 | use Th3Mouk\PokemonGoIVCalculator\Extractors\GameMasterExtractor; |
| 14 | 14 | |
| 15 | -describe('GameMasterExtractor', function () { |
|
| 16 | - describe('getGameMasterJson()', function () { |
|
| 17 | - it("Should return raw array result", function () { |
|
| 15 | +describe('GameMasterExtractor', function() { |
|
| 16 | + describe('getGameMasterJson()', function() { |
|
| 17 | + it("Should return raw array result", function() { |
|
| 18 | 18 | $raw = (new GameMasterExtractor())->getGameMasterJson(); |
| 19 | 19 | |
| 20 | 20 | $assert = new Assert(); |
@@ -24,8 +24,8 @@ discard block |
||
| 24 | 24 | }); |
| 25 | 25 | }); |
| 26 | 26 | |
| 27 | - describe('getGameMasterJsonCollection()', function () { |
|
| 28 | - it("Should return a non empty Illuminate\Collection", function () { |
|
| 27 | + describe('getGameMasterJsonCollection()', function() { |
|
| 28 | + it("Should return a non empty Illuminate\Collection", function() { |
|
| 29 | 29 | $collection = (new GameMasterExtractor())->getGameMasterJsonCollection(); |
| 30 | 30 | |
| 31 | 31 | $assert = new Assert(); |
@@ -14,13 +14,13 @@ discard block |
||
| 14 | 14 | use Th3Mouk\PokemonGoIVCalculator\Entities\IvCombinaison; |
| 15 | 15 | use Th3Mouk\PokemonGoIVCalculator\Entities\Level; |
| 16 | 16 | |
| 17 | -describe('Calculator', function () { |
|
| 18 | - beforeEach(function () { |
|
| 17 | +describe('Calculator', function() { |
|
| 18 | + beforeEach(function() { |
|
| 19 | 19 | $this->assert = new Assert(); |
| 20 | 20 | }); |
| 21 | 21 | |
| 22 | - describe('calculate()', function () { |
|
| 23 | - it("test exclusion double 13 IV (max)", function () { |
|
| 22 | + describe('calculate()', function() { |
|
| 23 | + it("test exclusion double 13 IV (max)", function() { |
|
| 24 | 24 | $bulbasaur = (new Calculator())->calculate( |
| 25 | 25 | 'bulbasaur', 515, 59, 2500, 4, 3, ['def'] |
| 26 | 26 | ); |
@@ -35,7 +35,7 @@ discard block |
||
| 35 | 35 | ); |
| 36 | 36 | }); |
| 37 | 37 | |
| 38 | - it("test double 13 IV (max)", function () { |
|
| 38 | + it("test double 13 IV (max)", function() { |
|
| 39 | 39 | $gengar = (new Calculator())->calculate( |
| 40 | 40 | 'gengar', 1421, 74, 2500, 3, 3, ['atk', 'def'] |
| 41 | 41 | ); |
@@ -43,7 +43,7 @@ discard block |
||
| 43 | 43 | $level = new Level(20, 2500, 0.5974); |
| 44 | 44 | $combinaison = new IvCombinaison($level, 13, 13, 5); |
| 45 | 45 | |
| 46 | - $this->assert->equal((int)$gengar->getAveragePerfection()*10, (int)68.9*10); |
|
| 46 | + $this->assert->equal((int) $gengar->getAveragePerfection() * 10, (int) 68.9 * 10); |
|
| 47 | 47 | $this->assert->equal( |
| 48 | 48 | $gengar->getIvCombinaisons(), |
| 49 | 49 | new Collection([$combinaison]) |
@@ -51,8 +51,8 @@ discard block |
||
| 51 | 51 | }); |
| 52 | 52 | }); |
| 53 | 53 | |
| 54 | - describe('setRanges()', function () { |
|
| 55 | - it("100% iv pokemon", function () { |
|
| 54 | + describe('setRanges()', function() { |
|
| 55 | + it("100% iv pokemon", function() { |
|
| 56 | 56 | $calculator = new Calculator(); |
| 57 | 57 | $calculator->calculate( |
| 58 | 58 | 'mew', 5000, 500, 200, 4, 4, ['atk', 'def', 'hp'] |
@@ -63,7 +63,7 @@ discard block |
||
| 63 | 63 | $this->assert->equal($calculator->getStaminaRAnge(), [15]); |
| 64 | 64 | }); |
| 65 | 65 | |
| 66 | - it("double max iv pokemon", function () { |
|
| 66 | + it("double max iv pokemon", function() { |
|
| 67 | 67 | $calculator = new Calculator(); |
| 68 | 68 | $calculator->calculate( |
| 69 | 69 | 'mew', 5000, 500, 200, 3, 3, ['atk', 'hp'] |
@@ -74,7 +74,7 @@ discard block |
||
| 74 | 74 | $this->assert->equal($calculator->getStaminaRAnge(), range(13, 14)); |
| 75 | 75 | }); |
| 76 | 76 | |
| 77 | - it("normal iv pokemon", function () { |
|
| 77 | + it("normal iv pokemon", function() { |
|
| 78 | 78 | $calculator = new Calculator(); |
| 79 | 79 | $calculator->calculate( |
| 80 | 80 | 'mew', 5000, 500, 200, 3, 3, ['atk'] |
@@ -85,7 +85,7 @@ discard block |
||
| 85 | 85 | $this->assert->equal($calculator->getStaminaRAnge(), range(0, 13)); |
| 86 | 86 | }); |
| 87 | 87 | |
| 88 | - it("0% iv pokemon", function () { |
|
| 88 | + it("0% iv pokemon", function() { |
|
| 89 | 89 | $calculator = new Calculator(); |
| 90 | 90 | $calculator->calculate( |
| 91 | 91 | 'mew', 5000, 500, 200, 1, 1, ['atk', 'def', 'hp'] |
@@ -96,7 +96,7 @@ discard block |
||
| 96 | 96 | $this->assert->equal($calculator->getStaminaRAnge(), range(0, 7)); |
| 97 | 97 | }); |
| 98 | 98 | |
| 99 | - it("check wtf stats values", function () { |
|
| 99 | + it("check wtf stats values", function() { |
|
| 100 | 100 | $calculator = new Calculator(); |
| 101 | 101 | $calculator->calculate( |
| 102 | 102 | 'mew', -43, 500, 200, 6, 7, ['atk', 'def', 'hp'] |