function CoderReviewSQLTest::testSQLLowerCaseKeywords in Coder 7
Same name and namespace in other branches
- 7.2 coder_review/tests/coder_review_sql.test \CoderReviewSQLTest::testSQLLowerCaseKeywords()
File
- coder_review/
tests/ coder_review_sql.test, line 22
Class
Code
function testSQLLowerCaseKeywords() {
$this
->assertCoderReviewFail(' $sql = "select * from {node}";');
$this
->assertCoderReviewFail(' $sql = "insert into {node} (changed) VALUES (%d)";');
$this
->assertCoderReviewFail(' $sql = "delete from {node}";');
$this
->assertCoderReviewFail(' $sql = "update {node} set changed = now()";');
$this
->assertCoderReviewFail(' $var = t("select something from this");');
$this
->assertCoderReviewPass(' $var = t("update something");');
$this
->assertCoderReviewPass(' $var = t("insert something");');
$this
->assertCoderReviewPass(' $var = t("delete something");');
}