-
Notifications
You must be signed in to change notification settings - Fork 2
Docker Compose
Willington Vega edited this page Aug 6, 2020
·
13 revisions
This page is an early draft on how to add Lumiere to a plugin (particularly payment gateways) to run the shared tests using the docker compose environment.
-
Add Lumiere repository to composer:
{ "type": "vcs", "url": "[email protected]:skyverge/lumiere.git" }
-
Require
skyverge/lumiere
as a development dependency:composer require codeception/module-db codeception/module-webdriver lucatume/wp-browser:2.4.8 skyverge/lumiere --dev
-
wp-bootstrap.sh
wp wc payment_gateway update {gateway_id} --enabled=true --user=admin
wp option patch insert woocommerce_{gateway_id}_settings debug_mode "log"
wp option patch insert woocommerce_{gateway_id}_settings transaction_type "authorization"
wp option patch insert woocommerce_{gateway_id}_settings charge_virtual_orders "yes"
wp option patch insert woocommerce_{gateway_id}_settings enable_paid_capture "yes"
wp option patch insert woocommerce_{gateway_id}_settings tokenization "yes"
wp option patch insert woocommerce_{gateway_id}_settings environment "test"
# set gateway specific configuration options
-
_support/Traits/PaymentGatewayMethods.php
example -
bootstrap.php
andcodeception.dist.yml
-
The main extension points are the abstract methods (get_gateway , get_plugin ), place_order , get_credit_cards_data , get_payment_tokens_data.