public function PatternsParserTestCase::check_valid_semantics in Patterns 7.2
File
- tests/
parser/ parser.test, line 67 - SimpleTests for the Taxonomy component of Patterns.
Class
- PatternsParserTestCase
- @file SimpleTests for the Taxonomy component of Patterns.
Code
public function check_valid_semantics($pattern) {
$scan = $this
->scan_pattern($pattern);
$analysis = $this
->analyze_scan($scan, PATTERNS_VALIDATE_SYNTAX);
$this
->assertEqual(count($analysis), 0, t('No error message generated while parsing syntactically valid pattern.'));
$analysis = $this
->analyze_scan($scan, PATTERNS_VALIDATE_ALL);
$this
->assertEqual(count($analysis), 0, t('Error messages generated while parsing semantically invalid pattern.'));
}