Skip to content

Commit

Permalink
Fix MobileRedirection tests that should not have previously passed
Browse files Browse the repository at this point in the history
  • Loading branch information
westonruter committed Nov 20, 2020
1 parent 48abd76 commit a418cc9
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions tests/php/src/MobileRedirectionTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@ public function test_redirect_on_transitional_and_not_available() {
AMP_Options_Manager::update_option( Option::THEME_SUPPORT, AMP_Theme_Support::TRANSITIONAL_MODE_SLUG );
AMP_Options_Manager::update_option( Option::ALL_TEMPLATES_SUPPORTED, false );
AMP_Options_Manager::update_option( Option::SUPPORTED_TEMPLATES, [ 'is_author' ] );
$this->go_to( amp_add_paired_endpoint( '/' ) );
$this->go_to( '/' );
$this->assertFalse( amp_is_canonical() );
$this->assertFalse( amp_is_available() );
$this->instance->redirect();
Expand Down Expand Up @@ -190,7 +190,8 @@ public function test_redirect_when_server_side_and_not_applicable() {
add_filter( 'amp_mobile_client_side_redirection', '__return_false' );
add_filter( 'amp_pre_is_mobile', '__return_false' );

$this->go_to( amp_add_paired_endpoint( '/' ) );
$this->go_to( '/' );

$this->assertFalse( amp_is_request() );
$this->assertFalse( $this->instance->is_mobile_request() );

Expand Down

0 comments on commit a418cc9

Please sign in to comment.