summaryrefslogtreecommitdiffstats
path: root/test/example1.test
diff options
context:
space:
mode:
authorJean Delvare <jdelvare@suse.de>2010-01-23 21:23:01 +0100
committerJean Delvare <jdelvare@suse.de>2010-01-23 21:23:01 +0100
commitf1458bf10fe56cb4f95f446bf35bcd09a55f6ecd (patch)
tree5fe723da550a121f8556e7bd136d4f58d0ecf374 /test/example1.test
parentb321567c52c9877a1532bf86f328f13620b06c7b (diff)
downloadquilt-f1458bf10fe56cb4f95f446bf35bcd09a55f6ecd.tar.gz
Separate working directory for each test case
Let the test suite runner script create a separate working directory for each test. This makes it possible to run several tests in parallel, speeding up testing on SMP systems. It also ensures that a broken test case can no longer cause another test case to fail. At this point, it is possible to run the test suite in parallel, the final result (success or failure) will be correct, however the output is hardly readable because the progress of all tests are interlaced. This will be improved later. As a nice side effect, this means we can drop the setup and clean-up steps that were present in all test cases.
Diffstat (limited to 'test/example1.test')
-rw-r--r--test/example1.test40
1 files changed, 18 insertions, 22 deletions
diff --git a/test/example1.test b/test/example1.test
index fabb362..822741b 100644
--- a/test/example1.test
+++ b/test/example1.test
@@ -1,9 +1,8 @@
The text used here was taken from:
http://the-tech.mit.edu/Shakespeare/midsummer/full.html
- $ rm -rf example1
- $ mkdir -p example1/patches
- $ cd example1
+ $ mkdir patches
+
$ cat > Oberon.txt
< Yet mark'd I where the bolt of Cupid fell:
< It fell upon a little western flower,
@@ -23,14 +22,14 @@ http://the-tech.mit.edu/Shakespeare/midsummer/full.html
Or ``quilt edit Oberon.txt''
- $ quilt refresh
+ $ quilt refresh -p ab
> Refreshed patch %{P}flower.diff
$ cat patches/flower.diff
- > Index: example1/Oberon.txt
+ > Index: b/Oberon.txt
> ===================================================================
- > --- example1.orig/Oberon.txt
- > +++ example1/Oberon.txt
+ > --- a/Oberon.txt
+ > +++ b/Oberon.txt
> @@ -2,3 +2,6 @@
> It fell upon a little western flower,
> Before milk-white, now purple with love's wound,
@@ -43,11 +42,11 @@ Or ``quilt edit Oberon.txt''
$ echo "Fetch me that flower; the herb I shew'd thee once:" >> Oberon.new
$ sed -e '1,4d' Oberon.txt >> Oberon.new
$ mv Oberon.new Oberon.txt
- $ quilt diff -z
- > Index: example1/Oberon.txt
+ $ quilt diff -z -p ab
+ > Index: b/Oberon.txt
> ===================================================================
- > --- example1.orig/Oberon.txt
- > +++ example1/Oberon.txt
+ > --- a/Oberon.txt
+ > +++ b/Oberon.txt
> @@ -2,6 +2,7 @@
> It fell upon a little western flower,
> Before milk-white, now purple with love's wound,
@@ -57,11 +56,11 @@ Or ``quilt edit Oberon.txt''
> Will make a man or woman madly dote
> Upon the next live creature that it sees.
- $ quilt diff
- > Index: example1/Oberon.txt
+ $ quilt diff -p ab
+ > Index: b/Oberon.txt
> ===================================================================
- > --- example1.orig/Oberon.txt
- > +++ example1/Oberon.txt
+ > --- a/Oberon.txt
+ > +++ b/Oberon.txt
> @@ -2,3 +2,7 @@
> It fell upon a little western flower,
> Before milk-white, now purple with love's wound,
@@ -110,7 +109,7 @@ Or ``quilt edit Oberon.txt''
< Will make a man or woman madly dote
< Upon the next live creature that it sees.
- $ quilt refresh
+ $ quilt refresh -p ab
> Refreshed patch %{P}flower.diff
$ cat Oberon.txt
@@ -124,10 +123,10 @@ Or ``quilt edit Oberon.txt''
> Upon the next live creature that it sees.
$ cat patches/flower.diff
- > Index: example1/Oberon.txt
+ > Index: b/Oberon.txt
> ===================================================================
- > --- example1.orig/Oberon.txt
- > +++ example1/Oberon.txt
+ > --- a/Oberon.txt
+ > +++ b/Oberon.txt
> @@ -2,3 +2,7 @@
> It fell upon a little western flower,
> Before milk-white, now purple with love's wound,
@@ -136,6 +135,3 @@ Or ``quilt edit Oberon.txt''
> +The juice of it on sleeping eye-lids laid
> +Will make a man or woman madly dote
> +Upon the next live creature that it sees.
-
- $ cd ..
- $ rm -rf example1