blob: cc57863d9bd8fa7a1aa041862f42033d91e1f17f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
|
<?php
/**
* Writes a single test case to a file
*
*/
class gtTestCaseWriter {
public static function write($name, $string, $type, $count = 0) {
if ($type == 'b') {
$fileName = $name."_basic.phpt";
}
if ($type == 'e') {
$fileName = $name."_error.phpt";
}
if ($type == 'v') {
$fileName = $name."_variation".$count.".phpt";
}
$fh = fopen($fileName, 'w');
fwrite ($fh, $string);
fclose($fh);
}
}
?>
|