1.20.x database_test.test DatabaseRegressionTestCase::testDBTableExists()

Test the db_table_exists() function.

File

modules/simpletest/tests/database_test.test, line 2802
Database tests.

Class

DatabaseRegressionTestCase
Regression tests.

Code

function testDBTableExists() {
  $this->assertIdentical(TRUE, db_table_exists('node'), 'Returns true for existent table.');
  $this->assertIdentical(FALSE, db_table_exists('nosuchtable'), 'Returns false for nonexistent table.');
}