Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release v5.13.1 #699

Closed
wants to merge 17 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
},
"autoload-dev": {
"psr-4": {
"SkyVerge\\WooCommerce\\PluginFramework\\v5_13_0\\Tests\\": "tests/"
"SkyVerge\\WooCommerce\\PluginFramework\\v5_13_1\\Tests\\": "tests/"
}
},
"config": {
Expand Down
2 changes: 1 addition & 1 deletion tests/TestCase.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

namespace SkyVerge\WooCommerce\PluginFramework\v5_13_0\Tests;
namespace SkyVerge\WooCommerce\PluginFramework\v5_13_1\Tests;

use WP_Mock\Tools\TestCase as WpMockTestCase;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ class SV_WC_Framework_Gateway_Test_Plugin_Loader {
const MINIMUM_WC_VERSION = '3.0.9';

/** SkyVerge plugin framework version used by this plugin */
const FRAMEWORK_VERSION = '5.13.0';
const FRAMEWORK_VERSION = '5.13.1-dev.1';

/** the plugin name, for displaying notices */
const PLUGIN_NAME = 'WooCommerce Framework Gateway Test Plugin';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

namespace SkyVerge\WooCommerce\GatewayTestPlugin;

use SkyVerge\WooCommerce\PluginFramework\v5_13_0 as Framework;
use SkyVerge\WooCommerce\PluginFramework\v5_13_1 as Framework;

defined( 'ABSPATH' ) or exit;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

namespace SkyVerge\WooCommerce\GatewayTestPlugin;

use SkyVerge\WooCommerce\PluginFramework\v5_13_0 as Framework;
use SkyVerge\WooCommerce\PluginFramework\v5_13_1 as Framework;

defined( 'ABSPATH' ) or exit;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php
namespace SkyVerge\WooCommerce\GatewayTestPlugin;

use SkyVerge\WooCommerce\PluginFramework\v5_13_0 as Framework;
use SkyVerge\WooCommerce\PluginFramework\v5_13_1 as Framework;

defined( 'ABSPATH' ) or exit;

Expand Down
2 changes: 1 addition & 1 deletion tests/_support/plugins/test-plugin/includes/API.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php
namespace SkyVerge\WooCommerce\TestPlugin;

use SkyVerge\WooCommerce\PluginFramework\v5_13_0 as Framework;
use SkyVerge\WooCommerce\PluginFramework\v5_13_1 as Framework;

defined( 'ABSPATH' ) or exit;

Expand Down
2 changes: 1 addition & 1 deletion tests/_support/plugins/test-plugin/includes/Gateway.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php
namespace SkyVerge\WooCommerce\TestPlugin;

use SkyVerge\WooCommerce\PluginFramework\v5_13_0 as Framework;
use SkyVerge\WooCommerce\PluginFramework\v5_13_1 as Framework;

defined( 'ABSPATH' ) or exit;

Expand Down
2 changes: 1 addition & 1 deletion tests/_support/plugins/test-plugin/includes/Plugin.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php
namespace SkyVerge\WooCommerce\TestPlugin;

use SkyVerge\WooCommerce\PluginFramework\v5_13_0 as Framework;
use SkyVerge\WooCommerce\PluginFramework\v5_13_1 as Framework;

defined( 'ABSPATH' ) or exit;

Expand Down
2 changes: 1 addition & 1 deletion tests/_support/plugins/test-plugin/test-plugin.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ class SV_WC_Framework_Test_Plugin_Loader {
const MINIMUM_WC_VERSION = '3.0.9';

/** SkyVerge plugin framework version used by this plugin */
const FRAMEWORK_VERSION = '5.13.0';
const FRAMEWORK_VERSION = '5.13.1-dev.1';

/** the plugin name, for displaying notices */
const PLUGIN_NAME = 'WooCommerce Framework Test Plugin';
Expand Down
4 changes: 4 additions & 0 deletions tests/bootstrap.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,10 @@
require_once PLUGIN_ROOT_DIR.'/woocommerce/class-sv-wc-plugin-exception.php';
require_once PLUGIN_ROOT_DIR.'/woocommerce/Enums/Traits/EnumTrait.php';
require_once PLUGIN_ROOT_DIR.'/woocommerce/Enums/PaymentFormContext.php';
require_once PLUGIN_ROOT_DIR.'/woocommerce/Traits/CanGetNewInstanceTrait.php';
require_once PLUGIN_ROOT_DIR.'/woocommerce/Traits/CanConvertToArrayTrait.php';
require_once PLUGIN_ROOT_DIR.'/woocommerce/Traits/IsSingletonTrait.php';
require_once PLUGIN_ROOT_DIR.'/woocommerce/Helpers/ArrayHelper.php';

WP_Mock::setUsePatchwork(true);
WP_Mock::bootstrap();
Expand Down
10 changes: 5 additions & 5 deletions tests/integration/API/CacheableAPIBaseTest.php
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
<?php

use SkyVerge\WooCommerce\PluginFramework\v5_13_0 as Framework;
use SkyVerge\WooCommerce\PluginFramework\v5_13_0\API\Abstract_Cacheable_API_Base;
use SkyVerge\WooCommerce\PluginFramework\v5_13_0\API\Traits\Cacheable_Request_Trait;
use SkyVerge\WooCommerce\PluginFramework\v5_13_0\SV_WC_API_JSON_Request;
use SkyVerge\WooCommerce\PluginFramework\v5_13_0\SV_WC_API_Request;
use SkyVerge\WooCommerce\PluginFramework\v5_13_1 as Framework;
use SkyVerge\WooCommerce\PluginFramework\v5_13_1\API\Abstract_Cacheable_API_Base;
use SkyVerge\WooCommerce\PluginFramework\v5_13_1\API\Traits\Cacheable_Request_Trait;
use SkyVerge\WooCommerce\PluginFramework\v5_13_1\SV_WC_API_JSON_Request;
use SkyVerge\WooCommerce\PluginFramework\v5_13_1\SV_WC_API_Request;

if ( ! defined( 'ABSPATH' ) ) {
define( 'ABSPATH', true );
Expand Down
6 changes: 3 additions & 3 deletions tests/integration/DependenciesTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
/**
* Tests for the SV_WC_Plugin_Dependencies class.
*
* @see \SkyVerge\WooCommerce\PluginFramework\v5_13_0\SV_WC_Plugin_Dependencies
* @see \SkyVerge\WooCommerce\PluginFramework\v5_13_1\SV_WC_Plugin_Dependencies
*/
class DependenciesTest extends \Codeception\TestCase\WPTestCase {

Expand Down Expand Up @@ -31,7 +31,7 @@ protected function _after() {


/**
* @see \SkyVerge\WooCommerce\PluginFramework\v5_13_0\SV_WC_Plugin_Dependencies::get_active_scripts_optimization_plugins()
* @see \SkyVerge\WooCommerce\PluginFramework\v5_13_1\SV_WC_Plugin_Dependencies::get_active_scripts_optimization_plugins()
*/
public function test_get_active_scripts_optimization_plugins() {

Expand All @@ -40,7 +40,7 @@ public function test_get_active_scripts_optimization_plugins() {


/**
* @see \SkyVerge\WooCommerce\PluginFramework\v5_13_0\SV_WC_Plugin_Dependencies::is_scripts_optimization_plugin_active()
* @see \SkyVerge\WooCommerce\PluginFramework\v5_13_1\SV_WC_Plugin_Dependencies::is_scripts_optimization_plugin_active()
*/
public function test_is_scripts_optimization_plugin_active() {

Expand Down
4 changes: 2 additions & 2 deletions tests/integration/HelperTest.php
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
<?php

use SkyVerge\WooCommerce\PluginFramework\v5_13_0 as Framework;
use SkyVerge\WooCommerce\PluginFramework\v5_13_1 as Framework;

/**
* Tests for the helper class.
*
* @see \SkyVerge\WooCommerce\PluginFramework\v5_13_0\SV_WC_Plugin_Compatibility
* @see \SkyVerge\WooCommerce\PluginFramework\v5_13_1\SV_WC_Plugin_Compatibility
*/
class HelperTest extends \Codeception\TestCase\WPTestCase {

Expand Down
6 changes: 3 additions & 3 deletions tests/integration/PluginTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
/**
* Tests for the base plugin class.
*
* @see \SkyVerge\WooCommerce\PluginFramework\v5_13_0\SV_WC_Plugin
* @see \SkyVerge\WooCommerce\PluginFramework\v5_13_1\SV_WC_Plugin
*/
class PluginTest extends \Codeception\TestCase\WPTestCase {

Expand Down Expand Up @@ -152,7 +152,7 @@ public function test_get_framework_assets_path() {
*/
public function test_get_dependency_handler() {

$this->assertInstanceOf( '\SkyVerge\WooCommerce\PluginFramework\v5_13_0\SV_WC_Plugin_Dependencies', $this->get_plugin()->get_dependency_handler() );
$this->assertInstanceOf( '\SkyVerge\WooCommerce\PluginFramework\v5_13_1\SV_WC_Plugin_Dependencies', $this->get_plugin()->get_dependency_handler() );
}


Expand All @@ -161,7 +161,7 @@ public function test_get_dependency_handler() {
*/
public function test_get_lifecycle_handler() {

$this->assertInstanceOf( '\SkyVerge\WooCommerce\PluginFramework\v5_13_0\Plugin\Lifecycle', $this->get_plugin()->get_lifecycle_handler() );
$this->assertInstanceOf( '\SkyVerge\WooCommerce\PluginFramework\v5_13_1\Plugin\Lifecycle', $this->get_plugin()->get_lifecycle_handler() );
}


Expand Down
10 changes: 5 additions & 5 deletions tests/integration/REST_API/Controllers/SettingsTest.php
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
<?php

use SkyVerge\WooCommerce\PluginFramework\v5_13_0\REST_API\Controllers\Settings;
use SkyVerge\WooCommerce\PluginFramework\v5_13_0\Settings_API\Abstract_Settings;
use SkyVerge\WooCommerce\PluginFramework\v5_13_0\Settings_API\Setting;
use SkyVerge\WooCommerce\PluginFramework\v5_13_0\Settings_API\Control;
use SkyVerge\WooCommerce\PluginFramework\v5_13_1\REST_API\Controllers\Settings;
use SkyVerge\WooCommerce\PluginFramework\v5_13_1\Settings_API\Abstract_Settings;
use SkyVerge\WooCommerce\PluginFramework\v5_13_1\Settings_API\Setting;
use SkyVerge\WooCommerce\PluginFramework\v5_13_1\Settings_API\Control;

/**
* Tests for the Settings class.
*
* @see \SkyVerge\WooCommerce\PluginFramework\v5_13_0\REST_API\Controllers\Settings
* @see \SkyVerge\WooCommerce\PluginFramework\v5_13_1\REST_API\Controllers\Settings
*/
class SettingsTest extends \Codeception\TestCase\WPTestCase {

Expand Down
8 changes: 4 additions & 4 deletions tests/integration/REST_API/RESTAPITest.php
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
<?php

use SkyVerge\WooCommerce\PluginFramework\v5_13_0 as Framework;
use SkyVerge\WooCommerce\PluginFramework\v5_13_0\Settings_API\Abstract_Settings;
use SkyVerge\WooCommerce\PluginFramework\v5_13_0\SV_WC_Helper;
use SkyVerge\WooCommerce\PluginFramework\v5_13_1 as Framework;
use SkyVerge\WooCommerce\PluginFramework\v5_13_1\Settings_API\Abstract_Settings;
use SkyVerge\WooCommerce\PluginFramework\v5_13_1\SV_WC_Helper;

/**
* Tests for the REST_API class.
*
* @see \SkyVerge\WooCommerce\PluginFramework\v5_13_0\REST_API
* @see \SkyVerge\WooCommerce\PluginFramework\v5_13_1\REST_API
*/
class RESTAPITest extends \Codeception\TestCase\WPTestCase {

Expand Down
4 changes: 2 additions & 2 deletions tests/integration/SV_WC_Payment_Gateway_Helper_Test.php
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
<?php

use SkyVerge\WooCommerce\PluginFramework\v5_13_0\SV_WC_Payment_Gateway_Helper;
use SkyVerge\WooCommerce\PluginFramework\v5_13_1\SV_WC_Payment_Gateway_Helper;

/**
* Tests for the Payment Gateway Helper class.
*
* @see \SkyVerge\WooCommerce\PluginFramework\v5_13_0\SV_WC_Payment_Gateway_Helper
* @see \SkyVerge\WooCommerce\PluginFramework\v5_13_1\SV_WC_Payment_Gateway_Helper
*/
class SV_WC_Payment_Gateway_Helper_Test extends \Codeception\TestCase\WPTestCase {

Expand Down
12 changes: 6 additions & 6 deletions tests/integration/Settings_API/AbstractSettingsTest.php
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
<?php

use SkyVerge\WooCommerce\PluginFramework\v5_13_0 as Framework;
use SkyVerge\WooCommerce\PluginFramework\v5_13_0\Settings_API\Abstract_Settings;
use SkyVerge\WooCommerce\PluginFramework\v5_13_0\Settings_API\Setting;
use SkyVerge\WooCommerce\PluginFramework\v5_13_0\Settings_API\Control;
use SkyVerge\WooCommerce\PluginFramework\v5_13_0\SV_WC_Plugin_Exception;
use SkyVerge\WooCommerce\PluginFramework\v5_13_1 as Framework;
use SkyVerge\WooCommerce\PluginFramework\v5_13_1\Settings_API\Abstract_Settings;
use SkyVerge\WooCommerce\PluginFramework\v5_13_1\Settings_API\Setting;
use SkyVerge\WooCommerce\PluginFramework\v5_13_1\Settings_API\Control;
use SkyVerge\WooCommerce\PluginFramework\v5_13_1\SV_WC_Plugin_Exception;

/**
* Tests for the Abstract_Settings class.
*
* @see \SkyVerge\WooCommerce\PluginFramework\v5_13_0\Settings_API\Abstract_Settings
* @see \SkyVerge\WooCommerce\PluginFramework\v5_13_1\Settings_API\Abstract_Settings
*/
class AbstractSettingsTest extends \Codeception\TestCase\WPTestCase {

Expand Down
4 changes: 2 additions & 2 deletions tests/integration/Settings_API/SettingTest.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php

use SkyVerge\WooCommerce\PluginFramework\v5_13_0\Settings_API\Setting;
use SkyVerge\WooCommerce\PluginFramework\v5_13_0\SV_WC_Plugin_Exception;
use SkyVerge\WooCommerce\PluginFramework\v5_13_1\Settings_API\Setting;
use SkyVerge\WooCommerce\PluginFramework\v5_13_1\SV_WC_Plugin_Exception;

class SettingTest extends \Codeception\TestCase\WPTestCase {

Expand Down
2 changes: 1 addition & 1 deletion tests/integration/payment-gateway/GatewayPluginTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
/**
* Tests for the gateway plugin class.
*
* @see \SkyVerge\WooCommerce\PluginFramework\v5_13_0\SV_WC_Payment_Gateway_Plugin
* @see \SkyVerge\WooCommerce\PluginFramework\v5_13_1\SV_WC_Payment_Gateway_Plugin
*/
class GatewayPluginTest extends \Codeception\TestCase\WPTestCase {

Expand Down
8 changes: 4 additions & 4 deletions tests/integration/payment-gateway/MyPaymentMethodsTest.php
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
<?php

use SkyVerge\WooCommerce\PluginFramework\v5_13_0\SV_WC_Payment_Gateway_My_Payment_Methods;
use SkyVerge\WooCommerce\PluginFramework\v5_13_0\SV_WC_Payment_Gateway_Plugin;
use SkyVerge\WooCommerce\PluginFramework\v5_13_1\SV_WC_Payment_Gateway_My_Payment_Methods;
use SkyVerge\WooCommerce\PluginFramework\v5_13_1\SV_WC_Payment_Gateway_Plugin;

/**
* Tests for the SV_WC_Payment_Gateway_My_Payment_Methods class.
*
* @see \SkyVerge\WooCommerce\PluginFramework\v5_13_0\SV_WC_Payment_Gateway_My_Payment_Methods
* @see \SkyVerge\WooCommerce\PluginFramework\v5_13_1\SV_WC_Payment_Gateway_My_Payment_Methods
*/
class MyPaymentMethodsTest extends \Codeception\TestCase\WPTestCase {

Expand Down Expand Up @@ -116,7 +116,7 @@ public function test_render_js() {
$payment_methods->render_js();

$this->assertStringContainsString( 'function load_gateway_test_plugin_payment_methods_handler', $wc_queued_js );
$this->assertStringContainsString( 'window.jQuery( document.body ).on( \'sv_wc_payment_methods_handler_v5_13_0_loaded\', load_gateway_test_plugin_payment_methods_handler );', $wc_queued_js );
$this->assertStringContainsString( 'window.jQuery( document.body ).on( \'sv_wc_payment_methods_handler_v5_13_1_loaded\', load_gateway_test_plugin_payment_methods_handler );', $wc_queued_js );
}


Expand Down
6 changes: 3 additions & 3 deletions tests/integration/payment-gateway/PaymentFormTest.php
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
<?php

use SkyVerge\WooCommerce\PluginFramework\v5_13_0\SV_WC_Payment_Gateway_Payment_Form;
use SkyVerge\WooCommerce\PluginFramework\v5_13_1\SV_WC_Payment_Gateway_Payment_Form;

/**
* Tests for the SV_WC_Payment_Gateway_Payment_Form class.
*
* @see \SkyVerge\WooCommerce\PluginFramework\v5_13_0\SV_WC_Payment_Gateway_Payment_Form
* @see \SkyVerge\WooCommerce\PluginFramework\v5_13_1\SV_WC_Payment_Gateway_Payment_Form
*/
class PaymentFormTest extends \Codeception\TestCase\WPTestCase {

Expand Down Expand Up @@ -90,7 +90,7 @@ public function test_render_js() {
$this->get_plugin()->get_gateway()->get_payment_form_instance()->render_js();

$this->assertStringContainsString( 'function load_test_gateway_payment_form_handler', $wc_queued_js );
$this->assertStringContainsString( 'window.jQuery( document.body ).on( \'sv_wc_payment_form_handler_v5_13_0_loaded\', load_test_gateway_payment_form_handler );', $wc_queued_js );
$this->assertStringContainsString( 'window.jQuery( document.body ).on( \'sv_wc_payment_form_handler_v5_13_1_loaded\', load_test_gateway_payment_form_handler );', $wc_queued_js );
}


Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
<?php

use \SkyVerge\WooCommerce\PluginFramework\v5_13_0 as Framework;
use \SkyVerge\WooCommerce\PluginFramework\v5_13_1 as Framework;

/**
* Tests for the payment token object
*
* @see \SkyVerge\WooCommerce\PluginFramework\v5_13_0\SV_WC_Payment_Gateway_Payment_Token
* @see \SkyVerge\WooCommerce\PluginFramework\v5_13_1\SV_WC_Payment_Gateway_Payment_Token
*/
class SV_WC_Payment_Gateway_Payment_Token_Test extends \Codeception\TestCase\WPTestCase {

Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
<?php

use \SkyVerge\WooCommerce\PluginFramework\v5_13_0 as Framework;
use \SkyVerge\WooCommerce\PluginFramework\v5_13_1 as Framework;

/**
* Tests for the payment tokens handler object
*
* @see \SkyVerge\WooCommerce\PluginFramework\v5_13_0\SV_WC_Payment_Gateway_Payment_Tokens_Handler
* @see \SkyVerge\WooCommerce\PluginFramework\v5_13_1\SV_WC_Payment_Gateway_Payment_Tokens_Handler
*/
class SV_WC_Payment_Gateway_Payment_Tokens_Handler_Test extends \Codeception\TestCase\WPTestCase {

Expand Down
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
<?php

use SkyVerge\WooCommerce\PluginFramework\v5_13_0\SV_WC_Payment_Gateway_Plugin;
use SkyVerge\WooCommerce\PluginFramework\v5_13_0\SV_WC_Payment_Gateway_Apple_Pay;
use SkyVerge\WooCommerce\PluginFramework\v5_13_0\SV_WC_Payment_Gateway_Apple_Pay_Frontend;
use SkyVerge\WooCommerce\PluginFramework\v5_13_1\SV_WC_Payment_Gateway_Plugin;
use SkyVerge\WooCommerce\PluginFramework\v5_13_1\SV_WC_Payment_Gateway_Apple_Pay;
use SkyVerge\WooCommerce\PluginFramework\v5_13_1\SV_WC_Payment_Gateway_Apple_Pay_Frontend;

/**
* Tests for the SV_WC_Payment_Gateway_Apple_Pay_Frontend class.
*
* @see \SkyVerge\WooCommerce\PluginFramework\v5_13_0\SV_WC_Payment_Gateway_Apple_Pay_Frontend
* @see \SkyVerge\WooCommerce\PluginFramework\v5_13_1\SV_WC_Payment_Gateway_Apple_Pay_Frontend
*/
class ApplePayFrontendTest extends \Codeception\TestCase\WPTestCase {

Expand Down Expand Up @@ -106,7 +106,7 @@ public function test_enqueue_js_handler() {
$method->invokeArgs( $frontend_instance, [[]] );

$this->assertStringContainsString( 'function load_test_gateway_apple_pay_handler', $wc_queued_js );
$this->assertStringContainsString( 'window.jQuery( document.body ).on( \'sv_wc_apple_pay_handler_v5_13_0_loaded\', load_test_gateway_apple_pay_handler );', $wc_queued_js );
$this->assertStringContainsString( 'window.jQuery( document.body ).on( \'sv_wc_apple_pay_handler_v5_13_1_loaded\', load_test_gateway_apple_pay_handler );', $wc_queued_js );
}


Expand Down
Loading
Loading