aboutsummaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rwxr-xr-xtests/create-repo.sh27
1 files changed, 19 insertions, 8 deletions
diff --git a/tests/create-repo.sh b/tests/create-repo.sh
index f97e6e4..f837b5d 100755
--- a/tests/create-repo.sh
+++ b/tests/create-repo.sh
@@ -54,22 +54,33 @@ main () {
edit file-a three foo # depends on file-a tag
edit file-b three bar # depends on file-b tag
+ # Change non-overlapping part of previously changed file
+ edit file-a eight foo # depends on file-a tag
+
+ # Change previously changed line
+ edit file-a three baz # depends on file-a-three-a tag
+}
+
+feature () {
+ cd $test_repo
+
# Start a feature branch
- git checkout -b feature
+ git checkout -b feature file-b-three-bar
new_file file-c
edit file-c four foo
edit file-c ten qux
# Switch back to master
git checkout master
-
- # Change non-overlapping part of previously changed file
- edit file-a eight foo # depends on file-a tag
-
- # Change previously changed line
- edit file-a three baz # depends on file-a-three-a tag
}
-main
+case "$1" in
+ feature)
+ feature
+ ;;
+ *)
+ main
+ ;;
+esac
exit 0