Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
811 changes: 605 additions & 206 deletions components/script/dom/html/htmlmediaelement.rs

Large diffs are not rendered by default.

7 changes: 5 additions & 2 deletions components/script/dom/html/htmlsourceelement.rs
Original file line number Diff line number Diff line change
Expand Up @@ -105,8 +105,11 @@ impl VirtualMethods for HTMLSourceElement {

// Step 2. If parent is a media element that has no src attribute and whose networkState has
// the value NETWORK_EMPTY, then invoke that media element's resource selection algorithm.
if let Some(media) = parent.downcast::<HTMLMediaElement>() {
media.handle_source_child_insertion(can_gc);
if parent.is::<HTMLMediaElement>() && std::ptr::eq(&*parent, context.parent) {
parent
.downcast::<HTMLMediaElement>()
.unwrap()
.handle_source_child_insertion(self, can_gc);
}

// Step 3. If parent is a picture element, then for each child of parent's children, if
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
[media-src-7_2.html]
expected: TIMEOUT
[In-policy audio source element]
expected: FAIL

[Should not fire policy violation events]
expected: NOTRUN
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
[media-src-7_2_2.sub.html]
expected: TIMEOUT
[Disallowed audio source element]
expected: NOTRUN
[Test that securitypolicyviolation events are fired]
expected: TIMEOUT
Original file line number Diff line number Diff line change
@@ -1,10 +1,4 @@
[media-src-blocked.sub.html]
expected: TIMEOUT
[Disallowed async video source element]
expected: TIMEOUT

[Disallowed audio src]
expected: NOTRUN

[Disallowed audio source element]
expected: NOTRUN
expected: TIMEOUT
Original file line number Diff line number Diff line change
Expand Up @@ -58,3 +58,39 @@

[Rec2020-222000000, Context display-p3, ImageData display-p3, cropSource=true]
expected: FAIL

[sRGB-FF0100, Context srgb, ImageData srgb, cropSource=false]
expected: FAIL

[sRGB-FF0100, Context srgb, ImageData srgb, cropSource=true]
expected: FAIL

[sRGB-FF0100, Context display-p3, ImageData srgb, cropSource=false]
expected: FAIL

[sRGB-FF0100, Context display-p3, ImageData srgb, cropSource=true]
expected: FAIL

[sRGB-BB0000, Context srgb, ImageData srgb, cropSource=false]
expected: FAIL

[sRGB-BB0000, Context srgb, ImageData srgb, cropSource=true]
expected: FAIL

[sRGB-BB0000, Context display-p3, ImageData srgb, cropSource=false]
expected: FAIL

[sRGB-BB0000, Context display-p3, ImageData srgb, cropSource=true]
expected: FAIL

[Rec2020-3FF000000, Context srgb, ImageData srgb, cropSource=false]
expected: FAIL

[Rec2020-3FF000000, Context srgb, ImageData srgb, cropSource=true]
expected: FAIL

[Rec2020-3FF000000, Context display-p3, ImageData srgb, cropSource=false]
expected: FAIL

[Rec2020-3FF000000, Context display-p3, ImageData srgb, cropSource=true]
expected: FAIL
Original file line number Diff line number Diff line change
Expand Up @@ -58,3 +58,39 @@

[Rec2020-222000000, Context display-p3, ImageData display-p3, scaleImage=true]
expected: FAIL

[sRGB-FF0100, Context srgb, ImageData srgb, scaleImage=false]
expected: FAIL

[sRGB-FF0100, Context srgb, ImageData srgb, scaleImage=true]
expected: FAIL

[sRGB-FF0100, Context display-p3, ImageData srgb, scaleImage=false]
expected: FAIL

[sRGB-FF0100, Context display-p3, ImageData srgb, scaleImage=true]
expected: FAIL

[sRGB-BB0000, Context srgb, ImageData srgb, scaleImage=false]
expected: FAIL

[sRGB-BB0000, Context srgb, ImageData srgb, scaleImage=true]
expected: FAIL

[sRGB-BB0000, Context display-p3, ImageData srgb, scaleImage=false]
expected: FAIL

[sRGB-BB0000, Context display-p3, ImageData srgb, scaleImage=true]
expected: FAIL

[Rec2020-3FF000000, Context srgb, ImageData srgb, scaleImage=false]
expected: FAIL

[Rec2020-3FF000000, Context srgb, ImageData srgb, scaleImage=true]
expected: FAIL

[Rec2020-3FF000000, Context display-p3, ImageData srgb, scaleImage=false]
expected: FAIL

[Rec2020-3FF000000, Context display-p3, ImageData srgb, scaleImage=true]
expected: FAIL

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,25 +1,6 @@
[audio-tag.https.html]
expected: TIMEOUT
[Mixed-Content: Expects blocked for audio-tag to cross-http origin and keep-scheme redirection from https context.]
expected: TIMEOUT

[Mixed-Content: Expects blocked for audio-tag to cross-http origin and no-redirect redirection from https context.]
expected: NOTRUN

[Mixed-Content: Expects blocked for audio-tag to cross-http origin and swap-scheme redirection from https context.]
expected: NOTRUN

[Mixed-Content: Expects blocked for audio-tag to cross-https origin and swap-scheme redirection from https context.]
expected: NOTRUN

[Mixed-Content: Expects blocked for audio-tag to same-http origin and keep-scheme redirection from https context.]
expected: NOTRUN

[Mixed-Content: Expects blocked for audio-tag to same-http origin and no-redirect redirection from https context.]
expected: NOTRUN

[Mixed-Content: Expects blocked for audio-tag to same-http origin and swap-scheme redirection from https context.]
expected: NOTRUN
expected: FAIL

[Mixed-Content: Expects blocked for audio-tag to same-https origin and swap-scheme redirection from https context.]
expected: NOTRUN
expected: FAIL
Original file line number Diff line number Diff line change
@@ -1,25 +1,6 @@
[video-tag.https.html]
expected: TIMEOUT
[Mixed-Content: Expects blocked for video-tag to cross-http origin and keep-scheme redirection from https context.]
expected: TIMEOUT

[Mixed-Content: Expects blocked for video-tag to cross-http origin and no-redirect redirection from https context.]
expected: NOTRUN

[Mixed-Content: Expects blocked for video-tag to cross-http origin and swap-scheme redirection from https context.]
expected: NOTRUN

[Mixed-Content: Expects blocked for video-tag to cross-https origin and swap-scheme redirection from https context.]
expected: NOTRUN

[Mixed-Content: Expects blocked for video-tag to same-http origin and keep-scheme redirection from https context.]
expected: NOTRUN

[Mixed-Content: Expects blocked for video-tag to same-http origin and no-redirect redirection from https context.]
expected: NOTRUN

[Mixed-Content: Expects blocked for video-tag to same-http origin and swap-scheme redirection from https context.]
expected: NOTRUN
expected: FAIL

[Mixed-Content: Expects blocked for video-tag to same-https origin and swap-scheme redirection from https context.]
expected: NOTRUN
expected: FAIL

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,25 +1,18 @@
[audio-tag.https.html]
expected: TIMEOUT
[Mixed-Content: Expects allowed for audio-tag to cross-http origin and keep-scheme redirection from https context.]
expected: TIMEOUT
expected: FAIL

[Mixed-Content: Expects allowed for audio-tag to cross-http origin and no-redirect redirection from https context.]
expected: NOTRUN
expected: FAIL

[Mixed-Content: Expects allowed for audio-tag to cross-http origin and swap-scheme redirection from https context.]
expected: NOTRUN
expected: FAIL

[Mixed-Content: Expects allowed for audio-tag to same-http origin and keep-scheme redirection from https context.]
expected: NOTRUN
expected: FAIL

[Mixed-Content: Expects allowed for audio-tag to same-http origin and no-redirect redirection from https context.]
expected: NOTRUN
expected: FAIL

[Mixed-Content: Expects allowed for audio-tag to same-http origin and swap-scheme redirection from https context.]
expected: NOTRUN

[Mixed-Content: Expects allowed for audio-tag to same-https origin and keep-scheme redirection from https context.]
expected: NOTRUN

[Mixed-Content: Expects allowed for audio-tag to same-https origin and no-redirect redirection from https context.]
expected: NOTRUN
expected: FAIL
Original file line number Diff line number Diff line change
@@ -1,25 +1,18 @@
[video-tag.https.html]
expected: TIMEOUT
[Mixed-Content: Expects allowed for video-tag to cross-http origin and keep-scheme redirection from https context.]
expected: TIMEOUT
expected: FAIL

[Mixed-Content: Expects allowed for video-tag to cross-http origin and no-redirect redirection from https context.]
expected: NOTRUN
expected: FAIL

[Mixed-Content: Expects allowed for video-tag to cross-http origin and swap-scheme redirection from https context.]
expected: NOTRUN
expected: FAIL

[Mixed-Content: Expects allowed for video-tag to same-http origin and keep-scheme redirection from https context.]
expected: NOTRUN
expected: FAIL

[Mixed-Content: Expects allowed for video-tag to same-http origin and no-redirect redirection from https context.]
expected: NOTRUN
expected: FAIL

[Mixed-Content: Expects allowed for video-tag to same-http origin and swap-scheme redirection from https context.]
expected: NOTRUN

[Mixed-Content: Expects allowed for video-tag to same-https origin and keep-scheme redirection from https context.]
expected: NOTRUN

[Mixed-Content: Expects allowed for video-tag to same-https origin and no-redirect redirection from https context.]
expected: NOTRUN
expected: FAIL
3 changes: 3 additions & 0 deletions tests/wpt/meta/resource-timing/initiator-type/audio.html.ini
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[audio.html]
[The initiator type for <source src> with type 'audio/ogg' must be 'audio']
expected: FAIL
3 changes: 3 additions & 0 deletions tests/wpt/meta/resource-timing/initiator-type/video.html.ini
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
[video.html]
[The initiator type for <track src> must be 'track']
expected: FAIL

[The initiator type for <source src> with type="video/mp4" must be 'video']
expected: FAIL
Loading
Loading