diff options
author | Thierry Vignaud <tv@mageia.org> | 2012-06-08 18:50:43 +0000 |
---|---|---|
committer | Thierry Vignaud <tv@mageia.org> | 2012-06-08 18:50:43 +0000 |
commit | 0a1719e9c340767641112ab79120cae41669f755 (patch) | |
tree | 9117432b5ca37aa8d3c89bf8c7e6e9292ebb398e /t/helper.pm | |
parent | f406c1c4b8e3d3df97510b2a85d062ebe4e4e1bc (diff) | |
download | urpmi-0a1719e9c340767641112ab79120cae41669f755.tar urpmi-0a1719e9c340767641112ab79120cae41669f755.tar.gz urpmi-0a1719e9c340767641112ab79120cae41669f755.tar.bz2 urpmi-0a1719e9c340767641112ab79120cae41669f755.tar.xz urpmi-0a1719e9c340767641112ab79120cae41669f755.zip |
(system_should_partially_fail,urpmi_partial) introduce them for next commit
Diffstat (limited to 't/helper.pm')
-rw-r--r-- | t/helper.pm | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/t/helper.pm b/t/helper.pm index e3c3a008..ba625ea8 100644 --- a/t/helper.pm +++ b/t/helper.pm @@ -5,7 +5,7 @@ use base 'Exporter'; our @EXPORT = qw(need_root_and_prepare start_httpd httpd_port urpmi_addmedia urpmi_removemedia urpmi_update - urpm_cmd run_urpm_cmd urpmi_cmd urpmi test_urpmi_fail urpme + urpm_cmd run_urpm_cmd urpmi_cmd urpmi urpmi_partial test_urpmi_fail urpme urpmi_cfg set_urpmi_cfg_global_options system_ system_should_fail rpm_is_jbj_version @@ -78,6 +78,10 @@ sub urpmi_update { my ($para) = @_; system_(urpm_cmd('urpmi.update') . " $para"); } +sub urpmi_partial { + my ($para) = @_; + system_should_partially_fail(urpmi_cmd() . " --ignoresize $para"); +} sub urpmi { my ($para) = @_; system_(urpmi_cmd() . " --ignoresize $para"); @@ -106,6 +110,11 @@ sub system_ { system($cmd); ok($? == 0, $cmd); } +sub system_should_partially_fail { + my ($cmd) = @_; + system($cmd); + ok($? == 17 << 8, $cmd); +} sub system_should_fail { my ($cmd) = @_; system($cmd); |