close OUT;
chmod 0444, 'dasboot.bs';
- eval{ Mkbootstrap('dasboot', 1) };
- like( $@, qr/Unable to open dasboot\.bs/, 'should die given bad filename' );
+ SKIP: {
+ skip("can write readonly files", 1) if -w 'dasboot.bs';
+
+ eval{ Mkbootstrap('dasboot', 1) };
+ like( $@, qr/Unable to open dasboot\.bs/, 'should die given bad filename' );
+ }
# now put it back like it was
chmod 0777, 'dasboot.bs';
# set this file to read-only
chmod 0444, 'eplist';
- eval { ExtUtils::Packlist::write({}, 'eplist') };
- like( $@, qr/Can't open file/, 'write() should croak on open failure' );
+ SKIP: {
+ skip("can write readonly files", 1) if -w 'eplist';
+
+ eval { ExtUtils::Packlist::write({}, 'eplist') };
+ like( $@, qr/Can't open file/, 'write() should croak on open failure' );
+ }
#'now set it back (tick here fixes vim syntax highlighting ;)
chmod 0777, 'eplist';