From 950f90c24d818782a88c612cb24845b8086a281f Mon Sep 17 00:00:00 2001 From: Ian Jackson Date: Wed, 4 Jul 2018 01:54:13 +0100 Subject: test suite: checkout: new test Signed-off-by: Ian Jackson --- tests/tests/checkout | 49 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 49 insertions(+) create mode 100755 tests/tests/checkout (limited to 'tests') diff --git a/tests/tests/checkout b/tests/tests/checkout new file mode 100755 index 0000000..4b205f3 --- /dev/null +++ b/tests/tests/checkout @@ -0,0 +1,49 @@ +#!/bin/bash +set -e +. tests/lib +t-tstunt-parsechangelog + +t-setup-import examplegit + +p=example + +mkdir $p.2 +cd $p.2 + +git init +t-dgit setup-new-tree +t-dgit checkout -p $p unstable + +t-refs-same-start +t-ref-head +t-ref-same refs/tags/test-dummy/$v + +t-dgit checkout -p $p stable + +t-dgit checkout -d no-such-distro sid +t-ref-head + +t-dgit checkout stable + +git branch -D dgit/sid +t-dgit checkout -d no-such-distro sid +t-ref-head + +git reflog --pretty=tformat:%gs >../reflog.got +cat >../reflog.expect <../refs.got +cat >../refs.expect <