diff options
Diffstat (limited to 'tests/textDisp.test')
-rw-r--r-- | tests/textDisp.test | 29 |
1 files changed, 15 insertions, 14 deletions
diff --git a/tests/textDisp.test b/tests/textDisp.test index 39d50d0..f64dd88 100644 --- a/tests/textDisp.test +++ b/tests/textDisp.test @@ -12,6 +12,7 @@ tcltest::loadTestedCommands namespace import -force tcltest::test testConstraint failsOnUbuntu [expr {![info exists ::env(TRAVIS_OS_NAME)] || ![string match linux $::env(TRAVIS_OS_NAME)]}] +testConstraint failsOnXQuarz [expr {$tcl_platform(os) ne "Darwin" || [tk windowingsystem] ne "x11" }] # Platform specific procedure for updating the text widget. @@ -665,7 +666,7 @@ test textDisp-4.7 {UpdateDisplayInfo, filling in extra vertical space} { updateText set x } {8.0 {16.0 17.0 15.0 14.0 13.0 12.0 11.0 10.0 9.0 8.0} {8.0 9.0 10.0 11.0 12.0 13.0 14.0 15.0 16.0 17.0}} -test textDisp-4.8 {UpdateDisplayInfo, filling in extra vertical space} { +test textDisp-4.8 {UpdateDisplayInfo, filling in extra vertical space} failsOnXQuarz { .t delete 1.0 end .t insert end "1\n2\n3\n4\n5\n6\n7\n8\n9\n10\n11\n12\n13\n14\n15\n16\n17" .t yview 16.0 @@ -728,7 +729,7 @@ test textDisp-4.13 {UpdateDisplayInfo, special handling for top/bottom lines} { updateText list $tk_textRelayout $tk_textRedraw } {{11.0 12.0 13.0} {4.0 10.0 11.0 12.0 13.0}} -test textDisp-4.14 {UpdateDisplayInfo, special handling for top/bottom lines} { +test textDisp-4.14 {UpdateDisplayInfo, special handling for top/bottom lines} failsOnXQuarz { .t tag remove x 1.0 end .t yview 1.0 updateText @@ -861,7 +862,7 @@ test textDisp-5.2 {DisplayDLine, line resizes during display} { } [list 30 30] .t configure -wrap char -test textDisp-6.1 {scrolling in DisplayText, scroll up} { +test textDisp-6.1 {scrolling in DisplayText, scroll up} failsOnXQuarz { .t delete 1.0 end .t insert 1.0 "Line 1" foreach i {2 3 4 5 6 7 8 9 10 11 12 13 14 15} { @@ -1149,7 +1150,7 @@ test textDisp-8.6 {TkTextChanged} { updateText list $tk_textRelayout $tk_textRedraw } {{1.0 1.20 1.40} {1.0 1.20 1.40}} -test textDisp-8.7 {TkTextChanged} { +test textDisp-8.7 {TkTextChanged} failsOnXQuarz { .t delete 1.0 end .t insert 1.0 "Line 1 is so long that it wraps around, two times" foreach i {2 3 4 5 6 7 8 9 10 11 12 13 14 15} { @@ -1171,7 +1172,7 @@ test textDisp-8.8 {TkTextChanged} { updateText list $tk_textRelayout $tk_textRedraw } {2.0 2.0} -test textDisp-8.9 {TkTextChanged} { +test textDisp-8.9 {TkTextChanged} failsOnXQuarz { .t delete 1.0 end .t insert 1.0 "Line 1 is so long that it wraps around, two times" foreach i {2 3 4 5 6 7 8 9 10 11 12 13 14 15} { @@ -1282,7 +1283,7 @@ test textDisp-9.4 {TkTextRedrawTag} failsOnUbuntu { updateText list $tk_textRelayout $tk_textRedraw } {{2.0 2.20} {2.0 2.20 eof}} -test textDisp-9.5 {TkTextRedrawTag} failsOnUbuntu { +test textDisp-9.5 {TkTextRedrawTag} {failsOnUbuntu failsOnXQuarz} { .t configure -wrap char .t delete 1.0 end .t insert 1.0 "Line 1\nLine 2 is long enough to wrap around\nLine 3\nLine 4" @@ -1444,7 +1445,7 @@ test textDisp-11.1 {TkTextSetYView} { updateText .t index @0,0 } {30.0} -test textDisp-11.2 {TkTextSetYView} { +test textDisp-11.2 {TkTextSetYView} failsOnXQuarz { .t yview 30.0 updateText .t yview 32.0 @@ -1458,7 +1459,7 @@ test textDisp-11.3 {TkTextSetYView} { updateText list [.t index @0,0] $tk_textRedraw } {28.0 {28.0 29.0}} -test textDisp-11.4 {TkTextSetYView} { +test textDisp-11.4 {TkTextSetYView} failsOnXQuarz { .t yview 30.0 updateText .t yview 31.4 @@ -1489,7 +1490,7 @@ test textDisp-11.7 {TkTextSetYView} { updateText list [.t index @0,0] $tk_textRedraw } {21.0 {21.0 22.0 23.0 24.0 25.0 26.0 27.0 28.0 29.0}} -test textDisp-11.8 {TkTextSetYView} { +test textDisp-11.8 {TkTextSetYView} failsOnXQuarz { .t yview 30.0 updateText set tk_textRedraw {} @@ -1497,7 +1498,7 @@ test textDisp-11.8 {TkTextSetYView} { updateText list [.t index @0,0] $tk_textRedraw } {32.0 {40.0 41.0}} -test textDisp-11.9 {TkTextSetYView} { +test textDisp-11.9 {TkTextSetYView} failsOnXQuarz { .t yview 30.0 updateText set tk_textRedraw {} @@ -1521,7 +1522,7 @@ test textDisp-11.11 {TkTextSetYView} { updateText list [.t index @0,0] $tk_textRedraw } {191.0 {191.0 192.0 193.0 194.0 195.0 196.0}} -test textDisp-11.12 {TkTextSetYView, wrapped line is off-screen} { +test textDisp-11.12 {TkTextSetYView, wrapped line is off-screen} failsOnXQuarz { .t insert 10.0 "Long line with enough text to wrap\n" .t yview 1.0 updateText @@ -2863,7 +2864,7 @@ test textDisp-19.16 {count -ypixels} { [.t count -ypixels 16.0 "16.0 displaylineend +1c"] \ [.t count -ypixels "16.0 +1 displaylines" "16.0 +4 displaylines +3c"] } [list [expr {260 + 20 * $fixedDiff}] [expr {260 + 20 * $fixedDiff}] $fixedHeight [expr {2*$fixedHeight}] $fixedHeight [expr {3*$fixedHeight}]] -test textDisp-19.17 {count -ypixels with indices in elided lines} failsOnUbuntu { +test textDisp-19.17 {count -ypixels with indices in elided lines} {failsOnUbuntu failsOnXQuarz} { .t configure -wrap none .t delete 1.0 end for {set i 1} {$i < 100} {incr i} { @@ -2890,7 +2891,7 @@ test textDisp-19.17 {count -ypixels with indices in elided lines} failsOnUbuntu .t yview 35.0 lappend res [.t count -ypixels 5.0 25.0] } [list [expr {4 * $fixedHeight}] [expr {3 * $fixedHeight}] 0 0 0 0 0 0 [expr {5 * $fixedHeight}] [expr {- 5 * $fixedHeight}] [expr {2 * $fixedHeight}] [expr {3 * $fixedHeight}] [expr {5 * $fixedHeight}]] -test textDisp-19.18 {count -ypixels with indices in elided lines} failsOnUbuntu { +test textDisp-19.18 {count -ypixels with indices in elided lines} {failsOnUbuntu failsOnXQuarz} { .t configure -wrap none .t delete 1.0 end for {set i 1} {$i < 100} {incr i} { @@ -3407,7 +3408,7 @@ test textDisp-24.24 {TkTextCharLayoutProc, justification and tabs} {textfonts} { .t tag add x 1.0 end list [.t bbox 1.0] [.t bbox 1.10] } [list [list 45 3 7 $fixedHeight] [list 94 3 7 $fixedHeight]] -test textDisp-24.25 {TkTextCharLayoutProc, justification and tabs} -constraints {textfonts} -setup { +test textDisp-24.25 {TkTextCharLayoutProc, justification and tabs} -constraints {textfonts failsOnXQuarz} -setup { text .tt -tabs {40 right} -wrap none -font $fixedFont pack .tt } -body { |