fix: removed live explat test (#46818)

This commit is contained in:
RJ 2024-04-24 18:51:49 +12:00 committed by GitHub
parent eab9d115d4
commit a0701f6ea5
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 7 additions and 11 deletions

View File

@ -0,0 +1,5 @@
Significance: patch
Type: fix
Removed explat test that calls live explat server

View File

@ -51,7 +51,7 @@ class Experimental_Abtest_Test extends WC_Unit_Test_Case {
}
/**
* Tests retrieve the test variation when consent is false
* Tests retrieve the default control variation when consent is false
*/
public function test_get_variation_return_control_when_no_consent() {
$exp = new Experimental_Abtest( 'anon', 'platform', false );
@ -62,7 +62,7 @@ class Experimental_Abtest_Test extends WC_Unit_Test_Case {
}
/**
* Tests retrieve the test variation when consent is false
* Tests retrieve the treatment variation when consent is true and experiment name is valid
*/
public function test_get_variation() {
delete_transient( 'abtest_variation_control' );
@ -104,15 +104,6 @@ class Experimental_Abtest_Test extends WC_Unit_Test_Case {
);
}
/**
* Test get_variation with valid experiment name.
*/
public function test_fetch_variation_with_valid_name() {
$exp = new Experimental_Abtest( 'anon', 'platform', true );
$variation = $exp->get_variation( 'valid_experiment_name_2' );
$this->assertNotInstanceOf( 'WP_Error', $variation );
}
/**
* Test get_variation with invalid experiment name.
*/