summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTiago Gomes <tiago.gomes@codethink.co.uk>2015-11-23 14:18:40 (GMT)
committerTiago Gomes <tiago.gomes@codethink.co.uk>2015-11-24 09:56:17 (GMT)
commitcbc3d789a4573704863de3a0247f55eda8b28638 (patch)
treed2ed4d405d2ca790826c4190b40c1699fbf4d46d
parent822d5415edc61fafeb8709e27b6fb1a2ddd3b288 (diff)
downloadmorph-cbc3d789a4573704863de3a0247f55eda8b28638.tar.gz
Remove tests for branch-and-merge plugin
Change-Id: Ie66b543eb67282c08a2651062727a4583057ee2d
-rwxr-xr-xcheck16
-rw-r--r--scripts/setup-3rd-party-strata134
-rwxr-xr-xtests.branching/branch-cleans-up-on-failure.script29
-rw-r--r--tests.branching/branch-cleans-up-on-failure.stderr1
-rwxr-xr-xtests.branching/branch-creates-new-system-branch-not-from-master.script37
-rw-r--r--tests.branching/branch-creates-new-system-branch-not-from-master.stdout29
-rwxr-xr-xtests.branching/branch-fails-if-branch-exists.script40
-rw-r--r--tests.branching/branch-fails-if-branch-exists.stderr1
-rw-r--r--tests.branching/branch-when-branchdir-exists-locally.exit1
-rwxr-xr-xtests.branching/branch-when-branchdir-exists-locally.script28
-rw-r--r--tests.branching/branch-when-branchdir-exists-locally.stderr1
-rwxr-xr-xtests.branching/branch-works-anywhere.script61
-rw-r--r--tests.branching/branch-works-anywhere.stdout112
-rwxr-xr-xtests.branching/checkout-cleans-up-on-failure.script28
-rw-r--r--tests.branching/checkout-cleans-up-on-failure.stderr1
-rwxr-xr-xtests.branching/checkout-non-aliased-repos.script51
-rw-r--r--tests.branching/checkout-non-aliased-repos.stdout4
-rwxr-xr-xtests.branching/checkout-works-anywhere.script49
-rw-r--r--tests.branching/checkout-works-anywhere.stdout36
-rwxr-xr-xtests.branching/init-cwd.script25
-rw-r--r--tests.branching/init-cwd.stdout2
-rwxr-xr-xtests.branching/init-default.script24
-rw-r--r--tests.branching/init-default.stdout2
-rwxr-xr-xtests.branching/init-existing.script24
-rw-r--r--tests.branching/init-existing.stdout2
-rwxr-xr-xtests.branching/init-newdir.script24
-rw-r--r--tests.branching/init-newdir.stdout2
-rw-r--r--tests.branching/init-nonempty.exit1
-rwxr-xr-xtests.branching/init-nonempty.script24
-rw-r--r--tests.branching/init-nonempty.stderr1
-rwxr-xr-xtests.branching/setup101
-rwxr-xr-xtests.branching/setup-second-chunk62
-rw-r--r--tests.branching/show-system-branch-fails-outside-workspace.exit1
-rwxr-xr-xtests.branching/show-system-branch-fails-outside-workspace.script32
-rw-r--r--tests.branching/show-system-branch-fails-outside-workspace.stderr2
-rw-r--r--tests.branching/show-system-branch-fails-when-branch-is-ambiguous.exit1
-rwxr-xr-xtests.branching/show-system-branch-fails-when-branch-is-ambiguous.script31
-rw-r--r--tests.branching/show-system-branch-fails-when-branch-is-ambiguous.stderr2
-rwxr-xr-xtests.branching/show-system-branch-works-anywhere-with-a-single-branch.script30
-rw-r--r--tests.branching/show-system-branch-works-anywhere-with-a-single-branch.stdout1
-rwxr-xr-xtests.branching/show-system-branch-works-in-different-directories-in-a-branch.script56
-rw-r--r--tests.branching/show-system-branch-works-in-different-directories-in-a-branch.stdout6
-rwxr-xr-xtests.branching/status-in-clean-branch.script26
-rw-r--r--tests.branching/status-in-clean-branch.stdout3
-rwxr-xr-xtests.branching/status-in-dirty-branch.script47
-rw-r--r--tests.branching/status-in-dirty-branch.stdout5
-rwxr-xr-xtests.branching/status-in-workspace.script29
-rw-r--r--tests.branching/status-in-workspace.stdout4
-rwxr-xr-xtests.branching/teardown21
-rw-r--r--tests.branching/workspace-not-found.exit1
-rwxr-xr-xtests.branching/workspace-not-found.script22
-rw-r--r--tests.branching/workspace-not-found.stderr2
-rwxr-xr-xtests.branching/workspace.script23
-rw-r--r--tests.branching/workspace.stdout1
-rw-r--r--without-test-modules1
55 files changed, 0 insertions, 1300 deletions
diff --git a/check b/check
index 1d56c51..ddcb5f0 100755
--- a/check
+++ b/check
@@ -25,14 +25,12 @@ set -e
run_style=false
run_unit_tests=false
run_cmdtests=false
-run_slow_cmdtests=false
run_yarns=false
snapshot=''
if [ "$#" -eq 0 ]; then
run_style=true
run_unit_tests=true
run_cmdtests=true
- run_slow_cmdtests=false
run_yarns=true
fi
while [ "$#" -gt 0 ]
@@ -42,7 +40,6 @@ do
run_style=true
run_unit_tests=true
run_cmdtests=true
- run_slow_cmdtests=true
run_yarns=true
;;
--style)
@@ -63,12 +60,6 @@ do
--no-cmdtests)
run_cmdtests=false
;;
- --slow-cmdtests)
- run_slow_cmdtests=true
- ;;
- --no-slow-cmdtests)
- run_slow_cmdtests=false
- ;;
--yarns)
run_yarns=true
;;
@@ -180,13 +171,6 @@ else
echo "NOT RUNNING test"
fi
-if "$run_slow_cmdtests"
-then
- cmdtest tests.branching
-else
- echo "NOT RUNNING test.branching"
-fi
-
# Building systems requires the 'filter' parameter of tarfile.TarFile.add():
# this was introduced in Python 2.7
if ! "$run_cmdtests"; then
diff --git a/scripts/setup-3rd-party-strata b/scripts/setup-3rd-party-strata
deleted file mode 100644
index fd5aab9..0000000
--- a/scripts/setup-3rd-party-strata
+++ /dev/null
@@ -1,134 +0,0 @@
-#!/bin/sh
-# Copyright (C) 2012-2013,2015 Codethink Limited
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; version 2 of the License.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License along
-# with this program. If not, see <http://www.gnu.org/licenses/>.
-
-
-# Create strata outside the main morphologies repository, which is useful
-# for the more complex workflow tests.
-
-
-. "$SRCDIR/scripts/fix-committer-info"
-
-create_chunk() {
- REPO="$1"
- NAME="$2"
-
- mkdir "$1"
- ln -s "$1" "$1.git"
- cd "$1"
-
- cat <<EOF > "$1/$2.morph"
-{
- "name": "$2",
- "kind": "chunk",
- "build-system": "dummy"
-}
-EOF
-
- git init --quiet
- git add .
- git commit --quiet -m "Initial commit"
-}
-
-write_stratum_morph() {
- REPO="$1"
- NAME="$2"
-
-cat <<EOF > "$1/$2.morph"
-{
- "name": "$2",
- "kind": "stratum",
- "chunks": [
- {
- "name": "hello",
- "repo": "test:$2-hello",
- "ref": "master",
- "build-mode": "test",
- "build-depends": []
- }
- ]
-}
-EOF
-}
-
-# Create two more strata outside the test:morphs repository
-
-EXTERNAL_STRATA_REPO="$DATADIR/external-strata"
-mkdir "$EXTERNAL_STRATA_REPO"
-ln -s "$EXTERNAL_STRATA_REPO" "$EXTERNAL_STRATA_REPO".git
-cd "$EXTERNAL_STRATA_REPO"
-
-git init --quiet .
-
-write_stratum_morph "$EXTERNAL_STRATA_REPO" "stratum2"
-write_stratum_morph "$EXTERNAL_STRATA_REPO" "stratum3"
-
-git add .
-git commit --quiet -m "Initial commit"
-
-# To make life harder, both chunks have the same name too
-
-create_chunk "$DATADIR/stratum2-hello" "hello"
-create_chunk "$DATADIR/stratum3-hello" "hello"
-
-# Update hello-system to include them ... using a system branch! Since the
-# strata refs are 'master' not 'me/add-external-strata' this does not cause
-# problems with merging.
-
-cd "$DATADIR/workspace"
-"$SRCDIR/scripts/test-morph" init
-"$SRCDIR/scripts/test-morph" branch test:morphs me/add-external-strata
-
-cd "$DATADIR/workspace/me/add-external-strata/test:morphs"
-
-cat <<EOF > "hello-system.morph"
-{
- "name": "hello-system",
- "kind": "system",
- "arch": "x86_64",
- "strata": [
- {
- "morph": "hello-stratum",
- "repo": "test:morphs",
- "ref": "master"
- },
- {
- "morph": "stratum2",
- "repo": "test:external-strata",
- "ref": "master"
- },
- {
- "morph": "stratum3",
- "repo": "test:external-strata",
- "ref": "master"
- }
- ]
-}
-EOF
-git commit --quiet --all -m "Add two more external strata"
-
-# Merge to master
-cd "$DATADIR/workspace"
-"$SRCDIR/scripts/test-morph" checkout test:morphs master
-cd master/test:morphs
-"$SRCDIR/scripts/test-morph" merge me/add-external-strata
-
-# In reality the user would do: 'git push origin master' here,
-# but since our remote repo is non-bare we must cheat a bit.
-# We should consider a separate fixture for the workflow tests.
-cd "$DATADIR/morphs"
-git pull -q \
- "file://$DATADIR/workspace/master/test:morphs" master
-
-cd "$DATADIR/workspace"
diff --git a/tests.branching/branch-cleans-up-on-failure.script b/tests.branching/branch-cleans-up-on-failure.script
deleted file mode 100755
index 6dd8eac..0000000
--- a/tests.branching/branch-cleans-up-on-failure.script
+++ /dev/null
@@ -1,29 +0,0 @@
-#!/bin/sh
-#
-# Copyright (C) 2012,2015 Codethink Limited
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; version 2 of the License.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License along
-# with this program. If not, see <http://www.gnu.org/licenses/>.
-
-
-## If a command fails, the state of the workspace should be as if the command
-## was never run
-
-set -eu
-
-cd "$DATADIR/workspace"
-"$SRCDIR/scripts/test-morph" init
-
-# This will fail because we're trying to branch off a ref that doesn't exist
-"$SRCDIR/scripts/test-morph" branch test:morphs foo/bar invalid-ref || true
-
-[ ! -d "$DATADIR/workspace/foo" ]
diff --git a/tests.branching/branch-cleans-up-on-failure.stderr b/tests.branching/branch-cleans-up-on-failure.stderr
deleted file mode 100644
index 959226d..0000000
--- a/tests.branching/branch-cleans-up-on-failure.stderr
+++ /dev/null
@@ -1 +0,0 @@
-ERROR: Git directory TMP/morphs has no commit at ref invalid-ref^{commit}.
diff --git a/tests.branching/branch-creates-new-system-branch-not-from-master.script b/tests.branching/branch-creates-new-system-branch-not-from-master.script
deleted file mode 100755
index e4d815d..0000000
--- a/tests.branching/branch-creates-new-system-branch-not-from-master.script
+++ /dev/null
@@ -1,37 +0,0 @@
-#!/bin/sh
-#
-# Copyright (C) 2012,2014-2015 Codethink Limited
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; version 2 of the License.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License along
-# with this program. If not, see <http://www.gnu.org/licenses/>.
-
-
-## Make sure "morph branch" creates a new system branch.
-
-set -eu
-
-cd "$DATADIR/workspace"
-"$SRCDIR/scripts/test-morph" init
-
-"$SRCDIR/scripts/test-morph" branch test:morphs newbranch alfred
-
-echo "File tree:"
-"$SRCDIR/scripts/list-tree" . | grep -v '/\.git/' |
- sed 's,/cache/gits/file_[^/]*_,/cache/gits/file_,' |
- grep -v 'cache/gits/file_[^/]*/'
-
-echo "Current branches:"
-"$SRCDIR/scripts/run-git-in" newbranch/test/morphs branch
-
-echo "Current origin:"
-"$SRCDIR/scripts/run-git-in" newbranch/test/morphs remote show origin |
- sed 's,\(TMP/workspace/\.morph/cache/gits/file_\).*_,\1,g'
diff --git a/tests.branching/branch-creates-new-system-branch-not-from-master.stdout b/tests.branching/branch-creates-new-system-branch-not-from-master.stdout
deleted file mode 100644
index c568247..0000000
--- a/tests.branching/branch-creates-new-system-branch-not-from-master.stdout
+++ /dev/null
@@ -1,29 +0,0 @@
-File tree:
-d .
-d ./.morph
-d ./newbranch
-d ./newbranch/.morph-system-branch
-d ./newbranch/test
-d ./newbranch/test/morphs
-d ./newbranch/test/morphs/.git
-f ./newbranch/.morph-system-branch/config
-f ./newbranch/test/morphs/DEFAULTS
-f ./newbranch/test/morphs/VERSION
-f ./newbranch/test/morphs/hello-stratum.morph
-f ./newbranch/test/morphs/hello-system.morph
-f ./newbranch/test/morphs/this.is.alfred
-Current branches:
- alfred
-* newbranch
-Current origin:
-* remote origin
- Fetch URL: file://TMP/morphs
- Push URL: file://TMP/morphs
- HEAD branch: master
- Remote branches:
- alfred tracked
- master tracked
- Local branch configured for 'git pull':
- alfred merges with remote alfred
- Local ref configured for 'git push':
- alfred pushes to alfred (up to date)
diff --git a/tests.branching/branch-fails-if-branch-exists.script b/tests.branching/branch-fails-if-branch-exists.script
deleted file mode 100755
index d396d4f..0000000
--- a/tests.branching/branch-fails-if-branch-exists.script
+++ /dev/null
@@ -1,40 +0,0 @@
-#!/bin/sh
-#
-# Copyright (C) 2012,2015 Codethink Limited
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; version 2 of the License.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License along
-# with this program. If not, see <http://www.gnu.org/licenses/>.
-
-
-## Make sure "morph branch" fails if the system branch already exists in the
-## branch root (morphologies repo).
-
-set -eu
-
-cd "$DATADIR/morphs"
-git checkout --quiet -b baserock/existing-branch
-
-cd "$DATADIR/workspace"
-"$SRCDIR/scripts/test-morph" init
-
-# We create a valid branch inside the same prefix first so we can check it
-# doesn't get caught up in the deletion of the invalid branch directory
-
-"$SRCDIR/scripts/test-morph" branch test:morphs baserock/new-branch
-
-[ -d "$DATADIR/workspace/baserock/new-branch" ]
-
-"$SRCDIR/scripts/test-morph" branch test:morphs \
- baserock/existing-branch || true
-
-[ -d "$DATADIR/workspace/baserock/new-branch" ]
-[ ! -d "$DATADIR/workspace/baserock/existing-branch" ]
diff --git a/tests.branching/branch-fails-if-branch-exists.stderr b/tests.branching/branch-fails-if-branch-exists.stderr
deleted file mode 100644
index 5b4bc94..0000000
--- a/tests.branching/branch-fails-if-branch-exists.stderr
+++ /dev/null
@@ -1 +0,0 @@
-ERROR: branch baserock/existing-branch already exists in repository test:morphs
diff --git a/tests.branching/branch-when-branchdir-exists-locally.exit b/tests.branching/branch-when-branchdir-exists-locally.exit
deleted file mode 100644
index d00491f..0000000
--- a/tests.branching/branch-when-branchdir-exists-locally.exit
+++ /dev/null
@@ -1 +0,0 @@
-1
diff --git a/tests.branching/branch-when-branchdir-exists-locally.script b/tests.branching/branch-when-branchdir-exists-locally.script
deleted file mode 100755
index f8f9381..0000000
--- a/tests.branching/branch-when-branchdir-exists-locally.script
+++ /dev/null
@@ -1,28 +0,0 @@
-#!/bin/sh
-#
-# Copyright (C) 2012,2015 Codethink Limited
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; version 2 of the License.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License along
-# with this program. If not, see <http://www.gnu.org/licenses/>.
-
-
-## Make sure "morph branch" fails when the system branch directory already
-## exists.
-
-set -eu
-
-cd "$DATADIR/workspace"
-"$SRCDIR/scripts/test-morph" init
-
-mkdir newbranch
-"$SRCDIR/scripts/test-morph" branch test:morphs newbranch
-
diff --git a/tests.branching/branch-when-branchdir-exists-locally.stderr b/tests.branching/branch-when-branchdir-exists-locally.stderr
deleted file mode 100644
index e178cf2..0000000
--- a/tests.branching/branch-when-branchdir-exists-locally.stderr
+++ /dev/null
@@ -1 +0,0 @@
-ERROR: TMP/workspace/newbranch: File exists
diff --git a/tests.branching/branch-works-anywhere.script b/tests.branching/branch-works-anywhere.script
deleted file mode 100755
index 3dfcffc..0000000
--- a/tests.branching/branch-works-anywhere.script
+++ /dev/null
@@ -1,61 +0,0 @@
-#!/bin/bash
-#
-# Copyright (C) 2012,2014-2015 Codethink Limited
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; version 2 of the License.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License along
-# with this program. If not, see <http://www.gnu.org/licenses/>.
-
-
-## Make sure "morph branch" works anywhere in a workspace or system branch.
-
-set -eu
-
-cd "$DATADIR/workspace"
-"$SRCDIR/scripts/test-morph" init
-
-# First, create a branch.
-"$SRCDIR/scripts/test-morph" branch test:morphs branch1
-
-echo "Workspace after creating the first branch:"
-"$SRCDIR/scripts/list-tree" "$DATADIR/workspace" | grep -v '/\.git/' |
- sed 's,/cache/gits/file_[^/]*_,/cache/gits/file_,' |
- grep -v 'cache/gits/file_[^/]*/'
-
-# Now, create a nother branch from the workspace.
-"$SRCDIR/scripts/test-morph" branch test:morphs branch2
-
-echo "Workspace after creating the second branch:"
-"$SRCDIR/scripts/list-tree" "$DATADIR/workspace" | grep -v '/\.git/' |
- sed 's,/cache/gits/file_[^/]*_,/cache/gits/file_,' |
- grep -v 'cache/gits/file_[^/]*/'
-
-# Now, enter the first branch and create a third branch, which
-# should not be created in the working directory but in the
-# workspace directory.
-cd "$DATADIR/workspace/branch1"
-"$SRCDIR/scripts/test-morph" branch test:morphs branch3
-
-echo "Workspace after creating the third branch:"
-"$SRCDIR/scripts/list-tree" "$DATADIR/workspace" | grep -v '/\.git/' |
- sed 's,/cache/gits/file_[^/]*_,/cache/gits/file_,' |
- grep -v 'cache/gits/file_[^/]*/'
-
-# Now, go into the morphs repository of that third branch and
-# create a fourth system branch from in there. This, too, should
-# end up being created in the toplevel workspace directory.
-cd "$DATADIR/workspace/branch3/test/morphs"
-"$SRCDIR/scripts/test-morph" branch test:morphs branch4
-
-echo "Workspace after creating the fourth branch:"
-"$SRCDIR/scripts/list-tree" "$DATADIR/workspace" | grep -v '/\.git/' |
- sed 's,/cache/gits/file_[^/]*_,/cache/gits/file_,' |
- grep -v 'cache/gits/file_[^/]*/'
diff --git a/tests.branching/branch-works-anywhere.stdout b/tests.branching/branch-works-anywhere.stdout
deleted file mode 100644
index e3c7bfb..0000000
--- a/tests.branching/branch-works-anywhere.stdout
+++ /dev/null
@@ -1,112 +0,0 @@
-Workspace after creating the first branch:
-d .
-d ./.morph
-d ./branch1
-d ./branch1/.morph-system-branch
-d ./branch1/test
-d ./branch1/test/morphs
-d ./branch1/test/morphs/.git
-f ./branch1/.morph-system-branch/config
-f ./branch1/test/morphs/DEFAULTS
-f ./branch1/test/morphs/VERSION
-f ./branch1/test/morphs/hello-stratum.morph
-f ./branch1/test/morphs/hello-system.morph
-Workspace after creating the second branch:
-d .
-d ./.morph
-d ./branch1
-d ./branch1/.morph-system-branch
-d ./branch1/test
-d ./branch1/test/morphs
-d ./branch1/test/morphs/.git
-d ./branch2
-d ./branch2/.morph-system-branch
-d ./branch2/test
-d ./branch2/test/morphs
-d ./branch2/test/morphs/.git
-f ./branch1/.morph-system-branch/config
-f ./branch1/test/morphs/DEFAULTS
-f ./branch1/test/morphs/VERSION
-f ./branch1/test/morphs/hello-stratum.morph
-f ./branch1/test/morphs/hello-system.morph
-f ./branch2/.morph-system-branch/config
-f ./branch2/test/morphs/DEFAULTS
-f ./branch2/test/morphs/VERSION
-f ./branch2/test/morphs/hello-stratum.morph
-f ./branch2/test/morphs/hello-system.morph
-Workspace after creating the third branch:
-d .
-d ./.morph
-d ./branch1
-d ./branch1/.morph-system-branch
-d ./branch1/test
-d ./branch1/test/morphs
-d ./branch1/test/morphs/.git
-d ./branch2
-d ./branch2/.morph-system-branch
-d ./branch2/test
-d ./branch2/test/morphs
-d ./branch2/test/morphs/.git
-d ./branch3
-d ./branch3/.morph-system-branch
-d ./branch3/test
-d ./branch3/test/morphs
-d ./branch3/test/morphs/.git
-f ./branch1/.morph-system-branch/config
-f ./branch1/test/morphs/DEFAULTS
-f ./branch1/test/morphs/VERSION
-f ./branch1/test/morphs/hello-stratum.morph
-f ./branch1/test/morphs/hello-system.morph
-f ./branch2/.morph-system-branch/config
-f ./branch2/test/morphs/DEFAULTS
-f ./branch2/test/morphs/VERSION
-f ./branch2/test/morphs/hello-stratum.morph
-f ./branch2/test/morphs/hello-system.morph
-f ./branch3/.morph-system-branch/config
-f ./branch3/test/morphs/DEFAULTS
-f ./branch3/test/morphs/VERSION
-f ./branch3/test/morphs/hello-stratum.morph
-f ./branch3/test/morphs/hello-system.morph
-Workspace after creating the fourth branch:
-d .
-d ./.morph
-d ./branch1
-d ./branch1/.morph-system-branch
-d ./branch1/test
-d ./branch1/test/morphs
-d ./branch1/test/morphs/.git
-d ./branch2
-d ./branch2/.morph-system-branch
-d ./branch2/test
-d ./branch2/test/morphs
-d ./branch2/test/morphs/.git
-d ./branch3
-d ./branch3/.morph-system-branch
-d ./branch3/test
-d ./branch3/test/morphs
-d ./branch3/test/morphs/.git
-d ./branch4
-d ./branch4/.morph-system-branch
-d ./branch4/test
-d ./branch4/test/morphs
-d ./branch4/test/morphs/.git
-f ./branch1/.morph-system-branch/config
-f ./branch1/test/morphs/DEFAULTS
-f ./branch1/test/morphs/VERSION
-f ./branch1/test/morphs/hello-stratum.morph
-f ./branch1/test/morphs/hello-system.morph
-f ./branch2/.morph-system-branch/config
-f ./branch2/test/morphs/DEFAULTS
-f ./branch2/test/morphs/VERSION
-f ./branch2/test/morphs/hello-stratum.morph
-f ./branch2/test/morphs/hello-system.morph
-f ./branch3/.morph-system-branch/config
-f ./branch3/test/morphs/DEFAULTS
-f ./branch3/test/morphs/VERSION
-f ./branch3/test/morphs/hello-stratum.morph
-f ./branch3/test/morphs/hello-system.morph
-f ./branch4/.morph-system-branch/config
-f ./branch4/test/morphs/DEFAULTS
-f ./branch4/test/morphs/VERSION
-f ./branch4/test/morphs/hello-stratum.morph
-f ./branch4/test/morphs/hello-system.morph
diff --git a/tests.branching/checkout-cleans-up-on-failure.script b/tests.branching/checkout-cleans-up-on-failure.script
deleted file mode 100755
index fa0d61f..0000000
--- a/tests.branching/checkout-cleans-up-on-failure.script
+++ /dev/null
@@ -1,28 +0,0 @@
-#!/bin/sh
-#
-# Copyright (C) 2012,2015 Codethink Limited
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; version 2 of the License.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License along
-# with this program. If not, see <http://www.gnu.org/licenses/>.
-
-
-## If a command fails, the state of the workspace should be as if the command
-## was never run
-
-set -eu
-
-cd "$DATADIR/workspace"
-"$SRCDIR/scripts/test-morph" init
-
-"$SRCDIR/scripts/test-morph" checkout test:morphs i/do/not/exist || true
-
-[ ! -d "$DATADIR/workspace/i" ]
diff --git a/tests.branching/checkout-cleans-up-on-failure.stderr b/tests.branching/checkout-cleans-up-on-failure.stderr
deleted file mode 100644
index 14ed130..0000000
--- a/tests.branching/checkout-cleans-up-on-failure.stderr
+++ /dev/null
@@ -1 +0,0 @@
-ERROR: Git directory TMP/morphs has no commit at ref i/do/not/exist^{commit}.
diff --git a/tests.branching/checkout-non-aliased-repos.script b/tests.branching/checkout-non-aliased-repos.script
deleted file mode 100755
index 4b2ac1c..0000000
--- a/tests.branching/checkout-non-aliased-repos.script
+++ /dev/null
@@ -1,51 +0,0 @@
-#!/bin/bash
-#
-# Copyright (C) 2012,2015 Codethink Limited
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; version 2 of the License.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License along
-# with this program. If not, see <http://www.gnu.org/licenses/>.
-
-
-## Verify that "morph checkout" works with repos that are not aliased.
-## This test in particular verifies that URI schemes are stripped off
-## and that the .git suffix is only removed at the end if it is actually
-## present.
-
-set -eu
-
-REPO_WITH_SUFFIX="file://$DATADIR/morphs.git"
-REPO_WITHOUT_SUFFIX="file://$DATADIR/morphs"
-
-TEMP_DIR=$(dirname "$DATADIR")
-
-cd "$DATADIR/workspace"
-
-"$SRCDIR/scripts/test-morph" init
-"$SRCDIR/scripts/test-morph" checkout "$REPO_WITH_SUFFIX" master
-
-test -d "$DATADIR/workspace/master/$DATADIR/morphs"
-
-echo "Current branches of repo with suffix:"
-"$SRCDIR/scripts/run-git-in" master/"${DATADIR:1}"/morphs branch
-
-cd "$DATADIR"
-rm -rf "$DATADIR/workspace"
-mkdir "$DATADIR/workspace"
-cd "$DATADIR/workspace"
-
-"$SRCDIR/scripts/test-morph" init
-"$SRCDIR/scripts/test-morph" checkout "$REPO_WITHOUT_SUFFIX" master
-
-test -d "$DATADIR/workspace/master/$DATADIR/morphs"
-
-echo "Current branches of repo without suffix:"
-"$SRCDIR/scripts/run-git-in" master/"${DATADIR:1}"/morphs branch
diff --git a/tests.branching/checkout-non-aliased-repos.stdout b/tests.branching/checkout-non-aliased-repos.stdout
deleted file mode 100644
index 2d056c2..0000000
--- a/tests.branching/checkout-non-aliased-repos.stdout
+++ /dev/null
@@ -1,4 +0,0 @@
-Current branches of repo with suffix:
-* master
-Current branches of repo without suffix:
-* master
diff --git a/tests.branching/checkout-works-anywhere.script b/tests.branching/checkout-works-anywhere.script
deleted file mode 100755
index ebd5afc..0000000
--- a/tests.branching/checkout-works-anywhere.script
+++ /dev/null
@@ -1,49 +0,0 @@
-#!/bin/bash
-#
-# Copyright (C) 2012,2014-2015 Codethink Limited
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; version 2 of the License.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License along
-# with this program. If not, see <http://www.gnu.org/licenses/>.
-
-
-## Make sure "morph checkout" works anywhere in a workspace or system branch.
-
-set -eu
-
-cd "$DATADIR/workspace"
-"$SRCDIR/scripts/test-morph" init
-
-# First, check out the master branch from the workspace directory.
-"$SRCDIR/scripts/test-morph" checkout test:morphs master
-
-echo "Workspace after checking out master from the workspace directory:"
-"$SRCDIR/scripts/list-tree" "$DATADIR/workspace" | grep -v '/\.git/' |
- sed 's,/cache/gits/file_[^/]*_,/cache/gits/file_,' |
- grep -v 'cache/gits/file_[^/]*/'
-
-# Reset the workspace.
-cd "$DATADIR"
-rm -rf workspace
-mkdir workspace
-cd workspace
-"$SRCDIR/scripts/test-morph" init
-
-# This time, create a new branch and check out the master branch
-# from within that branch.
-"$SRCDIR/scripts/test-morph" branch test:morphs newbranch
-cd newbranch/test/morphs
-"$SRCDIR/scripts/test-morph" checkout test:morphs master
-
-echo "Workspace after checking out master from within a new branch:"
-"$SRCDIR/scripts/list-tree" "$DATADIR/workspace" | grep -v '/\.git/' |
- sed 's,/cache/gits/file_[^/]*_,/cache/gits/file_,' |
- grep -v 'cache/gits/file_[^/]*/'
diff --git a/tests.branching/checkout-works-anywhere.stdout b/tests.branching/checkout-works-anywhere.stdout
deleted file mode 100644
index 737a605..0000000
--- a/tests.branching/checkout-works-anywhere.stdout
+++ /dev/null
@@ -1,36 +0,0 @@
-Workspace after checking out master from the workspace directory:
-d .
-d ./.morph
-d ./master
-d ./master/.morph-system-branch
-d ./master/test
-d ./master/test/morphs
-d ./master/test/morphs/.git
-f ./master/.morph-system-branch/config
-f ./master/test/morphs/DEFAULTS
-f ./master/test/morphs/VERSION
-f ./master/test/morphs/hello-stratum.morph
-f ./master/test/morphs/hello-system.morph
-Workspace after checking out master from within a new branch:
-d .
-d ./.morph
-d ./master
-d ./master/.morph-system-branch
-d ./master/test
-d ./master/test/morphs
-d ./master/test/morphs/.git
-d ./newbranch
-d ./newbranch/.morph-system-branch
-d ./newbranch/test
-d ./newbranch/test/morphs
-d ./newbranch/test/morphs/.git
-f ./master/.morph-system-branch/config
-f ./master/test/morphs/DEFAULTS
-f ./master/test/morphs/VERSION
-f ./master/test/morphs/hello-stratum.morph
-f ./master/test/morphs/hello-system.morph
-f ./newbranch/.morph-system-branch/config
-f ./newbranch/test/morphs/DEFAULTS
-f ./newbranch/test/morphs/VERSION
-f ./newbranch/test/morphs/hello-stratum.morph
-f ./newbranch/test/morphs/hello-system.morph
diff --git a/tests.branching/init-cwd.script b/tests.branching/init-cwd.script
deleted file mode 100755
index 9613bac..0000000
--- a/tests.branching/init-cwd.script
+++ /dev/null
@@ -1,25 +0,0 @@
-#!/bin/sh
-#
-# Copyright (C) 2012,2015 Codethink Limited
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; version 2 of the License.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License along
-# with this program. If not, see <http://www.gnu.org/licenses/>.
-
-
-## Test that "morph init" works for the current working directory.
-
-set -eu
-
-cd "$DATADIR/workspace"
-"$SRCDIR/scripts/test-morph" init .
-"$SRCDIR/scripts/list-tree" "$DATADIR/workspace"
-
diff --git a/tests.branching/init-cwd.stdout b/tests.branching/init-cwd.stdout
deleted file mode 100644
index e7922ee..0000000
--- a/tests.branching/init-cwd.stdout
+++ /dev/null
@@ -1,2 +0,0 @@
-d .
-d ./.morph
diff --git a/tests.branching/init-default.script b/tests.branching/init-default.script
deleted file mode 100755
index 328f9f8..0000000
--- a/tests.branching/init-default.script
+++ /dev/null
@@ -1,24 +0,0 @@
-#!/bin/sh
-#
-# Copyright (C) 2012,2015 Codethink Limited
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; version 2 of the License.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License along
-# with this program. If not, see <http://www.gnu.org/licenses/>.
-
-
-## Test that "morph init" works without an explicit argument.
-
-set -eu
-
-cd "$DATADIR/workspace"
-"$SRCDIR/scripts/test-morph" init
-"$SRCDIR/scripts/list-tree" "$DATADIR/workspace"
diff --git a/tests.branching/init-default.stdout b/tests.branching/init-default.stdout
deleted file mode 100644
index e7922ee..0000000
--- a/tests.branching/init-default.stdout
+++ /dev/null
@@ -1,2 +0,0 @@
-d .
-d ./.morph
diff --git a/tests.branching/init-existing.script b/tests.branching/init-existing.script
deleted file mode 100755
index c2671ab..0000000
--- a/tests.branching/init-existing.script
+++ /dev/null
@@ -1,24 +0,0 @@
-#!/bin/sh
-#
-# Copyright (C) 2012,2015 Codethink Limited
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; version 2 of the License.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License along
-# with this program. If not, see <http://www.gnu.org/licenses/>.
-
-
-## Test that "morph init" works when given the name of an existing,
-## empty directory.
-
-set -eu
-
-"$SRCDIR/scripts/test-morph" init "$DATADIR/workspace"
-"$SRCDIR/scripts/list-tree" "$DATADIR/workspace"
diff --git a/tests.branching/init-existing.stdout b/tests.branching/init-existing.stdout
deleted file mode 100644
index e7922ee..0000000
--- a/tests.branching/init-existing.stdout
+++ /dev/null
@@ -1,2 +0,0 @@
-d .
-d ./.morph
diff --git a/tests.branching/init-newdir.script b/tests.branching/init-newdir.script
deleted file mode 100755
index 2ebe432..0000000
--- a/tests.branching/init-newdir.script
+++ /dev/null
@@ -1,24 +0,0 @@
-#!/bin/sh
-#
-# Copyright (C) 2012,2015 Codethink Limited
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; version 2 of the License.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License along
-# with this program. If not, see <http://www.gnu.org/licenses/>.
-
-
-## Test that "morph init" works if given a directory that
-## does not exist yet.
-
-set -eu
-
-"$SRCDIR/scripts/test-morph" init "$DATADIR/foo"
-"$SRCDIR/scripts/list-tree" "$DATADIR/foo"
diff --git a/tests.branching/init-newdir.stdout b/tests.branching/init-newdir.stdout
deleted file mode 100644
index e7922ee..0000000
--- a/tests.branching/init-newdir.stdout
+++ /dev/null
@@ -1,2 +0,0 @@
-d .
-d ./.morph
diff --git a/tests.branching/init-nonempty.exit b/tests.branching/init-nonempty.exit
deleted file mode 100644
index d00491f..0000000
--- a/tests.branching/init-nonempty.exit
+++ /dev/null
@@ -1 +0,0 @@
-1
diff --git a/tests.branching/init-nonempty.script b/tests.branching/init-nonempty.script
deleted file mode 100755
index a3aba9e..0000000
--- a/tests.branching/init-nonempty.script
+++ /dev/null
@@ -1,24 +0,0 @@
-#!/bin/sh
-#
-# Copyright (C) 2012,2015 Codethink Limited
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; version 2 of the License.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License along
-# with this program. If not, see <http://www.gnu.org/licenses/>.
-
-
-## Test that "morph init" fails when given the name of an existing,
-## non-empty directory.
-
-set -eu
-
-touch "$DATADIR/workspace/foo"
-"$SRCDIR/scripts/test-morph" init "$DATADIR/workspace"
diff --git a/tests.branching/init-nonempty.stderr b/tests.branching/init-nonempty.stderr
deleted file mode 100644
index bc0ef0e..0000000
--- a/tests.branching/init-nonempty.stderr
+++ /dev/null
@@ -1 +0,0 @@
-ERROR: can only initialize empty directory as a workspace: TMP/workspace
diff --git a/tests.branching/setup b/tests.branching/setup
deleted file mode 100755
index c10b4fe..0000000
--- a/tests.branching/setup
+++ /dev/null
@@ -1,101 +0,0 @@
-#!/bin/bash
-# Copyright (C) 2012-2015 Codethink Limited
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; version 2 of the License.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License along
-# with this program. If not, see <http://www.gnu.org/licenses/>.
-
-
-# Set up $DATADIR.
-#
-# - a morph.conf configuration file
-# - an empty morph workspace directory
-# - a git repository called "morphs" for fake system, stratum morphologies
-# - a git repository calle "hello" for a dummy chunk
-
-set -eu
-
-source "$SRCDIR/scripts/fix-committer-info"
-
-# Create a morph configuration file
-cat <<EOF > "$DATADIR/morph.conf"
-[config]
-repo-alias = test=file://$DATADIR/%s#file://$DATADIR/%s
-cachedir = $DATADIR/cache
-log = $DATADIR/morph.log
-tempdir = $TMPDIR
-no-distcc = true
-quiet = true
-EOF
-
-
-# Create an empty directory to be used as a morph workspace
-mkdir "$DATADIR/workspace"
-
-
-# Create a fake morphs repository
-mkdir "$DATADIR/morphs"
-
-## Create a link to this repo that has a .git suffix
-ln -s "$DATADIR/morphs" "$DATADIR/morphs.git"
-
-echo 'version: 7' > "$DATADIR/morphs/VERSION"
-
-# We don't build anything, so empty DEFAULTS file is fine.
-echo '' > "$DATADIR/morphs/DEFAULTS"
-
-cat <<EOF > "$DATADIR/morphs/hello-system.morph"
-name: hello-system
-kind: system
-arch: $("$SRCDIR/scripts/test-morph" print-architecture)
-strata:
-- morph: hello-stratum
-EOF
-
-cat <<EOF > "$DATADIR/morphs/hello-stratum.morph"
-name: hello-stratum
-kind: stratum
-chunks:
-- name: hello
- repo: test:hello
- ref: master
- build-depends: []
- build-mode: bootstrap
- build-system: manual
-EOF
-
-
-scripts/run-git-in "$DATADIR/morphs" init
-scripts/run-git-in "$DATADIR/morphs" add .
-scripts/run-git-in "$DATADIR/morphs" commit -m initial
-
-
-# Add an extra branch to the morphs repo.
-scripts/run-git-in "$DATADIR/morphs" checkout -b alfred
-touch "$DATADIR/morphs/this.is.alfred"
-scripts/run-git-in "$DATADIR/morphs" add this.is.alfred
-scripts/run-git-in "$DATADIR/morphs" commit --quiet -m 'mark as alfred'
-scripts/run-git-in "$DATADIR/morphs" checkout master
-
-# Create a dummy chunk repository
-mkdir "$DATADIR/hello"
-
-echo 'Chunk repo is empty' > "$DATADIR"/hello/dummy
-
-scripts/run-git-in "$DATADIR/hello" init
-scripts/run-git-in "$DATADIR/hello" add .
-scripts/run-git-in "$DATADIR/hello" commit -m initial
-
-
-# Add an extra branch to the hello repo.
-scripts/run-git-in "$DATADIR/hello" checkout -b alfred
-scripts/run-git-in "$DATADIR/hello" checkout master
-
diff --git a/tests.branching/setup-second-chunk b/tests.branching/setup-second-chunk
deleted file mode 100755
index 416a773..0000000
--- a/tests.branching/setup-second-chunk
+++ /dev/null
@@ -1,62 +0,0 @@
-#!/bin/sh
-# Copyright (C) 2012-2015 Codethink Limited
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; version 2 of the License.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License along
-# with this program. If not, see <http://www.gnu.org/licenses/>.
-
-
-# Add a second chunk to hello-stratum.
-
-. "$SRCDIR/scripts/fix-committer-info"
-
-create_chunk() {
- REPO="$1"
- NAME="$2"
-
- mkdir "$1"
- ln -s "$1" "$1.git"
- cd "$1"
-
- cat <<EOF > "$1/$2.morph"
-kind: chunk
-name: $2
-EOF
-
- git init --quiet
- git add .
- git commit --quiet -m "Initial commit"
-}
-
-create_chunk "$DATADIR/goodbye" "goodbye"
-
-cd "$DATADIR/morphs"
-cat <<EOF > hello-stratum.morph
-name: hello-stratum
-kind: stratum
-chunks:
-- name: hello
- repo: test:hello
- ref: master
- build-depends: []
- build-mode: bootstrap
- build-system: manual
-- name: goodbye
- repo: test:goodbye
- ref: master
- build-depends: []
- build-mode: bootstrap
- build-system: manual
-EOF
-
-git commit -q --all -m "Add goodbye to hello-stratum"
-
-cd "$DATADIR/workspace"
diff --git a/tests.branching/show-system-branch-fails-outside-workspace.exit b/tests.branching/show-system-branch-fails-outside-workspace.exit
deleted file mode 100644
index d00491f..0000000
--- a/tests.branching/show-system-branch-fails-outside-workspace.exit
+++ /dev/null
@@ -1 +0,0 @@
-1
diff --git a/tests.branching/show-system-branch-fails-outside-workspace.script b/tests.branching/show-system-branch-fails-outside-workspace.script
deleted file mode 100755
index 95bdbc9..0000000
--- a/tests.branching/show-system-branch-fails-outside-workspace.script
+++ /dev/null
@@ -1,32 +0,0 @@
-#!/bin/sh
-#
-# Copyright (C) 2012,2015 Codethink Limited
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; version 2 of the License.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License along
-# with this program. If not, see <http://www.gnu.org/licenses/>.
-
-
-## Check that 'morph show-system-branch' fails when being run
-## outside a workspace.
-
-set -eu
-
-# Create a workspace and branch.
-cd "$DATADIR/workspace"
-"$SRCDIR/scripts/test-morph" init
-"$SRCDIR/scripts/test-morph" branch test:morphs testbranch
-
-# Leave the workspace.
-cd ..
-
-# Try to show the current branch.
-"$SRCDIR/scripts/test-morph" show-system-branch
diff --git a/tests.branching/show-system-branch-fails-outside-workspace.stderr b/tests.branching/show-system-branch-fails-outside-workspace.stderr
deleted file mode 100644
index 041c64b..0000000
--- a/tests.branching/show-system-branch-fails-outside-workspace.stderr
+++ /dev/null
@@ -1,2 +0,0 @@
-ERROR: Can't find the workspace directory.
-Morph must be built and deployed within the system branch checkout within the workspace directory.
diff --git a/tests.branching/show-system-branch-fails-when-branch-is-ambiguous.exit b/tests.branching/show-system-branch-fails-when-branch-is-ambiguous.exit
deleted file mode 100644
index d00491f..0000000
--- a/tests.branching/show-system-branch-fails-when-branch-is-ambiguous.exit
+++ /dev/null
@@ -1 +0,0 @@
-1
diff --git a/tests.branching/show-system-branch-fails-when-branch-is-ambiguous.script b/tests.branching/show-system-branch-fails-when-branch-is-ambiguous.script
deleted file mode 100755
index bb69eb1..0000000
--- a/tests.branching/show-system-branch-fails-when-branch-is-ambiguous.script
+++ /dev/null
@@ -1,31 +0,0 @@
-#!/bin/sh
-#
-# Copyright (C) 2012,2015 Codethink Limited
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; version 2 of the License.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License along
-# with this program. If not, see <http://www.gnu.org/licenses/>.
-
-
-## Check that 'morph show-system-branch' fails when the system branch
-## is not obvious.
-
-set -eu
-
-# Create a workspace and two system branches
-cd "$DATADIR/workspace"
-"$SRCDIR/scripts/test-morph" init
-"$SRCDIR/scripts/test-morph" branch test:morphs first/branch
-"$SRCDIR/scripts/test-morph" branch test:morphs second/branch
-
-# Try to find out the branch from the workspace directory.
-cd "$DATADIR/workspace"
-"$SRCDIR/scripts/test-morph" show-system-branch
diff --git a/tests.branching/show-system-branch-fails-when-branch-is-ambiguous.stderr b/tests.branching/show-system-branch-fails-when-branch-is-ambiguous.stderr
deleted file mode 100644
index 7a0a1b0..0000000
--- a/tests.branching/show-system-branch-fails-when-branch-is-ambiguous.stderr
+++ /dev/null
@@ -1,2 +0,0 @@
-ERROR: Can't find the system branch directory.
-Morph must be built and deployed within the system branch checkout.
diff --git a/tests.branching/show-system-branch-works-anywhere-with-a-single-branch.script b/tests.branching/show-system-branch-works-anywhere-with-a-single-branch.script
deleted file mode 100755
index f7d8c7a..0000000
--- a/tests.branching/show-system-branch-works-anywhere-with-a-single-branch.script
+++ /dev/null
@@ -1,30 +0,0 @@
-#!/bin/sh
-#
-# Copyright (C) 2012,2015 Codethink Limited
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; version 2 of the License.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License along
-# with this program. If not, see <http://www.gnu.org/licenses/>.
-
-
-## Check that 'morph show-system-branch' works even outside a branch
-## if there only is one in the workspcae.
-
-set -eu
-
-# Create a workspace and a system branch.
-cd "$DATADIR/workspace"
-"$SRCDIR/scripts/test-morph" init
-"$SRCDIR/scripts/test-morph" branch test:morphs first/branch
-
-# Show the branch even when outside the branch.
-cd "$DATADIR/workspace"
-"$SRCDIR/scripts/test-morph" show-system-branch
diff --git a/tests.branching/show-system-branch-works-anywhere-with-a-single-branch.stdout b/tests.branching/show-system-branch-works-anywhere-with-a-single-branch.stdout
deleted file mode 100644
index b934ad8..0000000
--- a/tests.branching/show-system-branch-works-anywhere-with-a-single-branch.stdout
+++ /dev/null
@@ -1 +0,0 @@
-first/branch
diff --git a/tests.branching/show-system-branch-works-in-different-directories-in-a-branch.script b/tests.branching/show-system-branch-works-in-different-directories-in-a-branch.script
deleted file mode 100755
index ab46cb0..0000000
--- a/tests.branching/show-system-branch-works-in-different-directories-in-a-branch.script
+++ /dev/null
@@ -1,56 +0,0 @@
-#!/bin/sh
-#
-# Copyright (C) 2012,2015 Codethink Limited
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; version 2 of the License.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License along
-# with this program. If not, see <http://www.gnu.org/licenses/>.
-
-
-## Check that 'morph show-system-branch' shows the name of the
-## current system branch correctly from various working directories.
-
-set -eu
-
-# Create a workspace and two system branches.
-cd "$DATADIR/workspace"
-"$SRCDIR/scripts/test-morph" init
-"$SRCDIR/scripts/test-morph" branch test:morphs first/branch
-"$SRCDIR/scripts/test-morph" branch test:morphs second/branch
-
-# Create a few subdirectories in the first branch.
-mkdir -p "$DATADIR/workspace/first/branch/foo"
-mkdir -p "$DATADIR/workspace/first/branch/bar"
-mkdir -p "$DATADIR/workspace/first/branch/foo/bar/baz"
-
-# Show the first branch when partially inside the branch.
-cd "$DATADIR/workspace/first"
-"$SRCDIR/scripts/test-morph" show-system-branch
-
-# Show the first branch when inside the main branch directory.
-cd "$DATADIR/workspace/first/branch"
-"$SRCDIR/scripts/test-morph" show-system-branch
-
-# Show the first branch when somewhere inside the branch.
-cd "$DATADIR/workspace/first/branch/foo"
-"$SRCDIR/scripts/test-morph" show-system-branch
-
-# Show the first branch when somewhere else inside the branch.
-cd "$DATADIR/workspace/first/branch/foo/bar/baz"
-"$SRCDIR/scripts/test-morph" show-system-branch
-
-# Show the second branch when partially inside the branch.
-cd "$DATADIR/workspace/second"
-"$SRCDIR/scripts/test-morph" show-system-branch
-
-# Show the second branch when inside the main branch directory.
-cd "$DATADIR/workspace/second/branch"
-"$SRCDIR/scripts/test-morph" show-system-branch
diff --git a/tests.branching/show-system-branch-works-in-different-directories-in-a-branch.stdout b/tests.branching/show-system-branch-works-in-different-directories-in-a-branch.stdout
deleted file mode 100644
index f9cc3ae..0000000
--- a/tests.branching/show-system-branch-works-in-different-directories-in-a-branch.stdout
+++ /dev/null
@@ -1,6 +0,0 @@
-first/branch
-first/branch
-first/branch
-first/branch
-second/branch
-second/branch
diff --git a/tests.branching/status-in-clean-branch.script b/tests.branching/status-in-clean-branch.script
deleted file mode 100755
index a7f38a6..0000000
--- a/tests.branching/status-in-clean-branch.script
+++ /dev/null
@@ -1,26 +0,0 @@
-#!/bin/sh
-#
-# Copyright (C) 2011, 2012,2015 Codethink Limited
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; version 2 of the License.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License along
-# with this program. If not, see <http://www.gnu.org/licenses/>.
-
-
-## 'morph status' within a branch
-
-set -eu
-
-cd "$DATADIR/workspace"
-"$SRCDIR/scripts/test-morph" init .
-"$SRCDIR/scripts/test-morph" branch test:morphs test
-
-"$SRCDIR/scripts/test-morph" status
diff --git a/tests.branching/status-in-clean-branch.stdout b/tests.branching/status-in-clean-branch.stdout
deleted file mode 100644
index 684ab9c..0000000
--- a/tests.branching/status-in-clean-branch.stdout
+++ /dev/null
@@ -1,3 +0,0 @@
-On branch test, root test:morphs
-
-No repos have outstanding changes.
diff --git a/tests.branching/status-in-dirty-branch.script b/tests.branching/status-in-dirty-branch.script
deleted file mode 100755
index 5cc8b3a..0000000
--- a/tests.branching/status-in-dirty-branch.script
+++ /dev/null
@@ -1,47 +0,0 @@
-#!/bin/sh
-#
-# Copyright (C) 2011-2015 Codethink Limited
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; version 2 of the License.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License along
-# with this program. If not, see <http://www.gnu.org/licenses/>.
-
-
-## 'morph status' within a branch
-
-set -eu
-
-# FIXME: This is disabled, since a) we haven't decided if we really
-# want to support system and stratum morphologies in different git
-# repos, and b) the rewritten "morph edit" thus doesn't support it,
-# since writing the code is not necessarily simple if one wants to
-# cover all corner cases.
-cat "$SRCDIR/tests.branching/status-in-dirty-branch.stdout"
-exit 0
-
-. "$SRCDIR/scripts/setup-3rd-party-strata"
-
-cd "$DATADIR/workspace"
-"$SRCDIR/scripts/test-morph" branch test:morphs branch1
-
-# Make the branch have some interesting changes and pitfalls
-cd branch1
-"$SRCDIR/scripts/test-morph" edit hello
-
-cd test/stratum2-hello
-git checkout -q master
-
-cd ..
-mkdir red-herring
-cd red-herring
-git init -q .
-
-"$SRCDIR/scripts/test-morph" status
diff --git a/tests.branching/status-in-dirty-branch.stdout b/tests.branching/status-in-dirty-branch.stdout
deleted file mode 100644
index bee47ea..0000000
--- a/tests.branching/status-in-dirty-branch.stdout
+++ /dev/null
@@ -1,5 +0,0 @@
-On branch branch1, root test:morphs
- test:morphs: uncommitted changes
- TMP/workspace/branch1/red-herring: not part of system branch
- test:external-strata: uncommitted changes
- test:stratum2-hello: unexpected ref checked out "master"
diff --git a/tests.branching/status-in-workspace.script b/tests.branching/status-in-workspace.script
deleted file mode 100755
index 9bfeb99..0000000
--- a/tests.branching/status-in-workspace.script
+++ /dev/null
@@ -1,29 +0,0 @@
-#!/bin/sh
-#
-# Copyright (C) 2011, 2012,2015 Codethink Limited
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; version 2 of the License.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License along
-# with this program. If not, see <http://www.gnu.org/licenses/>.
-
-
-## 'morph status' within a workspace
-
-set -eu
-
-cd "$DATADIR/workspace"
-"$SRCDIR/scripts/test-morph" init .
-"$SRCDIR/scripts/test-morph" checkout test:morphs master
-"$SRCDIR/scripts/test-morph" branch test:morphs a/b/c/d/e/foo
-"$SRCDIR/scripts/test-morph" branch test:morphs a/b/c/d/e/bar
-mkdir a/b/c/red-herring
-
-"$SRCDIR/scripts/test-morph" status
diff --git a/tests.branching/status-in-workspace.stdout b/tests.branching/status-in-workspace.stdout
deleted file mode 100644
index 1595873..0000000
--- a/tests.branching/status-in-workspace.stdout
+++ /dev/null
@@ -1,4 +0,0 @@
-System branches in current workspace:
- a/b/c/d/e/bar
- a/b/c/d/e/foo
- master
diff --git a/tests.branching/teardown b/tests.branching/teardown
deleted file mode 100755
index d5d7b60..0000000
--- a/tests.branching/teardown
+++ /dev/null
@@ -1,21 +0,0 @@
-#!/bin/sh
-# Copyright (C) 2012,2015 Codethink Limited
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; version 2 of the License.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License along
-# with this program. If not, see <http://www.gnu.org/licenses/>.
-
-
-# Clean up $DATADIR.
-
-set -eu
-
-find "$DATADIR" -mindepth 1 -delete
diff --git a/tests.branching/workspace-not-found.exit b/tests.branching/workspace-not-found.exit
deleted file mode 100644
index d00491f..0000000
--- a/tests.branching/workspace-not-found.exit
+++ /dev/null
@@ -1 +0,0 @@
-1
diff --git a/tests.branching/workspace-not-found.script b/tests.branching/workspace-not-found.script
deleted file mode 100755
index 629fd1e..0000000
--- a/tests.branching/workspace-not-found.script
+++ /dev/null
@@ -1,22 +0,0 @@
-#!/bin/sh
-#
-# Copyright (C) 2012,2015 Codethink Limited
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; version 2 of the License.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License along
-# with this program. If not, see <http://www.gnu.org/licenses/>.
-
-
-## Handle being run from outside workspace directory.
-
-scripts/test-morph init "$DATADIR/workspace"
-cd "$DATADIR"
-"$SRCDIR/scripts/test-morph" workspace
diff --git a/tests.branching/workspace-not-found.stderr b/tests.branching/workspace-not-found.stderr
deleted file mode 100644
index 041c64b..0000000
--- a/tests.branching/workspace-not-found.stderr
+++ /dev/null
@@ -1,2 +0,0 @@
-ERROR: Can't find the workspace directory.
-Morph must be built and deployed within the system branch checkout within the workspace directory.
diff --git a/tests.branching/workspace.script b/tests.branching/workspace.script
deleted file mode 100755
index 9da7517..0000000
--- a/tests.branching/workspace.script
+++ /dev/null
@@ -1,23 +0,0 @@
-#!/bin/sh
-#
-# Copyright (C) 2012,2015 Codethink Limited
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; version 2 of the License.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License along
-# with this program. If not, see <http://www.gnu.org/licenses/>.
-
-
-## morph init: Create a workspace.
-
-scripts/test-morph init "$DATADIR/workspace"
-mkdir -p "$DATADIR/workspace/a/b/c"
-cd "$DATADIR/workspace/a/b/c"
-"$SRCDIR/scripts/test-morph" workspace
diff --git a/tests.branching/workspace.stdout b/tests.branching/workspace.stdout
deleted file mode 100644
index 14c44f7..0000000
--- a/tests.branching/workspace.stdout
+++ /dev/null
@@ -1 +0,0 @@
-TMP/workspace
diff --git a/without-test-modules b/without-test-modules
index 7780347..558cee7 100644
--- a/without-test-modules
+++ b/without-test-modules
@@ -16,7 +16,6 @@ morphlib/plugins/syslinux-disk-systembuilder_plugin.py
morphlib/plugins/disk-systembuilder_plugin.py
morphlib/plugins/tarball-systembuilder_plugin.py
morphlib/plugins/show_dependencies_plugin.py
-morphlib/plugins/branch_and_merge_plugin.py
morphlib/buildcommand.py
morphlib/plugins/build_plugin.py
morphlib/gitversion.py