diff --git a/S16-io/cwd.t b/S16-io/cwd.t index ed9a6329e0..f826be7db0 100644 --- a/S16-io/cwd.t +++ b/S16-io/cwd.t @@ -5,6 +5,7 @@ use Test; plan 3; -isa_ok $*CWD, IO::Path; +#?rakudo todo 'still in newio branch' +isa_ok $*CWD, IO::Dir; lives_ok { $*CWD.perl }, '$*CWD.perl works'; lives_ok { $*CWD.gist }, '$*CWD.gist works'; diff --git a/S16-io/tmpdir.t b/S16-io/tmpdir.t index a31dffaea6..73f21a900a 100644 --- a/S16-io/tmpdir.t +++ b/S16-io/tmpdir.t @@ -4,6 +4,7 @@ use Test; plan 3; -isa_ok $*TMPDIR, IO::Path; +#?rakudo todo 'still in newio branch' +isa_ok $*TMPDIR, IO::Dir; lives_ok { $*TMPDIR.perl }, '$*TMPDIR.perl works'; lives_ok { $*TMPDIR.gist }, '$*TMPDIR.gist works'; diff --git a/S22-package-format/local.t b/S22-package-format/local.t index 0894058436..623e50e8f6 100644 --- a/S22-package-format/local.t +++ b/S22-package-format/local.t @@ -14,12 +14,12 @@ my $module := 'NanooNanoo'; my $srcext := 'pm'; my $src := "$module.$srcext"; my $base := "$cwd/t/spec/S22-package-format"; -my $srcdir := "$base/local-file-src"; -my $srcsrc := $*KERNEL.name eq 'win32' ?? "$srcdir\\$src" !! "$srcdir/$src"; +my $srcdir := "$base/local-file-src/"; +my $srcsrc := $srcdir ~ $src; my $cmpext := $*VM.precomp-ext; -my $cmpdir := "$base/local-file-cmp"; -my $cmpsrc := "$cmpdir/$src"; # should not exist -my $cmpcmp := "$cmpdir/$src.$cmpext"; +my $cmpdir := "$base/local-file-cmp/"; +my $cmpsrc := $cmpdir ~ $src; # should not exist +my $cmpcmp := "$cmpdir$src.$cmpext"; # creating dirs / files needed my $initialized = True; # try to cleanup from here on out @@ -34,8 +34,8 @@ ok signal(SIGINT).tap( {die} ), 'install Ctrl-C handler for cleanup in END'; # basic CURLF sanity my $curlf1 = CompUnitRepo::Local::File.new($cwd); isa_ok $curlf1, CompUnitRepo::Local::File; -isa_ok $curlf1.path, IO::Path; -is $curlf1.path, $cwd, 'is . looking at the right directory'; +isa_ok $curlf1.IO, IO::Path; +is $curlf1.IO, $cwd, 'is . looking at the right directory'; is $curlf1.short-id, 'file', 'is the short-id right'; dies_ok { $curlf1.install( "foo" ) }, 'Cannot install on CUR::File'; @@ -46,8 +46,8 @@ ok $curlf1 === $curlf2, 'are they the same'; my $curlf = CompUnitRepo::Local::File.new($srcdir); isa_ok $curlf, CompUnitRepo::Local::File; ok $curlf2 !=== $curlf, 'are they different'; -isa_ok $curlf.path, IO::Path; -is $curlf.path, IO::Path.new($srcdir), "is '$srcdir' looking at the right dir"; +isa_ok $curlf.IO, IO::Path; +is $curlf.IO, IO::Path.new($srcdir), "is '$srcdir' looking at the right dir"; # all candidates my $candidates = $curlf.candidates('NanooNanoo'); @@ -70,7 +70,7 @@ is $candidates.elems, 0, "did we get 0 candidates"; is $compunit-src.from, 'Perl6', "is the language 'Perl6'"; is $compunit-src.name, $module, "is the name '$module'"; is $compunit-src.extension, $srcext, "is the extension '$srcext'"; -is $compunit-src.path, $srcsrc, "is the path '$srcsrc'"; +is $compunit-src.abspath, $srcsrc, "is the abspath '$srcsrc'"; is $compunit-src.is-loaded, False, "is the module is-loaded"; is $compunit-src.has-source, True, "do we have the source?"; is $compunit-src.has-precomp, False, "is the module pre-compiled"; @@ -89,7 +89,7 @@ isa_ok $compunit-cmp, CompUnit; is $compunit-cmp.from, 'Perl6', "is the language 'Perl6'"; is $compunit-cmp.name, $module, "is the name '$module'"; is $compunit-cmp.extension, $srcext, "is the extension '$srcext'"; -is $compunit-cmp.path, $cmpsrc, "is the path '$cmpsrc'"; +is $compunit-cmp.abspath, $cmpsrc, "is the path '$cmpsrc'"; is $compunit-cmp.is-loaded, False, "is the module is-loaded"; is $compunit-cmp.has-source, False, "don't we have the source?"; is $compunit-cmp.has-precomp, True, "is the module pre-compiled"; diff --git a/S32-io/io-path-win.t b/S32-io/io-path-win.t index 176c84e9cd..c23ab49d0f 100644 --- a/S32-io/io-path-win.t +++ b/S32-io/io-path-win.t @@ -5,7 +5,7 @@ use Test; plan 49; my $*SPEC = IO::Spec::Win32; # .IO needs to have IO::Spec::Win32 -my $*CWD = 'C:\\zip\\loc'.IO; +my $*CWD = 'C:\\zip\\loc\\'; # for the sake of testing here, it's just a string my $relpath = IO::Path::Win32.new('foo\\bar' ); my $abspath = IO::Path::Win32.new('\\foo\\bar'); @@ -61,7 +61,7 @@ is IO::Path::Win32.new("\\usr\\bin").relative("/usr"), "bin", "rel is $relpath.absolute.IO.relative, "foo\\bar", "relative inverts absolute"; is $relpath.absolute("/foo").IO.relative("\\foo"), "foo\\bar","absolute inverts relative"; -#?rakudo 1 todo 'resolve NYI, needs nqp::readlink' +#?rakudo 1 skip 'resolve NYI, needs nqp::readlink' is $abspath.relative.IO.absolute.IO.resolve, "\\foo\\bar", "absolute inverts relative with resolve"; is IO::Path::Win32.new("foo/bar").parent, "foo", "parent of 'foo/bar' is 'foo'"; diff --git a/S32-io/io-spec-unix.t b/S32-io/io-spec-unix.t index 22bad8ef2c..ad6fbe460b 100644 --- a/S32-io/io-spec-unix.t +++ b/S32-io/io-spec-unix.t @@ -193,6 +193,7 @@ if $*DISTRO.name ~~ any() { } else { isa_ok $*SPEC, IO::Spec::Unix, "unix: loads correct module"; - is $*SPEC.rel2abs( $*SPEC.curdir ), $*CWD, "rel2abs: \$*CWD test"; + #?rakudo todo "awaiting newio merge" + is $*SPEC.rel2abs( $*SPEC.curdir ), $*CWD.chop, "rel2abs: \$*CWD test"; ok {.IO.d && .IO.w}.( $*SPEC.tmpdir ), "tmpdir: {$*SPEC.tmpdir} is a writable directory"; }