You are here

function ShoutboxUserAccessTest::_get_shout_id in Shoutbox 5

Same name and namespace in other branches
  1. 6 tests/shoutbox_user_access.test \ShoutboxUserAccessTest::_get_shout_id()

Helper function to get the shout id

2 calls to ShoutboxUserAccessTest::_get_shout_id()
ShoutboxUserAccessTest::testAdminUserAccess in tests/shoutbox_user_access.test
ShoutboxUserAccessTest::testShoutboxUserAccess in tests/shoutbox_user_access.test

File

tests/shoutbox_user_access.test, line 88
shoutbox unit test for shoutbox_user_access and shoutbox_is_user_owned

Class

ShoutboxUserAccessTest
@file shoutbox unit test for shoutbox_user_access and shoutbox_is_user_owned

Code

function _get_shout_id($shout) {
  $shout_id = db_result(db_query("SELECT shout_id FROM {shoutbox} WHERE nick = '%s' AND shout = '%s' ", $shout['nick'], $shout['message']));
  return $shout_id;
}