summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorfvogel <fvogelnew1@free.fr>2021-04-11 18:56:21 (GMT)
committerfvogel <fvogelnew1@free.fr>2021-04-11 18:56:21 (GMT)
commit3bd12138e37a4369aa0f615c7e75e5a9f8fef5cd (patch)
treeb4b525c505e30f15eef4cd2d13ceed3b4d28883e /tests
parenta3ea56136eebaeb8b37cd87b3b5f7c7142cd22d8 (diff)
downloadtk-3bd12138e37a4369aa0f615c7e75e5a9f8fef5cd.zip
tk-3bd12138e37a4369aa0f615c7e75e5a9f8fef5cd.tar.gz
tk-3bd12138e37a4369aa0f615c7e75e5a9f8fef5cd.tar.bz2
Add non-regression test textIndex-26.1
Diffstat (limited to 'tests')
-rw-r--r--tests/textIndex.test13
1 files changed, 13 insertions, 0 deletions
diff --git a/tests/textIndex.test b/tests/textIndex.test
index bd4e955..a6efd88 100644
--- a/tests/textIndex.test
+++ b/tests/textIndex.test
@@ -964,6 +964,19 @@ test textIndex-25.1 {IndexCountBytesOrdered, bug [3f1f79abcf]} {
destroy .t2
} {}
+test textIndex-26.1 {GetIndex restricts the returned index to -starline/-endline in peers, bug [34db75c0ac]} {
+ set res {}
+ pack [text .t2]
+ .t2 insert end "line 1\nline 2\nline 3\nline 4\nline 5\nline 6\n"
+ pack [.t2 peer create .p2 -startline 2 -endline 3]
+ lappend res [.p2 index "end"]
+ lappend res [.p2 index "end lineend"]
+ lappend res [.p2 index "end display lineend"]
+ destroy .t2 .p2
+ set res
+} {2.0 2.0 2.0}
+
+
# cleanup
rename textimage {}
catch {destroy .t}