You are here

function CoderReviewStyleTest::testStyleConstants in Coder 7

Same name and namespace in other branches
  1. 7.2 coder_review/tests/coder_review_style.test \CoderReviewStyleTest::testStyleConstants()

File

coder_review/tests/coder_review_style.test, line 53

Class

CoderReviewStyleTest

Code

function testStyleConstants() {
  $this
    ->assertCoderReviewPass('  $a = TRUE;');
  $this
    ->assertCoderReviewPass('  $atrue = "true";');
  $this
    ->assertCoderReviewFail('  $a = true;');
  $this
    ->assertCoderReviewFail('  $a =true;');
  $this
    ->assertCoderReviewFail('  if ($a == true) {');
  $this
    ->assertCoderReviewFail('    return false;');
}