function TestBase::deleteAssert

Delete an assertion record by message ID.

Parameters

$message_id: Message ID of the assertion to delete.

Return value

TRUE if the assertion was deleted, FALSE otherwise.

See also

\Drupal\simpletest\TestBase::insertAssert()

1 call to TestBase::deleteAssert()
TestBase::run in core/modules/simpletest/src/TestBase.php
Run all tests in this class.

File

core/modules/simpletest/src/TestBase.php, line 436

Class

TestBase
Base class for Drupal tests.

Namespace

Drupal\simpletest

Code

public static function deleteAssert($message_id) {
    // We can't use storeAssertion() because this method is static.
    return (bool) self::getDatabaseConnection()->delete('simpletest')
        ->condition('message_id', $message_id)
        ->execute();
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.