You are here

function NotificationsContentTests::assertRowCount in Notifications 6.4

Same name and namespace in other branches
  1. 6.2 tests/notifications_content.test \NotificationsContentTests::assertRowCount()
  2. 6.3 tests/notifications_content.test \NotificationsContentTests::assertRowCount()
  3. 7 tests/notifications_content.test \NotificationsContentTests::assertRowCount()
1 call to NotificationsContentTests::assertRowCount()
NotificationsContentTests::testNotificationsContent in tests/notifications_content.test
Play with creating, retrieving, deleting a pair subscriptions

File

tests/notifications_content.test, line 288

Class

NotificationsContentTests

Code

function assertRowCount($table, $target, $message = 'We have the right number of rows in table') {
  $count = db_result(db_query("SELECT COUNT(*) FROM {" . $table . "}"));
  $this
    ->assertEqual($count, $target, $message . " ({$table}, {$target} = {$count})");
}