@@ -32,14 +32,14 @@ discard block |
||
32 | 32 | $this->data = ['foo' => 'bar']; |
33 | 33 | $this->privateKey = 'privateKey'; |
34 | 34 | |
35 | - $this->hmac = new HashHmac($this->privateKey,$this->algo); |
|
35 | + $this->hmac = new HashHmac($this->privateKey, $this->algo); |
|
36 | 36 | |
37 | 37 | } |
38 | 38 | |
39 | 39 | public function testHash() |
40 | 40 | { |
41 | 41 | $actual = $this->hmac->create($this->data); |
42 | - $expected = hash_hmac($this->algo, json_encode($this->data) , $this->privateKey); |
|
42 | + $expected = hash_hmac($this->algo, json_encode($this->data), $this->privateKey); |
|
43 | 43 | $result = $this->hmac->verify($actual, $expected); |
44 | 44 | $this->assertEquals(true, $result); |
45 | 45 | } |
@@ -47,7 +47,7 @@ discard block |
||
47 | 47 | public function testCompareHash() |
48 | 48 | { |
49 | 49 | $encodedHash = $this->hmac->create($this->data); |
50 | - $this->assertEquals(true, $this->auth->verify($encodedHash,$this->data)); |
|
50 | + $this->assertEquals(true, $this->auth->verify($encodedHash, $this->data)); |
|
51 | 51 | } |
52 | 52 | |
53 | 53 | public function testCompareHashInvalidAlgo() |