diff options
author | Xavier Santolaria <xsa@cvs.openbsd.org> | 2006-04-20 17:17:23 +0000 |
---|---|---|
committer | Xavier Santolaria <xsa@cvs.openbsd.org> | 2006-04-20 17:17:23 +0000 |
commit | 63ea6a1272dfa4ad884c6481a4d1104af0ad1489 (patch) | |
tree | 94ad86a3f093a1f7eafc7b87fa9e752439e5c473 | |
parent | 1b1cba1df9dbdd38ec44c7068e96e633871dc9b7 (diff) |
add various tests for `rlog -r' (not enabled yet); OK ray@.
-rw-r--r-- | regress/usr.bin/rcs/Makefile | 20 | ||||
-rw-r--r-- | regress/usr.bin/rcs/rlog-rflag1.out | 17 | ||||
-rw-r--r-- | regress/usr.bin/rcs/rlog-rflag2.out | 25 | ||||
-rw-r--r-- | regress/usr.bin/rcs/rlog-rflag3.out | 21 | ||||
-rw-r--r-- | regress/usr.bin/rcs/rlog-rflag4.out | 17 |
5 files changed, 99 insertions, 1 deletions
diff --git a/regress/usr.bin/rcs/Makefile b/regress/usr.bin/rcs/Makefile index 8860c780c93..27be9b4bf73 100644 --- a/regress/usr.bin/rcs/Makefile +++ b/regress/usr.bin/rcs/Makefile @@ -1,4 +1,4 @@ -# $OpenBSD: Makefile,v 1.21 2006/04/17 15:52:18 xsa Exp $ +# $OpenBSD: Makefile,v 1.22 2006/04/20 17:17:22 xsa Exp $ # Regression tests by Niall O'Higgins <niallo@openbsd.org>. # ksh -> Makefile by Ray Lai <ray@cyth.net>. @@ -482,6 +482,24 @@ test-rlog-lflag: clean @${RLOG} -l file | fgrep -q 'revision 1.2' || \ case "$$?" in 1) exit 0;; esac && exit 1 +# Test various cases for the -r flag +test-rlog-rflag: clean + @touch file + @echo "foo" > file + @echo "descr" | ${CI} -q -m"first rev" -d'2006-01-01 00:00:00+00' \ + -wfoo file + @${CO} -q -l file + @echo "foo" >> file + @${CI} -q -m"second rev" -d'2006-01-01 00:00:00+00' -wfoo file + @${CO} -q -l file + @echo "foo" >> file + @${CI} -q -m"third rev" -d'2006-01-01 00:00:00+00' -wfoo file + + @${RLOG} -r1.1 file | diff -u ${.CURDIR}/rlog-rflag1.out - + @${RLOG} -r1.1:1.3 file | diff -u ${.CURDIR}/rlog-rflag2.out - + @${RLOG} -r1.2: file | diff -u ${.CURDIR}/rlog-rflag3.out - + @${RLOG} -r:1.1 file | diff -u ${.CURDIR}/rlog-rflag4.out - + test-ci-nofile: @${CI} -q nonexistent || case "$$?" in 1) exit 0;; esac && exit 1 diff --git a/regress/usr.bin/rcs/rlog-rflag1.out b/regress/usr.bin/rcs/rlog-rflag1.out new file mode 100644 index 00000000000..4195ad3fe29 --- /dev/null +++ b/regress/usr.bin/rcs/rlog-rflag1.out @@ -0,0 +1,17 @@ + +RCS file: file,v +Working file: file +head: 1.3 +branch: +locks: strict +access list: +symbolic names: +keyword substitution: kv +total revisions: 3; selected revisions: 1 +description: +descr +---------------------------- +revision 1.1 +date: 2006/01/01 00:00:00; author: foo; state: Exp; +first rev +============================================================================= diff --git a/regress/usr.bin/rcs/rlog-rflag2.out b/regress/usr.bin/rcs/rlog-rflag2.out new file mode 100644 index 00000000000..9d86e60716e --- /dev/null +++ b/regress/usr.bin/rcs/rlog-rflag2.out @@ -0,0 +1,25 @@ + +RCS file: file,v +Working file: file +head: 1.3 +branch: +locks: strict +access list: +symbolic names: +keyword substitution: kv +total revisions: 3; selected revisions: 3 +description: +descr +---------------------------- +revision 1.3 +date: 2006/01/01 00:00:00; author: foo; state: Exp; lines: +1 -0 +third rev +---------------------------- +revision 1.2 +date: 2006/01/01 00:00:00; author: foo; state: Exp; lines: +1 -0 +second rev +---------------------------- +revision 1.1 +date: 2006/01/01 00:00:00; author: foo; state: Exp; +first rev +============================================================================= diff --git a/regress/usr.bin/rcs/rlog-rflag3.out b/regress/usr.bin/rcs/rlog-rflag3.out new file mode 100644 index 00000000000..e5c448edce4 --- /dev/null +++ b/regress/usr.bin/rcs/rlog-rflag3.out @@ -0,0 +1,21 @@ + +RCS file: file,v +Working file: file +head: 1.3 +branch: +locks: strict +access list: +symbolic names: +keyword substitution: kv +total revisions: 3; selected revisions: 2 +description: +descr +---------------------------- +revision 1.3 +date: 2006/01/01 00:00:00; author: foo; state: Exp; lines: +1 -0 +third rev +---------------------------- +revision 1.2 +date: 2006/01/01 00:00:00; author: foo; state: Exp; lines: +1 -0 +second rev +============================================================================= diff --git a/regress/usr.bin/rcs/rlog-rflag4.out b/regress/usr.bin/rcs/rlog-rflag4.out new file mode 100644 index 00000000000..4195ad3fe29 --- /dev/null +++ b/regress/usr.bin/rcs/rlog-rflag4.out @@ -0,0 +1,17 @@ + +RCS file: file,v +Working file: file +head: 1.3 +branch: +locks: strict +access list: +symbolic names: +keyword substitution: kv +total revisions: 3; selected revisions: 1 +description: +descr +---------------------------- +revision 1.1 +date: 2006/01/01 00:00:00; author: foo; state: Exp; +first rev +============================================================================= |