Skip to content

Commit

Permalink
Fix the order
Browse files Browse the repository at this point in the history
  • Loading branch information
felipeelia committed Dec 11, 2024
1 parent 59a94d0 commit 28a17b8
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 10 deletions.
10 changes: 5 additions & 5 deletions tests/php/TestHealthCheckElasticsearch.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,10 @@ class TestHealthCheckElasticsearch extends WP_Ajax_UnitTestCase {
* @since 5.1.4
*/
public function set_up() {
parent::set_up();

remove_filter( 'query', [ $this, '_create_temporary_tables' ] );
remove_filter( 'query', [ $this, '_drop_temporary_tables' ] );

parent::set_up();
}

/**
Expand All @@ -37,10 +37,10 @@ public function set_up() {
* @since 5.1.4
*/
public function tear_down() {
parent::tear_down();

add_filter( 'query', [ $this, '_create_temporary_tables' ] );
add_filter( 'query', [ $this, '_drop_temporary_tables' ] );

parent::tear_down();
}

/**
Expand All @@ -55,7 +55,7 @@ public function testIsRegistered() {
/**
* Test ajax output.
*/
public function testAjaxOutput() {
public function testAjaxOutput_1() {
$admin_id = $this->factory->user->create( array( 'role' => 'administrator' ) );
wp_set_current_user( $admin_id );

Expand Down
2 changes: 1 addition & 1 deletion tests/php/TestSearchAlgorithm.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
/**
* Test abstract SearchAlgorithm class
*/
class TestSearchAlgorithm extends \ElasticPressTest\BaseTestCase {
class TestSearchAlgorithm extends BaseTestCase {
/**
* "Concrete" stub for the abstract class
*
Expand Down
8 changes: 4 additions & 4 deletions tests/php/includes/classes/BaseTestCase.php
Original file line number Diff line number Diff line change
Expand Up @@ -50,10 +50,10 @@ public function set_up() {

\ElasticPress\setup_roles();

parent::set_up();

remove_filter( 'query', [ $this, '_create_temporary_tables' ] );
remove_filter( 'query', [ $this, '_drop_temporary_tables' ] );

parent::set_up();
}

/**
Expand All @@ -63,10 +63,10 @@ public function set_up() {
* @since 5.1.4
*/
public function tear_down() {
parent::tear_down();

add_filter( 'query', [ $this, '_create_temporary_tables' ] );
add_filter( 'query', [ $this, '_drop_temporary_tables' ] );

parent::tear_down();
}

/**
Expand Down

0 comments on commit 28a17b8

Please sign in to comment.