Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-cw
Commits
81f8264b
Commit
81f8264b
authored
Apr 19, 2002
by
Paul Millar
Committed by
Alexandre Julliard
Apr 19, 2002
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added option for announcement of successful test results.
parent
7418d39f
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
22 additions
and
2 deletions
+22
-2
wine.pm
programs/winetest/include/wine.pm
+8
-1
runtest
programs/winetest/runtest
+2
-0
wtmain.c
programs/winetest/wtmain.c
+12
-1
No files found.
programs/winetest/include/wine.pm
View file @
81f8264b
...
...
@@ -26,6 +26,7 @@ package wine;
use
strict
;
use
vars
qw($VERSION @ISA @EXPORT @EXPORT_OK $AUTOLOAD $todo_level
$successes $failures $todo_successes $todo_failures
$winetest_report_success
%return_types %prototypes %loaded_modules)
;
require
Exporter
;
...
...
@@ -63,6 +64,8 @@ $failures = 0;
$todo_successes
=
0
;
$todo_failures
=
0
;
%
loaded_modules
=
();
$winetest_report_success
=
defined
(
$ENV
{
WINETEST_REPORT_SUCCESS
})
?
$ENV
{
WINETEST_REPORT_SUCCESS
}
:
0
;
# --------------------------------------------------------------
# | Return-type constants |
...
...
@@ -466,7 +469,11 @@ sub ok($;$)
(
$description
?
": $description"
:
""
)
.
"\n"
);
$failures
++
;
}
else
{
$successes
++
;
}
else
{
print
STDERR
(
"$filename:$line: Test succeeded\n"
)
if
(
$winetest_report_success
);
$successes
++
;
}
}
}
...
...
programs/winetest/runtest
View file @
81f8264b
...
...
@@ -32,6 +32,7 @@ Usage: $0 [options] input_file [perl_args...]
Options:
-q quiet mode
-v verbose mode (can be specified multiple times)
-s announce successful tests
-p prog name of the program to run for C tests
-I dir prepend dir to Perl include path
-P name set the current platform name
...
...
@@ -60,6 +61,7 @@ while ($#ARGV >= 0)
if
(
$arg
eq
"-p"
)
{
$program
=
shift
@ARGV
;
next
;
}
if
(
$arg
eq
"-q"
)
{
$ENV
{
WINETEST_DEBUG
}
=
0
;
next
;
}
if
(
$arg
eq
"-v"
)
{
$ENV
{
WINETEST_DEBUG
}
++
;
next
;
}
if
(
$arg
eq
"-s"
)
{
$ENV
{
WINETEST_REPORT_SUCCESS
}
=
1
;
next
;}
if
(
$arg
eq
"-P"
)
{
$platform
=
shift
@ARGV
;
next
;
}
if
(
$arg
eq
"-M"
)
{
push
@modules
,
split
/,/
,
shift
@ARGV
;
next
;
}
if
(
$arg
eq
"-I"
)
{
push
@include_dirs
,
shift
@ARGV
;
next
;
}
...
...
programs/winetest/wtmain.c
View file @
81f8264b
...
...
@@ -32,6 +32,9 @@ int winetest_debug = 1;
/* current platform */
const
char
*
winetest_platform
=
"windows"
;
/* report successful tests (BOOL) */
int
winetest_report_success
=
0
;
struct
test
{
const
char
*
name
;
...
...
@@ -123,7 +126,13 @@ int winetest_ok( int condition, const char *msg, ... )
InterlockedIncrement
(
&
failures
);
return
0
;
}
else
InterlockedIncrement
(
&
successes
);
else
{
if
(
winetest_report_success
)
fprintf
(
stderr
,
"%s:%d: Test succeeded
\n
"
,
data
->
current_file
,
data
->
current_line
);
InterlockedIncrement
(
&
successes
);
}
}
return
1
;
}
...
...
@@ -238,6 +247,8 @@ int main( int argc, char **argv )
if
((
p
=
getenv
(
"WINETEST_PLATFORM"
)))
winetest_platform
=
p
;
if
((
p
=
getenv
(
"WINETEST_DEBUG"
)))
winetest_debug
=
atoi
(
p
);
if
((
p
=
getenv
(
"WINETEST_REPORT_SUCCESS"
)))
winetest_report_success
=
\
atoi
(
p
);
if
(
!
argv
[
1
])
{
fprintf
(
stderr
,
"Usage: %s test_name
\n
"
,
argv
[
0
]
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment