- Timestamp:
- 11/11/11 13:17:43 (20 months ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/router/proftpd/tests/t/lib/ProFTPD/Tests/Commands/CDUP.pm
r14672 r17876 2 2 3 3 use lib qw(t/lib); 4 use base qw( Test::Unit::TestCaseProFTPD::TestSuite::Child);4 use base qw(ProFTPD::TestSuite::Child); 5 5 use strict; 6 6 7 use File::Path qw(mkpath rmtree);8 7 use File::Spec; 9 8 use IO::Handle; … … 36 35 return testsuite_get_runnable_tests($TESTS); 37 36 } 38 39 sub set_up {40 my $self = shift;41 $self->{tmpdir} = testsuite_get_tmp_dir();42 43 # Create temporary scratch dir44 eval { mkpath($self->{tmpdir}) };45 if ($@) {46 my $abs_path = File::Spec->rel2abs($self->{tmpdir});47 die("Can't create dir $abs_path: $@");48 }49 }50 51 sub tear_down {52 my $self = shift;53 54 # Remove temporary scratch dir55 if ($self->{tmpdir}) {56 eval { rmtree($self->{tmpdir}) };57 }58 59 undef $self;60 };61 37 62 38 sub cdup_ok { … … 141 117 142 118 $expected = "CDUP command successful"; 143 chomp($resp_msg);144 119 $self->assert($expected eq $resp_msg, 145 120 test_msg("Expected '$expected', got '$resp_msg'")); … … 256 231 257 232 $expected = "XCUP command successful"; 258 chomp($resp_msg);259 233 $self->assert($expected eq $resp_msg, 260 234 test_msg("Expected '$expected', got '$resp_msg'"));
Note: See TracChangeset
for help on using the changeset viewer.
