public function UserCrudReactionTest::testUserDeactivate in Search API Saved Searches 8
Verifies correct reaction to the deactivation of a user account.
See also
search_api_saved_searches_user_update()
_search_api_saved_searches_deactivate_searches()
File
- tests/
src/ Kernel/ UserCrudReactionTest.php, line 171
Class
- UserCrudReactionTest
- Verifies that the module reacts correctly to user CRUD operations.
Namespace
Drupal\Tests\search_api_saved_searches\KernelCode
public function testUserDeactivate() {
$this->testUser
->block()
->save();
$this
->reloadSavedSearches();
$search = array_shift($this->savedSearches);
$this
->assertEquals(-1, $search
->get('notify_interval')->value);
// Verify that the other alerts were unaffected.
foreach ($this->savedSearches as $search) {
$this
->assertEquals(3600 * 24, $search
->get('notify_interval')->value);
}
}