Fix the tests

This commit is contained in:
Narek Zakarian 2022-11-02 19:06:17 +04:00
parent 103a8911e0
commit 156acbf32c
3 changed files with 3 additions and 3 deletions

View file

@ -141,7 +141,7 @@ class SettingsPageAssets {
/**
* Register assets for admin pages.
*/
private function register_admin_assets() {
private function register_admin_assets(): void {
wp_enqueue_style(
'ppcp-gateway-settings',
trailingslashit( $this->module_url ) . 'assets/css/gateway-settings.css',

View file

@ -514,7 +514,7 @@ $data_rows_html
/**
* Renders the DCC onboarding info.
*/
private function render_dcc_onboarding_info() {
private function render_dcc_onboarding_info(): void {
?>
<tr>
<th><?php esc_html_e( 'Onboarding', 'woocommerce-paypal-payments' ); ?></th>

View file

@ -16,7 +16,7 @@ class SettingsPagesAssetsTest extends TestCase
$modulePath = '/var/www/html/wp-content/plugins/woocommerce-paypal-payments/modules/ppcp-wc-gateway';
$subscriptionsHelper = Mockery::mock(SubscriptionHelper::class);
$testee = new SettingsPageAssets($moduleUrl, $modulePath, $subscriptionsHelper, '123', 'EUR', 'DE');
$testee = new SettingsPageAssets($moduleUrl, $modulePath, $subscriptionsHelper, '123', 'EUR', 'DE', true);
when('is_admin')
->justReturn(true);