summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorSam Thursfield <sam.thursfield@codethink.co.uk>2012-11-14 16:51:48 +0000
committerSam Thursfield <sam.thursfield@codethink.co.uk>2012-11-14 17:02:58 +0000
commit70564c6457b732e1dd35384971da5df3c5a1665b (patch)
treefec929625b46df3eca62f4f316bef90f6128c51a /tests
parent4a2b2aa38b85971b72c925eea5ca18767c63cc50 (diff)
downloadmorph-70564c6457b732e1dd35384971da5df3c5a1665b.tar.gz
Tidy up command tests
Be consistent about placement of test description, blank lines, etc.
Diffstat (limited to 'tests')
-rwxr-xr-xtests/build-chunk-failures-dump-log.script11
-rwxr-xr-xtests/build-chunk-writes-log.script11
-rwxr-xr-xtests/build-chunk.script11
-rwxr-xr-xtests/build-stratum-with-submodules.script11
-rwxr-xr-xtests/build-stratum.script11
-rwxr-xr-xtests/build-system-autotools-fails-if-autogen-fails.script12
-rwxr-xr-xtests/build-system-autotools.script12
-rwxr-xr-xtests/build-system-cpan.script11
-rwxr-xr-xtests/build-system-python-distutils.script10
-rwxr-xr-xtests/missing-ref.script11
-rwxr-xr-xtests/morphless-chunks.script11
-rwxr-xr-xtests/name-clash.script17
-rwxr-xr-xtests/rebuild-cached-stratum.script17
-rwxr-xr-xtests/show-dependencies.script11
-rwxr-xr-xtests/stratum-overlap-warns.script13
-rwxr-xr-xtests/stratum-overlap-writes-overlap.script13
-rwxr-xr-xtests/trove-prefix.script5
-rwxr-xr-xtests/update-gits-chunk.script11
-rwxr-xr-xtests/update-gits-stratum.script11
-rwxr-xr-xtests/update-gits-submodules.script11
-rwxr-xr-xtests/uses-tempdir.script13
21 files changed, 131 insertions, 113 deletions
diff --git a/tests/build-chunk-failures-dump-log.script b/tests/build-chunk-failures-dump-log.script
index 05a3bd8a..3e0985d8 100755
--- a/tests/build-chunk-failures-dump-log.script
+++ b/tests/build-chunk-failures-dump-log.script
@@ -1,22 +1,23 @@
#!/bin/bash
#
-# Test building a chunk.
-#
# Copyright (C) 2011, 2012 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, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+
+## Test building a chunk that fails.
+
set -eu
chunkrepo="$DATADIR/chunk-repo"
diff --git a/tests/build-chunk-writes-log.script b/tests/build-chunk-writes-log.script
index e34914df..a258bf99 100755
--- a/tests/build-chunk-writes-log.script
+++ b/tests/build-chunk-writes-log.script
@@ -1,22 +1,23 @@
#!/bin/sh
#
-# Test building a chunk.
-#
# Copyright (C) 2011, 2012 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, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+
+## Test building a chunk - build log should be saved.
+
set -eu
"$SRCDIR/scripts/test-morph" build-morphology test:chunk-repo farrokh hello
diff --git a/tests/build-chunk.script b/tests/build-chunk.script
index e69515b3..9728f939 100755
--- a/tests/build-chunk.script
+++ b/tests/build-chunk.script
@@ -1,22 +1,23 @@
#!/bin/sh
#
-# Test building a chunk.
-#
# Copyright (C) 2011, 2012 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, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+
+## Test building a chunk.
+
set -eu
"$SRCDIR/scripts/test-morph" build-morphology test:chunk-repo farrokh hello
diff --git a/tests/build-stratum-with-submodules.script b/tests/build-stratum-with-submodules.script
index 2a99b12d..1799d74a 100755
--- a/tests/build-stratum-with-submodules.script
+++ b/tests/build-stratum-with-submodules.script
@@ -1,22 +1,23 @@
#!/bin/sh
#
-# Test build a stratum that uses a chunk which needs a submodule.
-#
# Copyright (C) 2011, 2012 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, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+
+## Test build a stratum that uses a chunk which needs a submodule.
+
set -eu
# tests/setup creates a chunk-repo. We now create a new chunk, which
diff --git a/tests/build-stratum.script b/tests/build-stratum.script
index d4909e9a..ac210129 100755
--- a/tests/build-stratum.script
+++ b/tests/build-stratum.script
@@ -1,22 +1,23 @@
#!/bin/sh
#
-# Test build a simple stratum.
-#
# Copyright (C) 2011, 2012 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, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+
+## Test build a simple stratum.
+
set -eu
"$SRCDIR/scripts/test-morph" build-morphology \
diff --git a/tests/build-system-autotools-fails-if-autogen-fails.script b/tests/build-system-autotools-fails-if-autogen-fails.script
index fb80fc72..46510516 100755
--- a/tests/build-system-autotools-fails-if-autogen-fails.script
+++ b/tests/build-system-autotools-fails-if-autogen-fails.script
@@ -1,24 +1,24 @@
#!/bin/sh
#
-# Test that the autotools build system fails if it runs autogen.sh and that
-# fails.
-#
# Copyright (C) 2012 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, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+## Test that the autotools build system fails if it runs autogen.sh and that
+## fails.
+
set -eu
x="$DATADIR/autogen-chunk"
diff --git a/tests/build-system-autotools.script b/tests/build-system-autotools.script
index f23eb04e..6037d1b5 100755
--- a/tests/build-system-autotools.script
+++ b/tests/build-system-autotools.script
@@ -1,24 +1,24 @@
#!/bin/sh
#
-# Convert the hello-chunk project to something autotools-like, then
-# build it.
-#
# Copyright (C) 2011, 2012 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, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+## Convert the hello-chunk project to something autotools-like, then
+## build it.
+
set -eu
chunkrepo="$DATADIR/chunk-repo"
diff --git a/tests/build-system-cpan.script b/tests/build-system-cpan.script
index aec91873..9217ab16 100755
--- a/tests/build-system-cpan.script
+++ b/tests/build-system-cpan.script
@@ -1,22 +1,23 @@
#!/bin/sh
#
-# Convert the hello-chunk project to perl with CPAN
-#
# Copyright (C) 2011, 2012 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, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+
+## Convert the hello-chunk project to perl with CPAN and build.
+
set -eu
chunkrepo="$DATADIR/chunk-repo"
diff --git a/tests/build-system-python-distutils.script b/tests/build-system-python-distutils.script
index d7be93bd..683599f2 100755
--- a/tests/build-system-python-distutils.script
+++ b/tests/build-system-python-distutils.script
@@ -1,23 +1,23 @@
#!/bin/sh
#
-# Convert the hello-chunk project to python with distutils
-#
# Copyright (C) 2011, 2012 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, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+## Convert the hello-chunk project to python with distutils and build.
+
set -eu
chunkrepo="$DATADIR/chunk-repo"
diff --git a/tests/missing-ref.script b/tests/missing-ref.script
index 2da9fa05..26183af3 100755
--- a/tests/missing-ref.script
+++ b/tests/missing-ref.script
@@ -1,22 +1,23 @@
#!/bin/sh
#
-# Test building with a bad reference.
-#
# Copyright (C) 2011,2012 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, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+
+## Test building with a bad reference.
+
"$SRCDIR/scripts/test-morph" build-morphology \
test:chunk-repo non-existent-branch hello
diff --git a/tests/morphless-chunks.script b/tests/morphless-chunks.script
index 315f42ea..d7b068da 100755
--- a/tests/morphless-chunks.script
+++ b/tests/morphless-chunks.script
@@ -1,23 +1,24 @@
#!/bin/sh
-# Try to build a morphless chunk.
+#
# Copyright (C) 2012 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, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
-set -eu
+## Try to build a morphless chunk.
+set -eu
# Create an auto-detectable chunk.
diff --git a/tests/name-clash.script b/tests/name-clash.script
index 9a3e942b..b1df563c 100755
--- a/tests/name-clash.script
+++ b/tests/name-clash.script
@@ -1,25 +1,26 @@
#!/bin/sh
#
-# Test when there are two chunks with the same "name" set in the morphology
-# cause only the first built to be used
-# This can cause build failures when the wrong name is set and could be
-# a vector for including dodgy data in a system
-#
# Copyright (C) 2012 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, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+
+## When there are two chunks with the same "name" set in the morphology,
+## only the first built should be used. This can cause build failures when
+## the wrong name is set and could be a vector for including dodgy data in
+## a system.
+
set -eu
( cd "$DATADIR/chunk-repo"
diff --git a/tests/rebuild-cached-stratum.script b/tests/rebuild-cached-stratum.script
index 2615fb30..70cc54cf 100755
--- a/tests/rebuild-cached-stratum.script
+++ b/tests/rebuild-cached-stratum.script
@@ -1,25 +1,26 @@
#!/bin/sh
#
-# Does a cached stratum get rebuilt if its chunk changes?
-# This tests a bug that is currently in morph, where the stratum does
-# not get rebuilt in that case. Later on, the test will guard against
-# regressions.
-#
# Copyright (C) 2011, 2012 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, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+
+## Does a cached stratum get rebuilt if its chunk changes?
+## This tests a bug that is currently in morph, where the stratum does
+## not get rebuilt in that case. Later on, the test will guard against
+## regressions.
+
set -eu
cache="$DATADIR/cache/artifacts"
diff --git a/tests/show-dependencies.script b/tests/show-dependencies.script
index aad036e9..056b81b2 100755
--- a/tests/show-dependencies.script
+++ b/tests/show-dependencies.script
@@ -1,22 +1,23 @@
#!/bin/bash
#
-# Test "show-dependencies" subcommand.
-#
# Copyright (C) 2012 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, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+
+## Test "show-dependencies" subcommand.
+
set -eu
"$SRCDIR/scripts/test-morph" \
diff --git a/tests/stratum-overlap-warns.script b/tests/stratum-overlap-warns.script
index 8cf1606c..c9aeed72 100755
--- a/tests/stratum-overlap-warns.script
+++ b/tests/stratum-overlap-warns.script
@@ -1,23 +1,24 @@
#!/bin/sh
#
-# If a stratum has multiple chunks that have the same files in them,
-# then this should be notified
-#
# Copyright (C) 2011, 2012 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, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+
+## If a stratum has multiple chunks that have the same files in them,
+## then this should be noted.
+
set -eu
log="$DATADIR/morph.log"
diff --git a/tests/stratum-overlap-writes-overlap.script b/tests/stratum-overlap-writes-overlap.script
index d06b4677..a52d1ba7 100755
--- a/tests/stratum-overlap-writes-overlap.script
+++ b/tests/stratum-overlap-writes-overlap.script
@@ -1,23 +1,24 @@
#!/bin/sh
#
-# If a stratum has multiple chunks that have the same files in them,
-# then the overlaps must be written to the cache
-#
# Copyright (C) 2011, 2012 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, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+
+## If a stratum has multiple chunks that have the same files in them,
+## then the overlaps must be written to the cache
+
set -eu
cache="$DATADIR/cache/artifacts"
diff --git a/tests/trove-prefix.script b/tests/trove-prefix.script
index 612311f3..0f8cee3f 100755
--- a/tests/trove-prefix.script
+++ b/tests/trove-prefix.script
@@ -1,7 +1,5 @@
#!/bin/sh
#
-# Verify that trove-prefix (and by corollary trove-host) work properly.
-#
# Copyright (C) 2012 Codethink Limited
#
# This program is free software; you can redistribute it and/or modify
@@ -17,6 +15,9 @@
# with this program; if not, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+
+## Verify that trove-prefix (and by corollary trove-host) work properly.
+
set -eu
RAWDUMP="$DATADIR/raw-configdump"
diff --git a/tests/update-gits-chunk.script b/tests/update-gits-chunk.script
index 55bdebd0..c2ad08d0 100755
--- a/tests/update-gits-chunk.script
+++ b/tests/update-gits-chunk.script
@@ -1,22 +1,23 @@
#!/bin/bash
#
# Copyright (C) 2012 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, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
-# Test that 'morph update-gits' updates every chunk listed on the
-# command line.
+
+## Test that 'morph update-gits' updates every chunk listed on the
+## command line.
set -eu
diff --git a/tests/update-gits-stratum.script b/tests/update-gits-stratum.script
index 04511563..112a8973 100755
--- a/tests/update-gits-stratum.script
+++ b/tests/update-gits-stratum.script
@@ -1,22 +1,23 @@
#!/bin/bash
#
# Copyright (C) 2012 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, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
-# Test that 'morph update-gits' updates every chunk that depends on the
-# strata listed on the command line.
+
+## Test that 'morph update-gits' updates every chunk that depends on the
+## strata listed on the command line.
set -eu
diff --git a/tests/update-gits-submodules.script b/tests/update-gits-submodules.script
index ad5f220c..66d35897 100755
--- a/tests/update-gits-submodules.script
+++ b/tests/update-gits-submodules.script
@@ -1,22 +1,23 @@
#!/bin/bash
#
# Copyright (C) 2012 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, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
-# Test that 'morph update-gits' caches all the submodules needed by
-# a chunk.
+
+## Test that 'morph update-gits' caches all the submodules needed by
+## a chunk.
set -eu
diff --git a/tests/uses-tempdir.script b/tests/uses-tempdir.script
index 328413dd..a4aac557 100755
--- a/tests/uses-tempdir.script
+++ b/tests/uses-tempdir.script
@@ -1,23 +1,24 @@
#!/bin/sh
#
-# Test that temporary directories are created in the dir specified
-# by --tempdir rather than specified in the environment by TMPDIR.
-#
# Copyright (C) 2011, 2012 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, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+
+## Test that temporary directories are created in the dir specified
+## by --tempdir rather than specified in the environment by TMPDIR.
+
set -eu
export TMPDIR
TMPDIR="$DATADIR"/unwritable-tmp