From 0e21a812b67319a7eb88e17a16ecdb33a43f1838 Mon Sep 17 00:00:00 2001 From: mao xiaojuan Date: Fri, 26 Jan 2018 15:22:36 +0800 Subject: [PATCH] Modify the case to adjust the function that use the value of --pack-to option as filename to match all outputs. Change-Id: I752f6864e8aaabd5abca5fc0d623b2f80835706e --- ...oop_compress_local-pkgs_record-pkgs_pack-to_armv7l.case | 4 ++-- .../func_cases/mic_cr_qcow_local-pkgs_record-pkgs.case | 4 ++-- .../create/opt_cases/mic_cr_loop_pack-to-Invalid_ia32.case | 7 ++----- cases/create/opt_cases/mic_cr_loop_pack-to-tar_ia32.case | 4 ++-- fixtures/ks_files/error_no_package.ks | 2 +- 5 files changed, 9 insertions(+), 12 deletions(-) diff --git a/cases/create/func_cases/mic_cr_loop_compress_local-pkgs_record-pkgs_pack-to_armv7l.case b/cases/create/func_cases/mic_cr_loop_compress_local-pkgs_record-pkgs_pack-to_armv7l.case index 86da41e..9ee8651 100644 --- a/cases/create/func_cases/mic_cr_loop_compress_local-pkgs_record-pkgs_pack-to_armv7l.case +++ b/cases/create/func_cases/mic_cr_loop_compress_local-pkgs_record-pkgs_pack-to_armv7l.case @@ -1,6 +1,6 @@ create loop image with armv7l arch, and options is - "--local-pkgs-path=./rpm --record-pkgs=name,content,license --taring-to=@NAME@ --compress-image=bz2" + "--local-pkgs-path=./rpm --record-pkgs=name,content,license --taring-to=@NAME@.tar --compress-image=bz2" @@ -16,7 +16,7 @@ fi sudo mic -d -v cr loop armv7l.ks \ --local-pkgs-path=./rpm \ --record-pkgs=name,content,license,vcs \ - --taring-to=@NAME@ \ + --taring-to=@NAME@.tar \ --compress-image=bz2 \ --logfile=log.file diff --git a/cases/create/func_cases/mic_cr_qcow_local-pkgs_record-pkgs.case b/cases/create/func_cases/mic_cr_qcow_local-pkgs_record-pkgs.case index 63f041b..796cde1 100644 --- a/cases/create/func_cases/mic_cr_qcow_local-pkgs_record-pkgs.case +++ b/cases/create/func_cases/mic_cr_qcow_local-pkgs_record-pkgs.case @@ -1,6 +1,6 @@ create qcow image with armv7l arch, and options is - "--local-pkgs-path=./rpm --record-pkgs=name,content,license --taring-to=@NAME@" + "--local-pkgs-path=./rpm --record-pkgs=name,content,license --taring-to=@NAME@.tar.gz" @@ -22,7 +22,7 @@ fi sudo mic -d -v cr qcow qcow_image.ks \ --local-pkgs-path=./rpm \ --record-pkgs=name,content,license,vcs \ - --taring-to=@NAME@ \ + --taring-to=@NAME@.tar.gz \ --logfile=log.file \ -k /home/build/mic-tmp-cache diff --git a/cases/create/opt_cases/mic_cr_loop_pack-to-Invalid_ia32.case b/cases/create/opt_cases/mic_cr_loop_pack-to-Invalid_ia32.case index ea60228..3600032 100644 --- a/cases/create/opt_cases/mic_cr_loop_pack-to-Invalid_ia32.case +++ b/cases/create/opt_cases/mic_cr_loop_pack-to-Invalid_ia32.case @@ -7,13 +7,10 @@ losetup_path=$(sudo which losetup) sudo $losetup_path -a sudo $losetup_path -a | wc -l | xargs test 0 -eq -sudo mic -d -v cr loop handset_blackbay.ks --pack-to=@NAME@.bz2 --logfile=mic.log -grep 'Finished' mic.log -test -f ./mic-output/handset_blackbay*.bz2.tar +(! sudo mic -d -v cr loop handset_blackbay.ks --pack-to=@NAME@.bz2 --logfile=mic.log) +grep 'Not supported archive file format' mic.log sudo $losetup_path -a sudo $losetup_path -a | wc -l | xargs test 0 -eq -sudo tar -xvf ./mic-output/handset_blackbay*.bz2.tar -C ./mic-output -sudo test -f ./mic-output/platform.img ]]> - create loop image with arch ia32 and --pack-to is @NAME@ + create loop image with arch ia32 and --pack-to is @NAME@.tar @@ -7,7 +7,7 @@ losetup_path=$(sudo which losetup) sudo $losetup_path -a sudo $losetup_path -a | wc -l | xargs test 0 -eq -sudo mic -d -v cr loop handset_blackbay.ks --pack-to=@NAME@ --logfile=mic.log +sudo mic -d -v cr loop handset_blackbay.ks --pack-to=@NAME@.tar --logfile=mic.log grep 'Finished' mic.log test -f ./mic-output/handset_blackbay*.tar sudo $losetup_path -a diff --git a/fixtures/ks_files/error_no_package.ks b/fixtures/ks_files/error_no_package.ks index 71dbe6e..2455ca9 100755 --- a/fixtures/ks_files/error_no_package.ks +++ b/fixtures/ks_files/error_no_package.ks @@ -1,4 +1,4 @@ -# -*-mic2-options-*- -f loop --pack-to=@NAME@-rs.zip -*-mic2-options-*- +# -*-mic2-options-*- -f loop --pack-to=@NAME@.zip -*-mic2-options-*- # # Do not Edit! Generated by: -- 2.34.1