From 6908c6b3bd0936b2b8ddb051b8a04a9ca2a6f33c Mon Sep 17 00:00:00 2001 From: schwarze Date: Thu, 1 Jul 2021 10:22:16 +0000 Subject: [PATCH] Just in case another developer besides anton@ and myself even wants to look at these tests: add a comment providing a high-level picture of what is going on here, such that everyday maintenance can be performed without going down the rabbit hole of subr.sh and edit.c. --- regress/bin/ksh/edit/emacs.sh | 6 +++++- regress/bin/ksh/edit/vi.sh | 6 +++++- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/regress/bin/ksh/edit/emacs.sh b/regress/bin/ksh/edit/emacs.sh index d1f5a41ca73..aee8864d3f8 100644 --- a/regress/bin/ksh/edit/emacs.sh +++ b/regress/bin/ksh/edit/emacs.sh @@ -1,6 +1,6 @@ #!/bin/sh # -# $OpenBSD: emacs.sh,v 1.13 2021/07/01 10:00:15 schwarze Exp $ +# $OpenBSD: emacs.sh,v 1.14 2021/07/01 10:22:16 schwarze Exp $ # # Copyright (c) 2017 Anton Lindqvist # Copyright (c) 2017 Ingo Schwarze @@ -30,6 +30,10 @@ PS1=' # ' VISUAL=emacs export EDITOR ENV HISTFILE MAIL MALLOC_OPTIONS PS1 VISUAL +# The function testseq() sets up a pseudo terminal and feeds its first +# argument to a shell on standard input. It then checks that output +# from the shell to the pseudo terminal agrees with the second argument. + # auto-insert testseq "abc" " # abc" diff --git a/regress/bin/ksh/edit/vi.sh b/regress/bin/ksh/edit/vi.sh index 26001c82afb..be15c4d1ee8 100644 --- a/regress/bin/ksh/edit/vi.sh +++ b/regress/bin/ksh/edit/vi.sh @@ -1,6 +1,6 @@ #!/bin/sh # -# $OpenBSD: vi.sh,v 1.7 2020/09/20 15:25:09 tb Exp $ +# $OpenBSD: vi.sh,v 1.8 2021/07/01 10:22:16 schwarze Exp $ # # Copyright (c) 2016 Ingo Schwarze # Copyright (c) 2017 Anton Lindqvist @@ -30,6 +30,10 @@ PS1=' # ' VISUAL=vi export EDITOR ENV HISTFILE MAIL MALLOC_OPTIONS PS1 VISUAL +# The function testseq() sets up a pseudo terminal and feeds its first +# argument to a shell on standard input. It then checks that output +# from the shell to the pseudo terminal agrees with the second argument. + # ^H, ^?: Erase. testseq "ab\bc" " # ab\b \bc" testseq "ab\0177c" " # ab\b \bc" -- 2.20.1