-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
mtest: unify parsed and non-parsed output handling
Use the same routines to handle output both when parsing the output and when not. Also fixes broken stderr handling for parsed tests.
- Loading branch information
Showing
4 changed files
with
97 additions
and
25 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
#include <stdio.h> | ||
|
||
int main(void) | ||
{ | ||
for (int i = 0 ; i < 100000 ; i++) | ||
fprintf(stderr, "# Iteration %d to stderr\n", i + 1); | ||
|
||
printf("ok 1 - dumper to stderr\n"); | ||
|
||
for (int i = 0 ; i < 100000 ; i++) | ||
fprintf(stdout, "# Iteration %d to stdout\n", i + 1); | ||
|
||
printf("ok 2 - dumper to stdout\n1..2\n"); | ||
|
||
return 0; | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
project('long-stderr', 'c') | ||
|
||
dumper = executable('dumper', 'dumper.c') | ||
test('dump-test', dumper) | ||
test('dump-test-TAP', dumper, protocol : 'tap') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters