https://bugzilla.redhat.com/show_bug.cgi?id=1967544
--- Comment #4 from Petr Pisar <ppisar(a)redhat.com> ---
I changes the initialization to check a return value instead of stderr like
this:
--- a/t/lib/SDL/TestTool.pm
+++ b/t/lib/SDL/TestTool.pm
@@ -20,6 +20,7 @@ sub init {
my ( $self, $init ) = @_;
my $stdout = '';
my $stderr = '';
+ my $retval;
if ( $init == SDL_INIT_VIDEO ) {
if ( $^O !~ /win/i && !$ENV{DISPLAY} &&
!$ENV{SDL_VIDEODRIVER}
) {
@@ -36,12 +37,15 @@ sub init {
SDL::quit();
}
- ($stdout, $stderr ) = capture { SDL::init($init) };
- if ( $stderr ne '' ) {
- warn 'Init ' . $inits{$init} . ' failed with SDL error: '
.
SDL::get_error() . "\nand stderr $stderr\n";
+ ($stdout, $stderr ) = capture { $retval = SDL::init($init) };
+ if ( $retval ) {
+ warn 'Init ' . $inits{$init} . ' failed with SDL error: '
.
SDL::get_error() . "\n" .
+ ($stderr eq '') ? '' : "and stderr $stderr\n";
+ } elsif ( $stderr ne '' ) {
+ warn 'Init ' . $inits{$init} . " succeeded but
warned:\n$stderr\n";
}
- return !( $stderr ne '' );
+ return !( $retval );
}
sub test_audio_open {
All tests pass with old SDL. Some tests fail with
sdl12-compat-0.0.1~git.20210609.efe9791-1.fc35:
Test Summary Report
-------------------
t/core.t (Wstat: 0 Tests: 28 Failed: 0)
TODO passed: 21-22, 27
t/core_audio.t (Wstat: 512 Tests: 45 Failed: 2)
Failed tests: 30-31
Non-zero exit status: 2
t/core_events.t (Wstat: 256 Tests: 679 Failed: 1)
Failed test: 668
Non-zero exit status: 1
t/core_multi.t (Wstat: 0 Tests: 4 Failed: 0)
TODO passed: 3
t/core_timer.t (Wstat: 0 Tests: 6 Failed: 0)
TODO passed: 6
t/core_video.t (Wstat: 256 Tests: 110 Failed: 1)
Failed test: 62
TODO passed: 57, 59
Non-zero exit status: 1
t/gfx_imagefilter.t (Wstat: 0 Tests: 8 Failed: 0)
TODO passed: 7
t/mixer.t (Wstat: 768 Tests: 26 Failed: 3)
Failed tests: 20-21, 23
Non-zero exit status: 3
t/mixer_mixchunk.t (Wstat: 256 Tests: 2 Failed: 2)
Failed tests: 1-2
Non-zero exit status: 1
Parse errors: Bad plan. You planned 6 tests but ran 2.
t/mixer_mixmusic.t (Wstat: 512 Tests: 6 Failed: 2)
Failed tests: 4-5
Non-zero exit status: 2
t/mixer_music.t (Wstat: 3584 Tests: 35 Failed: 14)
Failed tests: 1, 8-11, 13-16, 20, 23-24, 28-29
Non-zero exit status: 14
t/sdlx_music.t (Wstat: 256 Tests: 2 Failed: 0)
Non-zero exit status: 1
Parse errors: No plan found in TAP output
t/sdlx_sound.t (Wstat: 256 Tests: 5 Failed: 0)
Non-zero exit status: 1
Parse errors: No plan found in TAP output
t/sdlx_surface.t (Wstat: 256 Tests: 1 Failed: 0)
Non-zero exit status: 1
Parse errors: No plan found in TAP output
Files=58, Tests=3449, 89 wallclock secs ( 0.34 usr 0.11 sys + 22.68 cusr 2.39
csys = 25.52 CPU)
Result: FAIL
Failed 10/58 test programs. 25/3449 subtests failed.
--
You are receiving this mail because:
You are on the CC list for the bug.