mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 1144409 - Test that encrypted events are fired for each initData. r=edwin
This commit is contained in:
parent
660c5f330b
commit
a310d932fe
@ -664,6 +664,7 @@ var gEMETests = [
|
||||
"7e571d047e571d047e571d047e571d04" : "7e5744447e5744447e5744447e574444",
|
||||
},
|
||||
sessionType:"temporary",
|
||||
sessionCount:1,
|
||||
duration:1.60,
|
||||
},
|
||||
{
|
||||
@ -684,6 +685,7 @@ var gEMETests = [
|
||||
"7e571d047e571d047e571d047e571d04" : "7e5744447e5744447e5744447e574444",
|
||||
},
|
||||
sessionType:"temporary",
|
||||
sessionCount:1,
|
||||
crossOrigin:true,
|
||||
duration:1.60,
|
||||
},
|
||||
@ -714,6 +716,7 @@ var gEMETests = [
|
||||
"7e571d047e571d047e571d047e571d04" : "7e5744447e5744447e5744447e574444",
|
||||
},
|
||||
sessionType:"temporary",
|
||||
sessionCount:2,
|
||||
duration:1.60,
|
||||
},
|
||||
{
|
||||
@ -743,6 +746,7 @@ var gEMETests = [
|
||||
"7e571d047e571d047e571d047e571d04" : "7e5744447e5744447e5744447e574444",
|
||||
},
|
||||
sessionType:"temporary",
|
||||
sessionCount:2,
|
||||
crossOrigin:true,
|
||||
duration:1.60,
|
||||
},
|
||||
|
@ -48,11 +48,11 @@ function startTest(test, token)
|
||||
}
|
||||
);
|
||||
|
||||
var gotEncrypted = false;
|
||||
var gotEncrypted = 0;
|
||||
var gotPlaying = false;
|
||||
|
||||
v.addEventListener("encrypted", function(ev) {
|
||||
gotEncrypted = true;
|
||||
gotEncrypted += 1;
|
||||
});
|
||||
|
||||
v.addEventListener("playing", function () { gotPlaying = true; });
|
||||
@ -66,7 +66,9 @@ function startTest(test, token)
|
||||
v.addEventListener("ended", function(ev) {
|
||||
ok(true, TimeStamp(token) + " got ended event");
|
||||
|
||||
ok(gotEncrypted, TimeStamp(token) + " encrypted event should have fired");
|
||||
is(gotEncrypted, test.sessionCount,
|
||||
TimeStamp(token) + " encrypted events expected: " + test.sessionCount
|
||||
+ ", actual: " + gotEncrypted);
|
||||
ok(gotPlaying, TimeStamp(token) + " playing event should have fired");
|
||||
|
||||
ok(Math.abs(test.duration - v.duration) < 0.1,
|
||||
|
Loading…
Reference in New Issue
Block a user