function PatternsTestCase::runFile in Patterns 7
Same name and namespace in other branches
- 7.2 tests/patterns.test \PatternsTestCase::runFile()
Loads a pattern file and runs it.
Parameters
mixed $filename The full name (name + extension) of: the file to run
mixed $name An alphanumeric name or short sentence: to be displayed next to the test results
mixed $dir The path of the directory containing the: pattern file
mixed $format (optional) If set, forces the use of: a specific format
See also
quickRun()
33 calls to PatternsTestCase::runFile()
- PatternsBlockTestCase::testCreate in tests/
block/ block.test - PatternsBlockTestCase::testDelete in tests/
block/ block.test - PatternsBlockTestCase::testModify in tests/
block/ block.test - PatternsColorTestCase::testColor in tests/
color/ color.test - PatternsContentTypeTestCase::testCreate in tests/
node/ content.test
File
- tests/
patterns.test, line 78 - The base of the Patterns Component tests.
Class
- PatternsTestCase
- Abstract base class for testing pattern component behavior.
Code
function runFile($filename, $name, $dir, $format = NULL) {
$patterntext = $this
->loadPattern($filename, $dir);
if (is_null($format)) {
$path_parts = pathinfo($filename);
$format = $path_parts['extension'];
}
$this
->quickRun($patterntext, $name);
}