citrun

watch C/C++ source code execute
Log | Files | Refs | LICENSE

gl_welcome.t (712B)


      1 #
      2 # Checks that opening the viewer without any runtime files shows the welcome
      3 # message.
      4 #
      5 use Modern::Perl;
      6 use Test::More skip_all => 'not yet';
      7 
      8 use lib 't';
      9 require gl_utils;
     10 require utils;
     11 
     12 
     13 my $gl = Test::Cmd->new( prog => 'bin/citrun_gl', workdir => '' );
     14 $ENV{CITRUN_PROCDIR} =  $gl->workdir . "/procdir/";
     15 
     16 my $output_file = File::Spec->catdir( $gl->workdir, 'test.tga' );
     17 my $output_good = File::Spec->catfile( 't', 'gl', 'welcome.tga' );
     18 
     19 $gl->run( args => "$output_file 800 600" );
     20 isnt( $gl->stdout,	'',	'is citrun_gl stdout not silent' );
     21 is( $gl->stderr,	'',	'is citrun_gl stderr silent' );
     22 is( $? >> 8,		0,	'is citrun_gl exit code zero' );
     23 
     24 ok_image( $output_file, $output_good, $gl->workdir );