Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/tests/usr.bin/indent tests/indent: migrate test for '-bap -s...



details:   https://anonhg.NetBSD.org/src/rev/3c799d7054dd
branches:  trunk
changeset: 990017:3c799d7054dd
user:      rillig <rillig%NetBSD.org@localhost>
date:      Sat Oct 23 20:30:23 2021 +0000

description:
tests/indent: migrate test for '-bap -sob' to t_options

diffstat:

 distrib/sets/lists/tests/mi               |   9 ++++---
 tests/usr.bin/indent/Makefile             |   6 +---
 tests/usr.bin/indent/opt-bap+sob.0        |  20 -----------------
 tests/usr.bin/indent/opt-bap+sob.0.pro    |   5 ----
 tests/usr.bin/indent/opt-bap+sob.0.stdout |  20 -----------------
 tests/usr.bin/indent/opt_bap_sob.c        |  36 +++++++++++++++++++++++++++++++
 6 files changed, 43 insertions(+), 53 deletions(-)

diffs (154 lines):

diff -r 3f42c49b6f7a -r 3c799d7054dd distrib/sets/lists/tests/mi
--- a/distrib/sets/lists/tests/mi       Sat Oct 23 20:23:27 2021 +0000
+++ b/distrib/sets/lists/tests/mi       Sat Oct 23 20:30:23 2021 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: mi,v 1.1159 2021/10/23 20:23:27 rillig Exp $
+# $NetBSD: mi,v 1.1160 2021/10/23 20:30:23 rillig Exp $
 #
 # Note: don't delete entries from here - mark them as "obsolete" instead.
 #
@@ -4811,9 +4811,9 @@
 ./usr/tests/usr.bin/indent/opt-badp.0                                  tests-obsolete          obsolete,atf
 ./usr/tests/usr.bin/indent/opt-badp.0.pro                              tests-obsolete          obsolete,atf
 ./usr/tests/usr.bin/indent/opt-badp.0.stdout                           tests-obsolete          obsolete,atf
-./usr/tests/usr.bin/indent/opt-bap+sob.0                               tests-usr.bin-tests     compattestfile,atf
-./usr/tests/usr.bin/indent/opt-bap+sob.0.pro                           tests-usr.bin-tests     compattestfile,atf
-./usr/tests/usr.bin/indent/opt-bap+sob.0.stdout                                tests-usr.bin-tests     compattestfile,atf
+./usr/tests/usr.bin/indent/opt-bap+sob.0                               tests-obsolete          obsolete,atf
+./usr/tests/usr.bin/indent/opt-bap+sob.0.pro                           tests-obsolete          obsolete,atf
+./usr/tests/usr.bin/indent/opt-bap+sob.0.stdout                                tests-obsolete          obsolete,atf
 ./usr/tests/usr.bin/indent/opt-bap.0                                   tests-obsolete          obsolete,atf
 ./usr/tests/usr.bin/indent/opt-bap.0.pro                               tests-obsolete          obsolete,atf
 ./usr/tests/usr.bin/indent/opt-bap.0.stdout                            tests-obsolete          obsolete,atf
@@ -5009,6 +5009,7 @@
 ./usr/tests/usr.bin/indent/opt_bad.c                                   tests-usr.bin-tests     compattestfile,atf
 ./usr/tests/usr.bin/indent/opt_badp.c                                  tests-usr.bin-tests     compattestfile,atf
 ./usr/tests/usr.bin/indent/opt_bap.c                                   tests-usr.bin-tests     compattestfile,atf
+./usr/tests/usr.bin/indent/opt_bap_sob.c                               tests-usr.bin-tests     compattestfile,atf
 ./usr/tests/usr.bin/indent/opt_bbb.c                                   tests-usr.bin-tests     compattestfile,atf
 ./usr/tests/usr.bin/indent/opt_bc.c                                    tests-usr.bin-tests     compattestfile,atf
 ./usr/tests/usr.bin/indent/opt_bl_br.c                                 tests-usr.bin-tests     compattestfile,atf
diff -r 3f42c49b6f7a -r 3c799d7054dd tests/usr.bin/indent/Makefile
--- a/tests/usr.bin/indent/Makefile     Sat Oct 23 20:23:27 2021 +0000
+++ b/tests/usr.bin/indent/Makefile     Sat Oct 23 20:30:23 2021 +0000
@@ -1,4 +1,4 @@
-#      $NetBSD: Makefile,v 1.31 2021/10/23 20:23:27 rillig Exp $
+#      $NetBSD: Makefile,v 1.32 2021/10/23 20:30:23 rillig Exp $
 
 .include <bsd.own.mk>
 
@@ -22,9 +22,6 @@
 FILES+=                opt-U.0.list
 FILES+=                opt-U.0.pro
 FILES+=                opt-U.0.stdout
-FILES+=                opt-bap+sob.0
-FILES+=                opt-bap+sob.0.pro
-FILES+=                opt-bap+sob.0.stdout
 FILES+=                opt-npro.0
 FILES+=                opt-npro.0.pro
 FILES+=                opt-npro.0.stdout
@@ -37,6 +34,7 @@
 FILES+=                opt_bad.c
 FILES+=                opt_badp.c
 FILES+=                opt_bap.c
+FILES+=                opt_bap_sob.c
 FILES+=                opt_bbb.c
 FILES+=                opt_bc.c
 FILES+=                opt_bl_br.c
diff -r 3f42c49b6f7a -r 3c799d7054dd tests/usr.bin/indent/opt-bap+sob.0
--- a/tests/usr.bin/indent/opt-bap+sob.0        Sat Oct 23 20:23:27 2021 +0000
+++ /dev/null   Thu Jan 01 00:00:00 1970 +0000
@@ -1,20 +0,0 @@
-/* $NetBSD: opt-bap+sob.0,v 1.1 2021/03/08 22:13:05 rillig Exp $ */
-/* $FreeBSD$ */
-
-/*
- * As of 2021-03-08, the combination of -bap and -sob, which occurs in the
- * example indent.pro from NetBSD, removes the empty line above the
- * separator.  Seen in games/cgram/cgram.c.
- */
-
-void
-function1(void)
-{
-}
-
-///// separator /////
-
-void
-function2(void)
-{
-}
diff -r 3f42c49b6f7a -r 3c799d7054dd tests/usr.bin/indent/opt-bap+sob.0.pro
--- a/tests/usr.bin/indent/opt-bap+sob.0.pro    Sat Oct 23 20:23:27 2021 +0000
+++ /dev/null   Thu Jan 01 00:00:00 1970 +0000
@@ -1,5 +0,0 @@
-/* $NetBSD: opt-bap+sob.0.pro,v 1.1 2021/03/08 22:13:05 rillig Exp $ */
-/* $FreeBSD$ */
-
--bap
--sob
diff -r 3f42c49b6f7a -r 3c799d7054dd tests/usr.bin/indent/opt-bap+sob.0.stdout
--- a/tests/usr.bin/indent/opt-bap+sob.0.stdout Sat Oct 23 20:23:27 2021 +0000
+++ /dev/null   Thu Jan 01 00:00:00 1970 +0000
@@ -1,20 +0,0 @@
-/* $NetBSD: opt-bap+sob.0.stdout,v 1.2 2021/03/14 01:34:13 rillig Exp $ */
-/* $FreeBSD$ */
-
-/*
- * As of 2021-03-08, the combination of -bap and -sob, which occurs in the
- * example indent.pro from NetBSD, removes the empty line above the separator.
- * Seen in games/cgram/cgram.c.
- */
-
-void
-function1(void)
-{
-}
-/* $ FIXME: Keep the empty line between the '}' and the '//'. */
-///// separator /////
-
-void
-function2(void)
-{
-}
diff -r 3f42c49b6f7a -r 3c799d7054dd tests/usr.bin/indent/opt_bap_sob.c
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/usr.bin/indent/opt_bap_sob.c        Sat Oct 23 20:30:23 2021 +0000
@@ -0,0 +1,36 @@
+/* $NetBSD: opt_bap_sob.c,v 1.1 2021/10/23 20:30:23 rillig Exp $ */
+/* $FreeBSD$ */
+
+/*
+ * As of 2021-03-08, the combination of -bap and -sob, which occurs in the
+ * example indent.pro from NetBSD, removes the empty line above the
+ * separator.  Seen in games/cgram/cgram.c.
+ */
+
+#indent input
+void
+function1(void)
+{
+}
+
+///// separator /////
+
+void
+function2(void)
+{
+}
+#indent end
+
+#indent run -bap -sob
+void
+function1(void)
+{
+}
+/* $ FIXME: Keep the empty line between the '}' and the '//'. */
+///// separator /////
+
+void
+function2(void)
+{
+}
+#indent end



Home | Main Index | Thread Index | Old Index