Skip to content

Commit

Permalink
styleci
Browse files Browse the repository at this point in the history
  • Loading branch information
Recca Tsai committed Jan 18, 2017
1 parent e6924c0 commit b14774a
Show file tree
Hide file tree
Showing 8 changed files with 6 additions and 12 deletions.
5 changes: 2 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ The Payum extension to rapidly build new extensions.
$ composer create-project payum-tw/ecpay
```

2. Replace all occurrences of `payum` with your vendor name. It may be your github name, for now let's say you choose: `acme`.
2. Replace all occurrences of `payum` with your vendor name. It may be your github name, for now let's say you choose: `ecpay`.
3. Replace all occurrences of `ecpay` with a payment gateway name. For example Stripe, Paypal etc. For now let's say you choose: `ecpay`.
4. Register a gateway factory to the payum's builder and create a gateway:

Expand All @@ -42,8 +42,7 @@ $payum = (new PayumBuilder)
'sandbox' => true,
])

->getPayum()
;
->getPayum();
```

5. While using the gateway implement all method where you get `Not implemented` exception:
Expand Down
1 change: 0 additions & 1 deletion src/Action/CancelAction.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

namespace PayumTW\Ecpay\Action;

use Payum\Core\Request\Sync;
use Payum\Core\Request\Cancel;
use Payum\Core\GatewayAwareTrait;
use Payum\Core\GatewayAwareInterface;
Expand Down
3 changes: 1 addition & 2 deletions src/Action/CaptureAction.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,18 +2,17 @@

namespace PayumTW\Ecpay\Action;

use Payum\Core\Request\Sync;
use Payum\Core\Request\Capture;
use Payum\Core\GatewayAwareTrait;
use Payum\Core\GatewayAwareInterface;
use Payum\Core\Action\ActionInterface;
use Payum\Core\Bridge\Spl\ArrayObject;
use Payum\Core\Request\GetHttpRequest;
use PayumTW\Ecpay\Action\Api\BaseApiAwareAction;
use PayumTW\Ecpay\Request\Api\CreateTransaction;
use Payum\Core\Exception\RequestNotSupportedException;
use Payum\Core\Security\GenericTokenFactoryAwareTrait;
use Payum\Core\Security\GenericTokenFactoryAwareInterface;
use PayumTW\Ecpay\Action\Api\BaseApiAwareAction;

class CaptureAction extends BaseApiAwareAction implements ActionInterface, GatewayAwareInterface, GenericTokenFactoryAwareInterface
{
Expand Down
2 changes: 1 addition & 1 deletion src/Action/CaptureLogisticsAction.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,11 @@
use Payum\Core\Action\ActionInterface;
use Payum\Core\Bridge\Spl\ArrayObject;
use Payum\Core\Request\GetHttpRequest;
use PayumTW\Ecpay\Action\Api\BaseApiAwareAction;
use PayumTW\Ecpay\Request\Api\CreateTransaction;
use Payum\Core\Exception\RequestNotSupportedException;
use Payum\Core\Security\GenericTokenFactoryAwareTrait;
use Payum\Core\Security\GenericTokenFactoryAwareInterface;
use PayumTW\Ecpay\Action\Api\BaseApiAwareAction;

class CaptureLogisticsAction extends BaseApiAwareAction implements ActionInterface, GatewayAwareInterface, GenericTokenFactoryAwareInterface
{
Expand Down
1 change: 0 additions & 1 deletion src/Action/NotifyAction.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

namespace PayumTW\Ecpay\Action;

use Payum\Core\Request\Sync;
use Payum\Core\Request\Notify;
use Payum\Core\GatewayAwareTrait;
use Payum\Core\Reply\HttpResponse;
Expand Down
1 change: 0 additions & 1 deletion src/Action/RefundAction.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

namespace PayumTW\Ecpay\Action;

use Payum\Core\Request\Sync;
use Payum\Core\Request\Refund;
use Payum\Core\GatewayAwareTrait;
use Payum\Core\GatewayAwareInterface;
Expand Down
1 change: 0 additions & 1 deletion src/Action/SyncAction.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
use Payum\Core\GatewayAwareInterface;
use Payum\Core\Action\ActionInterface;
use Payum\Core\Bridge\Spl\ArrayObject;
use Payum\Core\Request\GetHttpRequest;
use PayumTW\Ecpay\Request\Api\GetTransactionData;
use Payum\Core\Exception\RequestNotSupportedException;

Expand Down
4 changes: 2 additions & 2 deletions tests/Action/Api/CreateTransactionActionTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ public function test_api_http_post_redirect()
$request = m::spy('PayumTW\Ecpay\Request\Api\CreateTransaction');
$details = new ArrayObject([
'foo' => 'bar',
'GoodsAmount' => 1
'GoodsAmount' => 1,
]);
$endpoint = 'foo.endpoint';

Expand Down Expand Up @@ -120,7 +120,7 @@ public function test_logistics_api_when_isset_rtn_code()
$request = m::spy('PayumTW\Ecpay\Request\Api\CreateTransaction');
$details = new ArrayObject([
'RtnCode' => '300',
'GoodsAmount' => 1
'GoodsAmount' => 1,
]);

/*
Expand Down

0 comments on commit b14774a

Please sign in to comment.