Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(917)

Side by Side Diff: LayoutTests/media/track/track-cue-rendering-rtl-expected.txt

Issue 747363003: Ignore <rt> children when determining WebVTT text direction (LTR/RTL) (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 Test that directionality is set correctly on cues. 1 Test that directionality is set correctly on cues.
2 2
3 ** RTL cues alternate with LTR cues ** 3 ** RTL cues alternate with LTR cues **
4 EVENT(canplaythrough) 4 EVENT(canplaythrough)
5 EVENT(seeked) 5 EVENT(seeked)
6 6
7 ** Jump to next cue ** 7 ** Jump to next cue **
8 EXPECTED (video.currentTime == '0.25') OK 8 EXPECTED (video.currentTime == '0.25') OK
9 EXPECTED (testTrack.track.activeCues.length == '1') OK 9 EXPECTED (testTrack.track.activeCues.length == '1') OK
10 EXPECTED (testTrack.track.activeCues[0].text == 'تجربة') OK 10 EXPECTED (testTrack.track.activeCues[0].text == 'تجربة') OK
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after
97 97
98 ** Jump to next cue ** 98 ** Jump to next cue **
99 EXPECTED (video.currentTime == '3.75') OK 99 EXPECTED (video.currentTime == '3.75') OK
100 EXPECTED (testTrack.track.activeCues.length == '1') OK 100 EXPECTED (testTrack.track.activeCues.length == '1') OK
101 EXPECTED (testTrack.track.activeCues[0].text == '𝅘𝅥 (Musical symbol quarter note, U+1D15F) strong LTR, non-BMP') OK 101 EXPECTED (testTrack.track.activeCues[0].text == '𝅘𝅥 (Musical symbol quarter note, U+1D15F) strong LTR, non-BMP') OK
102 EXPECTED (testCueDisplayBox.innerText == '𝅘𝅥 (Musical symbol quarter note, U+1D15 F) strong LTR, non-BMP') OK 102 EXPECTED (testCueDisplayBox.innerText == '𝅘𝅥 (Musical symbol quarter note, U+1D15 F) strong LTR, non-BMP') OK
103 103
104 ** The position should be default and CSS direction set to ltr ** 104 ** The position should be default and CSS direction set to ltr **
105 EXPECTED (2 * testCueDisplayBox.offsetLeft == video.videoWidth - testCueDisplayB ox.offsetWidth == 'true') OK 105 EXPECTED (2 * testCueDisplayBox.offsetLeft == video.videoWidth - testCueDisplayB ox.offsetWidth == 'true') OK
106 EXPECTED (getComputedStyle(testCueDisplayBox).direction == 'ltr') OK 106 EXPECTED (getComputedStyle(testCueDisplayBox).direction == 'ltr') OK
107
108 RUN(video.currentTime = 4.25)
109 EVENT(seeked)
110
111 ** Jump to next cue **
112 EXPECTED (video.currentTime == '4.25') OK
113 EXPECTED (testTrack.track.activeCues.length == '1') OK
114 EXPECTED (testTrack.track.activeCues[0].text == '𝅘𝅥تجربة') OK
115 EXPECTED (testCueDisplayBox.innerText == '𝅘𝅥تجربة') OK
116
117 ** The position should be default and CSS direction set to rtl **
118 EXPECTED (2 * testCueDisplayBox.offsetLeft == video.videoWidth - testCueDisplayB ox.offsetWidth == 'true') OK
119 EXPECTED (getComputedStyle(testCueDisplayBox).direction == 'rtl') OK
120
121 RUN(video.currentTime = 4.75)
122 EVENT(seeked)
123
124 ** Jump to next cue **
125 EXPECTED (video.currentTime == '4.75') OK
126 EXPECTED (testTrack.track.activeCues.length == '1') OK
127 EXPECTED (testTrack.track.activeCues[0].text == '1234تجربة') OK
128 EXPECTED (testCueDisplayBox.innerText == '1234تجربة') OK
129
130 ** The position should be default and CSS direction set to ltr **
131 EXPECTED (2 * testCueDisplayBox.offsetLeft == video.videoWidth - testCueDisplayB ox.offsetWidth == 'true') OK
132 EXPECTED (getComputedStyle(testCueDisplayBox).direction == 'ltr') OK
107 END OF TEST 133 END OF TEST
108 134
OLDNEW
« no previous file with comments | « LayoutTests/media/track/track-cue-rendering-rtl.html ('k') | Source/core/html/track/vtt/VTTCue.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698