Skip to content

Commit

Permalink
final one?
Browse files Browse the repository at this point in the history
  • Loading branch information
obenland committed Nov 12, 2023
1 parent 942183f commit 0e7fe6a
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions tests/test-ajax-requests.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ public function test_logged_in_user_can_access() {
} catch ( WPAjaxDieContinueException $exception ) {
// We expect this exception to be thrown.
}
var_dump( $this->_last_response );

// Assert that the response contains the post title.
$this->assertSame( 'Sample Post Title', $this->_last_response );

Expand Down Expand Up @@ -96,11 +96,11 @@ public function test_invalid_nonce_for_logged_in_user() {
// Make the request.
try {
$this->_handleAjax( 'wp-search-suggest' );
} catch ( WPAjaxDieContinueException $exception ) {
} catch ( WPAjaxDieStopException $exception ) {
// We expect this exception to be thrown.
}

// Assert that the response contains an error message.
$this->expectExceptionMessage( '-1' );
$this->assertSame( '-1', $this->_last_response );
}
}

0 comments on commit 0e7fe6a

Please sign in to comment.