Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.busybox.net/busybox.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'testsuite')
-rwxr-xr-xtestsuite/awk.tests7
1 files changed, 7 insertions, 0 deletions
diff --git a/testsuite/awk.tests b/testsuite/awk.tests
index ddc51047b..8ab1c6891 100755
--- a/testsuite/awk.tests
+++ b/testsuite/awk.tests
@@ -540,4 +540,11 @@ testing 'awk assign while assign' \
│ trim/eff : 57.02%/26, 0.00% │ [cpu000:100%]
└────────────────────────────────────────────────────┘^C"
+# If field separator FS=' ' (default), fields are split only on
+# space or tab or linefeed, NOT other whitespace.
+testing 'awk does not split on CR (char 13)' \
+ "awk '{ \$1=\$0; print }'" \
+ 'word1 word2 word3\r word2 word3\r\n' \
+ '' 'word1 word2 word3\r'
+
exit $FAILCOUNT