Skip to content

Commit afad966

Browse files
Tests: Improve assertions in object_ids null and zero tests for clarity
1 parent b38ba2a commit afad966

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

tests/phpunit/tests/term/query.php

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -452,7 +452,6 @@ public function test_object_ids_cache_should_be_invalidated_by_term_relationship
452452
}
453453

454454
/**
455-
*
456455
* @ticket 63256
457456
*/
458457
public function test_object_ids_null_should_return_all_terms() {
@@ -469,11 +468,10 @@ public function test_object_ids_null_should_return_all_terms() {
469468
)
470469
);
471470

472-
$this->assertSameSets( $terms, $query->terms );
471+
$this->assertSameSets( $terms, $query->terms, 'When object_ids is null, all terms should be returned without filtering.' );
473472
}
474473

475474
/**
476-
*
477475
* @ticket 63256
478476
*/
479477
public function test_object_ids_zero_should_be_treated_as_numeric() {
@@ -490,7 +488,7 @@ public function test_object_ids_zero_should_be_treated_as_numeric() {
490488
)
491489
);
492490

493-
$this->assertIsArray( $query->terms );
491+
$this->assertIsArray( $query->terms, 'When object_ids is 0, it should be treated as a numeric value and return an array.' );
494492
}
495493

496494
/**

0 commit comments

Comments
 (0)