diff --git a/config/config.php b/config/config.php new file mode 100644 index 00000000..c92d2fdb --- /dev/null +++ b/config/config.php @@ -0,0 +1,9 @@ +import('config/**/*.php'); +}; diff --git a/config/config/sylius_fixtures.php b/config/config/sylius_fixtures.php new file mode 100644 index 00000000..0c356aa0 --- /dev/null +++ b/config/config/sylius_fixtures.php @@ -0,0 +1,33 @@ +suites('default') + ->fixtures('payment_method', [ + 'options' => [ + 'custom' => [ + 'tpay' => [ + 'code' => 'tpay', + 'name' => 'Tpay', + 'gatewayFactory' => 'tpay', + 'gatewayName' => 'Tpay', + 'gatewayConfig' => [ + 'client_id' => '%env(string:TPAY_CLIENT_ID)%', + 'client_secret' => '%env(string:TPAY_CLIENT_SECRET)%', + 'production_mode' => false, + ], + 'channels' => [ + 'FASHION_WEB', + ], + 'enabled' => true, + ], + ], + ], + ]) + ; +}; diff --git a/config/services.php b/config/services.php index 04f84577..bba59be9 100644 --- a/config/services.php +++ b/config/services.php @@ -9,6 +9,8 @@ $parameters = $container->parameters(); $parameters + ->set('env(TPAY_CLIENT_ID)', '') + ->set('env(TPAY_CLIENT_SECRET)', '') ->set('commerce_weavers_tpay.payum.create_transaction.success_route', 'sylius_shop_order_thank_you') ->set('commerce_weavers_tpay.payum.create_transaction.error_route', 'sylius_shop_order_thank_you') ->set('commerce_weavers_tpay.payum.create_transaction.notify_route', 'commerce_weavers_tpay_payment_notification') diff --git a/tests/Application/config/packages/commerce_weavers_tpay.yaml b/tests/Application/config/packages/commerce_weavers_tpay.yaml new file mode 100644 index 00000000..5defcc58 --- /dev/null +++ b/tests/Application/config/packages/commerce_weavers_tpay.yaml @@ -0,0 +1,2 @@ +imports: + - { resource: "@CommerceWeaversSyliusTpayPlugin/config/config.php" }