Skip to content
Merged
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
1 change: 0 additions & 1 deletion tests/EndToEnd/bundle/BundleCustomFieldsCest.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ public function _before(EndToEndTester $I)
// Activate Plugins.
$I->activateConvertKitPlugin($I);
$I->activateThirdPartyPlugin($I, 'membermouse-platform');
$I->memberMouseSetupPlugin($I);
}

/**
Expand Down
1 change: 0 additions & 1 deletion tests/EndToEnd/bundle/BundleTagCest.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ public function _before(EndToEndTester $I)
// Activate Plugins.
$I->activateConvertKitPlugin($I);
$I->activateThirdPartyPlugin($I, 'membermouse-platform');
$I->memberMouseSetupPlugin($I);
}

/**
Expand Down
1 change: 0 additions & 1 deletion tests/EndToEnd/general/SettingsCest.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ public function _before(EndToEndTester $I)
// Activate Plugins.
$I->activateConvertKitPlugin($I);
$I->activateThirdPartyPlugin($I, 'membermouse-platform');
$I->memberMouseSetupPlugin($I);
}

/**
Expand Down
1 change: 0 additions & 1 deletion tests/EndToEnd/member-update/MemberSubscribeCest.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ public function _before(EndToEndTester $I)
// Activate Plugins.
$I->activateConvertKitPlugin($I);
$I->activateThirdPartyPlugin($I, 'membermouse-platform');
$I->memberMouseSetupPlugin($I);
}

/**
Expand Down
1 change: 0 additions & 1 deletion tests/EndToEnd/member/MemberCustomFieldsCest.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ public function _before(EndToEndTester $I)
// Activate Plugins.
$I->activateConvertKitPlugin($I);
$I->activateThirdPartyPlugin($I, 'membermouse-platform');
$I->memberMouseSetupPlugin($I);
}

/**
Expand Down
1 change: 0 additions & 1 deletion tests/EndToEnd/member/MemberTagCest.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ public function _before(EndToEndTester $I)
// Activate Plugins.
$I->activateConvertKitPlugin($I);
$I->activateThirdPartyPlugin($I, 'membermouse-platform');
$I->memberMouseSetupPlugin($I);
}

/**
Expand Down
5 changes: 2 additions & 3 deletions tests/EndToEnd/product/ProductCustomFieldsCest.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ public function _before(EndToEndTester $I)
// Activate Plugins.
$I->activateConvertKitPlugin($I);
$I->activateThirdPartyPlugin($I, 'membermouse-platform');
$I->memberMouseSetupPlugin($I);
}

/**
Expand All @@ -50,8 +49,8 @@ public function testMemberCustomFieldsWhenProductPurchased(EndToEndTester $I)
$I->setupConvertKitPlugin(
$I,
[
'convertkit-mapping-product-1' => $_ENV['CONVERTKIT_API_TAG_ID'],
'custom_field_last_name' => 'last_name',
'convertkit-mapping-product-' . $productID => $_ENV['CONVERTKIT_API_TAG_ID'],
'custom_field_last_name' => 'last_name',
]
);

Expand Down
5 changes: 2 additions & 3 deletions tests/EndToEnd/product/ProductTagCest.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ public function _before(EndToEndTester $I)
// Activate Plugins.
$I->activateConvertKitPlugin($I);
$I->activateThirdPartyPlugin($I, 'membermouse-platform');
$I->memberMouseSetupPlugin($I);
}

/**
Expand All @@ -49,7 +48,7 @@ public function testMemberTaggedWhenProductPurchased(EndToEndTester $I)
$I->setupConvertKitPlugin(
$I,
[
'convertkit-mapping-product-1' => $_ENV['CONVERTKIT_API_TAG_ID'],
'convertkit-mapping-product-' . $productID => $_ENV['CONVERTKIT_API_TAG_ID'],
]
);

Expand Down Expand Up @@ -99,7 +98,7 @@ public function testMemberNotTaggedWhenProductPurchased(EndToEndTester $I)
$I->setupConvertKitPlugin(
$I,
[
'convertkit-mapping-product-1' => '',
'convertkit-mapping-product-' . $productID => '',
]
);

Expand Down
6,756 changes: 6,505 additions & 251 deletions tests/Support/Data/dump.sql

Large diffs are not rendered by default.

31 changes: 0 additions & 31 deletions tests/Support/Helper/MemberMouse.php
Original file line number Diff line number Diff line change
Expand Up @@ -233,37 +233,6 @@ public function memberMouseResumeMemberBundle($I, $emailAddress, $bundleName)
$I->memberMouseAcceptPopups($I, 2);
}

/**
* Helper method to setup the MemberMouse Plugin for tests
*
* @since 1.2.0
*
* @param EndToEndTester $I Tester.
*/
public function memberMouseSetupPlugin($I)
{
// Define test payment service.
$I->dontHaveInDatabase('wp_mm_payment_services', [ 'token' => 'TEST' ]);
$I->haveInDatabase(
'wp_mm_payment_services',
[
'id' => 14,
'token' => 'TEST',
'name' => serialize(
[
'mode' => 'always-override',
'testProcessorOverrideKey' => '',
'productionProcessorOverrideKey' => '',
]
),
'active' => 1,
]
);

// Don't use MemberMouse login page, as it breaks some tests when cleaning up / deactivating Plugins.
$I->haveOptionInDatabase('mm-option-use-mm-login-page', '0');
}

/**
* Helper method to log out from WordPress when MemberMouse is enabled.
* We don't use logOut() as MemberMouse hijacks the logout process with a redirect,
Expand Down