Skip to content

Commit

Permalink
tests should pass on Win32 systems now.
Browse files Browse the repository at this point in the history
  • Loading branch information
trcjr committed Nov 23, 2011
1 parent efc9eb3 commit 2c65512
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 8 deletions.
5 changes: 4 additions & 1 deletion t/data/hello_world_TestCase.yaml
Expand Up @@ -42,4 +42,7 @@ commands:
- clickAndWait
- 'link=Hello world program - Wikipedia, the free encyclopedia'
- ''
filename: t/data/hello_world_TestCase.html
file_path_parts:
- t
- data
- hello_world_TestCase.html
5 changes: 4 additions & 1 deletion t/data/invalid_commands_TestCase.yaml
Expand Up @@ -6,4 +6,7 @@ commands:
- opentoast
- /
- ''
filename: t/data/invalid_commands_TestCase.html
file_path_parts:
- t
- data
- invalid_commands_TestCase.html
14 changes: 8 additions & 6 deletions t/lib/Tests/Parse/Selenese/TestCase.pm
Expand Up @@ -2,9 +2,12 @@ package Tests::Parse::Selenese::TestCase;
use Test::Class::Most parent => 'Tests::Parse::Selenese::Base';
use Parse::Selenese;
use Parse::Selenese::TestCase;
use Path::Class;
use FindBin;
use File::Find qw(find);
use Try::Tiny;
use File::Temp ();
use Data::Dumper;

sub setup : Tests(setup) {
my $self = shift;
Expand Down Expand Up @@ -109,11 +112,9 @@ sub test_each_stored_selenese_file : Tests {

sub test_save_file : Tests {
my $self = shift;
use File::Temp ();

my $c =
Parse::Selenese::TestCase->new(
filename => $self->selenese_data_files->[0] );
my ($f) = grep { /hello_world_TestCase/ } @{ $self->selenese_data_files };
my $c = Parse::Selenese::TestCase->new( filename => $f );

my $fh = File::Temp->new();
my $fname = $fh->filename;
Expand Down Expand Up @@ -222,8 +223,9 @@ sub _test_yaml {
# Load the yaml dump that matches
is $case->short_name => $yaml_data->{short_name},
$case->filename . " test case short name";

is $case->filename => $yaml_data->{filename},
my $want_file_name =
Path::Class::File->new( @{ $yaml_data->{file_path_parts} } )->stringify;
is $case->filename => $want_file_name,
$case->filename . " filename";
is $case->base_url => $yaml_data->{base_url},
$case->filename . " base_url";
Expand Down

0 comments on commit 2c65512

Please sign in to comment.