OLD | NEW |
(Empty) | |
| 1 <!doctype html> |
| 2 <title>VTTCue.positionAlign</title> |
| 3 <link rel="help" href="https://w3c.github.io/webvtt/#dom-vttcue-positionalign"> |
| 4 <script src=/resources/testharness.js></script> |
| 5 <script src=/resources/testharnessreport.js></script> |
| 6 <div id=log></div> |
| 7 <script> |
| 8 test(function(){ |
| 9 var cue = new VTTCue(0, 1, 'text'); |
| 10 |
| 11 ['line-left', 'center', 'line-right', 'auto'].forEach(function(valid) { |
| 12 cue.positionAlign = valid; |
| 13 assert_equals(cue.positionAlign, valid); |
| 14 }); |
| 15 |
| 16 cue.positionAlign = 'center'; |
| 17 ['auto\u0000', 'centre', 'middle'].forEach(function(invalid) { |
| 18 cue.positionAlign = invalid; |
| 19 assert_equals(cue.positionAlign, 'center'); |
| 20 }); |
| 21 }, document.title+', script-created cue'); |
| 22 </script> |
OLD | NEW |