Lines Matching refs:file_name
2852 * @param string $file_name
2859 function junit_mark_test_as($type, $file_name, $test_name, $time = null, $message = '', $details = … argument
2863 $suite = junit_get_suitename_for($file_name);
2867 $time = null !== $time ? $time : junit_get_timer($file_name);
2876 $escaped_test_name = basename($file_name) . ' - ' . htmlspecialchars($test_name, ENT_QUOTES);
2877 …$JUNIT['files'][$file_name]['xml'] = "<testcase classname='$suite' name='$escaped_test_name' time=…
2891 $JUNIT['files'][$file_name]['xml'] .= "<error type='$output_type' message='$escaped_message'/>\n";
2894 $JUNIT['files'][$file_name]['xml'] .= "<skipped>$escaped_message</skipped>\n";
2897 $JUNIT['files'][$file_name]['xml'] .= "<warning>$escaped_message</warning>\n";
2900 …$JUNIT['files'][$file_name]['xml'] .= "<failure type='$output_type' message='$escaped_message'>$es…
2903 …$JUNIT['files'][$file_name]['xml'] .= "<error type='$output_type' message='$escaped_message'>$esca…
2906 $JUNIT['files'][$file_name]['xml'] .= "</testcase>\n";
2917 function junit_get_timer($file_name) { argument
2921 if (isset($JUNIT['files'][$file_name]['total'])) {
2922 return number_format($JUNIT['files'][$file_name]['total'], 4);
2928 function junit_start_timer($file_name) { argument
2932 if (!isset($JUNIT['files'][$file_name]['start'])) {
2933 $JUNIT['files'][$file_name]['start'] = microtime(true);
2935 $suite = junit_get_suitename_for($file_name);
2937 $JUNIT['suites'][$suite]['files'][$file_name] = $file_name;
2941 function junit_get_suitename_for($file_name) { argument
2942 return junit_path_to_classname(dirname($file_name));
2945 function junit_path_to_classname($file_name) { argument
2947 return $JUNIT['name'] . '.' . str_replace(DIRECTORY_SEPARATOR, '.', $file_name);
2971 function junit_finish_timer($file_name) { argument
2975 if (!isset($JUNIT['files'][$file_name]['start'])) {
2976 error("Timer for $file_name was not started!");
2979 if (!isset($JUNIT['files'][$file_name]['total'])) {
2980 $JUNIT['files'][$file_name]['total'] = 0;
2983 $start = $JUNIT['files'][$file_name]['start'];
2984 $JUNIT['files'][$file_name]['total'] += microtime(true) - $start;
2985 unset($JUNIT['files'][$file_name]['start']);