summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBoris Faure <billiob@gmail.com>2019-11-21 21:50:18 +0100
committerBoris Faure <billiob@gmail.com>2019-11-21 21:50:18 +0100
commit1333e80866591f4507b5e038f47aaf4647030399 (patch)
tree3a5309c572d6a5bb4e58a5591e5f2a037106c85f
parent8e3263d42af9eecb86884a36170eb1c601dcd33e (diff)
tests: add one about selecting over empty lines
-rwxr-xr-xtests/selection_empty_lines.sh42
-rw-r--r--tests/tests.results1
2 files changed, 43 insertions, 0 deletions
diff --git a/tests/selection_empty_lines.sh b/tests/selection_empty_lines.sh
new file mode 100755
index 0000000..5bb671e
--- /dev/null
+++ b/tests/selection_empty_lines.sh
@@ -0,0 +1,42 @@
1#!/bin/sh
2
3# char width: 7
4# char height: 15
5
6# clear screen
7printf '\033[2J'
8
9# set color
10printf '\033[46;31;3m'
11
12#move to 0,0
13printf '\033[H'
14
15# set text
16TEXT="The path of the righteous man is beset on all sides by the iniquities of the selfish and the tyranny of evil men. Blessed is he who, in the name of charity and good will, shepherds the weak through the valley of darkness, for he is truly his brother's keeper and the finder of lost children. And I will strike down upon thee with great vengeance and furious anger those who would attempt to poison and destroy My brothers. And you will know My name is the Lord when I lay My vengeance upon thee."
17printf "%s\r\n\r\n%s" "$TEXT" "$TEXT"
18
19
20# mouse down to start selection
21printf '\033}td;16;85;1;0;0\0'
22
23# mouse move
24printf '\033}tm;244;150;0\0'
25
26# mouse up
27printf '\033}tu;244;150;1;0;0\0'
28
29# force render
30printf '\033}tr\0'
31
32# selection is
33printf '\033}tsdestroy My brothers. And you will know My name is the Lord when I lay My vengeance upon thee.\n\nThe path of the righteous man is beset on all sides by the iniquities of the selfish and the tyranny of evil men. B\0'
34
35# remove selection
36printf '\033}td;0;0;1;0;0\0\033}tu;0;0;1;0;0\0'
37
38# force render
39printf '\033}tr\0'
40
41# no more selection
42printf '\033}tn\0'
diff --git a/tests/tests.results b/tests/tests.results
index bbc8190..356b5ad 100644
--- a/tests/tests.results
+++ b/tests/tests.results
@@ -121,3 +121,4 @@ shift_in_out.sh 3896bcc6887998bbc41b43840a6b2e33
121osc-11-query.sh b762d503e40641ff896dac46391ad7a8 121osc-11-query.sh b762d503e40641ff896dac46391ad7a8
122link_detection.sh bbe87a849586e8b922f26ad5d88146dc 122link_detection.sh bbe87a849586e8b922f26ad5d88146dc
123selection_with_tabs.sh 23557497a8f28ca246048bb2443b3dab 123selection_with_tabs.sh 23557497a8f28ca246048bb2443b3dab
124selection_empty_lines.sh 7a90d9bfde9e9fb7f067f6c08eac57ff