diff options
author | Sam Thursfield <sam.thursfield@codethink.co.uk> | 2013-02-13 13:29:27 +0000 |
---|---|---|
committer | Sam Thursfield <sam.thursfield@codethink.co.uk> | 2013-02-13 13:29:27 +0000 |
commit | 24866984ce4c1e2e444ea4aaf2d4860c60ac617f (patch) | |
tree | ab3e8e6f5ff18ddfabdba331a1d5233fe6ef8e8c /tests.as-root | |
parent | 6e0a557be67b0d1fb33017cb521bf40372876096 (diff) | |
parent | b1c1d4877dfc305475b2b7b555477ba1332e0545 (diff) | |
download | morph-24866984ce4c1e2e444ea4aaf2d4860c60ac617f.tar.gz |
Merge branch 'baserock/richardmaw/fix-edit-build-depends'
Diffstat (limited to 'tests.as-root')
5 files changed, 51 insertions, 3 deletions
diff --git a/tests.as-root/build-handles-stratum-build-depends.script b/tests.as-root/build-handles-stratum-build-depends.script index 1d1aa4ee..32b9b5ee 100755 --- a/tests.as-root/build-handles-stratum-build-depends.script +++ b/tests.as-root/build-handles-stratum-build-depends.script @@ -25,8 +25,10 @@ cd "$DATADIR/workspace" cd test/stratum-build-depends/test:morphs -# Both 'linux-system' and the build-depends field of 'linux-stratum' need to -# be updated here. If they are not, the build command will fail. +# 'linux-system' and the build-depends fields of 'linux-stratum' need to +# be updated here. Any build-depends of any altered strata also need to +# be altered, such as the 'tools-stratum' which depends on linux-stratum +# If they are not updated, the build command will fail. "$SRCDIR/scripts/test-morph" edit linux-system hello-stratum # Likewise, this command must update build-depends or the 'repo' field will diff --git a/tests.as-root/building-a-system-branch-works-anywhere.script b/tests.as-root/building-a-system-branch-works-anywhere.script index 87b49199..fac07e21 100755 --- a/tests.as-root/building-a-system-branch-works-anywhere.script +++ b/tests.as-root/building-a-system-branch-works-anywhere.script @@ -48,7 +48,7 @@ cd "$DATADIR/workspace/branch1/test:kernel-repo" rm -rf "$DATADIR/cache/artifacts"/* # Verify that we build the right number of artifacts -[ $(wc < "$DATADIR/output1" -l) -eq 16 ] +[ $(wc < "$DATADIR/output1" -l) -eq 22 ] # List of files in the artifact cache should be identical after each build diff "$DATADIR/output1" "$DATADIR/output2" diff --git a/tests.as-root/disk-builds-rootfs-and-kernel.stdout b/tests.as-root/disk-builds-rootfs-and-kernel.stdout index af3a936b..4e8a67ae 100644 --- a/tests.as-root/disk-builds-rootfs-and-kernel.stdout +++ b/tests.as-root/disk-builds-rootfs-and-kernel.stdout @@ -10,8 +10,11 @@ ./factory-run/baserock/linux-stratum.meta ./factory-run/baserock/linux-system-rootfs.meta ./factory-run/baserock/linux.meta +./factory-run/baserock/tools-stratum.meta +./factory-run/baserock/tools.meta ./factory-run/bin ./factory-run/bin/hello +./factory-run/bin/strace ./factory-run/boot ./factory-run/boot/System.map ./factory-run/boot/vmlinuz @@ -25,8 +28,11 @@ ./factory/baserock/linux-stratum.meta ./factory/baserock/linux-system-rootfs.meta ./factory/baserock/linux.meta +./factory/baserock/tools-stratum.meta +./factory/baserock/tools.meta ./factory/bin ./factory/bin/hello +./factory/bin/strace ./factory/boot ./factory/boot/System.map ./factory/boot/vmlinuz diff --git a/tests.as-root/setup b/tests.as-root/setup index 285a3143..03a438e0 100755 --- a/tests.as-root/setup +++ b/tests.as-root/setup @@ -79,6 +79,22 @@ git commit --quiet -m "add a hello world program and morph" git checkout --quiet master +# Create tools repository, so there is an extra layer of build-depends +toolsrepo="$DATADIR/tools-repo" +mkdir -p "$toolsrepo" +cd "$toolsrepo" +git init --quiet +cat <<'EOF' >tools.morph +name: tools +kind: chunk +build-commands: + - echo 'echo dummy strace' >strace +install-commands: + - mkdir -p "$DESTDIR/bin" + - install strace "$DESTDIR/bin/strace" +EOF +git add tools.morph +git commit --quiet -m "add morphology" # Create morph repository. @@ -98,6 +114,21 @@ chunks: EOF git add hello-stratum.morph +cat <<EOF > tools-stratum.morph +name: tools-stratum +kind: stratum +build-depends: + - morph: linux-stratum + repo: test:morphs + ref: master +chunks: + - name: tools + repo: test:tools-repo + ref: master + build-depends: [] +EOF +git add tools-stratum.morph + cat <<EOF > hello-system.morph name: hello-system kind: system @@ -139,6 +170,9 @@ strata: - morph: linux-stratum repo: test:morphs ref: master + - morph: tools-stratum + repo: test:morphs + ref: master EOF git add linux-system.morph diff --git a/tests.as-root/syslinux-disk-builds-rootfs-and-kernel.stdout b/tests.as-root/syslinux-disk-builds-rootfs-and-kernel.stdout index dfa7d9d3..ecc10ba6 100644 --- a/tests.as-root/syslinux-disk-builds-rootfs-and-kernel.stdout +++ b/tests.as-root/syslinux-disk-builds-rootfs-and-kernel.stdout @@ -11,8 +11,11 @@ ./factory-run/baserock/linux-stratum.meta ./factory-run/baserock/linux-system-rootfs.meta ./factory-run/baserock/linux.meta +./factory-run/baserock/tools-stratum.meta +./factory-run/baserock/tools.meta ./factory-run/bin ./factory-run/bin/hello +./factory-run/bin/strace ./factory-run/boot ./factory-run/boot/System.map ./factory-run/boot/vmlinuz @@ -26,8 +29,11 @@ ./factory/baserock/linux-stratum.meta ./factory/baserock/linux-system-rootfs.meta ./factory/baserock/linux.meta +./factory/baserock/tools-stratum.meta +./factory/baserock/tools.meta ./factory/bin ./factory/bin/hello +./factory/bin/strace ./factory/boot ./factory/boot/System.map ./factory/boot/vmlinuz |