Skip to content

Commit

Permalink
Merge dde29df into e978588
Browse files Browse the repository at this point in the history
  • Loading branch information
carlosjoan91 authored Feb 21, 2023
2 parents e978588 + dde29df commit 1245166
Show file tree
Hide file tree
Showing 6 changed files with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@

function assert_audio_loads(test) {
// Since autoupgrades don't upgrade custom ports, we use the https port with an HTTP scheme. A successful autoupgrade will result in the right URL loading (and no autoupgrade will result in failure).
var url = new URL("http://{{host}}:{{ports[https][0]}}/mixed-content/tentative/resources/test.wav")
var url = new URL("http://{{host}}:{{ports[https][0]}}/mixed-content/resources/test.wav")
var i = document.createElement('audio');
i.oncanplaythrough = test.step_func_done(_ => {
assert_equals(i.duration, 1, "Length");
Expand All @@ -27,7 +27,7 @@
function assert_other_host_audio_loads(test) {
// Since autoupgrades don't upgrade custom ports, we use the https port with an HTTP scheme. A successful autoupgrade will result in the right URL loading (and no autoupgrade will result in failure).
var otherHost = get_host_info().HTTP_NOTSAMESITE_ORIGIN.slice(0,-4); // cut of http port
var url = new URL( otherHost + "{{ports[https][0]}}/mixed-content/tentative/resources/test.wav")
var url = new URL( otherHost + "{{ports[https][0]}}/mixed-content/resources/test.wav")
var i = document.createElement('audio');
i.oncanplaythrough = test.step_func_done(_ => {
assert_equals(i.duration, 1, "Length of other host audio is correct");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@

function assert_image_loads(test) {
// Since autoupgrades don't upgrade custom ports, we use the https port with an HTTP scheme. A successful autoupgrade will result in the right URL loading (and no autoupgrade will result in failure).
var url = new URL("http://{{host}}:{{ports[https][0]}}/mixed-content/tentative/resources/pass.png")
var url = new URL("http://{{host}}:{{ports[https][0]}}/mixed-content/resources/pass.png")
var i = document.createElement('img');
i.onload = test.step_func_done(_ => {
assert_equals(i.naturalHeight, 64, "Height.");
Expand All @@ -29,7 +29,7 @@
function assert_other_host_image_loads(test) {
// Since autoupgrades don't upgrade custom ports, we use the https port with an HTTP scheme. A successful autoupgrade will result in the right URL loading (and no autoupgrade will result in failure).
var otherHost = get_host_info().HTTP_NOTSAMESITE_ORIGIN.slice(0,-4); // cut of http port
var url = new URL( otherHost + "{{ports[https][0]}}/mixed-content/tentative/resources/pass.png")
var url = new URL( otherHost + "{{ports[https][0]}}/mixed-content/resources/pass.png")
var i = document.createElement('img');
i.onload = test.step_func_done(_ => {
assert_equals(i.naturalHeight, 64, "Height.");
Expand Down
File renamed without changes
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@

function assert_video_loads(test) {
// Since autoupgrades don't upgrade custom ports, we use the https port with an HTTP scheme. A successful autoupgrade will result in the right URL loading (and no autoupgrade will result in failure).
var url = new URL("http://{{host}}:{{ports[https][0]}}/mixed-content/tentative/resources/test.ogv")
var url = new URL("http://{{host}}:{{ports[https][0]}}/mixed-content/resources/test.ogv")
var i = document.createElement('video');
i.oncanplaythrough = test.step_func_done(_ => {
assert_equals(Math.floor(i.duration), 300, "Length.");
Expand All @@ -28,7 +28,7 @@
function assert_other_host_video_loads(test) {
// Since autoupgrades don't upgrade custom ports, we use the https port with an HTTP scheme. A successful autoupgrade will result in the right URL loading (and no autoupgrade will result in failure).
var otherHost = get_host_info().HTTP_NOTSAMESITE_ORIGIN.slice(0,-4); // cut of http port
var url = new URL( otherHost + "{{ports[https][0]}}/mixed-content/tentative/resources/test.ogv")
var url = new URL( otherHost + "{{ports[https][0]}}/mixed-content/resources/test.ogv")
var i = document.createElement('video');
i.oncanplaythrough = test.step_func_done(_ => {
assert_equals(Math.floor(i.duration), 300, "Length. Other host");
Expand Down

0 comments on commit 1245166

Please sign in to comment.