| OLD | NEW | 
|---|
| 1 <!DOCTYPE html> | 1 <!DOCTYPE html> | 
| 2 <html> | 2 <html> | 
| 3     <head> | 3     <head> | 
| 4         <title>Clear Key Playback with Multiple Sessions</title> | 4         <title>Clear Key Playback with Multiple Sessions</title> | 
| 5         <script src="encrypted-media-utils.js"></script> | 5         <script src="encrypted-media-utils.js"></script> | 
| 6         <script src="../../resources/testharness.js"></script> | 6         <script src="../../resources/testharness.js"></script> | 
| 7         <script src="../../resources/testharnessreport.js"></script> | 7         <script src="../../resources/testharnessreport.js"></script> | 
| 8     </head> | 8     </head> | 
| 9     <body> | 9     <body> | 
| 10         <video id="testVideo"></video> | 10         <video id="testVideo"></video> | 
| (...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 113                 } | 113                 } | 
| 114 | 114 | 
| 115                 function onTimeUpdate(event) | 115                 function onTimeUpdate(event) | 
| 116                 { | 116                 { | 
| 117                     if (event.target.currentTime < 0.2) | 117                     if (event.target.currentTime < 0.2) | 
| 118                         return; | 118                         return; | 
| 119 | 119 | 
| 120                     test.done(); | 120                     test.done(); | 
| 121                 } | 121                 } | 
| 122 | 122 | 
| 123                 MediaKeys.create('org.w3.clearkey').then(function(mediaKeys) { | 123                 navigator.requestMediaKeySystemAccess('org.w3.clearkey').then(fu
     nction(access) { | 
|  | 124                     return access.createMediaKeys(); | 
|  | 125                 }).then(function(mediaKeys) { | 
| 124                     waitForEventAndRunStep('encrypted', video, onEncrypted, test
     ); | 126                     waitForEventAndRunStep('encrypted', video, onEncrypted, test
     ); | 
| 125                     waitForEventAndRunStep('playing', video, onPlaying, test); | 127                     waitForEventAndRunStep('playing', video, onPlaying, test); | 
| 126                     video.src = '../content/test-encrypted-different-av-keys.web
     m'; | 128                     video.src = '../content/test-encrypted-different-av-keys.web
     m'; | 
| 127                     return video.setMediaKeys(mediaKeys); | 129                     return video.setMediaKeys(mediaKeys); | 
| 128                 }).then(function(result) { | 130                 }).then(function(result) { | 
| 129                     video.play(); | 131                     video.play(); | 
| 130                 }).catch(function(error) { | 132                 }).catch(function(error) { | 
| 131                     forceTestFailureFromPromise(test, error); | 133                     forceTestFailureFromPromise(test, error); | 
| 132                 }); | 134                 }); | 
| 133             }, 'Playback using Clear Key key system with multiple sessions.'); | 135             }, 'Playback using Clear Key key system with multiple sessions.'); | 
| 134         </script> | 136         </script> | 
| 135     </body> | 137     </body> | 
| 136 </html> | 138 </html> | 
| OLD | NEW | 
|---|