diff options
Diffstat (limited to 't')
-rwxr-xr-x | t/03-travis.t | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/t/03-travis.t b/t/03-travis.t index 4b77313..7b6c97f 100755 --- a/t/03-travis.t +++ b/t/03-travis.t @@ -26,7 +26,7 @@ SKIP: { skip 'Not doing online tests without TEST_ONLINE=1', 2 if $ENV{TEST_ONLINE} ne '1'; sbosnap 'fetch', { expected => qr/\APulling SlackBuilds tree\.\.\.\n/ }; - sbofind 'sbotools', { expected => "SBo: sbotools 1.9\nPath: /usr/sbo/repo/system/sbotools\n\n" }; + sbofind 'sbotools', { expected => qr"SBo: sbotools \d[.]\d\nPath: /usr/sbo/repo/system/sbotools\n\n" }; } # 4-10: Test alternative REPO @@ -75,12 +75,12 @@ Path: $RealBin/LO/nonexistentslackbuild8! sboinstall qw/ -r nonexistentslackbuild /, { expected => qr/nonexistentslackbuild added to install queue[.].*perf[.]dummy.* saved.*Cleaning for nonexistentslackbuild-1[.]0/s }; sboremove qw/ --nointeractive nonexistentslackbuild /, { expected => qr/Removing 1 package\(s\).*nonexistentslackbuild.*All operations have completed/s }; - is (system(qw!/sbin/installpkg nonexistentslackbuild-0.9-noarch-1_SBo.tgz!), 0, 'Old version fake installed'); + is (system(qw!touch /var/log/packages/nonexistentslackbuild-0.9-noarch-1_SBo!), 0, 'Old version fake installed'); sbocheck { expected => qr/Updating SlackBuilds tree.*Checking for updated SlackBuilds.*nonexistentslackbuild 0[.]9.*needs updating/s }; sboupgrade qw/ -r nonexistentslackbuild /, { expected => qr/nonexistentslackbuild added to upgrade queue.*Upgrade queue: nonexistentslackbuild/s }; # 18: Test missing dep - sboinstall 'nonexistentslackbuild2', { input => 'y', exit => 1, expected => "Unable to locate nonexistentslackbuild3 in the SlackBuilds.org tree.\n" }; + sboinstall 'nonexistentslackbuild2', { input => 'n', exit => 0, expected => "Unable to locate nonexistentslackbuild3 in the SlackBuilds.org tree.\nDo you want to ignore it and continue? [n] " }; } # 19-23: Test sboupgrade --all @@ -96,7 +96,7 @@ SKIP: { my @files = glob("/var/log/packages/nonexistentslackbuild-*"); skip 'Cannot test if nonexistentslackbuild is already installed', 4 if @files; - is (system(qw!/sbin/installpkg nonexistentslackbuild-0.9-noarch-1_SBo.tgz!), 0, 'installpkg old version works'); + is (system(qw!touch /var/log/packages/nonexistentslackbuild-0.9-noarch-1_SBo!), 0, 'installpkg old version works'); sboupgrade qw/ -r --all /, { expected => qr/Checking for updated SlackBuilds.*nonexistentslackbuild added to upgrade queue.*Cleaning for nonexistentslackbuild/s }; ok (-e "/var/log/packages/nonexistentslackbuild-1.0-noarch-1_SBo", 'updated package is installed'); ok (! -e "/var/log/packages/nonexistentslackbuild-0.9-noarch-1_SBo", 'old package is removed'); |