diff options
author | Sam Thursfield <sam.thursfield@codethink.co.uk> | 2012-11-14 17:52:38 +0000 |
---|---|---|
committer | Sam Thursfield <sam.thursfield@codethink.co.uk> | 2012-11-14 17:58:39 +0000 |
commit | e8a342e61989f06172457fc25311abc02e5dfee6 (patch) | |
tree | 1cb80924d7cd49b495a4844419fd1669ce7eeafd /tests.as-root/syslinux-fails-if-no-mbr-found.script | |
parent | 70564c6457b732e1dd35384971da5df3c5a1665b (diff) | |
download | morph-e8a342e61989f06172457fc25311abc02e5dfee6.tar.gz |
Update as-root tests to use their setup infrastructure
Code to generate system images was being duplicated in each test needlessly.
Diffstat (limited to 'tests.as-root/syslinux-fails-if-no-mbr-found.script')
-rwxr-xr-x | tests.as-root/syslinux-fails-if-no-mbr-found.script | 66 |
1 files changed, 2 insertions, 64 deletions
diff --git a/tests.as-root/syslinux-fails-if-no-mbr-found.script b/tests.as-root/syslinux-fails-if-no-mbr-found.script index fbf675dc..b0d5b9bd 100755 --- a/tests.as-root/syslinux-fails-if-no-mbr-found.script +++ b/tests.as-root/syslinux-fails-if-no-mbr-found.script @@ -16,8 +16,7 @@ # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. -# A system kind of syslinux-disk should create the disk image, plus a kernel -# file. +# Handle invalid syslinux MBR parameters. set -eu @@ -29,67 +28,6 @@ case "$arch" in esac cache="$DATADIR/cache/artifacts" -kernelrepo="$DATADIR/kernel-repo" -morphsrepo="$DATADIR/morphs" -log="$DATADIR/morph.log" - -cd "$morphsrepo" -git checkout --quiet -b custom master -cat <<EOF >system.morph -{ - "name": "system", - "kind": "system", - "system-kind": "syslinux-disk", - "arch": "$arch", - "disk-size": "1G", - "strata": [ - { - "morph": "stratum", - "repo": "test:morphs", - "ref": "custom" - } - ] -} -EOF -cat <<EOF >stratum.morph -{ - "name": "stratum", - "kind": "stratum", - "chunks": [ - { - "name": "hello", - "repo": "test:chunk-repo", - "ref": "farrokh", - "build-depends": [] - }, - { - "name": "linux", - "repo": "test:kernel-repo", - "ref": "custom", - "build-depends": ["hello"] - } - ] -} -EOF -git add system.morph stratum.morph -git commit --quiet -m "foo" - -cd "$kernelrepo" -git checkout --quiet -b custom master -cat <<EOF >linux.morph -{ - "name": "linux", - "kind": "chunk", - "install-commands": [ - "mkdir -p \"\$DESTDIR/boot\"", - "touch \"\$DESTDIR\"/boot/vmlinuz", - "touch \"\$DESTDIR\"/boot/System.map" - ] -} -EOF -git add linux.morph - -git commit --quiet -m 'Make the kernel create a dummy zImage' "$SRCDIR/scripts/test-morph" --syslinux-mbr-search-path=nosuchfile.bin \ - build-morphology test:morphs custom system > /dev/null + build-morphology test:morphs master linux-system > /dev/null |