From e12dce94add64763ad2378a74dd923f2123a37f8 Mon Sep 17 00:00:00 2001 From: frederik Date: Wed, 15 Oct 2014 16:19:06 +0200 Subject: [PATCH] php cs fixer: removed white space --- src/Gateway.php | 2 +- src/Message/PurchaseRequest.php | 8 ++++---- tests/Message/PurchaseRequestTest.php | 12 ++++++------ 3 files changed, 11 insertions(+), 11 deletions(-) diff --git a/src/Gateway.php b/src/Gateway.php index 1d58ce0..cfe2988 100644 --- a/src/Gateway.php +++ b/src/Gateway.php @@ -38,7 +38,7 @@ public function getApiKey() } /** - * @param string $value + * @param string $value * @return $this */ public function setApiKey($value) diff --git a/src/Message/PurchaseRequest.php b/src/Message/PurchaseRequest.php index 630cf9c..909a4b8 100644 --- a/src/Message/PurchaseRequest.php +++ b/src/Message/PurchaseRequest.php @@ -22,7 +22,7 @@ public function setMetadata($value) public function getData() { $this->validate('apiKey', 'amount', 'description', 'returnUrl'); - + $data = array(); $data['amount'] = $this->getAmount(); $data['description'] = $this->getDescription(); @@ -30,19 +30,19 @@ public function getData() $data['method'] = $this->getPaymentMethod(); $data['metadata'] = $this->getMetadata(); $data['issuer'] = $this->getIssuer(); - + $webhookUrl = $this->getNotifyUrl(); if (null !== $webhookUrl) { $data['webhookUrl'] = $webhookUrl; } - + return $data; } public function sendData($data) { $httpResponse = $this->sendRequest('POST', '/payments', $data); - + return $this->response = new PurchaseResponse($this, $httpResponse->json()); } } diff --git a/tests/Message/PurchaseRequestTest.php b/tests/Message/PurchaseRequestTest.php index 83ad669..0c209b8 100644 --- a/tests/Message/PurchaseRequestTest.php +++ b/tests/Message/PurchaseRequestTest.php @@ -37,9 +37,9 @@ public function testGetData() 'metadata' => 'meta', 'issuer' => 'my bank' )); - + $data = $this->request->getData(); - + $this->assertSame("12.00", $data['amount']); $this->assertSame('Description', $data['description']); $this->assertSame('https://www.example.com/return', $data['redirectUrl']); @@ -61,9 +61,9 @@ public function testGetDataWithWebhook() 'issuer' => 'my bank', 'notifyUrl' => 'https://www.example.com/hook' )); - + $data = $this->request->getData(); - + $this->assertSame("12.00", $data['amount']); $this->assertSame('Description', $data['description']); $this->assertSame('https://www.example.com/return', $data['redirectUrl']); @@ -78,7 +78,7 @@ public function testSendSuccess() { $this->setMockHttpResponse('PurchaseSuccess.txt'); $response = $this->request->send(); - + $this->assertInstanceOf('Omnipay\Mollie\Message\PurchaseResponse', $response); $this->assertFalse($response->isSuccessful()); $this->assertTrue($response->isRedirect()); @@ -96,7 +96,7 @@ public function testSendFailure() { $this->setMockHttpResponse('PurchaseFailure.txt'); $response = $this->request->send(); - + $this->assertInstanceOf('Omnipay\Mollie\Message\PurchaseResponse', $response); $this->assertFalse($response->isSuccessful()); $this->assertFalse($response->isRedirect());