Completed
Pull Request — master (#11)
by Siwapun
09:20
created
test/Asset/PlainObjectAsset.php 1 patch
Indentation   +13 added lines, -13 removed lines patch added patch discarded remove patch
@@ -3,21 +3,21 @@
 block discarded – undo
3 3
 
4 4
 class PlainObjectAsset
5 5
 {
6
-  private $data;
6
+    private $data;
7 7
 
8
-  /**
9
-   * @return mixed
10
-   */
11
-  public function getData()
12
-  {
8
+    /**
9
+     * @return mixed
10
+     */
11
+    public function getData()
12
+    {
13 13
     return $this->data;
14
-  }
14
+    }
15 15
 
16
-  /**
17
-   * @param mixed $data
18
-   */
19
-  public function setData($data): void
20
-  {
16
+    /**
17
+     * @param mixed $data
18
+     */
19
+    public function setData($data): void
20
+    {
21 21
     $this->data = $data;
22
-  }
22
+    }
23 23
 }
Please login to merge, or discard this patch.
test/AllTest.php 2 patches
Indentation   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -6,27 +6,27 @@
 block discarded – undo
6 6
 
7 7
 class AllTest extends TestCase
8 8
 {
9
-  public function testAllAndExpectTrue()
10
-  {
9
+    public function testAllAndExpectTrue()
10
+    {
11 11
     $lessThan10 = function ($it) {
12
-      return $it < 10;
12
+        return $it < 10;
13 13
     };
14 14
     $this->assertTrue(all($lessThan10)([1, 2, 3, 4]));
15
-  }
15
+    }
16 16
 
17
-  public function testAllAndExpectFalse()
18
-  {
17
+    public function testAllAndExpectFalse()
18
+    {
19 19
     $lessThan10 = function ($it) {
20
-      return $it < 10;
20
+        return $it < 10;
21 21
     };
22 22
     $this->assertFalse(all($lessThan10)([1, 2, 3, 4, 20]));
23
-  }
23
+    }
24 24
 
25
-  public function testAllWithEmptyArray()
26
-  {
25
+    public function testAllWithEmptyArray()
26
+    {
27 27
     $predicate = function ($it) {
28
-      return true;
28
+        return true;
29 29
     };
30 30
     $this->assertFalse(all($predicate)([]));
31
-  }
31
+    }
32 32
 }
Please login to merge, or discard this patch.
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -8,7 +8,7 @@  discard block
 block discarded – undo
8 8
 {
9 9
   public function testAllAndExpectTrue()
10 10
   {
11
-    $lessThan10 = function ($it) {
11
+    $lessThan10 = function($it) {
12 12
       return $it < 10;
13 13
     };
14 14
     $this->assertTrue(all($lessThan10)([1, 2, 3, 4]));
@@ -16,7 +16,7 @@  discard block
 block discarded – undo
16 16
 
17 17
   public function testAllAndExpectFalse()
18 18
   {
19
-    $lessThan10 = function ($it) {
19
+    $lessThan10 = function($it) {
20 20
       return $it < 10;
21 21
     };
22 22
     $this->assertFalse(all($lessThan10)([1, 2, 3, 4, 20]));
@@ -24,7 +24,7 @@  discard block
 block discarded – undo
24 24
 
25 25
   public function testAllWithEmptyArray()
26 26
   {
27
-    $predicate = function ($it) {
27
+    $predicate = function($it) {
28 28
       return true;
29 29
     };
30 30
     $this->assertFalse(all($predicate)([]));
Please login to merge, or discard this patch.
test/AnyTest.php 2 patches
Indentation   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -7,27 +7,27 @@
 block discarded – undo
7 7
 class AnyTest extends TestCase
8 8
 {
9 9
 
10
-  public function testAnyAndExpectTrue()
11
-  {
10
+    public function testAnyAndExpectTrue()
11
+    {
12 12
     $lessThan2 = function ($it) {
13
-      return $it < 2;
13
+        return $it < 2;
14 14
     };
15 15
     $this->assertTrue(any($lessThan2)([1, 2, 3, 4]));
16
-  }
16
+    }
17 17
 
18
-  public function testAnyAndExpectFalse()
19
-  {
18
+    public function testAnyAndExpectFalse()
19
+    {
20 20
     $lessThan2 = function ($it) {
21
-      return $it < 2;
21
+        return $it < 2;
22 22
     };
23 23
     $this->assertFalse(any($lessThan2)([3, 4, 5, 6]));
24
-  }
24
+    }
25 25
 
26
-  public function testAnyWithEmptyArray()
27
-  {
26
+    public function testAnyWithEmptyArray()
27
+    {
28 28
     $predicate = function ($it) {
29
-      return true;
29
+        return true;
30 30
     };
31 31
     $this->assertFalse(any($predicate)([]));
32
-  }
32
+    }
33 33
 }
Please login to merge, or discard this patch.
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -9,7 +9,7 @@  discard block
 block discarded – undo
9 9
 
10 10
   public function testAnyAndExpectTrue()
11 11
   {
12
-    $lessThan2 = function ($it) {
12
+    $lessThan2 = function($it) {
13 13
       return $it < 2;
14 14
     };
15 15
     $this->assertTrue(any($lessThan2)([1, 2, 3, 4]));
@@ -17,7 +17,7 @@  discard block
 block discarded – undo
17 17
 
18 18
   public function testAnyAndExpectFalse()
19 19
   {
20
-    $lessThan2 = function ($it) {
20
+    $lessThan2 = function($it) {
21 21
       return $it < 2;
22 22
     };
23 23
     $this->assertFalse(any($lessThan2)([3, 4, 5, 6]));
@@ -25,7 +25,7 @@  discard block
 block discarded – undo
25 25
 
26 26
   public function testAnyWithEmptyArray()
27 27
   {
28
-    $predicate = function ($it) {
28
+    $predicate = function($it) {
29 29
       return true;
30 30
     };
31 31
     $this->assertFalse(any($predicate)([]));
Please login to merge, or discard this patch.
test/CurryNTest.php 2 patches
Indentation   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -7,23 +7,23 @@
 block discarded – undo
7 7
 class CurryNTest extends TestCase
8 8
 {
9 9
 
10
-  public function testCurryNWithInvokeFunctionDirectly()
11
-  {
10
+    public function testCurryNWithInvokeFunctionDirectly()
11
+    {
12 12
     $curriedReduce = curryN('array_reduce', 3);
13 13
     $add = function ($a, $b) {
14
-      return $a + $b;
14
+        return $a + $b;
15 15
     };
16 16
     $result = $curriedReduce([4,5,6], $add, 0);
17 17
     $this->assertEquals(15, $result);
18
-  }
18
+    }
19 19
 
20
-  public function testCurryNWithAutoCurry()
21
-  {
20
+    public function testCurryNWithAutoCurry()
21
+    {
22 22
     $curriedReduce = curryN('array_reduce', 3);
23 23
     $add = function ($a, $b) {
24
-      return $a + $b;
24
+        return $a + $b;
25 25
     };
26 26
     $result = $curriedReduce([4,5,6])($add)(0);
27 27
     $this->assertEquals(15, $result);
28
-  }
28
+    }
29 29
 }
Please login to merge, or discard this patch.
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -10,20 +10,20 @@
 block discarded – undo
10 10
   public function testCurryNWithInvokeFunctionDirectly()
11 11
   {
12 12
     $curriedReduce = curryN('array_reduce', 3);
13
-    $add = function ($a, $b) {
13
+    $add = function($a, $b) {
14 14
       return $a + $b;
15 15
     };
16
-    $result = $curriedReduce([4,5,6], $add, 0);
16
+    $result = $curriedReduce([4, 5, 6], $add, 0);
17 17
     $this->assertEquals(15, $result);
18 18
   }
19 19
 
20 20
   public function testCurryNWithAutoCurry()
21 21
   {
22 22
     $curriedReduce = curryN('array_reduce', 3);
23
-    $add = function ($a, $b) {
23
+    $add = function($a, $b) {
24 24
       return $a + $b;
25 25
     };
26
-    $result = $curriedReduce([4,5,6])($add)(0);
26
+    $result = $curriedReduce([4, 5, 6])($add)(0);
27 27
     $this->assertEquals(15, $result);
28 28
   }
29 29
 }
Please login to merge, or discard this patch.
test/PipeTest.php 2 patches
Indentation   +17 added lines, -17 removed lines patch added patch discarded remove patch
@@ -8,30 +8,30 @@
 block discarded – undo
8 8
 class PipeTest extends TestCase
9 9
 {
10 10
 
11
-  /**
12
-   * @throws \Exception
13
-   */
14
-  public function testPipeSingleMethod()
15
-  {
11
+    /**
12
+     * @throws \Exception
13
+     */
14
+    public function testPipeSingleMethod()
15
+    {
16 16
     $piped = pipe(
17
-      always(10)
17
+        always(10)
18 18
     );
19 19
     $this->assertEquals(10, $piped());
20
-  }
20
+    }
21 21
 
22
-  /**
23
-   * @throws \Exception
24
-   */
25
-  public function testPipeMultipleMethods()
26
-  {
22
+    /**
23
+     * @throws \Exception
24
+     */
25
+    public function testPipeMultipleMethods()
26
+    {
27 27
     $piped = pipe(
28
-      function ($a, $b) {
28
+        function ($a, $b) {
29 29
         return $a + $b;
30
-      },
31
-      function ($i) {
30
+        },
31
+        function ($i) {
32 32
         return $i * 10;
33
-      }
33
+        }
34 34
     );
35 35
     $this->assertEquals(30, $piped(1, 2));
36
-  }
36
+    }
37 37
 }
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -25,10 +25,10 @@
 block discarded – undo
25 25
   public function testPipeMultipleMethods()
26 26
   {
27 27
     $piped = pipe(
28
-      function ($a, $b) {
28
+      function($a, $b) {
29 29
         return $a + $b;
30 30
       },
31
-      function ($i) {
31
+      function($i) {
32 32
         return $i * 10;
33 33
       }
34 34
     );
Please login to merge, or discard this patch.
test/ConstructTest.php 1 patch
Indentation   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -8,18 +8,18 @@
 block discarded – undo
8 8
 class ConstructTest extends TestCase
9 9
 {
10 10
 
11
-  public function testFactoryMustReturnCorrectObjectType()
12
-  {
11
+    public function testFactoryMustReturnCorrectObjectType()
12
+    {
13 13
     $construct = construct()(PlainObjectAsset::class);
14 14
     $obj = $construct();
15 15
     $this->assertInstanceOf(PlainObjectAsset::class, $obj);
16
-  }
16
+    }
17 17
 
18
-  public function testFactoryMustAlwaysReturnNewObject()
19
-  {
18
+    public function testFactoryMustAlwaysReturnNewObject()
19
+    {
20 20
     $construct = construct()(PlainObjectAsset::class);
21 21
     $obj1 = $construct();
22 22
     $obj2 = $construct();
23 23
     $this->assertNotSame($obj1, $obj2);
24
-  }
24
+    }
25 25
 }
Please login to merge, or discard this patch.
test/DropFirstTest.php 2 patches
Indentation   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -7,8 +7,8 @@
 block discarded – undo
7 7
 
8 8
 class DropFirstTest extends TestCase
9 9
 {
10
-  public function testDropFirst()
11
-  {
10
+    public function testDropFirst()
11
+    {
12 12
     $this->assertEquals([2,3,4], dropFirst()([1,2,3,4]));
13
-  }
13
+    }
14 14
 }
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -9,6 +9,6 @@
 block discarded – undo
9 9
 {
10 10
   public function testDropFirst()
11 11
   {
12
-    $this->assertEquals([2,3,4], dropFirst()([1,2,3,4]));
12
+    $this->assertEquals([2, 3, 4], dropFirst()([1, 2, 3, 4]));
13 13
   }
14 14
 }
Please login to merge, or discard this patch.
test/ConcatTest.php 1 patch
Indentation   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -6,12 +6,12 @@
 block discarded – undo
6 6
 
7 7
 class ConcatTest extends TestCase
8 8
 {
9
-  public function testConcat()
10
-  {
9
+    public function testConcat()
10
+    {
11 11
     $firstArray = [1, 2, 3];
12 12
     $secondArray = [4, 5, 6];
13 13
     $expectedResult = [1, 2, 3, 4, 5, 6];
14 14
     $actualResult = concat($firstArray)($secondArray);
15 15
     $this->assertEquals($expectedResult, $actualResult);
16
-  }
16
+    }
17 17
 }
Please login to merge, or discard this patch.
test/DivideTest.php 1 patch
Indentation   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -6,12 +6,12 @@
 block discarded – undo
6 6
 
7 7
 class DivideTest extends TestCase
8 8
 {
9
-  public function testDivide()
10
-  {
9
+    public function testDivide()
10
+    {
11 11
     $firstValue = 50;
12 12
     $secondValue = 10;
13 13
     $expectedResult = 5;
14 14
     $actualResult = divide($firstValue)($secondValue);
15 15
     $this->assertEquals($expectedResult, $actualResult);
16
-  }
16
+    }
17 17
 }
Please login to merge, or discard this patch.