From 965fbbd99ff8833b899362979b599273a2c13abe Mon Sep 17 00:00:00 2001 From: Connor Imes Date: Wed, 28 Oct 2015 14:53:47 -0500 Subject: [PATCH 01/58] Update energymon dependencies. Ensure the energymon is enabled before trying to get refresh interval. --- components/profile_traits/Cargo.toml | 2 +- components/profile_traits/energy.rs | 9 +++++++-- components/servo/Cargo.lock | 11 +++++------ 3 files changed, 13 insertions(+), 9 deletions(-) diff --git a/components/profile_traits/Cargo.toml b/components/profile_traits/Cargo.toml index 0f993d3dcd5..71a3de5662a 100644 --- a/components/profile_traits/Cargo.toml +++ b/components/profile_traits/Cargo.toml @@ -19,7 +19,7 @@ features = [ "serde_serialization" ] [dependencies.energymon] git = "https://github.com/energymon/energymon-rust.git" -rev = "67f74732ac" +rev = "eba1d8a" optional = true [dependencies.energy-monitor] diff --git a/components/profile_traits/energy.rs b/components/profile_traits/energy.rs index a4b60e1316f..23554386f77 100644 --- a/components/profile_traits/energy.rs +++ b/components/profile_traits/energy.rs @@ -36,8 +36,8 @@ mod energymon { static mut EM: Option<*mut EnergyMon> = None; - /// Read energy from the energy monitor, otherwise return 0. - pub fn read_energy_uj() -> u64 { + fn init() { + // can't use lazy_static macro for EM (no Sync trait for EnergyMon) static ONCE: Once = ONCE_INIT; ONCE.call_once(|| { if let Ok(em) = EnergyMon::new() { @@ -47,7 +47,11 @@ mod energymon { } } }); + } + /// Read energy from the energy monitor, otherwise return 0. + pub fn read_energy_uj() -> u64 { + init(); unsafe { // EnergyMon implementations of EnergyMonitor always return a value EM.map_or(0, |em| (*em).read_uj().unwrap()) @@ -55,6 +59,7 @@ mod energymon { } pub fn get_min_interval_ms() -> u32 { + init(); unsafe { EM.map_or(0, |em| ((*em).interval_us() as f64 / 1000.0).ceil() as u32) } diff --git a/components/servo/Cargo.lock b/components/servo/Cargo.lock index bfeee4a49ac..dfd5adf5a13 100644 --- a/components/servo/Cargo.lock +++ b/components/servo/Cargo.lock @@ -473,18 +473,17 @@ source = "registry+https://github.com/rust-lang/crates.io-index" [[package]] name = "energymon" version = "0.1.0" -source = "git+https://github.com/energymon/energymon-rust.git?rev=67f74732ac#67f74732ac0acc682659f7e81836155a32188fd0" +source = "git+https://github.com/energymon/energymon-rust.git?rev=eba1d8a#eba1d8a7256b710230ea2c1b26525b88bfcb529d" dependencies = [ "energy-monitor 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", - "energymon-default-sys 0.1.0 (git+https://github.com/energymon/energymon-default-sys.git)", - "energymon-sys 0.1.0 (git+https://github.com/energymon/energymon-sys.git)", + "energymon-default-sys 0.1.0 (git+https://github.com/energymon/energymon-sys.git)", "libc 0.1.10 (registry+https://github.com/rust-lang/crates.io-index)", ] [[package]] name = "energymon-default-sys" version = "0.1.0" -source = "git+https://github.com/energymon/energymon-default-sys.git#82dd2f6762b492ced15d8446b70569778200c287" +source = "git+https://github.com/energymon/energymon-sys.git#82756eee725db3ccb658f14857947a0260743d4d" dependencies = [ "energymon-sys 0.1.0 (git+https://github.com/energymon/energymon-sys.git)", "libc 0.1.10 (registry+https://github.com/rust-lang/crates.io-index)", @@ -494,7 +493,7 @@ dependencies = [ [[package]] name = "energymon-sys" version = "0.1.0" -source = "git+https://github.com/energymon/energymon-sys.git#6306f70e5d5c824fa168e43521385798fd1b890b" +source = "git+https://github.com/energymon/energymon-sys.git#82756eee725db3ccb658f14857947a0260743d4d" dependencies = [ "libc 0.1.10 (registry+https://github.com/rust-lang/crates.io-index)", ] @@ -1417,7 +1416,7 @@ name = "profile_traits" version = "0.0.1" dependencies = [ "energy-monitor 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", - "energymon 0.1.0 (git+https://github.com/energymon/energymon-rust.git?rev=67f74732ac)", + "energymon 0.1.0 (git+https://github.com/energymon/energymon-rust.git?rev=eba1d8a)", "ipc-channel 0.1.0 (git+https://github.com/pcwalton/ipc-channel)", "plugins 0.0.1", "serde 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)", From 04e32c7ab09920be8406e33581ba483e9c322409 Mon Sep 17 00:00:00 2001 From: Ms2ger Date: Thu, 29 Oct 2015 12:21:51 +0100 Subject: [PATCH 02/58] Remove the Zeroable definition for Finite. I have no idea why it was added, and it appears to be unused. --- components/script/dom/bindings/num.rs | 3 --- 1 file changed, 3 deletions(-) diff --git a/components/script/dom/bindings/num.rs b/components/script/dom/bindings/num.rs index ed5d78cdb6c..720aeb28557 100644 --- a/components/script/dom/bindings/num.rs +++ b/components/script/dom/bindings/num.rs @@ -4,7 +4,6 @@ //! The `Finite` struct. -use core::nonzero::Zeroable; use num::Float; use std::ops::Deref; @@ -12,8 +11,6 @@ use std::ops::Deref; #[derive(JSTraceable, Clone, Copy, Eq, PartialEq)] pub struct Finite(T); -unsafe impl Zeroable for Finite {} - impl Finite { /// Create a new `Finite` safely. pub fn new(value: T) -> Option> { From 244bd11f3fb2b5f765b3f86e9f85cbaebe06bced Mon Sep 17 00:00:00 2001 From: Ms2ger Date: Sun, 25 Oct 2015 11:13:37 +0100 Subject: [PATCH 03/58] Privatize LayoutNode::chain. There is no reason for this field to be public. --- components/layout/wrapper.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/components/layout/wrapper.rs b/components/layout/wrapper.rs index 38c23cd0b47..61bd20204bb 100644 --- a/components/layout/wrapper.rs +++ b/components/layout/wrapper.rs @@ -81,7 +81,7 @@ pub struct LayoutNode<'a> { node: LayoutJS, /// Being chained to a PhantomData prevents `LayoutNode`s from escaping. - pub chain: PhantomData<&'a ()>, + chain: PhantomData<&'a ()>, } impl<'a> PartialEq for LayoutNode<'a> { From 06f9a2bc34836bee1cf8376ac8f8c1e985f00971 Mon Sep 17 00:00:00 2001 From: Ms2ger Date: Sun, 25 Oct 2015 11:13:56 +0100 Subject: [PATCH 04/58] Implement a LayoutNode::new function. --- components/layout/wrapper.rs | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/components/layout/wrapper.rs b/components/layout/wrapper.rs index 61bd20204bb..9a936433d79 100644 --- a/components/layout/wrapper.rs +++ b/components/layout/wrapper.rs @@ -54,6 +54,7 @@ use script::dom::htmltextareaelement::{HTMLTextAreaElement, LayoutHTMLTextAreaEl use script::dom::node::{HAS_CHANGED, HAS_DIRTY_DESCENDANTS, IS_DIRTY}; use script::dom::node::{LayoutNodeHelpers, Node, SharedLayoutData}; use script::dom::text::Text; +use script::layout_interface::TrustedNodeAddress; use selectors::matching::DeclarationBlock; use selectors::parser::{AttrSelector, NamespaceConstraint}; use smallvec::VecLike; @@ -92,6 +93,14 @@ impl<'a> PartialEq for LayoutNode<'a> { } impl<'ln> LayoutNode<'ln> { + pub unsafe fn new(address: &TrustedNodeAddress) -> LayoutNode { + let node = LayoutJS::from_trusted_node_address(*address); + LayoutNode { + node: node, + chain: PhantomData, + } + } + /// Creates a new layout node with the same lifetime as this layout node. pub unsafe fn new_with_this_lifetime(&self, node: &LayoutJS) -> LayoutNode<'ln> { LayoutNode { From ee0b0c81d1b735bea149afca4c326be360d7d9d9 Mon Sep 17 00:00:00 2001 From: Ms2ger Date: Sun, 25 Oct 2015 11:22:27 +0100 Subject: [PATCH 05/58] Pass a LayoutNode to LayoutTask::dirty_all_nodes. There is no point in passing a mutable reference to what is essentially already a pointer. --- components/layout/layout_task.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/components/layout/layout_task.rs b/components/layout/layout_task.rs index 638488452f9..ad7bf3942ff 100644 --- a/components/layout/layout_task.rs +++ b/components/layout/layout_task.rs @@ -1144,7 +1144,7 @@ impl LayoutTask { transmute(&mut doc) }; - let mut node: LayoutNode = match doc.root_node() { + let node: LayoutNode = match doc.root_node() { None => return, Some(x) => x, }; @@ -1190,7 +1190,7 @@ impl LayoutTask { let needs_reflow = screen_size_changed && !needs_dirtying; unsafe { if needs_dirtying { - LayoutTask::dirty_all_nodes(&mut node); + LayoutTask::dirty_all_nodes(node); } } if needs_reflow { @@ -1466,7 +1466,7 @@ impl LayoutTask { } } - unsafe fn dirty_all_nodes(node: &mut LayoutNode) { + unsafe fn dirty_all_nodes(node: LayoutNode) { for node in node.traverse_preorder() { // TODO(cgaebel): mark nodes which are sensitive to media queries as // "changed": From 1eb8900f486e681888f0e5dccd7e677cd17ecadd Mon Sep 17 00:00:00 2001 From: Ms2ger Date: Thu, 29 Oct 2015 16:54:20 +0100 Subject: [PATCH 06/58] Simplify LayoutDocument::root_node. --- components/layout/wrapper.rs | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/components/layout/wrapper.rs b/components/layout/wrapper.rs index 9a936433d79..72973633067 100644 --- a/components/layout/wrapper.rs +++ b/components/layout/wrapper.rs @@ -369,11 +369,7 @@ impl<'le> LayoutDocument<'le> { } pub fn root_node(&self) -> Option> { - let mut node = self.as_node().first_child(); - while node.is_some() && !node.unwrap().is_element() { - node = node.unwrap().next_sibling(); - } - node + self.as_node().children().find(LayoutNode::is_element) } pub fn drain_event_state_changes(&self) -> Vec<(LayoutElement, EventState)> { From cce510900e9d1f95990556135b285e4b10f8eddd Mon Sep 17 00:00:00 2001 From: Ms2ger Date: Thu, 29 Oct 2015 16:55:27 +0100 Subject: [PATCH 07/58] Use LayoutNode::new to avoid transmute calls in LayoutTask. --- components/layout/layout_task.rs | 34 +++++++++----------------------- components/layout/wrapper.rs | 9 +++++++++ 2 files changed, 18 insertions(+), 25 deletions(-) diff --git a/components/layout/layout_task.rs b/components/layout/layout_task.rs index ad7bf3942ff..f4ea681e24a 100644 --- a/components/layout/layout_task.rs +++ b/components/layout/layout_task.rs @@ -51,9 +51,7 @@ use profile_traits::time::{self, ProfilerMetadata, profile}; use query::{LayoutRPCImpl, process_content_box_request, process_content_boxes_request}; use query::{MarginPadding, MarginRetrievingFragmentBorderBoxIterator, PositionProperty}; use query::{PositionRetrievingFragmentBorderBoxIterator, Side}; -use script::dom::bindings::js::LayoutJS; -use script::dom::document::Document; -use script::dom::node::{LayoutData, Node}; +use script::dom::node::LayoutData; use script::layout_interface::Animation; use script::layout_interface::{LayoutChan, LayoutRPC, OffsetParentResponse}; use script::layout_interface::{Msg, NewLayoutTaskInfo, Reflow, ReflowGoal, ReflowQueryType}; @@ -90,7 +88,7 @@ use util::opts; use util::task::spawn_named_with_send_on_failure; use util::task_state; use util::workqueue::WorkQueue; -use wrapper::{LayoutDocument, LayoutNode, ThreadSafeLayoutNode}; +use wrapper::{LayoutNode, ThreadSafeLayoutNode}; /// The number of screens of data we're allowed to generate display lists for in each direction. pub const DISPLAY_PORT_SIZE_FACTOR: i32 = 8; @@ -895,17 +893,9 @@ impl LayoutTask { property: &Atom, layout_root: &mut FlowRef) -> Option { - // FIXME: Isolate this transmutation into a "bridge" module. - // FIXME(rust#16366): The following line had to be moved because of a - // rustc bug. It should be in the next unsafe block. - let node: LayoutJS = unsafe { - LayoutJS::from_trusted_node_address(requested_node) - }; - let node: &LayoutNode = unsafe { - transmute(&node) - }; + let node = unsafe { LayoutNode::new(&requested_node) }; - let layout_node = ThreadSafeLayoutNode::new(node); + let layout_node = ThreadSafeLayoutNode::new(&node); let layout_node = match pseudo { &Some(PseudoElement::Before) => layout_node.get_before_pseudo(), &Some(PseudoElement::After) => layout_node.get_after_pseudo(), @@ -1136,15 +1126,9 @@ impl LayoutTask { }; let _ajst = AutoJoinScriptTask { data: data }; - // FIXME: Isolate this transmutation into a "bridge" module. - let mut doc: LayoutJS = unsafe { - LayoutJS::from_trusted_node_address(data.document).downcast::().unwrap() - }; - let doc: &mut LayoutDocument = unsafe { - transmute(&mut doc) - }; - - let node: LayoutNode = match doc.root_node() { + let document = unsafe { LayoutNode::new(&data.document) }; + let document = document.as_document().unwrap(); + let node: LayoutNode = match document.root_node() { None => return, Some(x) => x, }; @@ -1199,7 +1183,7 @@ impl LayoutTask { } } - let event_state_changes = doc.drain_event_state_changes(); + let event_state_changes = document.drain_event_state_changes(); if !needs_dirtying { for &(el, state) in event_state_changes.iter() { assert!(!state.is_empty()); @@ -1233,7 +1217,7 @@ impl LayoutTask { }); // Retrieve the (possibly rebuilt) root flow. - rw_data.root_flow = self.try_get_layout_root(node.clone()); + rw_data.root_flow = self.try_get_layout_root(node); } // Send new canvas renderers to the paint task diff --git a/components/layout/wrapper.rs b/components/layout/wrapper.rs index 72973633067..d10932530ae 100644 --- a/components/layout/wrapper.rs +++ b/components/layout/wrapper.rs @@ -221,6 +221,15 @@ impl<'ln> LayoutNode<'ln> { as_element(self.node) } + pub fn as_document(&self) -> Option> { + self.node.downcast().map(|document| { + LayoutDocument { + document: document, + chain: PhantomData, + } + }) + } + fn parent_node(&self) -> Option> { unsafe { self.node.parent_node_ref().map(|node| self.new_with_this_lifetime(&node)) From bb7e5375a041f22f9370eeedede4e36c0e4f4bae Mon Sep 17 00:00:00 2001 From: Connor Imes Date: Thu, 29 Oct 2015 12:18:43 -0500 Subject: [PATCH 08/58] Heartbeats support for Android. Add debug option to enable heartbeats for all profiler categories. --- components/profile/heartbeats.rs | 58 +++++++++++++++++++++++++------- components/util/opts.rs | 13 ++++++- 2 files changed, 57 insertions(+), 14 deletions(-) diff --git a/components/profile/heartbeats.rs b/components/profile/heartbeats.rs index 6eaff00e79f..0101f62e25b 100644 --- a/components/profile/heartbeats.rs +++ b/components/profile/heartbeats.rs @@ -11,6 +11,8 @@ use std::env::var_os; use std::error::Error; use std::fs::File; use std::mem; +use std::path::Path; +use util::opts; static mut HBS: Option<*mut HashMap> = None; @@ -72,6 +74,7 @@ pub fn cleanup() { } } +/// Check if a heartbeat exists for the given category pub fn is_heartbeat_enabled(category: &ProfilerCategory) -> bool { unsafe { HBS.map_or(false, |m| (*m).contains_key(category)) @@ -93,22 +96,51 @@ pub fn maybe_heartbeat(category: &ProfilerCategory, } } -/// Create a heartbeat if the correct environment variable is set +// TODO(cimes): Android doesn't really do environment variables. Need a better way to configure dynamically. + +fn is_create_heartbeat(category: &ProfilerCategory) -> bool { + opts::get().profile_heartbeats || var_os(format!("SERVO_HEARTBEAT_ENABLE_{:?}", category)).is_some() +} + +fn open_heartbeat_log>(name: P) -> Option { + match File::create(name) { + Ok(f) => Some(f), + Err(e) => { + warn!("Failed to open heartbeat log: {}", Error::description(&e)); + None + }, + } +} + +#[cfg(target_os = "android")] +fn get_heartbeat_log(category: &ProfilerCategory) -> Option { + open_heartbeat_log(format!("/sdcard/servo/heartbeat-{:?}.log", category)) +} + +#[cfg(not(target_os = "android"))] +fn get_heartbeat_log(category: &ProfilerCategory) -> Option { + var_os(format!("SERVO_HEARTBEAT_LOG_{:?}", category)).and_then(|name| open_heartbeat_log(&name)) +} + +fn get_heartbeat_window_size(category: &ProfilerCategory) -> usize { + const WINDOW_SIZE_DEFAULT: usize = 1; + match var_os(format!("SERVO_HEARTBEAT_WINDOW_{:?}", category)) { + Some(w) => match w.into_string() { + Ok(s) => s.parse::().unwrap_or(WINDOW_SIZE_DEFAULT), + _ => WINDOW_SIZE_DEFAULT, + }, + None => WINDOW_SIZE_DEFAULT, + } +} + +/// Possibly create a heartbeat fn maybe_create_heartbeat(hbs: &mut HashMap, category: ProfilerCategory) { - static WINDOW_SIZE_DEFAULT: usize = 20; - if let Some(_) = var_os(format!("SERVO_HEARTBEAT_ENABLE_{:?}", category)) { + if is_create_heartbeat(&category) { // get optional log file - let logfile: Option = var_os(format!("SERVO_HEARTBEAT_LOG_{:?}", category)) - .and_then(|name| File::create(name).ok()); - // get window size - let window_size: usize = match var_os(format!("SERVO_HEARTBEAT_WINDOW_{:?}", category)) { - Some(w) => match w.into_string() { - Ok(s) => s.parse::().unwrap_or(WINDOW_SIZE_DEFAULT), - _ => WINDOW_SIZE_DEFAULT, - }, - None => WINDOW_SIZE_DEFAULT, - }; + let logfile: Option = get_heartbeat_log(&category); + // window size + let window_size: usize = get_heartbeat_window_size(&category); // create the heartbeat match Heartbeat::new(window_size, Some(heartbeat_window_callback), logfile) { Ok(hb) => { diff --git a/components/util/opts.rs b/components/util/opts.rs index 785f5909240..9f68ffb432b 100644 --- a/components/util/opts.rs +++ b/components/util/opts.rs @@ -121,6 +121,9 @@ pub struct Opts { /// Periodically print out on which events script tasks spend their processing time. pub profile_script_events: bool, + /// Enable all heartbeats for profiling. + pub profile_heartbeats: bool, + /// `None` to disable devtools or `Some` with a port number to start a server to listen to /// remote Firefox devtools connections. pub devtools_port: Option, @@ -223,6 +226,9 @@ pub struct DebugOptions { /// Profile which events script tasks spend their time on. pub profile_script_events: bool, + /// Enable all heartbeats for profiling. + pub profile_heartbeats: bool, + /// Paint borders along layer and tile boundaries. pub show_compositor_borders: bool, @@ -286,6 +292,7 @@ impl DebugOptions { "relayout-event" => debug_options.relayout_event = true, "profile-tasks" => debug_options.profile_tasks = true, "profile-script-events" => debug_options.profile_script_events = true, + "profile-heartbeats" => debug_options.profile_heartbeats = true, "show-compositor-borders" => debug_options.show_compositor_borders = true, "show-fragment-borders" => debug_options.show_fragment_borders = true, "show-parallel-paint" => debug_options.show_parallel_paint = true, @@ -325,6 +332,8 @@ pub fn print_debug_usage(app: &str) -> ! { print_option("dump-layer-tree", "Print the layer tree whenever it changes."); print_option("relayout-event", "Print notifications when there is a relayout."); print_option("profile-tasks", "Instrument each task, writing the output to a file."); + print_option("profile-script-events", "Enable profiling of script-related events."); + print_option("profile-heartbeats", "Enable heartbeats for all task categories."); print_option("show-compositor-borders", "Paint borders along layer and tile boundaries."); print_option("show-fragment-borders", "Paint borders along fragment boundaries."); print_option("show-parallel-paint", "Overlay tiles with colors showing which thread painted them."); @@ -336,10 +345,10 @@ pub fn print_debug_usage(app: &str) -> ! { print_option("disable-share-style-cache", "Disable the style sharing cache."); print_option("parallel-display-list-building", "Build display lists in parallel."); + print_option("convert-mouse-to-touch", "Send touch events instead of mouse events"); print_option("replace-surrogates", "Replace unpaires surrogates in DOM strings with U+FFFD. \ See https://github.com/servo/servo/issues/6564"); print_option("gc-profile", "Log GC passes and their durations."); - print_option("convert-mouse-to-touch", "Send touch events instead of mouse events"); println!(""); @@ -433,6 +442,7 @@ pub fn default_opts() -> Opts { validate_display_list_geometry: false, profile_tasks: false, profile_script_events: false, + profile_heartbeats: false, sniff_mime_types: false, disable_share_style_cache: false, parallel_display_list_building: false, @@ -620,6 +630,7 @@ pub fn from_cmdline_args(args: &[String]) { bubble_inline_sizes_separately: bubble_inline_sizes_separately, profile_tasks: debug_options.profile_tasks, profile_script_events: debug_options.profile_script_events, + profile_heartbeats: debug_options.profile_heartbeats, trace_layout: debug_options.trace_layout, devtools_port: devtools_port, webdriver_port: webdriver_port, From 4dd48a708066defad3f11398d8911525f3d72291 Mon Sep 17 00:00:00 2001 From: Matt Brubeck Date: Thu, 29 Oct 2015 09:32:51 -0700 Subject: [PATCH 09/58] Remove some unused code on Android --- components/servo/main.rs | 2 -- components/util/lib.rs | 2 +- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/components/servo/main.rs b/components/servo/main.rs index 3e81da46f1f..34c9bfe3d90 100644 --- a/components/servo/main.rs +++ b/components/servo/main.rs @@ -31,8 +31,6 @@ use servo::Browser; use servo::compositing::windowing::WindowEvent; use servo::net_traits::hosts; use servo::util::opts; -#[cfg(target_os = "android")] -use std::borrow::ToOwned; use std::rc::Rc; fn main() { diff --git a/components/util/lib.rs b/components/util/lib.rs index 5cfda0e8c7c..850998408f1 100644 --- a/components/util/lib.rs +++ b/components/util/lib.rs @@ -11,7 +11,7 @@ #![feature(heap_api)] #![feature(oom)] #![feature(optin_builtin_traits)] -#![feature(path_ext)] +#![cfg_attr(not(target_os = "android"), feature(path_ext))] #![feature(plugin)] #![feature(slice_splits)] #![feature(step_by)] From c844c53ba54aad49c0ab4a3d2589060d261354c0 Mon Sep 17 00:00:00 2001 From: Corey Farwell Date: Thu, 29 Oct 2015 18:49:44 -0400 Subject: [PATCH 10/58] Remove struct field for 'face' attribute Part of #7863 --- components/script/dom/htmlfontelement.rs | 17 +++++------------ 1 file changed, 5 insertions(+), 12 deletions(-) diff --git a/components/script/dom/htmlfontelement.rs b/components/script/dom/htmlfontelement.rs index 6c54bfbc773..c0717e8e3e7 100644 --- a/components/script/dom/htmlfontelement.rs +++ b/components/script/dom/htmlfontelement.rs @@ -4,7 +4,6 @@ use cssparser::RGBA; use dom::attr::{Attr, AttrValue}; -use dom::bindings::cell::DOMRefCell; use dom::bindings::codegen::Bindings::HTMLFontElementBinding; use dom::bindings::codegen::Bindings::HTMLFontElementBinding::HTMLFontElementMethods; use dom::bindings::conversions::Castable; @@ -23,7 +22,6 @@ use util::str::{self, DOMString, parse_legacy_font_size}; pub struct HTMLFontElement { htmlelement: HTMLElement, color: Cell>, - face: DOMRefCell>, } @@ -32,7 +30,6 @@ impl HTMLFontElement { HTMLFontElement { htmlelement: HTMLElement::new_inherited(localName, prefix, document), color: Cell::new(None), - face: DOMRefCell::new(None), } } @@ -82,11 +79,6 @@ impl VirtualMethods for HTMLFontElement { str::parse_legacy_color(&value).ok() })); }, - &atom!(face) => { - *self.face.borrow_mut() = - mutation.new_value(attr) - .map(|value| value.as_atom().clone()) - }, _ => {}, } } @@ -111,10 +103,11 @@ impl HTMLFontElement { #[allow(unsafe_code)] pub fn get_face(&self) -> Option { - let face = unsafe { self.face.borrow_for_layout() }; - match *face { - Some(ref s) => Some(s.clone()), - None => None, + unsafe { + self.upcast::() + .get_attr_for_layout(&ns!(""), &atom!("face")) + .map(AttrValue::as_atom) + .cloned() } } From edc14939328cb3d43961daa2eaffacb021d118cd Mon Sep 17 00:00:00 2001 From: Corey Farwell Date: Fri, 30 Oct 2015 08:30:13 -0400 Subject: [PATCH 11/58] Use 'atom!' macro for known static strings --- components/script/dom/htmlbodyelement.rs | 2 +- components/script/dom/htmlfontelement.rs | 2 +- components/script/dom/htmliframeelement.rs | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/components/script/dom/htmlbodyelement.rs b/components/script/dom/htmlbodyelement.rs index 4b639d0ed42..333febd77c9 100644 --- a/components/script/dom/htmlbodyelement.rs +++ b/components/script/dom/htmlbodyelement.rs @@ -70,7 +70,7 @@ impl HTMLBodyElementMethods for HTMLBodyElement { fn SetText(&self, value: DOMString) { let element = self.upcast::(); let color = str::parse_legacy_color(&value).ok(); - element.set_attribute(&Atom::from_slice("text"), AttrValue::Color(value, color)); + element.set_attribute(&atom!("text"), AttrValue::Color(value, color)); } // https://html.spec.whatwg.org/multipage/#the-body-element diff --git a/components/script/dom/htmlfontelement.rs b/components/script/dom/htmlfontelement.rs index c0717e8e3e7..da551dd0deb 100644 --- a/components/script/dom/htmlfontelement.rs +++ b/components/script/dom/htmlfontelement.rs @@ -62,7 +62,7 @@ impl HTMLFontElementMethods for HTMLFontElement { fn SetSize(&self, value: DOMString) { let element = self.upcast::(); let length = parse_length(&value); - element.set_attribute(&Atom::from_slice("size"), AttrValue::Length(value, length)); + element.set_attribute(&atom!("size"), AttrValue::Length(value, length)); } } diff --git a/components/script/dom/htmliframeelement.rs b/components/script/dom/htmliframeelement.rs index da119309bef..505b727b3b8 100644 --- a/components/script/dom/htmliframeelement.rs +++ b/components/script/dom/htmliframeelement.rs @@ -304,7 +304,7 @@ impl HTMLIFrameElementMethods for HTMLIFrameElement { fn Mozbrowser(&self) -> bool { if mozbrowser_enabled() { let element = self.upcast::(); - element.has_attribute(&Atom::from_slice("mozbrowser")) + element.has_attribute(&atom!("mozbrowser")) } else { false } @@ -314,7 +314,7 @@ impl HTMLIFrameElementMethods for HTMLIFrameElement { fn SetMozbrowser(&self, value: bool) -> ErrorResult { if mozbrowser_enabled() { let element = self.upcast::(); - element.set_bool_attribute(&Atom::from_slice("mozbrowser"), value); + element.set_bool_attribute(&atom!("mozbrowser"), value); } Ok(()) } From b0841e007e9805ae8905f17d1eda39c700fb7e52 Mon Sep 17 00:00:00 2001 From: Ms2ger Date: Fri, 30 Oct 2015 15:45:25 +0100 Subject: [PATCH 12/58] Avoid a Vec copy in SendParam::extract. --- components/script/dom/xmlhttprequest.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/components/script/dom/xmlhttprequest.rs b/components/script/dom/xmlhttprequest.rs index a68d9478270..6bf36809ff6 100644 --- a/components/script/dom/xmlhttprequest.rs +++ b/components/script/dom/xmlhttprequest.rs @@ -1110,7 +1110,7 @@ impl Extractable for SendParam { }, eURLSearchParams(ref usp) => { // Default encoding is UTF-8. - usp.r().serialize(None).as_bytes().to_owned() + usp.r().serialize(None).into_bytes() }, } } From 2f8826435173d5e3f66ad06a66f0fae37776bd10 Mon Sep 17 00:00:00 2001 From: Ms2ger Date: Fri, 30 Oct 2015 15:45:48 +0100 Subject: [PATCH 13/58] Use if let in ScriptTask::notify_devtools. --- components/script/script_task.rs | 21 +++++++++------------ 1 file changed, 9 insertions(+), 12 deletions(-) diff --git a/components/script/script_task.rs b/components/script/script_task.rs index 30bb371667b..02046df717e 100644 --- a/components/script/script_task.rs +++ b/components/script/script_task.rs @@ -1656,18 +1656,15 @@ impl ScriptTask { } fn notify_devtools(&self, title: DOMString, url: Url, ids: (PipelineId, Option)) { - match self.devtools_chan { - None => {} - Some(ref chan) => { - let page_info = DevtoolsPageInfo { - title: title, - url: url, - }; - chan.send(ScriptToDevtoolsControlMsg::NewGlobal( - ids, - self.devtools_sender.clone(), - page_info)).unwrap(); - } + if let Some(ref chan) = self.devtools_chan { + let page_info = DevtoolsPageInfo { + title: title, + url: url, + }; + chan.send(ScriptToDevtoolsControlMsg::NewGlobal( + ids, + self.devtools_sender.clone(), + page_info)).unwrap(); } } From a67eaa2d829f8552164cf5508ce6bb3011533dbb Mon Sep 17 00:00:00 2001 From: Ms2ger Date: Fri, 30 Oct 2015 15:46:17 +0100 Subject: [PATCH 14/58] Avoid string copies in handle_find_{element,elements}_css. --- components/script/webdriver_handlers.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/components/script/webdriver_handlers.rs b/components/script/webdriver_handlers.rs index 5e9b87be23a..9669ce0fd2b 100644 --- a/components/script/webdriver_handlers.rs +++ b/components/script/webdriver_handlers.rs @@ -114,7 +114,7 @@ pub fn handle_get_frame_id(page: &Rc, pub fn handle_find_element_css(page: &Rc, _pipeline: PipelineId, selector: String, reply: IpcSender, ()>>) { - reply.send(match page.document().r().QuerySelector(selector.clone()) { + reply.send(match page.document().r().QuerySelector(selector) { Ok(node) => { Ok(node.map(|x| x.upcast::().get_unique_id())) } @@ -126,7 +126,7 @@ pub fn handle_find_elements_css(page: &Rc, _pipeline: PipelineId, selector: String, reply: IpcSender, ()>>) { - reply.send(match page.document().r().QuerySelectorAll(selector.clone()) { + reply.send(match page.document().r().QuerySelectorAll(selector) { Ok(ref nodes) => { let mut result = Vec::with_capacity(nodes.r().Length() as usize); for i in 0..nodes.r().Length() { From 5a2459748ba350e22798afb5208485febb0e6b6a Mon Sep 17 00:00:00 2001 From: Connor Imes Date: Thu, 29 Oct 2015 15:16:21 -0500 Subject: [PATCH 15/58] Read params from a file on Android --- components/servo/main.rs | 38 ++++++++++++++++++++++++++++++++++---- resources/android_params | 9 +++++++++ 2 files changed, 43 insertions(+), 4 deletions(-) create mode 100644 resources/android_params diff --git a/components/servo/main.rs b/components/servo/main.rs index 34c9bfe3d90..b339babb972 100644 --- a/components/servo/main.rs +++ b/components/servo/main.rs @@ -23,6 +23,8 @@ extern crate android_glue; // The window backed by glutin extern crate glutin_app as app; extern crate env_logger; +#[macro_use] +extern crate log; // The Servo engine extern crate servo; extern crate time; @@ -128,11 +130,39 @@ fn setup_logging() { } #[cfg(target_os = "android")] +/// Attempt to read parameters from a file since they are not passed to us in Android environments. +/// The first line should be the "servo" argument and the last should be the URL to load. +/// Blank lines and those beginning with a '#' are ignored. +/// Each line should be a separate parameter as would be parsed by the shell. +/// For example, "servo -p 10 http://en.wikipedia.org/wiki/Rust" would take 4 lines. fn args() -> Vec { - vec![ - "servo".to_owned(), - "http://en.wikipedia.org/wiki/Rust".to_owned() - ] + use std::error::Error; + use std::fs::File; + use std::io::{BufRead, BufReader}; + + const PARAMS_FILE: &'static str = "/sdcard/servo/android_params"; + match File::open(PARAMS_FILE) { + Ok(f) => { + let mut vec = Vec::new(); + let file = BufReader::new(&f); + for line in file.lines() { + let l = line.unwrap().trim().to_owned(); + // ignore blank lines and those that start with a '#' + match l.is_empty() || l.as_bytes()[0] == b'#' { + true => (), + false => vec.push(l), + } + } + vec + }, + Err(e) => { + debug!("Failed to open params file '{}': {}", PARAMS_FILE, Error::description(&e)); + vec![ + "servo".to_owned(), + "http://en.wikipedia.org/wiki/Rust".to_owned() + ] + }, + } } #[cfg(not(target_os = "android"))] diff --git a/resources/android_params b/resources/android_params new file mode 100644 index 00000000000..17775237c00 --- /dev/null +++ b/resources/android_params @@ -0,0 +1,9 @@ +# The first line here should be the "servo" argument (without quotes) and the +# last should be the URL to load. +# Blank lines and those beginning with a '#' are ignored. +# Each line should be a separate parameter as would be parsed by the shell. +# For example, "servo -p 10 http://en.wikipedia.org/wiki/Rust" would take 4 +# lines (the "-p" and "10" are separate even though they are related). + +servo +http://en.wikipedia.org/wiki/Rust From 7ccc5ad7da306989972b31f827ea3b451f79321c Mon Sep 17 00:00:00 2001 From: Ms2ger Date: Fri, 30 Oct 2015 16:24:04 +0100 Subject: [PATCH 16/58] Support unions that contain USVStrings. --- components/script/dom/bindings/codegen/CodegenRust.py | 4 ++++ components/script/dom/testbinding.rs | 4 ++++ components/script/dom/webidls/TestBinding.webidl | 1 + 3 files changed, 9 insertions(+) diff --git a/components/script/dom/bindings/codegen/CodegenRust.py b/components/script/dom/bindings/codegen/CodegenRust.py index 51a4653279f..0aa15a8d5a6 100644 --- a/components/script/dom/bindings/codegen/CodegenRust.py +++ b/components/script/dom/bindings/codegen/CodegenRust.py @@ -2000,6 +2000,7 @@ def UnionTypes(descriptors, dictionaries, callbacks, config): 'dom::bindings::conversions::StringificationBehavior', 'dom::bindings::error::throw_not_in_union', 'dom::bindings::js::Root', + 'dom::bindings::str::USVString', 'dom::types::*', 'js::jsapi::JSContext', 'js::jsapi::{HandleValue, MutableHandleValue}', @@ -3492,6 +3493,9 @@ def getUnionTypeTemplateVars(type, descriptorProvider): elif type.isDOMString(): name = type.name typeName = "DOMString" + elif type.isUSVString(): + name = type.name + typeName = "USVString" elif type.isPrimitive(): name = type.name typeName = builtinNames[type.tag()] diff --git a/components/script/dom/testbinding.rs b/components/script/dom/testbinding.rs index 7c2038eab3b..057b3c2172b 100644 --- a/components/script/dom/testbinding.rs +++ b/components/script/dom/testbinding.rs @@ -12,6 +12,8 @@ use dom::bindings::codegen::Bindings::TestBindingBinding::TestEnum::_empty; use dom::bindings::codegen::UnionTypes::BlobOrString; use dom::bindings::codegen::UnionTypes::EventOrString; use dom::bindings::codegen::UnionTypes::EventOrString::eString; +use dom::bindings::codegen::UnionTypes::EventOrUSVString; +use dom::bindings::codegen::UnionTypes::EventOrUSVString::eUSVString; use dom::bindings::codegen::UnionTypes::HTMLElementOrLong; use dom::bindings::codegen::UnionTypes::HTMLElementOrLong::eLong; use dom::bindings::global::{GlobalField, GlobalRef}; @@ -77,6 +79,8 @@ impl TestBindingMethods for TestBinding { fn SetUnionAttribute(&self, _: HTMLElementOrLong) {} fn Union2Attribute(&self) -> EventOrString { eString("".to_owned()) } fn SetUnion2Attribute(&self, _: EventOrString) {} + fn Union3Attribute(&self) -> EventOrUSVString { eUSVString(USVString("".to_owned())) } + fn SetUnion3Attribute(&self, _: EventOrUSVString) {} fn ArrayAttribute(&self, _: *mut JSContext) -> *mut JSObject { NullValue().to_object_or_null() } fn AnyAttribute(&self, _: *mut JSContext) -> JSVal { NullValue() } fn SetAnyAttribute(&self, _: *mut JSContext, _: HandleValue) {} diff --git a/components/script/dom/webidls/TestBinding.webidl b/components/script/dom/webidls/TestBinding.webidl index 181909721aa..f845be7dc15 100644 --- a/components/script/dom/webidls/TestBinding.webidl +++ b/components/script/dom/webidls/TestBinding.webidl @@ -89,6 +89,7 @@ interface TestBinding { attribute Blob interfaceAttribute; attribute (HTMLElement or long) unionAttribute; attribute (Event or DOMString) union2Attribute; + attribute (Event or USVString) union3Attribute; readonly attribute Uint8ClampedArray arrayAttribute; attribute any anyAttribute; attribute object objectAttribute; From e8914cd82929e0a82b7288df7d84b4125d9212e0 Mon Sep 17 00:00:00 2001 From: Ms2ger Date: Fri, 30 Oct 2015 16:33:29 +0100 Subject: [PATCH 17/58] Update URLSearchParams to use USVString and String. This matches the specification. --- components/script/dom/urlsearchparams.rs | 43 ++++++++++--------- .../script/dom/webidls/URLSearchParams.webidl | 14 +++--- 2 files changed, 29 insertions(+), 28 deletions(-) diff --git a/components/script/dom/urlsearchparams.rs b/components/script/dom/urlsearchparams.rs index 6ddfe4f5278..887869eafa4 100644 --- a/components/script/dom/urlsearchparams.rs +++ b/components/script/dom/urlsearchparams.rs @@ -5,11 +5,12 @@ use dom::bindings::cell::DOMRefCell; use dom::bindings::codegen::Bindings::URLSearchParamsBinding; use dom::bindings::codegen::Bindings::URLSearchParamsBinding::URLSearchParamsMethods; -use dom::bindings::codegen::UnionTypes::StringOrURLSearchParams; -use dom::bindings::codegen::UnionTypes::StringOrURLSearchParams::{eString, eURLSearchParams}; +use dom::bindings::codegen::UnionTypes::USVStringOrURLSearchParams; +use dom::bindings::codegen::UnionTypes::USVStringOrURLSearchParams::{eUSVString, eURLSearchParams}; use dom::bindings::error::Fallible; use dom::bindings::global::GlobalRef; use dom::bindings::js::Root; +use dom::bindings::str::USVString; use dom::bindings::utils::{Reflector, reflect_dom_object}; use encoding::types::EncodingRef; use url::form_urlencoded::{parse, serialize_with_encoding}; @@ -20,7 +21,7 @@ use util::str::DOMString; pub struct URLSearchParams { reflector_: Reflector, // https://url.spec.whatwg.org/#concept-urlsearchparams-list - list: DOMRefCell>, + list: DOMRefCell>, } impl URLSearchParams { @@ -37,14 +38,14 @@ impl URLSearchParams { } // https://url.spec.whatwg.org/#dom-urlsearchparams-urlsearchparams - pub fn Constructor(global: GlobalRef, init: Option) -> + pub fn Constructor(global: GlobalRef, init: Option) -> Fallible> { // Step 1. let query = URLSearchParams::new(global); match init { - Some(eString(init)) => { + Some(eUSVString(init)) => { // Step 2. - *query.r().list.borrow_mut() = parse(init.as_bytes()); + *query.r().list.borrow_mut() = parse(init.0.as_bytes()); }, Some(eURLSearchParams(init)) => { // Step 3. @@ -59,27 +60,27 @@ impl URLSearchParams { impl URLSearchParamsMethods for URLSearchParams { // https://url.spec.whatwg.org/#dom-urlsearchparams-append - fn Append(&self, name: DOMString, value: DOMString) { + fn Append(&self, name: USVString, value: USVString) { // Step 1. - self.list.borrow_mut().push((name, value)); + self.list.borrow_mut().push((name.0, value.0)); // Step 2. self.update_steps(); } // https://url.spec.whatwg.org/#dom-urlsearchparams-delete - fn Delete(&self, name: DOMString) { + fn Delete(&self, name: USVString) { // Step 1. - self.list.borrow_mut().retain(|&(ref k, _)| k != &name); + self.list.borrow_mut().retain(|&(ref k, _)| k != &name.0); // Step 2. self.update_steps(); } // https://url.spec.whatwg.org/#dom-urlsearchparams-get - fn Get(&self, name: DOMString) -> Option { + fn Get(&self, name: USVString) -> Option { let list = self.list.borrow(); list.iter().filter_map(|&(ref k, ref v)| { - if k == &name { - Some(v.clone()) + if k == &name.0 { + Some(USVString(v.clone())) } else { None } @@ -87,31 +88,31 @@ impl URLSearchParamsMethods for URLSearchParams { } // https://url.spec.whatwg.org/#dom-urlsearchparams-has - fn Has(&self, name: DOMString) -> bool { + fn Has(&self, name: USVString) -> bool { let list = self.list.borrow(); - list.iter().find(|&&(ref k, _)| k == &name).is_some() + list.iter().any(|&(ref k, _)| k == &name.0) } // https://url.spec.whatwg.org/#dom-urlsearchparams-set - fn Set(&self, name: DOMString, value: DOMString) { + fn Set(&self, name: USVString, value: USVString) { let mut list = self.list.borrow_mut(); let mut index = None; let mut i = 0; list.retain(|&(ref k, _)| { if index.is_none() { - if k == &name { + if k == &name.0 { index = Some(i); } else { i += 1; } true } else { - k != &name + k != &name.0 } }); match index { - Some(index) => list[index].1 = value, - None => list.push((name, value)), + Some(index) => list[index].1 = value.0, + None => list.push((name.0, value.0)), }; self.update_steps(); } @@ -125,7 +126,7 @@ impl URLSearchParamsMethods for URLSearchParams { impl URLSearchParams { // https://url.spec.whatwg.org/#concept-urlencoded-serializer - pub fn serialize(&self, encoding: Option) -> DOMString { + pub fn serialize(&self, encoding: Option) -> String { let list = self.list.borrow(); serialize_with_encoding(list.iter(), encoding) } diff --git a/components/script/dom/webidls/URLSearchParams.webidl b/components/script/dom/webidls/URLSearchParams.webidl index 4ab1cd43019..4804056273f 100644 --- a/components/script/dom/webidls/URLSearchParams.webidl +++ b/components/script/dom/webidls/URLSearchParams.webidl @@ -7,14 +7,14 @@ * https://url.spec.whatwg.org/#interface-urlsearchparams */ -[Constructor(optional (DOMString or URLSearchParams) init/* = ""*/)] +[Constructor(optional (USVString or URLSearchParams) init/* = ""*/)] interface URLSearchParams { - void append(DOMString name, DOMString value); - void delete(DOMString name); - DOMString? get(DOMString name); - // sequence getAll(DOMString name); - boolean has(DOMString name); - void set(DOMString name, DOMString value); + void append(USVString name, USVString value); + void delete(USVString name); + USVString? get(USVString name); + // sequence getAll(USVString name); + boolean has(USVString name); + void set(USVString name, USVString value); // iterable; stringifier; }; From 4b5f8e997038f355e16b8926e3aad90be634f571 Mon Sep 17 00:00:00 2001 From: Corey Farwell Date: Fri, 30 Oct 2015 11:46:41 -0400 Subject: [PATCH 18/58] Alphabetize entries in the WPT manifests --- tests/wpt/metadata/MANIFEST.json | 8 ++--- tests/wpt/mozilla/meta/MANIFEST.json | 48 ++++++++++++++-------------- 2 files changed, 28 insertions(+), 28 deletions(-) diff --git a/tests/wpt/metadata/MANIFEST.json b/tests/wpt/metadata/MANIFEST.json index cf966b53ed4..cca191cbca1 100644 --- a/tests/wpt/metadata/MANIFEST.json +++ b/tests/wpt/metadata/MANIFEST.json @@ -17909,6 +17909,10 @@ "path": "html/semantics/forms/the-select-element/common-HTMLOptionsCollection.html", "url": "/html/semantics/forms/the-select-element/common-HTMLOptionsCollection.html" }, + { + "path": "html/semantics/forms/the-select-element/select-ask-for-reset.html", + "url": "/html/semantics/forms/the-select-element/select-ask-for-reset.html" + }, { "path": "html/semantics/forms/the-select-element/select-named-getter.html", "url": "/html/semantics/forms/the-select-element/select-named-getter.html" @@ -17917,10 +17921,6 @@ "path": "html/semantics/forms/the-select-element/select-remove.html", "url": "/html/semantics/forms/the-select-element/select-remove.html" }, - { - "path": "html/semantics/forms/the-select-element/select-ask-for-reset.html", - "url": "/html/semantics/forms/the-select-element/select-ask-for-reset.html" - }, { "path": "html/semantics/forms/the-textarea-element/textarea-type.html", "url": "/html/semantics/forms/the-textarea-element/textarea-type.html" diff --git a/tests/wpt/mozilla/meta/MANIFEST.json b/tests/wpt/mozilla/meta/MANIFEST.json index a43ee30fded..9db826ec669 100644 --- a/tests/wpt/mozilla/meta/MANIFEST.json +++ b/tests/wpt/mozilla/meta/MANIFEST.json @@ -2087,18 +2087,6 @@ "url": "/_mozilla/css/link_style_order.html" } ], - "css/list_style_fixed_inside_a.html": [ - { - "path": "css/list_style_fixed_inside_a.html", - "references": [ - [ - "/_mozilla/css/list_style_fixed_inside_ref.html", - "==" - ] - ], - "url": "/_mozilla/css/list_style_fixed_inside_a.html" - } - ], "css/list_item_overflow.html": [ { "path": "css/list_item_overflow.html", @@ -2111,6 +2099,18 @@ "url": "/_mozilla/css/list_item_overflow.html" } ], + "css/list_style_fixed_inside_a.html": [ + { + "path": "css/list_style_fixed_inside_a.html", + "references": [ + [ + "/_mozilla/css/list_style_fixed_inside_ref.html", + "==" + ] + ], + "url": "/_mozilla/css/list_style_fixed_inside_a.html" + } + ], "css/list_style_image_sizing_a.html": [ { "path": "css/list_style_image_sizing_a.html", @@ -6708,18 +6708,6 @@ "url": "/_mozilla/css/link_style_order.html" } ], - "css/list_style_fixed_inside_a.html": [ - { - "path": "css/list_style_fixed_inside_a.html", - "references": [ - [ - "/_mozilla/css/list_style_fixed_inside_ref.html", - "==" - ] - ], - "url": "/_mozilla/css/list_style_fixed_inside_a.html" - } - ], "css/list_item_overflow.html": [ { "path": "css/list_item_overflow.html", @@ -6732,6 +6720,18 @@ "url": "/_mozilla/css/list_item_overflow.html" } ], + "css/list_style_fixed_inside_a.html": [ + { + "path": "css/list_style_fixed_inside_a.html", + "references": [ + [ + "/_mozilla/css/list_style_fixed_inside_ref.html", + "==" + ] + ], + "url": "/_mozilla/css/list_style_fixed_inside_a.html" + } + ], "css/list_style_image_sizing_a.html": [ { "path": "css/list_style_image_sizing_a.html", From 48c232f72b966ef3561249987caa26b22bc367d2 Mon Sep 17 00:00:00 2001 From: Ms2ger Date: Fri, 30 Oct 2015 16:48:30 +0100 Subject: [PATCH 19/58] Remove the pointless TextEncoder::encoding field. --- components/script/dom/textencoder.rs | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/components/script/dom/textencoder.rs b/components/script/dom/textencoder.rs index 913b7c4fe86..e6aa9a3d747 100644 --- a/components/script/dom/textencoder.rs +++ b/components/script/dom/textencoder.rs @@ -22,22 +22,20 @@ use util::str::DOMString; #[dom_struct] pub struct TextEncoder { reflector_: Reflector, - encoding: DOMString, #[ignore_heap_size_of = "Defined in rust-encoding"] encoder: EncodingRef, } impl TextEncoder { - fn new_inherited(encoding: DOMString, encoder: EncodingRef) -> TextEncoder { + fn new_inherited(encoder: EncodingRef) -> TextEncoder { TextEncoder { reflector_: Reflector::new(), - encoding: encoding, encoder: encoder, } } - pub fn new(global: GlobalRef, encoding: DOMString, encoder: EncodingRef) -> Root { - reflect_dom_object(box TextEncoder::new_inherited(encoding, encoder), + pub fn new(global: GlobalRef, encoder: EncodingRef) -> Root { + reflect_dom_object(box TextEncoder::new_inherited(encoder), global, TextEncoderBinding::Wrap) } @@ -55,7 +53,7 @@ impl TextEncoder { match encoding.name() { "utf-8" | "utf-16be" | "utf-16le" => { - Ok(TextEncoder::new(global, encoding.name().to_owned(), encoding)) + Ok(TextEncoder::new(global, encoding)) } _ => { debug!("Encoding Not UTF"); @@ -68,7 +66,7 @@ impl TextEncoder { impl TextEncoderMethods for TextEncoder { // https://encoding.spec.whatwg.org/#dom-textencoder-encoding fn Encoding(&self) -> DOMString { - self.encoding.clone() + self.encoder.name().to_owned() } #[allow(unsafe_code)] From d9a1c06fb45dacc11c1d794feb39f967d28f849d Mon Sep 17 00:00:00 2001 From: Corey Farwell Date: Fri, 30 Oct 2015 12:16:16 -0400 Subject: [PATCH 20/58] Add missing WPT to reftest_nodes --- tests/wpt/mozilla/meta/MANIFEST.json | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/tests/wpt/mozilla/meta/MANIFEST.json b/tests/wpt/mozilla/meta/MANIFEST.json index 9db826ec669..2c07bd173f4 100644 --- a/tests/wpt/mozilla/meta/MANIFEST.json +++ b/tests/wpt/mozilla/meta/MANIFEST.json @@ -6552,6 +6552,18 @@ "url": "/_mozilla/css/last_of_type_pseudo_a.html" } ], + "css/layerization_layer_size.html": [ + { + "path": "css/layerization_layer_size.html", + "references": [ + [ + "/_mozilla/css/layerization_layer_size_ref.html", + "==" + ] + ], + "url": "/_mozilla/css/layerization_layer_size.html" + } + ], "css/layerization_z_order_a.html": [ { "path": "css/layerization_z_order_a.html", From 03bf082fb3c6089b8272f58f31bd08e419b8b979 Mon Sep 17 00:00:00 2001 From: nxnfufunezn Date: Fri, 30 Oct 2015 22:08:04 +0530 Subject: [PATCH 21/58] Added support for using --features argument with --android --- python/servo/build_commands.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/python/servo/build_commands.py b/python/servo/build_commands.py index 62702ace5c4..9b5b3e4e11a 100644 --- a/python/servo/build_commands.py +++ b/python/servo/build_commands.py @@ -137,6 +137,10 @@ class MachCommands(CommandBase): @CommandArgument('--jobs', '-j', default=None, help='Number of jobs to run in parallel') + @CommandArgument('--features', + default=None, + help='Space-separated list of features to also build', + nargs='+') @CommandArgument('--android', default=None, action='store_true', @@ -151,12 +155,12 @@ class MachCommands(CommandBase): @CommandArgument('params', nargs='...', help="Command-line arguments to be passed through to Cargo") def build(self, target=None, release=False, dev=False, jobs=None, - android=None, verbose=False, debug_mozjs=False, params=None): + features=None, android=None, verbose=False, debug_mozjs=False, params=None): if android is None: android = self.config["build"]["android"] + features = features or [] opts = params or [] - features = [] base_path = self.get_target_dir() release_path = path.join(base_path, "release", "servo") From 7e786fb8ac0e0656682b16e5339950df1f5df931 Mon Sep 17 00:00:00 2001 From: Michael Wu Date: Fri, 30 Oct 2015 15:23:29 -0400 Subject: [PATCH 22/58] Infer types when appropriate --- components/script/dom/element.rs | 4 ++-- components/script/dom/xmlhttprequest.rs | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/components/script/dom/element.rs b/components/script/dom/element.rs index 0bdca0714a7..306feee6998 100644 --- a/components/script/dom/element.rs +++ b/components/script/dom/element.rs @@ -189,7 +189,7 @@ pub unsafe fn get_attr_for_layout<'a>(elem: &'a Element, namespace: &Namespace, -> Option> { // cast to point to T in RefCell directly let attrs = elem.attrs.borrow_for_layout(); - attrs.iter().find(|attr: & &JS| { + attrs.iter().find(|attr| { let attr = attr.to_layout(); *name == attr.local_name_atom_forever() && (*attr.unsafe_get()).namespace() == namespace @@ -216,7 +216,7 @@ impl RawLayoutElementHelpers for Element { #[inline] unsafe fn get_attr_vals_for_layout<'a>(&'a self, name: &Atom) -> Vec<&'a str> { let attrs = self.attrs.borrow_for_layout(); - (*attrs).iter().filter_map(|attr: &JS| { + attrs.iter().filter_map(|attr| { let attr = attr.to_layout(); if *name == attr.local_name_atom_forever() { Some(attr.value_ref_forever()) diff --git a/components/script/dom/xmlhttprequest.rs b/components/script/dom/xmlhttprequest.rs index 6bf36809ff6..0e998c2fa1c 100644 --- a/components/script/dom/xmlhttprequest.rs +++ b/components/script/dom/xmlhttprequest.rs @@ -881,7 +881,7 @@ impl XMLHttpRequest { _ => "error", }; - let upload_complete: &Cell = &self.upload_complete; + let upload_complete = &self.upload_complete; if !upload_complete.get() { upload_complete.set(true); self.dispatch_upload_progress_event("progress".to_owned(), None); From 434a5f1d8b7fa3e2abd36d832f16381337885e3d Mon Sep 17 00:00:00 2001 From: Michael Wu Date: Fri, 30 Oct 2015 15:40:43 -0400 Subject: [PATCH 23/58] Initialize dom struct fields in declaration order --- components/script/dom/cssstyledeclaration.rs | 2 +- components/script/dom/element.rs | 4 ++-- components/script/dom/event.rs | 6 +++--- components/script/dom/xmlhttprequest.rs | 3 +-- 4 files changed, 7 insertions(+), 8 deletions(-) diff --git a/components/script/dom/cssstyledeclaration.rs b/components/script/dom/cssstyledeclaration.rs index ba6923c1f6f..f4ab910e913 100644 --- a/components/script/dom/cssstyledeclaration.rs +++ b/components/script/dom/cssstyledeclaration.rs @@ -60,8 +60,8 @@ impl CSSStyleDeclaration { CSSStyleDeclaration { reflector_: Reflector::new(), owner: JS::from_ref(owner), - pseudo: pseudo, readonly: modification_access == CSSModificationAccess::Readonly, + pseudo: pseudo, } } diff --git a/components/script/dom/element.rs b/components/script/dom/element.rs index 306feee6998..d2636820362 100644 --- a/components/script/dom/element.rs +++ b/components/script/dom/element.rs @@ -155,10 +155,10 @@ impl Element { namespace: namespace, prefix: prefix, attrs: DOMRefCell::new(vec!()), - attr_list: Default::default(), - class_list: Default::default(), id_attribute: DOMRefCell::new(None), style_attribute: DOMRefCell::new(None), + attr_list: Default::default(), + class_list: Default::default(), event_state: Cell::new(state), } } diff --git a/components/script/dom/event.rs b/components/script/dom/event.rs index 6b63b3a58ee..c56d44e15c3 100644 --- a/components/script/dom/event.rs +++ b/components/script/dom/event.rs @@ -62,15 +62,15 @@ impl Event { reflector_: Reflector::new(), current_target: Default::default(), target: Default::default(), - phase: Cell::new(EventPhase::None), type_: DOMRefCell::new("".to_owned()), + phase: Cell::new(EventPhase::None), canceled: Cell::new(false), + stop_propagation: Cell::new(false), + stop_immediate: Cell::new(false), cancelable: Cell::new(false), bubbles: Cell::new(false), trusted: Cell::new(false), dispatching: Cell::new(false), - stop_propagation: Cell::new(false), - stop_immediate: Cell::new(false), initialized: Cell::new(false), timestamp: time::get_time().sec as u64, } diff --git a/components/script/dom/xmlhttprequest.rs b/components/script/dom/xmlhttprequest.rs index 0e998c2fa1c..39b86117b34 100644 --- a/components/script/dom/xmlhttprequest.rs +++ b/components/script/dom/xmlhttprequest.rs @@ -163,10 +163,9 @@ impl XMLHttpRequest { request_headers: DOMRefCell::new(Headers::new()), request_body_len: Cell::new(0), sync: Cell::new(false), - send_flag: Cell::new(false), - upload_complete: Cell::new(false), upload_events: Cell::new(false), + send_flag: Cell::new(false), global: GlobalField::from_rooted(&global), timeout_cancel: DOMRefCell::new(None), From 4f866625ccd81a682589640b360065eb43ffdf85 Mon Sep 17 00:00:00 2001 From: Eli Friedman Date: Thu, 29 Oct 2015 21:11:06 -0700 Subject: [PATCH 24/58] Attempt to fix webfont-related intermittent test failures. I'm not completely sure the race condition outlined in this patch is actually the race condition causing failures... but it seems reasonable. --- components/compositing/constellation.rs | 22 +++++++++++++++------- 1 file changed, 15 insertions(+), 7 deletions(-) diff --git a/components/compositing/constellation.rs b/components/compositing/constellation.rs index d0c5003f908..d578fac7832 100644 --- a/components/compositing/constellation.rs +++ b/components/compositing/constellation.rs @@ -1203,6 +1203,21 @@ impl Constellation { for frame in self.current_frame_tree_iter(self.root_frame_id) { let pipeline = self.pipeline(frame.current); + // Check to see if there are any webfonts still loading. + // + // If GetWebFontLoadState returns false, either there are no + // webfonts loading, or there's a WebFontLoaded message waiting in + // script_chan's message queue. Therefore, we need to check this + // before we check whether the document is ready; otherwise, + // there's a race condition where a webfont has finished loading, + // but hasn't yet notified the document. + let (sender, receiver) = ipc::channel().unwrap(); + let msg = LayoutControlMsg::GetWebFontLoadState(sender); + pipeline.layout_chan.0.send(msg).unwrap(); + if receiver.recv().unwrap() { + return false; + } + // Synchronously query the script task for this pipeline // to see if it is idle. let (sender, receiver) = channel(); @@ -1213,13 +1228,6 @@ impl Constellation { return false; } - let (sender, receiver) = ipc::channel().unwrap(); - let msg = LayoutControlMsg::GetWebFontLoadState(sender); - pipeline.layout_chan.0.send(msg).unwrap(); - if receiver.recv().unwrap() { - return false; - } - // Check the visible rectangle for this pipeline. If the constellation has received a // size for the pipeline, then its painting should be up to date. If the constellation // *hasn't* received a size, it could be that the layer was hidden by script before the From 04dc8ed20122405839e583d9efc23e823d758726 Mon Sep 17 00:00:00 2001 From: Martin Robinson Date: Fri, 30 Oct 2015 17:04:48 -0400 Subject: [PATCH 25/58] Snap fragment scroll points to pixel boundaries These don't match hardware pixels, but work well enough when the device pixel ratio is a whole number. --- components/script/script_task.rs | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/components/script/script_task.rs b/components/script/script_task.rs index 30bb371667b..421077665a8 100644 --- a/components/script/script_task.rs +++ b/components/script/script_task.rs @@ -1672,12 +1672,21 @@ impl ScriptTask { } fn scroll_fragment_point(&self, pipeline_id: PipelineId, element: &Element) { - let rect = element.upcast::().get_bounding_content_box(); - let point = Point2D::new(rect.origin.x.to_f32_px(), rect.origin.y.to_f32_px()); - // FIXME(#2003, pcwalton): This is pretty bogus when multiple layers are involved. + // FIXME(#8275, pcwalton): This is pretty bogus when multiple layers are involved. // Really what needs to happen is that this needs to go through layout to ask which // layer the element belongs to, and have it send the scroll message to the // compositor. + let rect = element.upcast::().get_bounding_content_box(); + + // In order to align with element edges, we snap to unscaled pixel boundaries, since the + // paint task currently does the same for drawing elements. This is important for pages + // that require pixel perfect scroll positioning for proper display (like Acid2). Since we + // don't have the device pixel ratio here, this might not be accurate, but should work as + // long as the ratio is a whole number. Once #8275 is fixed this should actually take into + // account the real device pixel ratio. + let point = Point2D::new(rect.origin.x.to_nearest_px() as f32, + rect.origin.y.to_nearest_px() as f32); + self.compositor.borrow_mut().send(ScriptToCompositorMsg::ScrollFragmentPoint( pipeline_id, LayerId::null(), point, false)).unwrap(); } From 16fa9cabc92e8c69c1161a20b58d0e32c7ab40c2 Mon Sep 17 00:00:00 2001 From: Corey Farwell Date: Fri, 30 Oct 2015 18:41:22 -0400 Subject: [PATCH 26/58] Fix some rust-clippy violations --- components/layout/block.rs | 15 +++++---------- components/script/dom/htmlscriptelement.rs | 4 ++-- components/script/dom/htmlselectelement.rs | 4 ++-- components/script/dom/htmltablecellelement.rs | 12 ++++++------ components/script/dom/htmltableelement.rs | 14 +++++++------- components/script/dom/htmltablerowelement.rs | 4 ++-- components/script/dom/htmltablesectionelement.rs | 4 ++-- components/script/dom/htmltextareaelement.rs | 14 +++++++------- components/script/dom/node.rs | 4 ++-- components/script/dom/range.rs | 2 +- components/script/timers.rs | 2 +- 11 files changed, 37 insertions(+), 42 deletions(-) diff --git a/components/layout/block.rs b/components/layout/block.rs index f580763e931..adb48e3248f 100644 --- a/components/layout/block.rs +++ b/components/layout/block.rs @@ -1024,17 +1024,12 @@ impl BlockFlow { let mut candidate_block_size_iterator = CandidateBSizeIterator::new( &self.fragment, self.base.block_container_explicit_block_size); - loop { - match candidate_block_size_iterator.next() { - Some(candidate_block_size) => { - candidate_block_size_iterator.candidate_value = - match candidate_block_size { - MaybeAuto::Auto => block_size, - MaybeAuto::Specified(value) => value - } + while let Some(candidate_block_size) = candidate_block_size_iterator.next() { + candidate_block_size_iterator.candidate_value = + match candidate_block_size { + MaybeAuto::Auto => block_size, + MaybeAuto::Specified(value) => value } - None => break, - } } // Adjust `cur_b` as necessary to account for the explicitly-specified block-size. diff --git a/components/script/dom/htmlscriptelement.rs b/components/script/dom/htmlscriptelement.rs index 97fefdf30e2..118c0648e77 100644 --- a/components/script/dom/htmlscriptelement.rs +++ b/components/script/dom/htmlscriptelement.rs @@ -562,8 +562,8 @@ impl VirtualMethods for HTMLScriptElement { fn attribute_mutated(&self, attr: &Attr, mutation: AttributeMutation) { self.super_type().unwrap().attribute_mutated(attr, mutation); - match attr.local_name() { - &atom!("src") => { + match *attr.local_name() { + atom!("src") => { if let AttributeMutation::Set(_) = mutation { if !self.parser_inserted.get() && self.upcast::().is_in_doc() { self.prepare(); diff --git a/components/script/dom/htmlselectelement.rs b/components/script/dom/htmlselectelement.rs index 04a3d174108..d20a6451543 100644 --- a/components/script/dom/htmlselectelement.rs +++ b/components/script/dom/htmlselectelement.rs @@ -205,8 +205,8 @@ impl VirtualMethods for HTMLSelectElement { } fn parse_plain_attribute(&self, local_name: &Atom, value: DOMString) -> AttrValue { - match local_name { - &atom!("size") => AttrValue::from_u32(value, DEFAULT_SELECT_SIZE), + match *local_name { + atom!("size") => AttrValue::from_u32(value, DEFAULT_SELECT_SIZE), _ => self.super_type().unwrap().parse_plain_attribute(local_name, value), } } diff --git a/components/script/dom/htmltablecellelement.rs b/components/script/dom/htmltablecellelement.rs index 3f1b13633f2..ac96982a45d 100644 --- a/components/script/dom/htmltablecellelement.rs +++ b/components/script/dom/htmltablecellelement.rs @@ -107,18 +107,18 @@ impl VirtualMethods for HTMLTableCellElement { fn attribute_mutated(&self, attr: &Attr, mutation: AttributeMutation) { self.super_type().unwrap().attribute_mutated(attr, mutation); - match attr.local_name() { - &atom!(bgcolor) => { + match *attr.local_name() { + atom!(bgcolor) => { self.background_color.set(mutation.new_value(attr).and_then(|value| { str::parse_legacy_color(&value).ok() })); }, - &atom!(colspan) => { + atom!(colspan) => { self.colspan.set(mutation.new_value(attr).map(|value| { max(DEFAULT_COLSPAN, value.as_uint()) })); }, - &atom!(width) => { + atom!(width) => { let width = mutation.new_value(attr).map(|value| { str::parse_length(&value) }); @@ -129,8 +129,8 @@ impl VirtualMethods for HTMLTableCellElement { } fn parse_plain_attribute(&self, local_name: &Atom, value: DOMString) -> AttrValue { - match local_name { - &atom!("colspan") => AttrValue::from_u32(value, DEFAULT_COLSPAN), + match *local_name { + atom!("colspan") => AttrValue::from_u32(value, DEFAULT_COLSPAN), _ => self.super_type().unwrap().parse_plain_attribute(local_name, value), } } diff --git a/components/script/dom/htmltableelement.rs b/components/script/dom/htmltableelement.rs index ddd87314587..1f20bc54ef8 100644 --- a/components/script/dom/htmltableelement.rs +++ b/components/script/dom/htmltableelement.rs @@ -141,24 +141,24 @@ impl VirtualMethods for HTMLTableElement { fn attribute_mutated(&self, attr: &Attr, mutation: AttributeMutation) { self.super_type().unwrap().attribute_mutated(attr, mutation); - match attr.local_name() { - &atom!(bgcolor) => { + match *attr.local_name() { + atom!(bgcolor) => { self.background_color.set(mutation.new_value(attr).and_then(|value| { str::parse_legacy_color(&value).ok() })); }, - &atom!(border) => { + atom!(border) => { // According to HTML5 ยง 14.3.9, invalid values map to 1px. self.border.set(mutation.new_value(attr).map(|value| { str::parse_unsigned_integer(value.chars()).unwrap_or(1) })); } - &atom!(cellspacing) => { + atom!(cellspacing) => { self.cellspacing.set(mutation.new_value(attr).and_then(|value| { str::parse_unsigned_integer(value.chars()) })); }, - &atom!(width) => { + atom!(width) => { let width = mutation.new_value(attr).map(|value| { str::parse_length(&value) }); @@ -169,8 +169,8 @@ impl VirtualMethods for HTMLTableElement { } fn parse_plain_attribute(&self, local_name: &Atom, value: DOMString) -> AttrValue { - match local_name { - &atom!("border") => AttrValue::from_u32(value, 1), + match *local_name { + atom!("border") => AttrValue::from_u32(value, 1), _ => self.super_type().unwrap().parse_plain_attribute(local_name, value), } } diff --git a/components/script/dom/htmltablerowelement.rs b/components/script/dom/htmltablerowelement.rs index 8db70bd9d2a..e7bb8b1fd6d 100644 --- a/components/script/dom/htmltablerowelement.rs +++ b/components/script/dom/htmltablerowelement.rs @@ -102,8 +102,8 @@ impl VirtualMethods for HTMLTableRowElement { fn attribute_mutated(&self, attr: &Attr, mutation: AttributeMutation) { self.super_type().unwrap().attribute_mutated(attr, mutation); - match attr.local_name() { - &atom!(bgcolor) => { + match *attr.local_name() { + atom!(bgcolor) => { self.background_color.set(mutation.new_value(attr).and_then(|value| { str::parse_legacy_color(&value).ok() })); diff --git a/components/script/dom/htmltablesectionelement.rs b/components/script/dom/htmltablesectionelement.rs index 5c6f04ef0ec..c4983552d3a 100644 --- a/components/script/dom/htmltablesectionelement.rs +++ b/components/script/dom/htmltablesectionelement.rs @@ -87,8 +87,8 @@ impl VirtualMethods for HTMLTableSectionElement { fn attribute_mutated(&self, attr: &Attr, mutation: AttributeMutation) { self.super_type().unwrap().attribute_mutated(attr, mutation); - match attr.local_name() { - &atom!(bgcolor) => { + match *attr.local_name() { + atom!(bgcolor) => { self.background_color.set(mutation.new_value(attr).and_then(|value| { str::parse_legacy_color(&value).ok() })); diff --git a/components/script/dom/htmltextareaelement.rs b/components/script/dom/htmltextareaelement.rs index 2ef5a24775d..5bbde574e19 100644 --- a/components/script/dom/htmltextareaelement.rs +++ b/components/script/dom/htmltextareaelement.rs @@ -246,8 +246,8 @@ impl VirtualMethods for HTMLTextAreaElement { fn attribute_mutated(&self, attr: &Attr, mutation: AttributeMutation) { self.super_type().unwrap().attribute_mutated(attr, mutation); - match attr.local_name() { - &atom!(disabled) => { + match *attr.local_name() { + atom!(disabled) => { let el = self.upcast::(); match mutation { AttributeMutation::Set(_) => { @@ -261,13 +261,13 @@ impl VirtualMethods for HTMLTextAreaElement { } } }, - &atom!(cols) => { + atom!(cols) => { let cols = mutation.new_value(attr).map(|value| { value.as_uint() }); self.cols.set(cols.unwrap_or(DEFAULT_COLS)); }, - &atom!(rows) => { + atom!(rows) => { let rows = mutation.new_value(attr).map(|value| { value.as_uint() }); @@ -286,9 +286,9 @@ impl VirtualMethods for HTMLTextAreaElement { } fn parse_plain_attribute(&self, name: &Atom, value: DOMString) -> AttrValue { - match name { - &atom!("cols") => AttrValue::from_limited_u32(value, DEFAULT_COLS), - &atom!("rows") => AttrValue::from_limited_u32(value, DEFAULT_ROWS), + match *name { + atom!("cols") => AttrValue::from_limited_u32(value, DEFAULT_COLS), + atom!("rows") => AttrValue::from_limited_u32(value, DEFAULT_ROWS), _ => self.super_type().unwrap().parse_plain_attribute(name, value), } } diff --git a/components/script/dom/node.rs b/components/script/dom/node.rs index 18c40157514..c5a891d56db 100644 --- a/components/script/dom/node.rs +++ b/components/script/dom/node.rs @@ -885,8 +885,8 @@ fn first_node_not_in(mut nodes: I, not_in: &[NodeOrString]) -> Option n != node, + match *n { + NodeOrString::eNode(ref n) => n != node, _ => true, } }) diff --git a/components/script/dom/range.rs b/components/script/dom/range.rs index 2d89530ef1b..974255e8741 100644 --- a/components/script/dom/range.rs +++ b/components/script/dom/range.rs @@ -809,7 +809,7 @@ fn bp_position(a_node: &Node, a_offset: u32, } else if position & NodeConstants::DOCUMENT_POSITION_CONTAINS != 0 { // Step 3-1, 3-2. let mut b_ancestors = b_node.inclusive_ancestors(); - let ref child = b_ancestors.find(|child| { + let child = b_ancestors.find(|child| { child.r().GetParentNode().unwrap().r() == a_node }).unwrap(); // Step 3-3. diff --git a/components/script/timers.rs b/components/script/timers.rs index 6c982cb1ad4..a431c51b138 100644 --- a/components/script/timers.rs +++ b/components/script/timers.rs @@ -78,7 +78,7 @@ impl Ord for Timer { fn cmp(&self, other: &Timer) -> Ordering { match self.next_call.cmp(&other.next_call).reverse() { Ordering::Equal => self.handle.cmp(&other.handle).reverse(), - res @ _ => res + res => res } } } From 73c4af626ad261225d0fba23c78b1a8bceeac411 Mon Sep 17 00:00:00 2001 From: Nova Fallen Date: Sun, 25 Oct 2015 13:05:22 -0400 Subject: [PATCH 27/58] Implement DOMStringMap::SupportedPropertyNames and NamedNodeMap::SupportedPropertyNames --- components/script/dom/domstringmap.rs | 3 +- components/script/dom/htmlelement.rs | 48 +++++++++++++++++ components/script/dom/namednodemap.rs | 6 ++- tests/wpt/metadata/MANIFEST.json | 8 +++ .../dataset-enumeration.html.ini | 8 --- ...domstringmap-supported-property-names.html | 54 +++++++++++++++++++ ...namednodemap-supported-property-names.html | 30 +++++++++++ 7 files changed, 145 insertions(+), 12 deletions(-) delete mode 100644 tests/wpt/metadata/html/dom/elements/global-attributes/dataset-enumeration.html.ini create mode 100644 tests/wpt/web-platform-tests/dom/collections/domstringmap-supported-property-names.html create mode 100644 tests/wpt/web-platform-tests/dom/collections/namednodemap-supported-property-names.html diff --git a/components/script/dom/domstringmap.rs b/components/script/dom/domstringmap.rs index 95f727c93cb..bed48031786 100644 --- a/components/script/dom/domstringmap.rs +++ b/components/script/dom/domstringmap.rs @@ -61,7 +61,6 @@ impl DOMStringMapMethods for DOMStringMap { // https://html.spec.whatwg.org/multipage/#the-domstringmap-interface:supported-property-names fn SupportedPropertyNames(&self) -> Vec { - // FIXME: unimplemented (https://github.com/servo/servo/issues/7273) - vec![] + self.element.supported_prop_names_custom_attr().iter().cloned().collect() } } diff --git a/components/script/dom/htmlelement.rs b/components/script/dom/htmlelement.rs index b04082eae4d..ba2bcdacc16 100644 --- a/components/script/dom/htmlelement.rs +++ b/components/script/dom/htmlelement.rs @@ -27,6 +27,7 @@ use dom::node::{Node, SEQUENTIALLY_FOCUSABLE}; use dom::node::{document_from_node, window_from_node}; use dom::virtualmethods::VirtualMethods; use msg::constellation_msg::FocusType; +use std::ascii::AsciiExt; use std::borrow::ToOwned; use std::default::Default; use std::intrinsics; @@ -275,6 +276,45 @@ fn to_snake_case(name: DOMString) -> DOMString { attr_name } + +// https://html.spec.whatwg.org/multipage/#attr-data-* +// if this attribute is in snake case with a data- prefix, +// this function returns a name converted to camel case +// without the data prefix. + +fn to_camel_case(name: &str) -> Option { + if !name.starts_with("data-") { + return None; + } + let name = &name[5..]; + let has_uppercase = name.chars().any(|curr_char| { + curr_char.is_ascii() && curr_char.is_uppercase() + }); + if has_uppercase { + return None; + } + let mut result = "".to_owned(); + let mut name_chars = name.chars(); + while let Some(curr_char) = name_chars.next() { + //check for hyphen followed by character + if curr_char == '\x2d' { + if let Some(next_char) = name_chars.next() { + if next_char.is_ascii() && next_char.is_lowercase() { + result.push(next_char.to_ascii_uppercase()); + } else { + result.push(curr_char); + result.push(next_char); + } + } else { + result.push(curr_char); + } + } else { + result.push(curr_char); + } + } + Some(result) +} + impl HTMLElement { pub fn set_custom_attr(&self, name: DOMString, value: DOMString) -> ErrorResult { if name.chars() @@ -316,6 +356,14 @@ impl HTMLElement { _ => false, } } + + pub fn supported_prop_names_custom_attr(&self) -> Vec { + let element = self.upcast::(); + element.attrs().iter().map(JS::root).filter_map(|attr| { + let raw_name = attr.r().local_name(); + to_camel_case(&raw_name) + }).collect() + } } impl VirtualMethods for HTMLElement { diff --git a/components/script/dom/namednodemap.rs b/components/script/dom/namednodemap.rs index 6070c0bb0c2..5c78de0ed51 100644 --- a/components/script/dom/namednodemap.rs +++ b/components/script/dom/namednodemap.rs @@ -85,8 +85,10 @@ impl NamedNodeMapMethods for NamedNodeMap { item } + // https://heycam.github.io/webidl/#dfn-supported-property-names fn SupportedPropertyNames(&self) -> Vec { - // FIXME: unimplemented (https://github.com/servo/servo/issues/7273) - vec![] + self.owner.attrs().iter().map(JS::root).map(|attr| { + (**attr.name()).to_owned() + }).collect() } } diff --git a/tests/wpt/metadata/MANIFEST.json b/tests/wpt/metadata/MANIFEST.json index d2d65fe522c..d642e0762be 100644 --- a/tests/wpt/metadata/MANIFEST.json +++ b/tests/wpt/metadata/MANIFEST.json @@ -13281,6 +13281,14 @@ "path": "dom/collections/HTMLCollection-supported-property-names.html", "url": "/dom/collections/HTMLCollection-supported-property-names.html" }, + { + "path": "dom/collections/domstringmap-supported-property-names.html", + "url": "/dom/collections/domstringmap-supported-property-names.html" + }, + { + "path": "dom/collections/namednodemap-supported-property-names.html", + "url": "/dom/collections/namednodemap-supported-property-names.html" + }, { "path": "dom/events/Event-constants.html", "url": "/dom/events/Event-constants.html" diff --git a/tests/wpt/metadata/html/dom/elements/global-attributes/dataset-enumeration.html.ini b/tests/wpt/metadata/html/dom/elements/global-attributes/dataset-enumeration.html.ini deleted file mode 100644 index 7b228c9e6ea..00000000000 --- a/tests/wpt/metadata/html/dom/elements/global-attributes/dataset-enumeration.html.ini +++ /dev/null @@ -1,8 +0,0 @@ -[dataset-enumeration.html] - type: testharness - [A dataset should be enumeratable.] - expected: FAIL - - [Only attributes who qualify as dataset properties should be enumeratable in the dataset.] - expected: FAIL - diff --git a/tests/wpt/web-platform-tests/dom/collections/domstringmap-supported-property-names.html b/tests/wpt/web-platform-tests/dom/collections/domstringmap-supported-property-names.html new file mode 100644 index 00000000000..f84ee27ae29 --- /dev/null +++ b/tests/wpt/web-platform-tests/dom/collections/domstringmap-supported-property-names.html @@ -0,0 +1,54 @@ + + +DOMStringMap Test: Supported property names + + +
+ +
Simple
+ +
Simple
+ +
+ John Doe +
+ +
Jane Doe
+ +
Jim Doe
+ + \ No newline at end of file diff --git a/tests/wpt/web-platform-tests/dom/collections/namednodemap-supported-property-names.html b/tests/wpt/web-platform-tests/dom/collections/namednodemap-supported-property-names.html new file mode 100644 index 00000000000..2c5dee4efd6 --- /dev/null +++ b/tests/wpt/web-platform-tests/dom/collections/namednodemap-supported-property-names.html @@ -0,0 +1,30 @@ + + +NamedNodeMap Test: Supported property names + + +
+
Simple
+ + \ No newline at end of file From f7f27a81463b062f0aef8055315ba6ad167ea592 Mon Sep 17 00:00:00 2001 From: Bobby Holley Date: Thu, 22 Oct 2015 12:56:18 -0700 Subject: [PATCH 28/58] Hoist checked and indeterminate state into EventState. This is necessary for those selectors to take advantage of restyle hints. --- components/script/dom/element.rs | 25 +++++++++++++++++------ components/script/dom/htmlinputelement.rs | 20 ++++++++---------- 2 files changed, 27 insertions(+), 18 deletions(-) diff --git a/components/script/dom/element.rs b/components/script/dom/element.rs index d2636820362..50f571452b6 100644 --- a/components/script/dom/element.rs +++ b/components/script/dom/element.rs @@ -85,19 +85,28 @@ use util::str::{DOMString, LengthOrPercentageOrAuto}; bitflags! { #[doc = "Element Event States."] #[derive(JSTraceable, HeapSizeOf)] - flags EventState: u8 { + flags EventState: u16 { #[doc = "The mouse is down on this element. \ (https://html.spec.whatwg.org/multipage/#selector-active). \ FIXME(#7333): set/unset this when appropriate"] const IN_ACTIVE_STATE = 0x01, - #[doc = "This element has focus."] + #[doc = "This element has focus. + https://html.spec.whatwg.org/multipage/scripting.html#selector-focus"] const IN_FOCUS_STATE = 0x02, - #[doc = "The mouse is hovering over this element."] + #[doc = "The mouse is hovering over this element. \ + https://html.spec.whatwg.org/multipage/scripting.html#selector-hover"] const IN_HOVER_STATE = 0x04, - #[doc = "Content is enabled (and can be disabled)."] + #[doc = "Content is enabled (and can be disabled). \ + http://www.whatwg.org/html/#selector-enabled"] const IN_ENABLED_STATE = 0x08, - #[doc = "Content is disabled."] + #[doc = "Content is disabled. \ + http://www.whatwg.org/html/#selector-disabled"] const IN_DISABLED_STATE = 0x10, + #[doc = "Content is checked. \ + https://html.spec.whatwg.org/multipage/scripting.html#selector-checked"] + const IN_CHECKED_STATE = 0x20, + #[doc = "https://html.spec.whatwg.org/multipage/scripting.html#selector-indeterminate"] + const IN_INDETERMINATE_STATE = 0x40, } } @@ -1834,7 +1843,11 @@ impl Element { self.set_click_in_progress(false); } - fn set_state(&self, which: EventState, value: bool) { + pub fn get_state(&self) -> EventState { + self.event_state.get() + } + + pub fn set_state(&self, which: EventState, value: bool) { let mut state = self.event_state.get(); if state.contains(which) == value { return diff --git a/components/script/dom/htmlinputelement.rs b/components/script/dom/htmlinputelement.rs index b82f96aed63..baaa2db012d 100644 --- a/components/script/dom/htmlinputelement.rs +++ b/components/script/dom/htmlinputelement.rs @@ -15,7 +15,7 @@ use dom::bindings::conversions::Castable; use dom::bindings::global::GlobalRef; use dom::bindings::js::{JS, LayoutJS, Root, RootedReference}; use dom::document::Document; -use dom::element::{AttributeMutation, Element, IN_ENABLED_STATE, RawLayoutElementHelpers}; +use dom::element::{AttributeMutation, Element, IN_CHECKED_STATE, IN_ENABLED_STATE, IN_INDETERMINATE_STATE, RawLayoutElementHelpers}; use dom::event::{Event, EventBubbles, EventCancelable}; use dom::eventtarget::EventTarget; use dom::htmlelement::HTMLElement; @@ -57,10 +57,8 @@ enum InputType { pub struct HTMLInputElement { htmlelement: HTMLElement, input_type: Cell, - checked: Cell, checked_changed: Cell, placeholder: DOMRefCell, - indeterminate: Cell, value_changed: Cell, size: Cell, #[ignore_heap_size_of = "#7193"] @@ -111,9 +109,7 @@ impl HTMLInputElement { HTMLElement::new_inherited_with_state(IN_ENABLED_STATE, localName, prefix, document), input_type: Cell::new(InputType::InputText), - checked: Cell::new(false), placeholder: DOMRefCell::new("".to_owned()), - indeterminate: Cell::new(false), checked_changed: Cell::new(false), value_changed: Cell::new(false), size: Cell::new(DEFAULT_INPUT_SIZE), @@ -204,13 +200,13 @@ impl RawLayoutHTMLInputElementHelpers for HTMLInputElement { #[allow(unrooted_must_root)] #[allow(unsafe_code)] unsafe fn get_checked_state_for_layout(&self) -> bool { - self.checked.get() + self.Checked() } #[allow(unrooted_must_root)] #[allow(unsafe_code)] unsafe fn get_indeterminate_state_for_layout(&self) -> bool { - self.indeterminate.get() + self.Indeterminate() } #[allow(unrooted_must_root)] @@ -240,7 +236,7 @@ impl HTMLInputElementMethods for HTMLInputElement { // https://html.spec.whatwg.org/multipage/#dom-input-checked fn Checked(&self) -> bool { - self.checked.get() + self.upcast::().get_state().contains(IN_CHECKED_STATE) } // https://html.spec.whatwg.org/multipage/#dom-input-checked @@ -329,12 +325,12 @@ impl HTMLInputElementMethods for HTMLInputElement { // https://html.spec.whatwg.org/multipage/#dom-input-indeterminate fn Indeterminate(&self) -> bool { - self.indeterminate.get() + self.upcast::().get_state().contains(IN_INDETERMINATE_STATE) } // https://html.spec.whatwg.org/multipage/#dom-input-indeterminate fn SetIndeterminate(&self, val: bool) { - self.indeterminate.set(val) + self.upcast::().set_state(IN_INDETERMINATE_STATE, val) } } @@ -443,7 +439,7 @@ impl HTMLInputElement { } fn update_checked_state(&self, checked: bool, dirty: bool) { - self.checked.set(checked); + self.upcast::().set_state(IN_CHECKED_STATE, checked); if dirty { self.checked_changed.set(true); @@ -459,7 +455,7 @@ impl HTMLInputElement { } pub fn get_indeterminate_state(&self) -> bool { - self.indeterminate.get() + self.Indeterminate() } // https://html.spec.whatwg.org/multipage/#concept-fe-mutable From 79ac365a68333072d80c41c05e56effbe1335f3d Mon Sep 17 00:00:00 2001 From: Bobby Holley Date: Wed, 21 Oct 2015 11:37:51 -0700 Subject: [PATCH 29/58] Move EventState to rust-selectors. --- components/layout/layout_task.rs | 6 +- components/layout/lib.rs | 2 +- components/layout/wrapper.rs | 56 +++------ components/script/dom/bindings/trace.rs | 2 + components/script/dom/document.rs | 23 ++-- components/script/dom/element.rs | 115 ++++++------------- components/script/dom/htmlbuttonelement.rs | 3 +- components/script/dom/htmlelement.rs | 7 +- components/script/dom/htmlfieldsetelement.rs | 3 +- components/script/dom/htmlinputelement.rs | 3 +- components/script/dom/htmloptgroupelement.rs | 3 +- components/script/dom/htmloptionelement.rs | 3 +- components/script/dom/htmlselectelement.rs | 3 +- components/script/dom/htmltextareaelement.rs | 3 +- components/script/lib.rs | 2 +- components/servo/Cargo.lock | 16 +-- components/util/mem.rs | 3 +- ports/cef/Cargo.lock | 14 +-- ports/gonk/Cargo.lock | 14 +-- tests/unit/style/stylesheets.rs | 2 +- 20 files changed, 114 insertions(+), 169 deletions(-) diff --git a/components/layout/layout_task.rs b/components/layout/layout_task.rs index 5f9c732d87c..4ebe8363fbc 100644 --- a/components/layout/layout_task.rs +++ b/components/layout/layout_task.rs @@ -1180,11 +1180,11 @@ impl LayoutTask { } } - let event_state_changes = document.drain_event_state_changes(); + let state_changes = document.drain_element_state_changes(); if !needs_dirtying { - for &(el, state) in event_state_changes.iter() { + for &(el, state) in state_changes.iter() { assert!(!state.is_empty()); - el.note_event_state_change(); + el.note_state_change(); } } diff --git a/components/layout/lib.rs b/components/layout/lib.rs index f12335d9c04..fa8e939839c 100644 --- a/components/layout/lib.rs +++ b/components/layout/lib.rs @@ -47,7 +47,7 @@ extern crate net_traits; extern crate rustc_serialize; extern crate script; extern crate script_traits; -extern crate selectors; +#[macro_use(state_pseudo_classes)] extern crate selectors; extern crate serde; extern crate serde_json; extern crate smallvec; diff --git a/components/layout/wrapper.rs b/components/layout/wrapper.rs index c9a809dc07a..46a2caed506 100644 --- a/components/layout/wrapper.rs +++ b/components/layout/wrapper.rs @@ -43,8 +43,7 @@ use script::dom::bindings::conversions::Castable; use script::dom::bindings::js::LayoutJS; use script::dom::characterdata::LayoutCharacterDataHelpers; use script::dom::document::{Document, LayoutDocumentHelpers}; -use script::dom::element; -use script::dom::element::{Element, EventState, LayoutElementHelpers, RawLayoutElementHelpers}; +use script::dom::element::{Element, LayoutElementHelpers, RawLayoutElementHelpers}; use script::dom::htmlcanvaselement::{LayoutHTMLCanvasElementHelpers, HTMLCanvasData}; use script::dom::htmliframeelement::HTMLIFrameElement; use script::dom::htmlimageelement::LayoutHTMLImageElementHelpers; @@ -56,6 +55,7 @@ use script::dom::text::Text; use script::layout_interface::TrustedNodeAddress; use selectors::matching::DeclarationBlock; use selectors::parser::{AttrSelector, NamespaceConstraint}; +use selectors::states::*; use smallvec::VecLike; use std::borrow::ToOwned; use std::cell::{Ref, RefMut}; @@ -375,9 +375,9 @@ impl<'le> LayoutDocument<'le> { self.as_node().children().find(LayoutNode::is_element) } - pub fn drain_event_state_changes(&self) -> Vec<(LayoutElement, EventState)> { + pub fn drain_element_state_changes(&self) -> Vec<(LayoutElement, ElementState)> { unsafe { - let changes = self.document.drain_event_state_changes(); + let changes = self.document.drain_element_state_changes(); Vec::from_iter(changes.iter().map(|&(el, state)| (LayoutElement { element: el, @@ -408,11 +408,11 @@ impl<'le> LayoutElement<'le> { } } - /// Properly marks nodes as dirty in response to event state changes. + /// Properly marks nodes as dirty in response to state changes. /// /// Currently this implementation is very conservative, and basically mirrors node::dirty_impl. /// With restyle hints, we can do less work here. - pub fn note_event_state_change(&self) { + pub fn note_state_change(&self) { let node = self.as_node(); // Bail out if we're already dirty. This won't be valid when we start doing more targeted @@ -453,6 +453,15 @@ fn as_element<'le>(node: LayoutJS) -> Option> { }) } +macro_rules! state_getter { + ($( + $(#[$Flag_attr: meta])* + state $css: expr => $variant: ident / $method: ident / + $flag: ident = $value: expr, + )+) => { + $( fn $method(&self) -> bool { self.element.get_state_for_layout().contains($flag) } )+ + } +} impl<'le> ::selectors::Element for LayoutElement<'le> { fn parent_element(&self) -> Option> { @@ -544,20 +553,7 @@ impl<'le> ::selectors::Element for LayoutElement<'le> { false } - #[inline] - fn get_hover_state(&self) -> bool { - self.element.get_event_state_for_layout().contains(element::IN_HOVER_STATE) - } - - #[inline] - fn get_focus_state(&self) -> bool { - self.element.get_event_state_for_layout().contains(element::IN_FOCUS_STATE) - } - - #[inline] - fn get_active_state(&self) -> bool { - self.element.get_event_state_for_layout().contains(element::IN_ACTIVE_STATE) - } + state_pseudo_classes!(state_getter); #[inline] fn get_id(&self) -> Option { @@ -566,26 +562,6 @@ impl<'le> ::selectors::Element for LayoutElement<'le> { } } - #[inline] - fn get_disabled_state(&self) -> bool { - self.element.get_event_state_for_layout().contains(element::IN_DISABLED_STATE) - } - - #[inline] - fn get_enabled_state(&self) -> bool { - self.element.get_event_state_for_layout().contains(element::IN_ENABLED_STATE) - } - - #[inline] - fn get_checked_state(&self) -> bool { - self.element.get_checked_state_for_layout() - } - - #[inline] - fn get_indeterminate_state(&self) -> bool { - self.element.get_indeterminate_state_for_layout() - } - #[inline] fn has_class(&self, name: &Atom) -> bool { unsafe { diff --git a/components/script/dom/bindings/trace.rs b/components/script/dom/bindings/trace.rs index c78429f8368..f18719073fc 100644 --- a/components/script/dom/bindings/trace.rs +++ b/components/script/dom/bindings/trace.rs @@ -62,6 +62,7 @@ use profile_traits::time::ProfilerChan as TimeProfilerChan; use script_task::ScriptChan; use script_traits::{TimerEventChan, TimerEventId, TimerSource, UntrustedNodeAddress}; use selectors::parser::PseudoElement; +use selectors::states::*; use serde::{Deserialize, Serialize}; use smallvec::SmallVec; use std::boxed::FnBox; @@ -308,6 +309,7 @@ no_jsmanaged_fields!(TimeProfilerChan); no_jsmanaged_fields!(MemProfilerChan); no_jsmanaged_fields!(PseudoElement); no_jsmanaged_fields!(Length); +no_jsmanaged_fields!(ElementState); impl JSTraceable for Box { #[inline] diff --git a/components/script/dom/document.rs b/components/script/dom/document.rs index 2ad0a12262f..0a94f9f5504 100644 --- a/components/script/dom/document.rs +++ b/components/script/dom/document.rs @@ -32,7 +32,7 @@ use dom::customevent::CustomEvent; use dom::documentfragment::DocumentFragment; use dom::documenttype::DocumentType; use dom::domimplementation::DOMImplementation; -use dom::element::{Element, ElementCreator, EventState}; +use dom::element::{Element, ElementCreator}; use dom::event::{Event, EventBubbles, EventCancelable}; use dom::eventtarget::{EventTarget}; use dom::htmlanchorelement::HTMLAnchorElement; @@ -85,6 +85,7 @@ use net_traits::{AsyncResponseTarget, PendingAsyncLoad}; use num::ToPrimitive; use script_task::{MainThreadScriptMsg, Runnable}; use script_traits::{MouseButton, UntrustedNodeAddress}; +use selectors::states::*; use std::ascii::AsciiExt; use std::borrow::ToOwned; use std::boxed::FnBox; @@ -174,8 +175,8 @@ pub struct Document { /// This field is set to the document itself for inert documents. /// https://html.spec.whatwg.org/multipage/#appropriate-template-contents-owner-document appropriate_template_contents_owner_document: MutNullableHeap>, - // The collection of EventStates that have been changed since the last restyle. - event_state_changes: DOMRefCell, EventState>>, + // The collection of ElementStates that have been changed since the last restyle. + element_state_changes: DOMRefCell, ElementState>>, } impl PartialEq for Document { @@ -305,7 +306,7 @@ impl Document { pub fn needs_reflow(&self) -> bool { self.GetDocumentElement().is_some() && - (self.upcast::().get_has_dirty_descendants() || !self.event_state_changes.borrow().is_empty()) + (self.upcast::().get_has_dirty_descendants() || !self.element_state_changes.borrow().is_empty()) } /// Returns the first `base` element in the DOM that has an `href` attribute. @@ -1185,7 +1186,7 @@ pub enum DocumentSource { #[allow(unsafe_code)] pub trait LayoutDocumentHelpers { unsafe fn is_html_document_for_layout(&self) -> bool; - unsafe fn drain_event_state_changes(&self) -> Vec<(LayoutJS, EventState)>; + unsafe fn drain_element_state_changes(&self) -> Vec<(LayoutJS, ElementState)>; } #[allow(unsafe_code)] @@ -1197,8 +1198,8 @@ impl LayoutDocumentHelpers for LayoutJS { #[inline] #[allow(unrooted_must_root)] - unsafe fn drain_event_state_changes(&self) -> Vec<(LayoutJS, EventState)> { - let mut changes = (*self.unsafe_get()).event_state_changes.borrow_mut_for_layout(); + unsafe fn drain_element_state_changes(&self) -> Vec<(LayoutJS, ElementState)> { + let mut changes = (*self.unsafe_get()).element_state_changes.borrow_mut_for_layout(); let drain = changes.drain(); let layout_drain = drain.map(|(k, v)| (k.to_layout(), v)); Vec::from_iter(layout_drain) @@ -1268,7 +1269,7 @@ impl Document { reflow_timeout: Cell::new(None), base_element: Default::default(), appropriate_template_contents_owner_document: Default::default(), - event_state_changes: DOMRefCell::new(HashMap::new()), + element_state_changes: DOMRefCell::new(HashMap::new()), } } @@ -1334,12 +1335,12 @@ impl Document { self.idmap.borrow().get(&id).map(|ref elements| (*elements)[0].root()) } - pub fn record_event_state_change(&self, el: &Element, which: EventState) { - let mut map = self.event_state_changes.borrow_mut(); + pub fn record_element_state_change(&self, el: &Element, which: ElementState) { + let mut map = self.element_state_changes.borrow_mut(); let empty; { let states = map.entry(JS::from_ref(el)) - .or_insert(EventState::empty()); + .or_insert(ElementState::empty()); states.toggle(which); empty = states.is_empty(); } diff --git a/components/script/dom/element.rs b/components/script/dom/element.rs index 50f571452b6..46628935bb1 100644 --- a/components/script/dom/element.rs +++ b/components/script/dom/element.rs @@ -26,6 +26,7 @@ use dom::bindings::error::{Error, ErrorResult, Fallible}; use dom::bindings::global::GlobalRef; use dom::bindings::js::{JS, LayoutJS, MutNullableHeap}; use dom::bindings::js::{Root, RootedReference}; +use dom::bindings::trace::JSTraceable; use dom::bindings::utils::XMLName::InvalidXMLName; use dom::bindings::utils::{namespace_from_domstring, validate_and_extract, xml_name_type}; use dom::characterdata::CharacterData; @@ -63,8 +64,8 @@ use html5ever::serialize::TraversalScope; use html5ever::serialize::TraversalScope::{ChildrenOnly, IncludeNode}; use html5ever::tree_builder::{LimitedQuirks, NoQuirks, Quirks}; use selectors::matching::{DeclarationBlock, matches}; -use selectors::parser::parse_author_origin_selector_list_from_str; -use selectors::parser::{AttrSelector, NamespaceConstraint}; +use selectors::parser::{AttrSelector, NamespaceConstraint, parse_author_origin_selector_list_from_str}; +use selectors::states::*; use smallvec::VecLike; use std::ascii::AsciiExt; use std::borrow::{Cow, ToOwned}; @@ -80,35 +81,12 @@ use style::properties::{PropertyDeclaration, PropertyDeclarationBlock, parse_sty use style::values::CSSFloat; use style::values::specified::{self, CSSColor, CSSRGBA}; use url::UrlParser; +use util::mem::HeapSizeOf; use util::str::{DOMString, LengthOrPercentageOrAuto}; -bitflags! { - #[doc = "Element Event States."] - #[derive(JSTraceable, HeapSizeOf)] - flags EventState: u16 { - #[doc = "The mouse is down on this element. \ - (https://html.spec.whatwg.org/multipage/#selector-active). \ - FIXME(#7333): set/unset this when appropriate"] - const IN_ACTIVE_STATE = 0x01, - #[doc = "This element has focus. - https://html.spec.whatwg.org/multipage/scripting.html#selector-focus"] - const IN_FOCUS_STATE = 0x02, - #[doc = "The mouse is hovering over this element. \ - https://html.spec.whatwg.org/multipage/scripting.html#selector-hover"] - const IN_HOVER_STATE = 0x04, - #[doc = "Content is enabled (and can be disabled). \ - http://www.whatwg.org/html/#selector-enabled"] - const IN_ENABLED_STATE = 0x08, - #[doc = "Content is disabled. \ - http://www.whatwg.org/html/#selector-disabled"] - const IN_DISABLED_STATE = 0x10, - #[doc = "Content is checked. \ - https://html.spec.whatwg.org/multipage/scripting.html#selector-checked"] - const IN_CHECKED_STATE = 0x20, - #[doc = "https://html.spec.whatwg.org/multipage/scripting.html#selector-indeterminate"] - const IN_INDETERMINATE_STATE = 0x40, - } -} +// TODO: Update focus state when the top-level browsing context gains or loses system focus, +// and when the element enters or leaves a browsing context container. +// https://html.spec.whatwg.org/multipage/#selector-focus #[dom_struct] pub struct Element { @@ -121,7 +99,7 @@ pub struct Element { style_attribute: DOMRefCell>, attr_list: MutNullableHeap>, class_list: MutNullableHeap>, - event_state: Cell, + state: Cell, } impl PartialEq for Element { @@ -150,11 +128,11 @@ impl Element { pub fn new_inherited(local_name: DOMString, namespace: Namespace, prefix: Option, document: &Document) -> Element { - Element::new_inherited_with_state(EventState::empty(), local_name, + Element::new_inherited_with_state(ElementState::empty(), local_name, namespace, prefix, document) } - pub fn new_inherited_with_state(state: EventState, local_name: DOMString, + pub fn new_inherited_with_state(state: ElementState, local_name: DOMString, namespace: Namespace, prefix: Option, document: &Document) -> Element { @@ -168,7 +146,7 @@ impl Element { style_attribute: DOMRefCell::new(None), attr_list: Default::default(), class_list: Default::default(), - event_state: Cell::new(state), + state: Cell::new(state), } } @@ -261,7 +239,7 @@ pub trait LayoutElementHelpers { fn get_checked_state_for_layout(&self) -> bool; fn get_indeterminate_state_for_layout(&self) -> bool; - fn get_event_state_for_layout(&self) -> EventState; + fn get_state_for_layout(&self) -> ElementState; } impl LayoutElementHelpers for LayoutJS { @@ -614,9 +592,9 @@ impl LayoutElementHelpers for LayoutJS { #[inline] #[allow(unsafe_code)] - fn get_event_state_for_layout(&self) -> EventState { + fn get_state_for_layout(&self) -> ElementState { unsafe { - (*self.unsafe_get()).event_state.get() + (*self.unsafe_get()).state.get() } } } @@ -1592,6 +1570,16 @@ impl VirtualMethods for Element { } } +macro_rules! state_getter { + ($( + $(#[$Flag_attr: meta])* + state $css: expr => $variant: ident / $method: ident / + $flag: ident = $value: expr, + )+) => { + $( fn $method(&self) -> bool { Element::get_state(self).contains($flag) } )+ + } +} + impl<'a> ::selectors::Element for Root { fn parent_element(&self) -> Option> { self.upcast::().GetParentElement() @@ -1658,42 +1646,11 @@ impl<'a> ::selectors::Element for Root { self.namespace() } - fn get_hover_state(&self) -> bool { - Element::get_hover_state(self) - } - - fn get_active_state(&self) -> bool { - Element::get_active_state(self) - } - - fn get_focus_state(&self) -> bool { - // TODO: Also check whether the top-level browsing context has the system focus, - // and whether this element is a browsing context container. - // https://html.spec.whatwg.org/multipage/#selector-focus - Element::get_focus_state(self) - } + state_pseudo_classes!(state_getter); fn get_id(&self) -> Option { self.id_attribute.borrow().clone() } - fn get_disabled_state(&self) -> bool { - Element::get_disabled_state(self) - } - fn get_enabled_state(&self) -> bool { - Element::get_enabled_state(self) - } - fn get_checked_state(&self) -> bool { - match self.downcast::() { - Some(input) => input.Checked(), - None => false, - } - } - fn get_indeterminate_state(&self) -> bool { - match self.downcast::() { - Some(input) => input.get_indeterminate_state(), - None => false, - } - } fn has_class(&self, name: &Atom) -> bool { Element::has_class(&**self, name) } @@ -1843,12 +1800,12 @@ impl Element { self.set_click_in_progress(false); } - pub fn get_state(&self) -> EventState { - self.event_state.get() + pub fn get_state(&self) -> ElementState { + self.state.get() } - pub fn set_state(&self, which: EventState, value: bool) { - let mut state = self.event_state.get(); + pub fn set_state(&self, which: ElementState, value: bool) { + let mut state = self.state.get(); if state.contains(which) == value { return } @@ -1856,14 +1813,14 @@ impl Element { true => state.insert(which), false => state.remove(which), }; - self.event_state.set(state); + self.state.set(state); let node = self.upcast::(); - node.owner_doc().record_event_state_change(self, which); + node.owner_doc().record_element_state_change(self, which); } pub fn get_active_state(&self) -> bool { - self.event_state.get().contains(IN_ACTIVE_STATE) + self.state.get().contains(IN_ACTIVE_STATE) } pub fn set_active_state(&self, value: bool) { @@ -1871,7 +1828,7 @@ impl Element { } pub fn get_focus_state(&self) -> bool { - self.event_state.get().contains(IN_FOCUS_STATE) + self.state.get().contains(IN_FOCUS_STATE) } pub fn set_focus_state(&self, value: bool) { @@ -1879,7 +1836,7 @@ impl Element { } pub fn get_hover_state(&self) -> bool { - self.event_state.get().contains(IN_HOVER_STATE) + self.state.get().contains(IN_HOVER_STATE) } pub fn set_hover_state(&self, value: bool) { @@ -1887,7 +1844,7 @@ impl Element { } pub fn get_enabled_state(&self) -> bool { - self.event_state.get().contains(IN_ENABLED_STATE) + self.state.get().contains(IN_ENABLED_STATE) } pub fn set_enabled_state(&self, value: bool) { @@ -1895,7 +1852,7 @@ impl Element { } pub fn get_disabled_state(&self) -> bool { - self.event_state.get().contains(IN_DISABLED_STATE) + self.state.get().contains(IN_DISABLED_STATE) } pub fn set_disabled_state(&self, value: bool) { diff --git a/components/script/dom/htmlbuttonelement.rs b/components/script/dom/htmlbuttonelement.rs index 5146c7e4888..203f04c0009 100644 --- a/components/script/dom/htmlbuttonelement.rs +++ b/components/script/dom/htmlbuttonelement.rs @@ -9,7 +9,7 @@ use dom::bindings::codegen::Bindings::HTMLButtonElementBinding::HTMLButtonElemen use dom::bindings::conversions::Castable; use dom::bindings::js::Root; use dom::document::Document; -use dom::element::{AttributeMutation, Element, IN_ENABLED_STATE}; +use dom::element::{AttributeMutation, Element}; use dom::event::Event; use dom::eventtarget::EventTarget; use dom::htmlelement::HTMLElement; @@ -19,6 +19,7 @@ use dom::htmlformelement::{SubmittedFrom, HTMLFormElement}; use dom::node::{Node, document_from_node, window_from_node}; use dom::validitystate::ValidityState; use dom::virtualmethods::VirtualMethods; +use selectors::states::*; use std::ascii::AsciiExt; use std::borrow::ToOwned; use std::cell::Cell; diff --git a/components/script/dom/htmlelement.rs b/components/script/dom/htmlelement.rs index ba2bcdacc16..bb52cbc2402 100644 --- a/components/script/dom/htmlelement.rs +++ b/components/script/dom/htmlelement.rs @@ -17,7 +17,7 @@ use dom::bindings::utils::Reflectable; use dom::cssstyledeclaration::{CSSModificationAccess, CSSStyleDeclaration}; use dom::document::Document; use dom::domstringmap::DOMStringMap; -use dom::element::{AttributeMutation, Element, EventState}; +use dom::element::{AttributeMutation, Element}; use dom::eventtarget::EventTarget; use dom::htmlbodyelement::HTMLBodyElement; use dom::htmlframesetelement::HTMLFrameSetElement; @@ -27,6 +27,7 @@ use dom::node::{Node, SEQUENTIALLY_FOCUSABLE}; use dom::node::{document_from_node, window_from_node}; use dom::virtualmethods::VirtualMethods; use msg::constellation_msg::FocusType; +use selectors::states::*; use std::ascii::AsciiExt; use std::borrow::ToOwned; use std::default::Default; @@ -51,10 +52,10 @@ impl PartialEq for HTMLElement { impl HTMLElement { pub fn new_inherited(tag_name: DOMString, prefix: Option, document: &Document) -> HTMLElement { - HTMLElement::new_inherited_with_state(EventState::empty(), tag_name, prefix, document) + HTMLElement::new_inherited_with_state(ElementState::empty(), tag_name, prefix, document) } - pub fn new_inherited_with_state(state: EventState, tag_name: DOMString, + pub fn new_inherited_with_state(state: ElementState, tag_name: DOMString, prefix: Option, document: &Document) -> HTMLElement { HTMLElement { diff --git a/components/script/dom/htmlfieldsetelement.rs b/components/script/dom/htmlfieldsetelement.rs index 63c614d308f..98c6b86b5f7 100644 --- a/components/script/dom/htmlfieldsetelement.rs +++ b/components/script/dom/htmlfieldsetelement.rs @@ -9,7 +9,7 @@ use dom::bindings::codegen::InheritTypes::{ElementTypeId, HTMLElementTypeId, Nod use dom::bindings::conversions::Castable; use dom::bindings::js::{Root, RootedReference}; use dom::document::Document; -use dom::element::{AttributeMutation, Element, IN_ENABLED_STATE}; +use dom::element::{AttributeMutation, Element}; use dom::htmlcollection::{CollectionFilter, HTMLCollection}; use dom::htmlelement::HTMLElement; use dom::htmlformelement::{FormControl, HTMLFormElement}; @@ -17,6 +17,7 @@ use dom::htmllegendelement::HTMLLegendElement; use dom::node::{Node, window_from_node}; use dom::validitystate::ValidityState; use dom::virtualmethods::VirtualMethods; +use selectors::states::*; use util::str::{DOMString, StaticStringVec}; #[dom_struct] diff --git a/components/script/dom/htmlinputelement.rs b/components/script/dom/htmlinputelement.rs index baaa2db012d..1adfc56b304 100644 --- a/components/script/dom/htmlinputelement.rs +++ b/components/script/dom/htmlinputelement.rs @@ -15,7 +15,7 @@ use dom::bindings::conversions::Castable; use dom::bindings::global::GlobalRef; use dom::bindings::js::{JS, LayoutJS, Root, RootedReference}; use dom::document::Document; -use dom::element::{AttributeMutation, Element, IN_CHECKED_STATE, IN_ENABLED_STATE, IN_INDETERMINATE_STATE, RawLayoutElementHelpers}; +use dom::element::{AttributeMutation, Element, RawLayoutElementHelpers}; use dom::event::{Event, EventBubbles, EventCancelable}; use dom::eventtarget::EventTarget; use dom::htmlelement::HTMLElement; @@ -27,6 +27,7 @@ use dom::node::{Node, NodeDamage}; use dom::node::{document_from_node, window_from_node}; use dom::virtualmethods::VirtualMethods; use msg::constellation_msg::ConstellationChan; +use selectors::states::*; use std::borrow::ToOwned; use std::cell::Cell; use string_cache::Atom; diff --git a/components/script/dom/htmloptgroupelement.rs b/components/script/dom/htmloptgroupelement.rs index 4d9ec9b6ca9..cb97991b52b 100644 --- a/components/script/dom/htmloptgroupelement.rs +++ b/components/script/dom/htmloptgroupelement.rs @@ -8,11 +8,12 @@ use dom::bindings::codegen::Bindings::HTMLOptGroupElementBinding::HTMLOptGroupEl use dom::bindings::conversions::Castable; use dom::bindings::js::Root; use dom::document::Document; -use dom::element::{AttributeMutation, Element, IN_ENABLED_STATE}; +use dom::element::{AttributeMutation, Element}; use dom::htmlelement::HTMLElement; use dom::htmloptionelement::HTMLOptionElement; use dom::node::Node; use dom::virtualmethods::VirtualMethods; +use selectors::states::*; use util::str::DOMString; #[dom_struct] diff --git a/components/script/dom/htmloptionelement.rs b/components/script/dom/htmloptionelement.rs index 8c7dea8ac1e..b06406c4df5 100644 --- a/components/script/dom/htmloptionelement.rs +++ b/components/script/dom/htmloptionelement.rs @@ -11,13 +11,14 @@ use dom::bindings::conversions::Castable; use dom::bindings::js::Root; use dom::characterdata::CharacterData; use dom::document::Document; -use dom::element::{AttributeMutation, Element, IN_ENABLED_STATE}; +use dom::element::{AttributeMutation, Element}; use dom::htmlelement::HTMLElement; use dom::htmlscriptelement::HTMLScriptElement; use dom::htmlselectelement::HTMLSelectElement; use dom::node::Node; use dom::text::Text; use dom::virtualmethods::VirtualMethods; +use selectors::states::*; use std::cell::Cell; use util::str::{DOMString, split_html_space_chars, str_join}; diff --git a/components/script/dom/htmlselectelement.rs b/components/script/dom/htmlselectelement.rs index d20a6451543..c6e90e12c84 100644 --- a/components/script/dom/htmlselectelement.rs +++ b/components/script/dom/htmlselectelement.rs @@ -11,7 +11,7 @@ use dom::bindings::codegen::UnionTypes::HTMLOptionElementOrHTMLOptGroupElement; use dom::bindings::conversions::Castable; use dom::bindings::js::Root; use dom::document::Document; -use dom::element::{AttributeMutation, Element, IN_ENABLED_STATE}; +use dom::element::{AttributeMutation, Element}; use dom::htmlelement::HTMLElement; use dom::htmlfieldsetelement::HTMLFieldSetElement; use dom::htmlformelement::{FormControl, HTMLFormElement}; @@ -19,6 +19,7 @@ use dom::htmloptionelement::HTMLOptionElement; use dom::node::{Node, window_from_node}; use dom::validitystate::ValidityState; use dom::virtualmethods::VirtualMethods; +use selectors::states::*; use std::borrow::ToOwned; use string_cache::Atom; use util::str::DOMString; diff --git a/components/script/dom/htmltextareaelement.rs b/components/script/dom/htmltextareaelement.rs index 5bbde574e19..b057204245f 100644 --- a/components/script/dom/htmltextareaelement.rs +++ b/components/script/dom/htmltextareaelement.rs @@ -13,7 +13,7 @@ use dom::bindings::global::GlobalRef; use dom::bindings::js::{LayoutJS, Root}; use dom::bindings::refcounted::Trusted; use dom::document::Document; -use dom::element::{AttributeMutation, IN_ENABLED_STATE, Element}; +use dom::element::{AttributeMutation, Element}; use dom::event::{Event, EventBubbles, EventCancelable}; use dom::eventtarget::EventTarget; use dom::htmlelement::HTMLElement; @@ -26,6 +26,7 @@ use dom::virtualmethods::VirtualMethods; use msg::constellation_msg::ConstellationChan; use script_task::ScriptTaskEventCategory::InputEvent; use script_task::{CommonScriptMsg, Runnable}; +use selectors::states::*; use std::borrow::ToOwned; use std::cell::Cell; use string_cache::Atom; diff --git a/components/script/lib.rs b/components/script/lib.rs index b442a3b2d31..e4481fb7d49 100644 --- a/components/script/lib.rs +++ b/components/script/lib.rs @@ -70,7 +70,7 @@ extern crate rand; extern crate rustc_serialize; extern crate rustc_unicode; extern crate script_traits; -extern crate selectors; +#[macro_use(state_pseudo_classes)] extern crate selectors; extern crate serde; extern crate smallvec; extern crate string_cache; diff --git a/components/servo/Cargo.lock b/components/servo/Cargo.lock index 2edee037257..5c4478bfb36 100644 --- a/components/servo/Cargo.lock +++ b/components/servo/Cargo.lock @@ -1039,7 +1039,7 @@ dependencies = [ "rustc-serialize 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)", "script 0.0.1", "script_traits 0.0.1", - "selectors 0.1.0 (git+https://github.com/servo/rust-selectors)", + "selectors 0.2.0 (git+https://github.com/servo/rust-selectors)", "serde 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)", "serde_json 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)", "serde_macros 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)", @@ -1548,7 +1548,7 @@ dependencies = [ "rand 0.3.11 (registry+https://github.com/rust-lang/crates.io-index)", "rustc-serialize 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)", "script_traits 0.0.1", - "selectors 0.1.0 (git+https://github.com/servo/rust-selectors)", + "selectors 0.2.0 (git+https://github.com/servo/rust-selectors)", "serde 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)", "smallvec 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)", "string_cache 0.1.15 (registry+https://github.com/rust-lang/crates.io-index)", @@ -1593,8 +1593,8 @@ dependencies = [ [[package]] name = "selectors" -version = "0.1.0" -source = "git+https://github.com/servo/rust-selectors#1e1e44c2f4090e8beb95a8d27f184aefcf91a362" +version = "0.2.0" +source = "git+https://github.com/servo/rust-selectors#d3bd9b7c665c838f703ef0bbc7fd67b89847550d" dependencies = [ "bitflags 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)", "cssparser 0.3.9 (registry+https://github.com/rust-lang/crates.io-index)", @@ -1751,7 +1751,7 @@ dependencies = [ "num 0.1.27 (registry+https://github.com/rust-lang/crates.io-index)", "plugins 0.0.1", "rustc-serialize 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)", - "selectors 0.1.0 (git+https://github.com/servo/rust-selectors)", + "selectors 0.2.0 (git+https://github.com/servo/rust-selectors)", "serde 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)", "serde_macros 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)", "smallvec 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)", @@ -1769,7 +1769,7 @@ dependencies = [ "app_units 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)", "cssparser 0.3.9 (registry+https://github.com/rust-lang/crates.io-index)", "euclid 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)", - "selectors 0.1.0 (git+https://github.com/servo/rust-selectors)", + "selectors 0.2.0 (git+https://github.com/servo/rust-selectors)", "string_cache 0.1.15 (registry+https://github.com/rust-lang/crates.io-index)", "string_cache_plugin 0.1.9 (registry+https://github.com/rust-lang/crates.io-index)", "style 0.0.1", @@ -1789,7 +1789,7 @@ dependencies = [ "num 0.1.27 (registry+https://github.com/rust-lang/crates.io-index)", "plugins 0.0.1", "rustc-serialize 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)", - "selectors 0.1.0 (git+https://github.com/servo/rust-selectors)", + "selectors 0.2.0 (git+https://github.com/servo/rust-selectors)", "serde 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)", "serde_macros 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)", "url 0.2.37 (registry+https://github.com/rust-lang/crates.io-index)", @@ -1934,7 +1934,7 @@ dependencies = [ "plugins 0.0.1", "rand 0.3.11 (registry+https://github.com/rust-lang/crates.io-index)", "rustc-serialize 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)", - "selectors 0.1.0 (git+https://github.com/servo/rust-selectors)", + "selectors 0.2.0 (git+https://github.com/servo/rust-selectors)", "serde 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)", "serde_macros 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)", "smallvec 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)", diff --git a/components/util/mem.rs b/components/util/mem.rs index 1577ff39dc2..bcd8de3250d 100644 --- a/components/util/mem.rs +++ b/components/util/mem.rs @@ -27,6 +27,7 @@ use logical_geometry::WritingMode; use rand::OsRng; use range::Range; use selectors::parser::{Combinator, CompoundSelector, PseudoElement, Selector, SimpleSelector}; +use selectors::states::ElementState; use std::cell::{Cell, RefCell}; use std::collections::{HashMap, LinkedList, hash_state}; use std::hash::Hash; @@ -417,4 +418,4 @@ known_heap_size!(0, Au, WritingMode, CSSParserColor, Color, RGBA, Cursor, Matrix known_heap_size!(0, JSVal, PagePx, ViewportPx, DevicePixel, QuirksMode, OsRng, RawStatus); known_heap_size!(0, TokenSerializationType, LengthOrPercentageOrAuto); -known_heap_size!(0, PseudoElement, Combinator, str); +known_heap_size!(0, ElementState, Combinator, PseudoElement, str); diff --git a/ports/cef/Cargo.lock b/ports/cef/Cargo.lock index 2b966346713..051695a4b02 100644 --- a/ports/cef/Cargo.lock +++ b/ports/cef/Cargo.lock @@ -989,7 +989,7 @@ dependencies = [ "rustc-serialize 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)", "script 0.0.1", "script_traits 0.0.1", - "selectors 0.1.0 (git+https://github.com/servo/rust-selectors)", + "selectors 0.2.0 (git+https://github.com/servo/rust-selectors)", "serde 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)", "serde_json 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)", "serde_macros 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)", @@ -1480,7 +1480,7 @@ dependencies = [ "rand 0.3.11 (registry+https://github.com/rust-lang/crates.io-index)", "rustc-serialize 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)", "script_traits 0.0.1", - "selectors 0.1.0 (git+https://github.com/servo/rust-selectors)", + "selectors 0.2.0 (git+https://github.com/servo/rust-selectors)", "serde 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)", "smallvec 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)", "string_cache 0.1.15 (registry+https://github.com/rust-lang/crates.io-index)", @@ -1517,8 +1517,8 @@ dependencies = [ [[package]] name = "selectors" -version = "0.1.0" -source = "git+https://github.com/servo/rust-selectors#1e1e44c2f4090e8beb95a8d27f184aefcf91a362" +version = "0.2.0" +source = "git+https://github.com/servo/rust-selectors#d3bd9b7c665c838f703ef0bbc7fd67b89847550d" dependencies = [ "bitflags 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)", "cssparser 0.3.9 (registry+https://github.com/rust-lang/crates.io-index)", @@ -1708,7 +1708,7 @@ dependencies = [ "num 0.1.27 (registry+https://github.com/rust-lang/crates.io-index)", "plugins 0.0.1", "rustc-serialize 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)", - "selectors 0.1.0 (git+https://github.com/servo/rust-selectors)", + "selectors 0.2.0 (git+https://github.com/servo/rust-selectors)", "serde 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)", "serde_macros 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)", "smallvec 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)", @@ -1730,7 +1730,7 @@ dependencies = [ "num 0.1.27 (registry+https://github.com/rust-lang/crates.io-index)", "plugins 0.0.1", "rustc-serialize 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)", - "selectors 0.1.0 (git+https://github.com/servo/rust-selectors)", + "selectors 0.2.0 (git+https://github.com/servo/rust-selectors)", "serde 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)", "serde_macros 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)", "url 0.2.37 (registry+https://github.com/rust-lang/crates.io-index)", @@ -1875,7 +1875,7 @@ dependencies = [ "plugins 0.0.1", "rand 0.3.11 (registry+https://github.com/rust-lang/crates.io-index)", "rustc-serialize 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)", - "selectors 0.1.0 (git+https://github.com/servo/rust-selectors)", + "selectors 0.2.0 (git+https://github.com/servo/rust-selectors)", "serde 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)", "serde_macros 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)", "smallvec 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)", diff --git a/ports/gonk/Cargo.lock b/ports/gonk/Cargo.lock index e98e9e35c90..07d85f98b20 100644 --- a/ports/gonk/Cargo.lock +++ b/ports/gonk/Cargo.lock @@ -938,7 +938,7 @@ dependencies = [ "rustc-serialize 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)", "script 0.0.1", "script_traits 0.0.1", - "selectors 0.1.0 (git+https://github.com/servo/rust-selectors)", + "selectors 0.2.0 (git+https://github.com/servo/rust-selectors)", "serde 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)", "serde_json 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)", "serde_macros 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)", @@ -1429,7 +1429,7 @@ dependencies = [ "rand 0.3.11 (registry+https://github.com/rust-lang/crates.io-index)", "rustc-serialize 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)", "script_traits 0.0.1", - "selectors 0.1.0 (git+https://github.com/servo/rust-selectors)", + "selectors 0.2.0 (git+https://github.com/servo/rust-selectors)", "serde 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)", "smallvec 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)", "string_cache 0.1.15 (registry+https://github.com/rust-lang/crates.io-index)", @@ -1466,8 +1466,8 @@ dependencies = [ [[package]] name = "selectors" -version = "0.1.0" -source = "git+https://github.com/servo/rust-selectors#1e1e44c2f4090e8beb95a8d27f184aefcf91a362" +version = "0.2.0" +source = "git+https://github.com/servo/rust-selectors#d3bd9b7c665c838f703ef0bbc7fd67b89847550d" dependencies = [ "bitflags 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)", "cssparser 0.3.9 (registry+https://github.com/rust-lang/crates.io-index)", @@ -1655,7 +1655,7 @@ dependencies = [ "num 0.1.27 (registry+https://github.com/rust-lang/crates.io-index)", "plugins 0.0.1", "rustc-serialize 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)", - "selectors 0.1.0 (git+https://github.com/servo/rust-selectors)", + "selectors 0.2.0 (git+https://github.com/servo/rust-selectors)", "serde 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)", "serde_macros 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)", "smallvec 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)", @@ -1677,7 +1677,7 @@ dependencies = [ "num 0.1.27 (registry+https://github.com/rust-lang/crates.io-index)", "plugins 0.0.1", "rustc-serialize 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)", - "selectors 0.1.0 (git+https://github.com/servo/rust-selectors)", + "selectors 0.2.0 (git+https://github.com/servo/rust-selectors)", "serde 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)", "serde_macros 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)", "url 0.2.37 (registry+https://github.com/rust-lang/crates.io-index)", @@ -1822,7 +1822,7 @@ dependencies = [ "plugins 0.0.1", "rand 0.3.11 (registry+https://github.com/rust-lang/crates.io-index)", "rustc-serialize 0.3.16 (registry+https://github.com/rust-lang/crates.io-index)", - "selectors 0.1.0 (git+https://github.com/servo/rust-selectors)", + "selectors 0.2.0 (git+https://github.com/servo/rust-selectors)", "serde 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)", "serde_macros 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)", "smallvec 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)", diff --git a/tests/unit/style/stylesheets.rs b/tests/unit/style/stylesheets.rs index 8d133e8820e..6eb9cde4402 100644 --- a/tests/unit/style/stylesheets.rs +++ b/tests/unit/style/stylesheets.rs @@ -103,7 +103,7 @@ fn test_parse_stylesheet() { simple_selectors: vec![ SimpleSelector::Class(Atom::from_slice("ok")), ], - next: Some((Box::new(CompoundSelector { + next: Some((Arc::new(CompoundSelector { simple_selectors: vec![ SimpleSelector::ID(Atom::from_slice("d1")), ], From e05d9d0646f27e03cca1982f6d08ace50e0a9273 Mon Sep 17 00:00:00 2001 From: Ms2ger Date: Sat, 31 Oct 2015 13:25:32 +0100 Subject: [PATCH 30/58] Cleanup Document::handle_mouse_move_event a bit. --- components/script/dom/document.rs | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/components/script/dom/document.rs b/components/script/dom/document.rs index 0a94f9f5504..6eb3460ace0 100644 --- a/components/script/dom/document.rs +++ b/components/script/dom/document.rs @@ -672,14 +672,13 @@ impl Document { prev_mouse_over_targets: &mut RootedVec>) { // Build a list of elements that are currently under the mouse. let mouse_over_addresses = self.get_nodes_under_mouse(&point); - let mut mouse_over_targets: RootedVec> = RootedVec::new(); - for node_address in &mouse_over_addresses { - let node = node::from_untrusted_node_address(js_runtime, *node_address); - mouse_over_targets.push(node.r().inclusive_ancestors() - .find(|node| node.is::()) - .map(|node| JS::from_ref(node.downcast::().unwrap())) - .unwrap()); - }; + let mut mouse_over_targets = mouse_over_addresses.iter().map(|node_address| { + node::from_untrusted_node_address(js_runtime, *node_address) + .inclusive_ancestors() + .filter_map(Root::downcast::) + .next() + .unwrap() + }).collect::>>(); // Remove hover from any elements in the previous list that are no longer // under the mouse. From d8ef3809a6c73922a5affc475f623a0f1152be28 Mon Sep 17 00:00:00 2001 From: nxnfufunezn Date: Sat, 31 Oct 2015 17:41:00 +0530 Subject: [PATCH 31/58] Removed JS::root Fixes #8251 --- components/script/dom/bindings/global.rs | 4 +- components/script/dom/bindings/js.rs | 8 +-- .../script/dom/canvasrenderingcontext2d.rs | 15 +++-- components/script/dom/document.rs | 46 ++++++++-------- components/script/dom/domrectlist.rs | 2 +- components/script/dom/element.rs | 26 ++++----- components/script/dom/filelist.rs | 2 +- components/script/dom/formdata.rs | 2 +- components/script/dom/htmlcanvaselement.rs | 4 +- components/script/dom/htmlcollection.rs | 2 +- components/script/dom/htmlelement.rs | 4 +- components/script/dom/htmlscriptelement.rs | 2 +- components/script/dom/namednodemap.rs | 4 +- components/script/dom/node.rs | 20 +++---- components/script/dom/nodeiterator.rs | 2 +- components/script/dom/nodelist.rs | 2 +- components/script/dom/performance.rs | 2 +- components/script/dom/servohtmlparser.rs | 2 +- components/script/dom/touchlist.rs | 2 +- components/script/dom/treewalker.rs | 2 +- .../script/dom/webglrenderingcontext.rs | 7 +-- components/script/dom/xmlhttprequest.rs | 2 +- components/script/page.rs | 4 +- components/script/parse/html.rs | 55 +++++++------------ components/script/script_task.rs | 3 +- 25 files changed, 98 insertions(+), 126 deletions(-) diff --git a/components/script/dom/bindings/global.rs b/components/script/dom/bindings/global.rs index a1a1c68c8c0..e91e94a0a4b 100644 --- a/components/script/dom/bindings/global.rs +++ b/components/script/dom/bindings/global.rs @@ -230,8 +230,8 @@ impl GlobalField { /// Create a stack-bounded root for this reference. pub fn root(&self) -> GlobalRoot { match *self { - GlobalField::Window(ref window) => GlobalRoot::Window(window.root()), - GlobalField::Worker(ref worker) => GlobalRoot::Worker(worker.root()), + GlobalField::Window(ref window) => GlobalRoot::Window(Root::from_ref(window)), + GlobalField::Worker(ref worker) => GlobalRoot::Worker(Root::from_ref(worker)), } } } diff --git a/components/script/dom/bindings/js.rs b/components/script/dom/bindings/js.rs index a6af7680a96..c78399189ab 100644 --- a/components/script/dom/bindings/js.rs +++ b/components/script/dom/bindings/js.rs @@ -73,10 +73,6 @@ impl JS { } impl JS { - /// Root this JS-owned value to prevent its collection as garbage. - pub fn root(&self) -> Root { - Root::new(self.ptr) - } /// Create a JS from a Root /// XXX Not a great API. Should be a call on Root instead #[allow(unrooted_must_root)] @@ -291,7 +287,7 @@ impl MutHeap> { pub fn get(&self) -> Root { debug_assert!(task_state::get().is_script()); unsafe { - ptr::read(self.val.get()).root() + Root::from_ref(&*ptr::read(self.val.get())) } } } @@ -369,7 +365,7 @@ impl MutNullableHeap> { pub fn get(&self) -> Option> { debug_assert!(task_state::get().is_script()); unsafe { - ptr::read(self.ptr.get()).map(|o| o.root()) + ptr::read(self.ptr.get()).map(|o| Root::from_ref(&*o)) } } diff --git a/components/script/dom/canvasrenderingcontext2d.rs b/components/script/dom/canvasrenderingcontext2d.rs index aa7936f69f5..a42e98a1a03 100644 --- a/components/script/dom/canvasrenderingcontext2d.rs +++ b/components/script/dom/canvasrenderingcontext2d.rs @@ -148,7 +148,7 @@ impl CanvasRenderingContext2D { } fn mark_as_dirty(&self) { - self.canvas.root().upcast::().dirty(NodeDamage::OtherNodeDamage); + self.canvas.upcast::().dirty(NodeDamage::OtherNodeDamage); } fn update_transform(&self) { @@ -290,7 +290,7 @@ impl CanvasRenderingContext2D { let smoothing_enabled = self.state.borrow().image_smoothing_enabled; // If the source and target canvas are the same - let msg = if self.canvas.root().r() == canvas { + let msg = if &*self.canvas == canvas { CanvasMsg::Canvas2d(Canvas2dMsg::DrawImageSelf(image_size, dest_rect, source_rect, smoothing_enabled)) } else { // Source and target canvases are different let context = match canvas.get_or_init_2d_context() { @@ -367,8 +367,7 @@ impl CanvasRenderingContext2D { #[inline] fn request_image_from_cache(&self, url: Url) -> ImageResponse { - let canvas = self.canvas.root(); - let window = window_from_node(canvas.r()); + let window = window_from_node(&*self.canvas); canvas_utils::request_image_from_cache(window.r(), url) } @@ -422,7 +421,7 @@ impl LayoutCanvasRenderingContext2DHelpers for LayoutJS Root { - self.canvas.root() + Root::from_ref(&*self.canvas) } // https://html.spec.whatwg.org/multipage/#dom-context-2d-save @@ -764,7 +763,7 @@ impl CanvasRenderingContext2DMethods for CanvasRenderingContext2D { StringOrCanvasGradientOrCanvasPattern::eString(result) }, CanvasFillOrStrokeStyle::Gradient(ref gradient) => { - StringOrCanvasGradientOrCanvasPattern::eCanvasGradient(gradient.root()) + StringOrCanvasGradientOrCanvasPattern::eCanvasGradient(Root::from_ref(&*gradient)) }, } } @@ -804,7 +803,7 @@ impl CanvasRenderingContext2DMethods for CanvasRenderingContext2D { StringOrCanvasGradientOrCanvasPattern::eString(result) }, CanvasFillOrStrokeStyle::Gradient(ref gradient) => { - StringOrCanvasGradientOrCanvasPattern::eCanvasGradient(gradient.root()) + StringOrCanvasGradientOrCanvasPattern::eCanvasGradient(Root::from_ref(&*gradient)) }, } } @@ -881,7 +880,7 @@ impl CanvasRenderingContext2DMethods for CanvasRenderingContext2D { let (sender, receiver) = ipc::channel::>().unwrap(); let dest_rect = Rect::new(Point2D::new(sx.to_i32().unwrap(), sy.to_i32().unwrap()), Size2D::new(sw as i32, sh as i32)); - let canvas_size = self.canvas.root().r().get_size(); + let canvas_size = self.canvas.get_size(); let canvas_size = Size2D::new(canvas_size.width as f64, canvas_size.height as f64); self.ipc_renderer .send(CanvasMsg::Canvas2d(Canvas2dMsg::GetImageData(dest_rect, canvas_size, sender))) diff --git a/components/script/dom/document.rs b/components/script/dom/document.rs index 0a94f9f5504..4559bb0981c 100644 --- a/components/script/dom/document.rs +++ b/components/script/dom/document.rs @@ -391,8 +391,7 @@ impl Document { None => false, Some(elements) => { let position = elements.iter() - .map(|elem| elem.root()) - .position(|element| element.r() == to_unregister) + .position(|element| &**element == to_unregister) .expect("This element should be in registered."); elements.remove(position); elements.is_empty() @@ -428,7 +427,7 @@ impl Document { let root = root.upcast::(); for node in root.traverse_preorder() { if let Some(elem) = node.downcast() { - if (*elements)[head].root().r() == elem { + if &*(*elements)[head] == elem { head += 1; } if new_node == node.r() || head == elements.len() { @@ -685,8 +684,7 @@ impl Document { // under the mouse. for target in prev_mouse_over_targets.iter() { if !mouse_over_targets.contains(target) { - let target = target.root(); - let target_ref = target.r(); + let target_ref = &**target; if target_ref.get_hover_state() { target_ref.set_hover_state(false); @@ -749,27 +747,27 @@ impl Document { }, }; let target = el.upcast::(); - let window = self.window.root(); + let window = &*self.window; let client_x = Finite::wrap(point.x as f64); let client_y = Finite::wrap(point.y as f64); let page_x = Finite::wrap(point.x as f64 + window.PageXOffset() as f64); let page_y = Finite::wrap(point.y as f64 + window.PageYOffset() as f64); - let touch = Touch::new(window.r(), identifier, target, + let touch = Touch::new(window, identifier, target, client_x, client_y, // TODO: Get real screen coordinates? client_x, client_y, page_x, page_y); let mut touches = RootedVec::new(); touches.push(JS::from_rooted(&touch)); - let touches = TouchList::new(window.r(), touches.r()); + let touches = TouchList::new(window, touches.r()); - let event = TouchEvent::new(window.r(), + let event = TouchEvent::new(window, event_name, EventBubbles::Bubbles, EventCancelable::Cancelable, - Some(window.r()), + Some(window), 0i32, &touches, &touches, &touches, // FIXME: modifier keys @@ -777,9 +775,9 @@ impl Document { let event = event.upcast::(); let result = event.fire(target); - window.r().reflow(ReflowGoal::ForDisplay, - ReflowQueryType::NoQuery, - ReflowReason::MouseEvent); + window.reflow(ReflowGoal::ForDisplay, + ReflowQueryType::NoQuery, + ReflowReason::MouseEvent); result } @@ -1089,13 +1087,15 @@ impl Document { } let mut deferred_scripts = self.deferred_scripts.borrow_mut(); while !deferred_scripts.is_empty() { - let script = deferred_scripts[0].root(); - // Part of substep 1. - if !script.is_ready_to_be_executed() { - return; + { + let script = &*deferred_scripts[0]; + // Part of substep 1. + if !script.is_ready_to_be_executed() { + return; + } + // Substep 2. + script.execute(); } - // Substep 2. - script.execute(); // Substep 3. deferred_scripts.remove(0); // Substep 4 (implicit). @@ -1110,7 +1110,7 @@ impl Document { // Execute the first in-order asap-executed script if it's ready, repeat as required. // Re-borrowing the list for each step because it can also be borrowed under execute. while self.asap_in_order_scripts_list.borrow().len() > 0 { - let script = self.asap_in_order_scripts_list.borrow()[0].root(); + let script = Root::from_ref(&*self.asap_in_order_scripts_list.borrow()[0]); if !script.r().is_ready_to_be_executed() { break; } @@ -1121,7 +1121,7 @@ impl Document { let mut idx = 0; // Re-borrowing the set for each step because it can also be borrowed under execute. while idx < self.asap_scripts_set.borrow().len() { - let script = self.asap_scripts_set.borrow()[idx].root(); + let script = Root::from_ref(&*self.asap_scripts_set.borrow()[idx]); if !script.r().is_ready_to_be_executed() { idx += 1; continue; @@ -1332,7 +1332,7 @@ impl Document { } pub fn get_element_by_id(&self, id: &Atom) -> Option> { - self.idmap.borrow().get(&id).map(|ref elements| (*elements)[0].root()) + self.idmap.borrow().get(&id).map(|ref elements| Root::from_ref(&*(*elements)[0])) } pub fn record_element_state_change(&self, el: &Element, which: ElementState) { @@ -1925,7 +1925,7 @@ impl DocumentMethods for Document { // https://html.spec.whatwg.org/multipage/#dom-document-defaultview fn DefaultView(&self) -> Root { - self.window.root() + Root::from_ref(&*self.window) } // https://html.spec.whatwg.org/multipage/#dom-document-cookie diff --git a/components/script/dom/domrectlist.rs b/components/script/dom/domrectlist.rs index cd67dbc28c7..963d97df623 100644 --- a/components/script/dom/domrectlist.rs +++ b/components/script/dom/domrectlist.rs @@ -42,7 +42,7 @@ impl DOMRectListMethods for DOMRectList { fn Item(&self, index: u32) -> Option> { let rects = &self.rects; if index < rects.len() as u32 { - Some(rects[index as usize].root()) + Some(Root::from_ref(&*rects[index as usize])) } else { None } diff --git a/components/script/dom/element.rs b/components/script/dom/element.rs index 46628935bb1..eaee0d241f0 100644 --- a/components/script/dom/element.rs +++ b/components/script/dom/element.rs @@ -874,16 +874,15 @@ impl Element { } pub fn get_attribute(&self, namespace: &Namespace, local_name: &Atom) -> Option> { - self.attrs.borrow().iter().map(JS::root).find(|attr| { + self.attrs.borrow().iter().find(|attr| { attr.local_name() == local_name && attr.namespace() == namespace - }) + }).map(|js| Root::from_ref(&**js)) } // https://dom.spec.whatwg.org/#concept-element-attributes-get-by-name pub fn get_attribute_by_name(&self, name: DOMString) -> Option> { let name = &self.parsed_name(name); - self.attrs.borrow().iter().map(JS::root) - .find(|a| a.r().name() == name) + self.attrs.borrow().iter().find(|a| a.name() == name).map(|js| Root::from_ref(&**js)) } pub fn set_attribute_from_parser(&self, @@ -891,8 +890,8 @@ impl Element { value: DOMString, prefix: Option) { // Don't set if the attribute already exists, so we can handle add_attrs_if_missing - if self.attrs.borrow().iter().map(JS::root) - .any(|a| *a.r().local_name() == qname.local && *a.r().namespace() == qname.ns) { + if self.attrs.borrow().iter() + .any(|a| *a.local_name() == qname.local && *a.namespace() == qname.ns) { return; } @@ -942,7 +941,8 @@ impl Element { find: F) where F: Fn(&Attr) -> bool { - let attr = self.attrs.borrow().iter().map(JS::root).find(|attr| find(&attr)); + let attr = self.attrs.borrow().iter() + .find(|attr| find(&attr)).map(|js| Root::from_ref(&**js)); if let Some(attr) = attr { attr.set_value(value, self); } else { @@ -973,10 +973,10 @@ impl Element { fn remove_first_matching_attribute(&self, find: F) -> Option> where F: Fn(&Attr) -> bool { - let idx = self.attrs.borrow().iter().map(JS::root).position(|attr| find(&attr)); + let idx = self.attrs.borrow().iter().position(|attr| find(&attr)); idx.map(|idx| { - let attr = (*self.attrs.borrow())[idx].root(); + let attr = Root::from_ref(&*(*self.attrs.borrow())[idx]); self.attrs.borrow_mut().remove(idx); attr.set_owner(None); if attr.namespace() == &ns!("") { @@ -1005,8 +1005,8 @@ impl Element { pub fn has_attribute(&self, local_name: &Atom) -> bool { assert!(local_name.bytes().all(|b| b.to_ascii_lowercase() == b)); - self.attrs.borrow().iter().map(JS::root).any(|attr| { - attr.r().local_name() == local_name && attr.r().namespace() == &ns!("") + self.attrs.borrow().iter().any(|attr| { + attr.local_name() == local_name && attr.namespace() == &ns!("") }) } @@ -1695,8 +1695,8 @@ impl<'a> ::selectors::Element for Root { }) }, NamespaceConstraint::Any => { - self.attrs.borrow().iter().map(JS::root).any(|attr| { - attr.local_name() == local_name && test(&attr.value()) + self.attrs.borrow().iter().any(|attr| { + attr.local_name() == local_name && test(&attr.value()) }) } } diff --git a/components/script/dom/filelist.rs b/components/script/dom/filelist.rs index d695ac8f43a..78a9ee30012 100644 --- a/components/script/dom/filelist.rs +++ b/components/script/dom/filelist.rs @@ -40,7 +40,7 @@ impl FileListMethods for FileList { // https://w3c.github.io/FileAPI/#dfn-item fn Item(&self, index: u32) -> Option> { - Some(self.list[index as usize].root()) + Some(Root::from_ref(&*(self.list[index as usize]))) } // check-tidy: no specs after this line diff --git a/components/script/dom/formdata.rs b/components/script/dom/formdata.rs index a51e058b864..5956aadd26c 100644 --- a/components/script/dom/formdata.rs +++ b/components/script/dom/formdata.rs @@ -90,7 +90,7 @@ impl FormDataMethods for FormData { .get(&name) .map(|entry| match entry[0] { FormDatum::StringData(ref s) => eString(s.clone()), - FormDatum::FileData(ref f) => eFile(f.root()), + FormDatum::FileData(ref f) => eFile(Root::from_ref(&*f)), }) } diff --git a/components/script/dom/htmlcanvaselement.rs b/components/script/dom/htmlcanvaselement.rs index 47126ed3dd0..67894f36429 100644 --- a/components/script/dom/htmlcanvaselement.rs +++ b/components/script/dom/htmlcanvaselement.rs @@ -153,7 +153,7 @@ impl HTMLCanvasElement { } match *self.context.borrow().as_ref().unwrap() { - CanvasContext::Context2d(ref context) => Some(context.root()), + CanvasContext::Context2d(ref context) => Some(Root::from_ref(&*context)), _ => None, } } @@ -182,7 +182,7 @@ impl HTMLCanvasElement { } if let Some(CanvasContext::WebGL(ref context)) = *self.context.borrow() { - Some(context.root()) + Some(Root::from_ref(&*context)) } else { None } diff --git a/components/script/dom/htmlcollection.rs b/components/script/dom/htmlcollection.rs index 4ddc0fef6dd..62335a33a6e 100644 --- a/components/script/dom/htmlcollection.rs +++ b/components/script/dom/htmlcollection.rs @@ -164,7 +164,7 @@ impl HTMLCollection { pub fn elements_iter(&self) -> HTMLCollectionElementsIter { let ref filter = self.collection.1; - let root = self.collection.0.root(); + let root = Root::from_ref(&*self.collection.0); let mut node_iter = root.traverse_preorder(); let _ = node_iter.next(); // skip the root node HTMLCollectionElementsIter { diff --git a/components/script/dom/htmlelement.rs b/components/script/dom/htmlelement.rs index bb52cbc2402..6ebf0106099 100644 --- a/components/script/dom/htmlelement.rs +++ b/components/script/dom/htmlelement.rs @@ -360,8 +360,8 @@ impl HTMLElement { pub fn supported_prop_names_custom_attr(&self) -> Vec { let element = self.upcast::(); - element.attrs().iter().map(JS::root).filter_map(|attr| { - let raw_name = attr.r().local_name(); + element.attrs().iter().filter_map(|attr| { + let raw_name = attr.local_name(); to_camel_case(&raw_name) }).collect() } diff --git a/components/script/dom/htmlscriptelement.rs b/components/script/dom/htmlscriptelement.rs index 118c0648e77..4f1b0ca135a 100644 --- a/components/script/dom/htmlscriptelement.rs +++ b/components/script/dom/htmlscriptelement.rs @@ -364,7 +364,7 @@ impl HTMLScriptElement { // Step 1. let doc = document_from_node(self); - if self.parser_inserted.get() && doc.r() != self.parser_document.root().r() { + if self.parser_inserted.get() && &*doc != &*self.parser_document { return; } diff --git a/components/script/dom/namednodemap.rs b/components/script/dom/namednodemap.rs index 5c78de0ed51..fc344e78ccf 100644 --- a/components/script/dom/namednodemap.rs +++ b/components/script/dom/namednodemap.rs @@ -42,7 +42,7 @@ impl NamedNodeMapMethods for NamedNodeMap { // https://dom.spec.whatwg.org/#dom-namednodemap-item fn Item(&self, index: u32) -> Option> { - self.owner.attrs().get(index as usize).map(JS::root) + self.owner.attrs().get(index as usize).map(|js| Root::from_ref(&**js)) } // https://dom.spec.whatwg.org/#dom-namednodemap-getnameditem @@ -87,7 +87,7 @@ impl NamedNodeMapMethods for NamedNodeMap { // https://heycam.github.io/webidl/#dfn-supported-property-names fn SupportedPropertyNames(&self) -> Vec { - self.owner.attrs().iter().map(JS::root).map(|attr| { + self.owner.attrs().iter().map(|attr| { (**attr.name()).to_owned() }).collect() } diff --git a/components/script/dom/node.rs b/components/script/dom/node.rs index c5a891d56db..a8dd8972ca0 100644 --- a/components/script/dom/node.rs +++ b/components/script/dom/node.rs @@ -1648,7 +1648,7 @@ impl Node { let node_elem = node.downcast::().unwrap(); let copy_elem = copy.downcast::().unwrap(); - for attr in node_elem.attrs().iter().map(JS::root) { + for attr in node_elem.attrs().iter() { copy_elem.push_new_attribute(attr.local_name().clone(), attr.value().clone(), attr.name().clone(), @@ -1719,12 +1719,10 @@ impl Node { let prefix_atom = prefix.as_ref().map(|s| Atom::from_slice(s)); // Step 2. - let namespace_attr = - element.attrs() - .iter() - .map(|attr| attr.root()) - .find(|attr| attr_defines_namespace(attr.r(), - &prefix_atom)); + let attrs = element.attrs(); + let namespace_attr = attrs.iter().find(|attr| { + attr_defines_namespace(attr, &prefix_atom) + }); // Steps 2.1-2. if let Some(attr) = namespace_attr { @@ -2154,12 +2152,10 @@ impl NodeMethods for Node { // FIXME(https://github.com/rust-lang/rust/issues/23338) let attrs = element.attrs(); attrs.iter().all(|attr| { - let attr = attr.root(); other_element.attrs().iter().any(|other_attr| { - let other_attr = other_attr.root(); - (*attr.r().namespace() == *other_attr.r().namespace()) && - (attr.r().local_name() == other_attr.r().local_name()) && - (**attr.r().value() == **other_attr.r().value()) + (*attr.namespace() == *other_attr.namespace()) && + (attr.local_name() == other_attr.local_name()) && + (**attr.value() == **other_attr.value()) }) }) } diff --git a/components/script/dom/nodeiterator.rs b/components/script/dom/nodeiterator.rs index 27a99ec3b55..762d2233c6c 100644 --- a/components/script/dom/nodeiterator.rs +++ b/components/script/dom/nodeiterator.rs @@ -67,7 +67,7 @@ impl NodeIterator { impl NodeIteratorMethods for NodeIterator { // https://dom.spec.whatwg.org/#dom-nodeiterator-root fn Root(&self) -> Root { - self.root_node.root() + Root::from_ref(&*self.root_node) } // https://dom.spec.whatwg.org/#dom-nodeiterator-whattoshow diff --git a/components/script/dom/nodelist.rs b/components/script/dom/nodelist.rs index 490df73bd56..68e3b7ee424 100644 --- a/components/script/dom/nodelist.rs +++ b/components/script/dom/nodelist.rs @@ -66,7 +66,7 @@ impl NodeListMethods for NodeList { fn Item(&self, index: u32) -> Option> { match self.list_type { NodeListType::Simple(ref elems) => { - elems.get(index as usize).map(|node| node.root()) + elems.get(index as usize).map(|node| Root::from_ref(&**node)) }, NodeListType::Children(ref list) => list.item(index), } diff --git a/components/script/dom/performance.rs b/components/script/dom/performance.rs index b8b6c17ef09..591cb5472c4 100644 --- a/components/script/dom/performance.rs +++ b/components/script/dom/performance.rs @@ -46,7 +46,7 @@ impl Performance { impl PerformanceMethods for Performance { // https://dvcs.w3.org/hg/webperf/raw-file/tip/specs/NavigationTiming/Overview.html#performance-timing-attribute fn Timing(&self) -> Root { - self.timing.root() + Root::from_ref(&*self.timing) } // https://dvcs.w3.org/hg/webperf/raw-file/tip/specs/HighResolutionTime/Overview.html#dom-performance-now diff --git a/components/script/dom/servohtmlparser.rs b/components/script/dom/servohtmlparser.rs index 3a4a59ba3af..433c1085aef 100644 --- a/components/script/dom/servohtmlparser.rs +++ b/components/script/dom/servohtmlparser.rs @@ -45,7 +45,7 @@ impl Sink { #[allow(unrooted_must_root)] // method is only run at parse time pub fn get_or_create(&self, child: NodeOrText>) -> Root { match child { - NodeOrText::AppendNode(n) => n.root(), + NodeOrText::AppendNode(n) => Root::from_ref(&*n), NodeOrText::AppendText(t) => { let text = Text::new(t.into(), &self.document); Root::upcast(text) diff --git a/components/script/dom/touchlist.rs b/components/script/dom/touchlist.rs index 5806f945008..f964a1ff250 100644 --- a/components/script/dom/touchlist.rs +++ b/components/script/dom/touchlist.rs @@ -38,7 +38,7 @@ impl TouchListMethods for TouchList { /// https://w3c.github.io/touch-events/#widl-TouchList-item-getter-Touch-unsigned-long-index fn Item(&self, index: u32) -> Option> { - self.touches.get(index as usize).map(JS::root) + self.touches.get(index as usize).map(|js| Root::from_ref(&**js)) } /// https://w3c.github.io/touch-events/#widl-TouchList-item-getter-Touch-unsigned-long-index diff --git a/components/script/dom/treewalker.rs b/components/script/dom/treewalker.rs index f19e8383ddf..2bd5cc706e7 100644 --- a/components/script/dom/treewalker.rs +++ b/components/script/dom/treewalker.rs @@ -65,7 +65,7 @@ impl TreeWalker { impl TreeWalkerMethods for TreeWalker { // https://dom.spec.whatwg.org/#dom-treewalker-root fn Root(&self) -> Root { - self.root_node.root() + Root::from_ref(&*self.root_node) } // https://dom.spec.whatwg.org/#dom-treewalker-whattoshow diff --git a/components/script/dom/webglrenderingcontext.rs b/components/script/dom/webglrenderingcontext.rs index aa92967cb1e..07ac00000a2 100644 --- a/components/script/dom/webglrenderingcontext.rs +++ b/components/script/dom/webglrenderingcontext.rs @@ -153,7 +153,7 @@ impl WebGLRenderingContext { } fn mark_as_dirty(&self) { - self.canvas.root().upcast::().dirty(NodeDamage::OtherNodeDamage); + self.canvas.upcast::().dirty(NodeDamage::OtherNodeDamage); } } @@ -166,7 +166,7 @@ impl Drop for WebGLRenderingContext { impl WebGLRenderingContextMethods for WebGLRenderingContext { // https://www.khronos.org/registry/webgl/specs/latest/1.0/#5.14.1 fn Canvas(&self) -> Root { - self.canvas.root() + Root::from_ref(&*self.canvas) } // https://www.khronos.org/registry/webgl/specs/latest/1.0/#5.14.1 @@ -848,8 +848,7 @@ impl WebGLRenderingContextMethods for WebGLRenderingContext { None => return, }; - let canvas = self.canvas.root(); - let window = window_from_node(canvas.r()); + let window = window_from_node(&*self.canvas); let img = match canvas_utils::request_image_from_cache(window.r(), img_url) { ImageResponse::Loaded(img) => img, diff --git a/components/script/dom/xmlhttprequest.rs b/components/script/dom/xmlhttprequest.rs index 39b86117b34..c5f8ef62556 100644 --- a/components/script/dom/xmlhttprequest.rs +++ b/components/script/dom/xmlhttprequest.rs @@ -465,7 +465,7 @@ impl XMLHttpRequestMethods for XMLHttpRequest { // https://xhr.spec.whatwg.org/#the-upload-attribute fn Upload(&self) -> Root { - self.upload.root() + Root::from_ref(&*self.upload) } // https://xhr.spec.whatwg.org/#the-send()-method diff --git a/components/script/page.rs b/components/script/page.rs index b6b35c6119a..67cb1ca46ed 100644 --- a/components/script/page.rs +++ b/components/script/page.rs @@ -68,11 +68,11 @@ impl Page { } pub fn window(&self) -> Root { - self.frame.borrow().as_ref().unwrap().window.root() + Root::from_ref(&*self.frame.borrow().as_ref().unwrap().window) } pub fn document(&self) -> Root { - self.frame.borrow().as_ref().unwrap().document.root() + Root::from_ref(&*self.frame.borrow().as_ref().unwrap().document) } // must handle root case separately diff --git a/components/script/parse/html.rs b/components/script/parse/html.rs index 4943fecdb5f..07c5d19b1f3 100644 --- a/components/script/parse/html.rs +++ b/components/script/parse/html.rs @@ -10,8 +10,7 @@ use dom::bindings::codegen::Bindings::HTMLTemplateElementBinding::HTMLTemplateEl use dom::bindings::codegen::Bindings::NodeBinding::NodeMethods; use dom::bindings::codegen::InheritTypes::{CharacterDataTypeId, NodeTypeId}; use dom::bindings::conversions::Castable; -use dom::bindings::js::{JS, Root}; -use dom::bindings::js::{RootedReference}; +use dom::bindings::js::{JS, RootedReference}; use dom::characterdata::CharacterData; use dom::comment::Comment; use dom::document::Document; @@ -45,11 +44,10 @@ impl<'a> TreeSink for servohtmlparser::Sink { type Handle = JS; fn get_document(&mut self) -> JS { - JS::from_ref(self.document.root().upcast()) + JS::from_ref(self.document.upcast()) } fn get_template_contents(&self, target: JS) -> JS { - let target = target.root(); let template = target.downcast::() .expect("tried to get template contents of non-HTMLTemplateElement in HTML parsing"); JS::from_ref(template.Content().upcast()) @@ -60,8 +58,7 @@ impl<'a> TreeSink for servohtmlparser::Sink { } fn elem_name(&self, target: JS) -> QualName { - let node: Root = target.root(); - let elem = node.downcast::() + let elem = target.downcast::() .expect("tried to get name of non-Element in HTML parsing"); QualName { ns: elem.namespace().clone(), @@ -71,8 +68,7 @@ impl<'a> TreeSink for servohtmlparser::Sink { fn create_element(&mut self, name: QualName, attrs: Vec) -> JS { - let doc = self.document.root(); - let elem = Element::create(name, None, doc.r(), + let elem = Element::create(name, None, &*self.document, ElementCreator::ParserCreated); for attr in attrs { @@ -83,8 +79,7 @@ impl<'a> TreeSink for servohtmlparser::Sink { } fn create_comment(&mut self, text: StrTendril) -> JS { - let doc = self.document.root(); - let comment = Comment::new(text.into(), doc.r()); + let comment = Comment::new(text.into(), &*self.document); JS::from_ref(comment.upcast()) } @@ -92,14 +87,13 @@ impl<'a> TreeSink for servohtmlparser::Sink { sibling: JS, new_node: NodeOrText>) -> Result<(), NodeOrText>> { // If there is no parent, return the node to the parser. - let sibling: Root = sibling.root(); - let parent = match sibling.r().GetParentNode() { + let parent = match sibling.GetParentNode() { Some(p) => p, None => return Err(new_node), }; let child = self.get_or_create(new_node); - assert!(parent.r().InsertBefore(child.r(), Some(sibling.r())).is_ok()); + assert!(parent.r().InsertBefore(child.r(), Some(&*sibling)).is_ok()); Ok(()) } @@ -108,29 +102,26 @@ impl<'a> TreeSink for servohtmlparser::Sink { } fn set_quirks_mode(&mut self, mode: QuirksMode) { - let doc = self.document.root(); - doc.r().set_quirks_mode(mode); + self.document.set_quirks_mode(mode); } fn append(&mut self, parent: JS, child: NodeOrText>) { - let parent: Root = parent.root(); let child = self.get_or_create(child); // FIXME(#3701): Use a simpler algorithm and merge adjacent text nodes - assert!(parent.r().AppendChild(child.r()).is_ok()); + assert!(parent.AppendChild(child.r()).is_ok()); } fn append_doctype_to_document(&mut self, name: StrTendril, public_id: StrTendril, system_id: StrTendril) { - let doc = self.document.root(); + let doc = &*self.document; let doctype = DocumentType::new( - name.into(), Some(public_id.into()), Some(system_id.into()), doc.r()); + name.into(), Some(public_id.into()), Some(system_id.into()), doc); doc.upcast::().AppendChild(doctype.upcast()).expect("Appending failed"); } fn add_attrs_if_missing(&mut self, target: JS, attrs: Vec) { - let node: Root = target.root(); - let elem = node.downcast::() + let elem = target.downcast::() .expect("tried to set attrs on non-Element in HTML parsing"); for attr in attrs { elem.set_attribute_from_parser(attr.name, attr.value.into(), None); @@ -138,20 +129,17 @@ impl<'a> TreeSink for servohtmlparser::Sink { } fn remove_from_parent(&mut self, target: JS) { - let node = target.root(); - if let Some(ref parent) = node.r().GetParentNode() { - parent.r().RemoveChild(node.r()).unwrap(); + if let Some(ref parent) = target.GetParentNode() { + parent.r().RemoveChild(&*target).unwrap(); } } fn mark_script_already_started(&mut self, node: JS) { - let node: Root = node.root(); let script = node.downcast::(); script.map(|script| script.mark_already_started()); } fn complete_script(&mut self, node: JS) -> NextParserState { - let node: Root = node.root(); let script = node.downcast::(); if let Some(script) = script { return script.prepare(); @@ -160,11 +148,7 @@ impl<'a> TreeSink for servohtmlparser::Sink { } fn reparent_children(&mut self, node: JS, new_parent: JS) { - let new_parent = new_parent.root(); - let new_parent = new_parent.r(); - let old_parent = node.root(); - let old_parent = old_parent.r(); - while let Some(ref child) = old_parent.GetFirstChild() { + while let Some(ref child) = node.GetFirstChild() { new_parent.AppendChild(child.r()).unwrap(); } @@ -181,11 +165,10 @@ impl<'a> Serializable for &'a Node { let name = QualName::new(elem.namespace().clone(), elem.local_name().clone()); if traversal_scope == IncludeNode { - let attrs = elem.attrs().iter().map(|at| { - let attr = at.root(); - let qname = QualName::new(attr.r().namespace().clone(), - attr.r().local_name().clone()); - let value = attr.r().value().clone(); + let attrs = elem.attrs().iter().map(|attr| { + let qname = QualName::new(attr.namespace().clone(), + attr.local_name().clone()); + let value = attr.value().clone(); (qname, value) }).collect::>(); let attr_refs = attrs.iter().map(|&(ref qname, ref value)| { diff --git a/components/script/script_task.rs b/components/script/script_task.rs index fa427db6ff1..4939a58e086 100644 --- a/components/script/script_task.rs +++ b/components/script/script_task.rs @@ -1747,9 +1747,8 @@ impl ScriptTask { // Notify Constellation about the topmost anchor mouse over target. for target in &*mouse_over_targets { - let target = target.root(); if target.upcast::().is_anchor_element() { - let status = target.r().get_attribute(&ns!(""), &atom!("href")) + let status = target.get_attribute(&ns!(""), &atom!("href")) .and_then(|href| { let value = href.value(); let url = document.r().url(); From aa7a3919c4fe018fb1a85a70f51a2a0a66deace4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?G=C3=B6kberk=20Yalt=C4=B1rakl=C4=B1?= Date: Sat, 31 Oct 2015 18:07:13 +0300 Subject: [PATCH 32/58] Made binary files show an info message instead of garbled text. --- components/script/dom/servohtmlparser.rs | 31 ++++++++++++++++++------ 1 file changed, 24 insertions(+), 7 deletions(-) diff --git a/components/script/dom/servohtmlparser.rs b/components/script/dom/servohtmlparser.rs index 3a4a59ba3af..4855f77b384 100644 --- a/components/script/dom/servohtmlparser.rs +++ b/components/script/dom/servohtmlparser.rs @@ -68,8 +68,8 @@ pub type Tokenizer = tokenizer::Tokenizer, Sink>>; pub struct ParserContext { /// The parser that initiated the request. parser: Option>, - /// Is this document a synthesized document for a single image? - is_image_document: bool, + /// Is this a synthesized document + is_synthesized_document: bool, /// The pipeline associated with this document. id: PipelineId, /// The subpage associated with this document. @@ -85,7 +85,7 @@ impl ParserContext { url: Url) -> ParserContext { ParserContext { parser: None, - is_image_document: false, + is_synthesized_document: false, id: id, subpage: subpage, script_chan: script_chan, @@ -111,12 +111,12 @@ impl AsyncResponseListener for ParserContext { match content_type { Some(ContentType(Mime(TopLevel::Image, _, _))) => { - self.is_image_document = true; + self.is_synthesized_document = true; let page = format!("", self.url.serialize()); parser.pending_input.borrow_mut().push(page); parser.parse_sync(); - } + }, Some(ContentType(Mime(TopLevel::Text, SubLevel::Plain, _))) => { // FIXME: When servo/html5ever#109 is fixed remove usage and // replace with fix from that issue. @@ -130,12 +130,29 @@ impl AsyncResponseListener for ParserContext { parser.pending_input.borrow_mut().push(page); parser.parse_sync(); }, - _ => {} + Some(ContentType(Mime(TopLevel::Text, SubLevel::Html, _))) => {}, // Handle text/html + Some(ContentType(Mime(toplevel, sublevel, _))) => { + if toplevel.as_str() == "application" && sublevel.as_str() == "xhtml+xml" { + // Handle xhtml (application/xhtml+xml). + return; + } + + // Show warning page for unknown mime types. + let page = format!("<html><body><p>Unknown content type ({}/{}).</p></body></html>", + toplevel.as_str(), sublevel.as_str()); + self.is_synthesized_document = true; + parser.pending_input.borrow_mut().push(page); + parser.parse_sync(); + }, + None => { + // No content-type header. + // Merge with #4212 when fixed. + } } } fn data_available(&mut self, payload: Vec<u8>) { - if !self.is_image_document { + if !self.is_synthesized_document { // FIXME: use Vec<u8> (html5ever #34) let data = UTF_8.decode(&payload, DecoderTrap::Replace).unwrap(); let parser = match self.parser.as_ref() { From b492a3e8b1762491f84ab134d9d2904fce69b1ea Mon Sep 17 00:00:00 2001 From: Ms2ger <Ms2ger@gmail.com> Date: Sat, 31 Oct 2015 14:26:53 +0100 Subject: [PATCH 33/58] Update web-platform-tests to revision 7123012427f92f0dc38a120e6e86a75b6c03aab5 --- tests/wpt/metadata/MANIFEST.json | 21 ++- .../frameElement.sub.html.ini | 6 + .../select-ask-for-reset.html.ini | 1 + tests/wpt/metadata/mozilla-sync | 2 +- tests/wpt/web-platform-tests/.gitignore | 1 + .../idbobjectstore_openKeyCursor.htm | 139 ++++++++++++++++++ .../web-platform-tests/IndexedDB/support.js | 23 --- tests/wpt/web-platform-tests/README.md | 6 +- .../scripthash-unicode-normalization.sub.html | 69 ++++++--- ...unicode-normalization.sub.html.sub.headers | 2 +- .../frameElement.sub.html | 35 +++-- .../nested-browsing-contexts/testcase3.html | 14 ++ .../resources/testharness.js | 2 + .../web-platform-tests/webdriver/base_test.py | 17 ++- .../webdriver/cookie/cookie_test.py | 26 +--- .../element_location/element_location_test.py | 29 +++- .../webdriver/element_state/method_test.py | 22 +-- .../webdriver/element_state/properties.py | 17 +++ .../element_state/res/elements_text.html | 10 ++ .../element_state/visibility_test.py | 106 ++++++------- .../javascript/execute_script_test.py | 1 + .../webdriver/modal/alerts_quit_test.py | 7 +- .../webdriver/modal/alerts_test.py | 87 +++++------ .../webdriver/navigation/auth_tests.py | 2 +- .../webdriver/navigation/forward.py | 10 +- .../webdriver/navigation/forwardToNothing.py | 6 +- .../navigation/get_from_http_test.py | 10 +- .../webdriver/navigation/invalid_cert_test.py | 2 +- .../webdriver/navigation/refresh_page.py | 27 ++++ .../webdriver/runtests_p0.py | 42 ++++++ .../webdriver/screenshot/__init__.py | 1 + .../webdriver/screenshot/res/screenshot.html | 5 + .../webdriver/screenshot/take_screenshot.py | 15 ++ .../timeouts/implicit_waits_tests.py | 36 ++--- .../timeouts/page_load_timeouts_tests.py | 2 +- .../webdriver/user_input/clear_test.py | 16 +- .../webdriver/webdriver.cfg | 4 + .../webdriver/windows/__init__.py | 1 + .../webdriver/windows/res/win1.html | 5 + .../webdriver/windows/res/win2.html | 5 + .../webdriver/windows/res/win3.html | 5 + .../webdriver/windows/res/win4.html | 5 + .../webdriver/windows/res/win5.html | 5 + .../webdriver/windows/tabbing.py | 30 ++++ .../webdriver/windows/window_manipulation.py | 43 ++++++ 45 files changed, 688 insertions(+), 232 deletions(-) create mode 100644 tests/wpt/web-platform-tests/IndexedDB/idbobjectstore_openKeyCursor.htm create mode 100644 tests/wpt/web-platform-tests/html/browsers/windows/nested-browsing-contexts/testcase3.html create mode 100644 tests/wpt/web-platform-tests/webdriver/element_state/properties.py create mode 100644 tests/wpt/web-platform-tests/webdriver/element_state/res/elements_text.html create mode 100644 tests/wpt/web-platform-tests/webdriver/navigation/refresh_page.py create mode 100644 tests/wpt/web-platform-tests/webdriver/runtests_p0.py create mode 100644 tests/wpt/web-platform-tests/webdriver/screenshot/__init__.py create mode 100644 tests/wpt/web-platform-tests/webdriver/screenshot/res/screenshot.html create mode 100644 tests/wpt/web-platform-tests/webdriver/screenshot/take_screenshot.py create mode 100644 tests/wpt/web-platform-tests/webdriver/windows/__init__.py create mode 100644 tests/wpt/web-platform-tests/webdriver/windows/res/win1.html create mode 100644 tests/wpt/web-platform-tests/webdriver/windows/res/win2.html create mode 100644 tests/wpt/web-platform-tests/webdriver/windows/res/win3.html create mode 100644 tests/wpt/web-platform-tests/webdriver/windows/res/win4.html create mode 100644 tests/wpt/web-platform-tests/webdriver/windows/res/win5.html create mode 100644 tests/wpt/web-platform-tests/webdriver/windows/tabbing.py create mode 100644 tests/wpt/web-platform-tests/webdriver/windows/window_manipulation.py diff --git a/tests/wpt/metadata/MANIFEST.json b/tests/wpt/metadata/MANIFEST.json index fd7aace016b..3222090ad1d 100644 --- a/tests/wpt/metadata/MANIFEST.json +++ b/tests/wpt/metadata/MANIFEST.json @@ -11437,6 +11437,10 @@ "path": "IndexedDB/idbobjectstore_openCursor_invalid.htm", "url": "/IndexedDB/idbobjectstore_openCursor_invalid.htm" }, + { + "path": "IndexedDB/idbobjectstore_openKeyCursor.htm", + "url": "/IndexedDB/idbobjectstore_openKeyCursor.htm" + }, { "path": "IndexedDB/idbobjectstore_put.htm", "url": "/IndexedDB/idbobjectstore_put.htm" @@ -29747,6 +29751,9 @@ { "path": "webdriver/element_state/method_test.py" }, + { + "path": "webdriver/element_state/properties.py" + }, { "path": "webdriver/element_state/visibility_test.py" }, @@ -29777,6 +29784,12 @@ { "path": "webdriver/navigation/refresh-page.py" }, + { + "path": "webdriver/navigation/refresh_page.py" + }, + { + "path": "webdriver/screenshot/take_screenshot.py" + }, { "path": "webdriver/timeouts/implicit_waits_tests.py" }, @@ -29785,6 +29798,12 @@ }, { "path": "webdriver/user_input/clear_test.py" + }, + { + "path": "webdriver/windows/tabbing.py" + }, + { + "path": "webdriver/windows/window_manipulation.py" } ] }, @@ -35327,7 +35346,7 @@ } ] }, - "rev": "4b25d322ac6ed466f992669e5408b15d37d56436", + "rev": "7123012427f92f0dc38a120e6e86a75b6c03aab5", "url_base": "/", "version": 2 } \ No newline at end of file diff --git a/tests/wpt/metadata/html/browsers/windows/nested-browsing-contexts/frameElement.sub.html.ini b/tests/wpt/metadata/html/browsers/windows/nested-browsing-contexts/frameElement.sub.html.ini index 1df7bd3dc0b..b56a9490e9a 100644 --- a/tests/wpt/metadata/html/browsers/windows/nested-browsing-contexts/frameElement.sub.html.ini +++ b/tests/wpt/metadata/html/browsers/windows/nested-browsing-contexts/frameElement.sub.html.ini @@ -6,3 +6,9 @@ [The SecurityError must be thrown if the container's document does not have the same effective script origin] expected: FAIL + [The SecurityError must be thrown if the window accesses to frameElement attribute of a Window which does not have the same effective script origin] + expected: FAIL + + [The window's frameElement attribute must return null if the container's document does not have the same effective script origin] + expected: FAIL + diff --git a/tests/wpt/metadata/html/semantics/forms/the-select-element/select-ask-for-reset.html.ini b/tests/wpt/metadata/html/semantics/forms/the-select-element/select-ask-for-reset.html.ini index f858a12d101..dd109c994dd 100644 --- a/tests/wpt/metadata/html/semantics/forms/the-select-element/select-ask-for-reset.html.ini +++ b/tests/wpt/metadata/html/semantics/forms/the-select-element/select-ask-for-reset.html.ini @@ -2,3 +2,4 @@ type: testharness [ask for reset on node remove, non multiple.] expected: FAIL + diff --git a/tests/wpt/metadata/mozilla-sync b/tests/wpt/metadata/mozilla-sync index c30d6257fc1..296a35e4d67 100644 --- a/tests/wpt/metadata/mozilla-sync +++ b/tests/wpt/metadata/mozilla-sync @@ -1 +1 @@ -7574a8ec72e121613cb56f2af746f858c02b7181 \ No newline at end of file +521a87180a85709f8f704df33537f79bd131bf71 \ No newline at end of file diff --git a/tests/wpt/web-platform-tests/.gitignore b/tests/wpt/web-platform-tests/.gitignore index 72908a311d8..7728bbdc3c4 100644 --- a/tests/wpt/web-platform-tests/.gitignore +++ b/tests/wpt/web-platform-tests/.gitignore @@ -9,3 +9,4 @@ config.json node_modules scratch testharness_runner.html +webdriver/.idea diff --git a/tests/wpt/web-platform-tests/IndexedDB/idbobjectstore_openKeyCursor.htm b/tests/wpt/web-platform-tests/IndexedDB/idbobjectstore_openKeyCursor.htm new file mode 100644 index 00000000000..9dc547c3ff9 --- /dev/null +++ b/tests/wpt/web-platform-tests/IndexedDB/idbobjectstore_openKeyCursor.htm @@ -0,0 +1,139 @@ +<!DOCTYPE html> +<title>IDBObjectStore.openKeyCursor()</title> +<script src="/resources/testharness.js"></script> +<script src="/resources/testharnessreport.js"></script> +<script> +function store_test(func, name) { + async_test(function(t) { + var del = indexedDB.deleteDatabase(name); + del.onerror = t.unreached_func("deleteDatabase failed"); + var open = indexedDB.open(name); + open.onupgradeneeded = t.step_func(function() { + var db = open.result; + var store = db.createObjectStore("store"); + for (var i = 0; i < 10; ++i) { + store.put("value: " + i, i); + } + }); + + open.onsuccess = t.step_func(function() { + var db = open.result; + var tx = db.transaction("store"); + var store = tx.objectStore("store"); + func(t, db, tx, store); + }); + }, name); +} + +store_test(function(t, db, tx, store) { + var expected = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9]; + var actual = []; + var request = store.openKeyCursor(); + request.onsuccess = t.step_func(function() { + var cursor = request.result; + if (!cursor) + return; + assert_equals(cursor.direction, "next"); + assert_false("value" in cursor); + assert_equals(indexedDB.cmp(cursor.key, cursor.primaryKey), 0); + actual.push(cursor.key); + cursor.continue(); + }); + + tx.onabort = t.unreached_func("transaction aborted"); + tx.oncomplete = t.step_func(function() { + assert_array_equals(expected, actual, "keys should match"); + t.done(); + }); + +}, "IDBObjectStore.openKeyCursor() - forward iteration"); + +store_test(function(t, db, tx, store) { + var expected = [9, 8, 7, 6, 5, 4, 3, 2, 1, 0]; + var actual = []; + var request = store.openKeyCursor(null, "prev"); + request.onsuccess = t.step_func(function() { + var cursor = request.result; + if (!cursor) + return; + assert_equals(cursor.direction, "prev"); + assert_false("value" in cursor); + assert_equals(indexedDB.cmp(cursor.key, cursor.primaryKey), 0); + actual.push(cursor.key); + cursor.continue(); + }); + + tx.onabort = t.unreached_func("transaction aborted"); + tx.oncomplete = t.step_func(function() { + assert_array_equals(expected, actual, "keys should match"); + t.done(); + }); + +}, "IDBObjectStore.openKeyCursor() - reverse iteration"); + +store_test(function(t, db, tx, store) { + var expected = [4, 5, 6]; + var actual = []; + var request = store.openKeyCursor(IDBKeyRange.bound(4, 6)); + request.onsuccess = t.step_func(function() { + var cursor = request.result; + if (!cursor) + return; + assert_equals(cursor.direction, "next"); + assert_false("value" in cursor); + assert_equals(indexedDB.cmp(cursor.key, cursor.primaryKey), 0); + actual.push(cursor.key); + cursor.continue(); + }); + + tx.onabort = t.unreached_func("transaction aborted"); + tx.oncomplete = t.step_func(function() { + assert_array_equals(expected, actual, "keys should match"); + t.done(); + }); + +}, "IDBObjectStore.openKeyCursor() - forward iteration with range"); + +store_test(function(t, db, tx, store) { + var expected = [6, 5, 4]; + var actual = []; + var request = store.openKeyCursor(IDBKeyRange.bound(4, 6), "prev"); + request.onsuccess = t.step_func(function() { + var cursor = request.result; + if (!cursor) + return; + assert_equals(cursor.direction, "prev"); + assert_false("value" in cursor); + assert_equals(indexedDB.cmp(cursor.key, cursor.primaryKey), 0); + actual.push(cursor.key); + cursor.continue(); + }); + + tx.onabort = t.unreached_func("transaction aborted"); + tx.oncomplete = t.step_func(function() { + assert_array_equals(expected, actual, "keys should match"); + t.done(); + }); + +}, "IDBObjectStore.openKeyCursor() - reverse iteration with range"); + +store_test(function(t, db, tx, store) { + assert_throws("DataError", function() { store.openKeyCursor(NaN); }, + "openKeyCursor should throw on invalid number key"); + assert_throws("DataError", function() { store.openKeyCursor(new Date(NaN)); }, + "openKeyCursor should throw on invalid date key"); + assert_throws("DataError", function() { + var cycle = []; + cycle.push(cycle); + store.openKeyCursor(cycle); + }, "openKeyCursor should throw on invalid array key"); + assert_throws("DataError", function() { store.openKeyCursor({}); }, + "openKeyCursor should throw on invalid key type"); + setTimeout(t.step_func(function() { + assert_throws("TransactionInactiveError", function() { store.openKeyCursor(); }, + "openKeyCursor should throw if transaction is inactive"); + t.done(); + }), 0); + +}, "IDBObjectStore.openKeyCursor() - invalid inputs"); +</script> diff --git a/tests/wpt/web-platform-tests/IndexedDB/support.js b/tests/wpt/web-platform-tests/IndexedDB/support.js index 2eeca4f1f53..1e8458fee96 100644 --- a/tests/wpt/web-platform-tests/IndexedDB/support.js +++ b/tests/wpt/web-platform-tests/IndexedDB/support.js @@ -1,29 +1,6 @@ var databaseName = "database"; var databaseVersion = 1; -if (!window.indexedDB) -{ - if (window.msIndexedDB) - { - window.indexedDB = window.msIndexedDB; - } - else if (window.mozIndexedDB) - { - window.indexedDB = window.mozIndexedDB; - } - else if (window.webkitIndexedDB) - { - window.indexedDB = webkitIndexedDB; - IDBCursor = webkitIDBCursor; - IDBDatabaseException = webkitIDBDatabaseException; - IDBIndex = webkitIDBIndex; - IDBObjectStore = webkitIDBObjectStore; - IDBRequest = webkitIDBRequest; - IDBKeyRange = webkitIDBKeyRange; - IDBTransaction = webkitIDBTransaction; - } -} - /* Delete created databases * * Go through each finished test, see if it has an associated database. Close diff --git a/tests/wpt/web-platform-tests/README.md b/tests/wpt/web-platform-tests/README.md index 8157a4a841c..cac36bc2f37 100644 --- a/tests/wpt/web-platform-tests/README.md +++ b/tests/wpt/web-platform-tests/README.md @@ -2,8 +2,10 @@ The Web Platform Tests Project [![IRC chat](https://goo.gl/6nCIks)](http://irc.w ============================== The Web Platform Tests Project is a W3C-coordinated attempt to build a -cross-browser testsuite for the Web-platform stack. Writing tests in a -way that allows them to be run in all browsers gives browser projects +cross-browser testsuite for the Web-platform stack. However, for mainly +historic reasons, the CSS WG testsuite is in a separate repository, +[csswg-test](https://github.com/w3c/csswg-test). Writing tests in a way +that allows them to be run in all browsers gives browser projects confidence that they are shipping software that is compatible with other implementations, and that later implementations will be compatible with their implementations. This in turn gives Web authors/developers diff --git a/tests/wpt/web-platform-tests/content-security-policy/blink-contrib-2/scripthash-unicode-normalization.sub.html b/tests/wpt/web-platform-tests/content-security-policy/blink-contrib-2/scripthash-unicode-normalization.sub.html index 14582670b22..8a064c70172 100644 --- a/tests/wpt/web-platform-tests/content-security-policy/blink-contrib-2/scripthash-unicode-normalization.sub.html +++ b/tests/wpt/web-platform-tests/content-security-policy/blink-contrib-2/scripthash-unicode-normalization.sub.html @@ -6,37 +6,68 @@ <title>scripthash-unicode-normalization</title> <script src="/resources/testharness.js"></script> <script src="/resources/testharnessreport.js"></script> - <script src="/content-security-policy/support/alertAssert.sub.js?alerts=%5B%22PASS%22%2C%22PASS%22%5D"> - </script> <!-- enforcing policy: -script-src 'self' 'unsafe-inline' 'sha256-xy4iRAvdlFCq+M5+4yu4B7dy0Kc2FfljmZO4Jkj3Yhw='; connect-src 'self'; +script-src 'self' 'nonce-nonceynonce' 'sha256-dWTP4Di8KBjaiXvQ5mRquI9OoBSo921ahYxLfYSiuT8='; connect-src 'self'; --> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> - <!-- The following two scripts contain two separate code points (U+00C5 - and U+212B, respectively) which, depending on your text editor, might be - rendered the same. However, their difference is important as they should - be NFC normalized to the same code point, thus they should hash to the - same value.--> - <script> - 'ร…'; - alert_assert('PASS'); - - </script> - <script> - 'โ„ซ'; - alert_assert('PASS'); - - </script> </head> <body> + <!-- The following two scripts contain two separate code points (U+00C5 + and U+212B, respectively) which, depending on your text editor, might be + rendered the same.However, their difference is important because, under + NFC normalization, they would become the same code point, which would be + against the spec. This test, therefore, validates that the scripts have + *different* hash values. --> + <script nonce="nonceynonce"> + var matchingContent = 'ร…'; + var nonMatchingContent = 'โ„ซ'; + + // This script should have a hash value of + // sha256-9UFeeZbvnMa0tLNu76v96T4Hh+UtDWHm2lPQJoTWb9c= + var scriptContent1 = "window.finish('" + matchingContent + "');"; + + // This script should have a hash value of + // sha256-iNjjXUXds31FFvkAmbC74Sxnvreug3PzGtu16udQyqM= + var scriptContent2 = "window.finish('" + nonMatchingContent + "');"; + + var script1 = document.createElement('script'); + script1.innerHTML = scriptContent1; + var script2 = document.createElement('script'); + script2.innerHTML = scriptContent2; + + script1.test = async_test("Inline script with hash in CSP"); + script2.test = async_test("Inline script without hash in CSP"); + + var failure = function() { + assert_unreached(); + } + + window.finish = function(content) { + if (content == matchingContent) { + script1.test.step(function() { + script1.test.done(); + }); + } else { + assert_unreached(); + } + } + + script1.onerror = failure; + script2.onerror = script2.test.step_func(function() { + script2.test.done(); + }); + document.body.appendChild(script1); + document.body.appendChild(script2); + </script> + <p> This tests Unicode normalization. While appearing the same, the strings in the scripts are different Unicode points, but through normalization, should be the same when the hash is taken. </p> <div id="log"></div> - <script async defer src="../support/checkReport.sub.js?reportExists=false"></script> + <script async defer src="../support/checkReport.sub.js?reportExists=true"></script> </body> </html> diff --git a/tests/wpt/web-platform-tests/content-security-policy/blink-contrib-2/scripthash-unicode-normalization.sub.html.sub.headers b/tests/wpt/web-platform-tests/content-security-policy/blink-contrib-2/scripthash-unicode-normalization.sub.html.sub.headers index 6281a262386..a23724f8ab4 100644 --- a/tests/wpt/web-platform-tests/content-security-policy/blink-contrib-2/scripthash-unicode-normalization.sub.html.sub.headers +++ b/tests/wpt/web-platform-tests/content-security-policy/blink-contrib-2/scripthash-unicode-normalization.sub.html.sub.headers @@ -3,4 +3,4 @@ Cache-Control: no-store, no-cache, must-revalidate Cache-Control: post-check=0, pre-check=0, false Pragma: no-cache Set-Cookie: scripthash-unicode-normalization={{$id:uuid()}}; Path=/content-security-policy/blink-contrib-2 -Content-Security-Policy: script-src 'self' 'sha256-xy4iRAvdlFCq+M5+4yu4B7dy0Kc2FfljmZO4Jkj3Yhw='; connect-src 'self'; report-uri /content-security-policy/support/report.py?op=put&reportID={{$id}} +Content-Security-Policy: script-src 'self' 'nonce-nonceynonce' 'sha256-9UFeeZbvnMa0tLNu76v96T4Hh+UtDWHm2lPQJoTWb9c='; connect-src 'self'; report-uri /content-security-policy/support/report.py?op=put&reportID={{$id}} diff --git a/tests/wpt/web-platform-tests/html/browsers/windows/nested-browsing-contexts/frameElement.sub.html b/tests/wpt/web-platform-tests/html/browsers/windows/nested-browsing-contexts/frameElement.sub.html index ffc4a2c0d16..0ee6783b4b4 100644 --- a/tests/wpt/web-platform-tests/html/browsers/windows/nested-browsing-contexts/frameElement.sub.html +++ b/tests/wpt/web-platform-tests/html/browsers/windows/nested-browsing-contexts/frameElement.sub.html @@ -7,7 +7,8 @@ <script> var t1 = async_test("The window's frameElement attribute must return its container element if it is a nested browsing context"); -var t2 = async_test("The SecurityError must be thrown if the container's document does not have the same effective script origin"); +var t2 = async_test("The SecurityError must be thrown if the window accesses to frameElement attribute of a Window which does not have the same effective script origin"); +var t3 = async_test("The window's frameElement attribute must return null if the container's document does not have the same effective script origin"); function on_load() { t1.step(function () { @@ -17,9 +18,9 @@ function on_load() { "The frameElement attribute should be the object element."); assert_equals(window["win3"].frameElement, document.getElementById("emb"), "The frameElement attribute should be the embed element."); - assert_equals(document.getElementById("fr3").contentWindow[0].frameElement, - document.getElementById("fr3").contentDocument.getElementById("f1"), - "The frameElement attribute should be the frame element in 'test.html'."); + assert_equals(document.getElementById("fr4").contentWindow[0].frameElement, + document.getElementById("fr4").contentDocument.getElementById("f1"), + "The frameElement attribute should be the frame element in 'test.html'."); }); t1.done(); @@ -28,23 +29,39 @@ function on_load() { "The SecurityError exception should be thrown."); }); t2.done(); + + t3.step(function () { + document.getElementById("fr5").contentWindow.postMessage(null, "*"); + }); + window.addEventListener("message", function (event) { + var data = JSON.parse(event.data); + if (data.name == "testcase3") { + t3.step(function () { + assert_equals(data.result, "window.frameElement = null", + "The frameElement attribute shoudl be null."); + }); + t3.done(); + } + }, false); } </script> <body onload="on_load()"> <div id="log"></div> <iframe id="fr1"></iframe> - <iframe id="fr2" src="test.html"></iframe> + <iframe id="fr2" src="test.html"></iframe> <!-- cross origin --> <iframe id="fr3" src="" style="display:none"></iframe> <object id="obj" name="win2" type="text/html" data="about:blank"></object> <embed id="emb" name="win3" type="image/svg+xml" src="/images/green.svg" /> + <iframe id="fr4" src="test.html"></iframe> <!-- same origin --> + <iframe id="fr5" src="testcase3.html"></iframe> <!-- cross origin --> <script> setup(function () { - var src = "http://{{domains[www1]}}:{{ports[http][0]}}"; - src += document.location.pathname.substring(0, document.location.pathname.lastIndexOf("/") + 1); - src += "test.html"; - document.getElementById("fr2").src = src; + var src_base = "http://{{domains[www1]}}:{{ports[http][0]}}"; + src_base += document.location.pathname.substring(0, document.location.pathname.lastIndexOf("/") + 1); + document.getElementById("fr2").src = src_base + "test.html"; + document.getElementById("fr5").src = src_base + "testcase3.html"; }); test(function () { diff --git a/tests/wpt/web-platform-tests/html/browsers/windows/nested-browsing-contexts/testcase3.html b/tests/wpt/web-platform-tests/html/browsers/windows/nested-browsing-contexts/testcase3.html new file mode 100644 index 00000000000..d67bde26f43 --- /dev/null +++ b/tests/wpt/web-platform-tests/html/browsers/windows/nested-browsing-contexts/testcase3.html @@ -0,0 +1,14 @@ +<!DOCTYPE html> +<meta charset="utf-8"/> +<title>Testcase 3: frameElement attribute must return null if the container\'s document does not have the same effective script origin</title> +<script> +window.addEventListener("message", function (event) { + try { + var result = "window.frameElement = " + window.frameElement; + } catch (e) { + result = e.message; + } + event.source.postMessage(JSON.stringify({name: "testcase3", result: result}), + "*"); +}, false); +</script> diff --git a/tests/wpt/web-platform-tests/resources/testharness.js b/tests/wpt/web-platform-tests/resources/testharness.js index 4e203c4863a..7920ccd4e80 100644 --- a/tests/wpt/web-platform-tests/resources/testharness.js +++ b/tests/wpt/web-platform-tests/resources/testharness.js @@ -1176,6 +1176,7 @@ policies and contribution forms [3]. NO_MODIFICATION_ALLOWED_ERR: 'NoModificationAllowedError', NOT_FOUND_ERR: 'NotFoundError', NOT_SUPPORTED_ERR: 'NotSupportedError', + INUSE_ATTRIBUTE_ERR: 'InUseAttributeError', INVALID_STATE_ERR: 'InvalidStateError', SYNTAX_ERR: 'SyntaxError', INVALID_MODIFICATION_ERR: 'InvalidModificationError', @@ -1202,6 +1203,7 @@ policies and contribution forms [3]. NoModificationAllowedError: 7, NotFoundError: 8, NotSupportedError: 9, + InUseAttributeError: 10, InvalidStateError: 11, SyntaxError: 12, InvalidModificationError: 13, diff --git a/tests/wpt/web-platform-tests/webdriver/base_test.py b/tests/wpt/web-platform-tests/webdriver/base_test.py index 9fe6b6ef3f0..851099936d2 100644 --- a/tests/wpt/web-platform-tests/webdriver/base_test.py +++ b/tests/wpt/web-platform-tests/webdriver/base_test.py @@ -10,7 +10,7 @@ repo_root = os.path.abspath(os.path.join(__file__, "../..")) sys.path.insert(1, os.path.join(repo_root, "tools", "webdriver")) sys.path.insert(1, os.path.join(repo_root, "tools", "wptserve")) from wptserve import server -from webdriver.driver import WebDriver +from selenium import webdriver class WebDriverBaseTest(unittest.TestCase): @@ -33,9 +33,10 @@ def create_driver(): config = ConfigParser.ConfigParser() config.read('webdriver.cfg') section = os.environ.get("WD_BROWSER", 'firefox') - url = 'http://127.0.0.1:4444/wd/hub' if config.has_option(section, 'url'): url = config.get(section, "url") + else: + url = 'http://127.0.0.1:4444/wd/hub' capabilities = None if config.has_option(section, 'capabilities'): try: @@ -45,5 +46,15 @@ def create_driver(): mode = 'compatibility' if config.has_option(section, 'mode'): mode = config.get(section, 'mode') + if section == 'firefox': + driver = webdriver.Firefox() + elif section == 'chrome': + driver = webdriver.Chrome() + elif section == 'edge': + driver = webdriver.Remote() + elif section == 'ie': + driver = webdriver.Ie() + elif section == 'selendroid': + driver = webdriver.Android() - return WebDriver(url, {}, capabilities, mode) + return driver diff --git a/tests/wpt/web-platform-tests/webdriver/cookie/cookie_test.py b/tests/wpt/web-platform-tests/webdriver/cookie/cookie_test.py index e4211cbb946..e57d4671308 100644 --- a/tests/wpt/web-platform-tests/webdriver/cookie/cookie_test.py +++ b/tests/wpt/web-platform-tests/webdriver/cookie/cookie_test.py @@ -4,7 +4,7 @@ import unittest sys.path.insert(1, os.path.abspath(os.path.join(__file__, "../.."))) import base_test -from webdriver import exceptions +from selenium.common import exceptions class CookieTest(base_test.WebDriverBaseTest): @@ -12,20 +12,14 @@ class CookieTest(base_test.WebDriverBaseTest): self.driver.get(self.webserver.where_is("cookie/res/cookie_container.html")) def test_can_create_a_well_formed_cookie( self ): - name = 'foo' - value = 'bar' - - self.driver.add_cookie({ 'name': name, 'value': value }) + self.driver.add_cookie({'name': 'foo', 'value': 'bar'}) def test_cookies_should_allow_secure_to_be_set( self ): name = 'foo' - value = 'bar' - secure = True - - self.driver.add_cookie({ 'name': name, - 'value': value, - 'path': '/', - 'secure': secure}) + self.driver.add_cookie({'name': name, + 'value': 'bar', + 'path': '/', + 'secure': (True)}) self.assertTrue(self.driver.get_cookie(name)[0]['secure']) def test_secure_defaults_to_false( self ): @@ -39,10 +33,8 @@ class CookieTest(base_test.WebDriverBaseTest): def test_should_throw_an_exception_when_semicolon_exists_in_the_cookie_attribute(self): invalid_name = 'foo;bar' - value = 'foobar' - try: - self.driver.add_cookie({ 'name': invalid_name, 'value': value }) + self.driver.add_cookie({'name': invalid_name, 'value': 'foobar'}) self.fail( 'should have thrown exceptions.' ) except exceptions.UnableToSetCookieException: @@ -51,10 +43,8 @@ class CookieTest(base_test.WebDriverBaseTest): pass def test_should_throw_an_exception_the_name_is_null(self): - val = 'foobar' - try: - self.driver.add_cookie({ 'name': None, 'value': val }) + self.driver.add_cookie({'name': None, 'value': 'foobar'}) self.fail( 'should have thrown exceptions.' ) except exceptions.UnableToSetCookieException: diff --git a/tests/wpt/web-platform-tests/webdriver/element_location/element_location_test.py b/tests/wpt/web-platform-tests/webdriver/element_location/element_location_test.py index acbc56d7ee4..aff548ea5e4 100644 --- a/tests/wpt/web-platform-tests/webdriver/element_location/element_location_test.py +++ b/tests/wpt/web-platform-tests/webdriver/element_location/element_location_test.py @@ -5,16 +5,15 @@ import unittest sys.path.insert(1, os.path.abspath(os.path.join(__file__, "../.."))) import base_test - class ElementLocationTest(base_test.WebDriverBaseTest): def test_find_element_by_name(self): self.driver.get(self.webserver.where_is("element_location/res/elements.html")) - e = self.driver.find_element_by_css("*[name='name']") + e = self.driver.find_element_by_name("name") self.assertEquals("name", e.text) def test_find_element_by_css_selector(self): self.driver.get(self.webserver.where_is("element_location/res/elements.html")) - e = self.driver.find_element_by_css("#id") + e = self.driver.find_element_by_css_selector("#id") self.assertEquals("id", e.text) def test_find_element_by_link_text(self): @@ -32,6 +31,30 @@ class ElementLocationTest(base_test.WebDriverBaseTest): e = self.driver.find_element_by_xpath("//*[@id='id']") self.assertEquals("id", e.text) + def test_find_elements_by_name(self): + self.driver.get(self.webserver.where_is("element_location/res/elements.html")) + e = self.driver.find_elements_by_name("name") + self.assertEquals("name", e[0].text) + + def test_find_elements_by_css_selector(self): + self.driver.get(self.webserver.where_is("element_location/res/elements.html")) + e = self.driver.find_elements_by_css_selector("#id") + self.assertEquals("id", e[0].text) + + def test_find_elements_by_link_text(self): + self.driver.get(self.webserver.where_is("element_location/res/elements.html")) + e = self.driver.find_elements_by_link_text("link text") + self.assertEquals("link text", e[0].text) + + def test_find_elements_by_partial_link_text(self): + self.driver.get(self.webserver.where_is("element_location/res/elements.html")) + e = self.driver.find_elements_by_partial_link_text("link tex") + self.assertEquals("link text", e[0].text) + + def test_find_elements_by_xpath(self): + self.driver.get(self.webserver.where_is("element_location/res/elements.html")) + e = self.driver.find_elements_by_xpath("//*[@id='id']") + self.assertEquals("id", e[0].text) if __name__ == "__main__": unittest.main() diff --git a/tests/wpt/web-platform-tests/webdriver/element_state/method_test.py b/tests/wpt/web-platform-tests/webdriver/element_state/method_test.py index e357471a0c2..dacd81b6ae0 100644 --- a/tests/wpt/web-platform-tests/webdriver/element_state/method_test.py +++ b/tests/wpt/web-platform-tests/webdriver/element_state/method_test.py @@ -9,12 +9,12 @@ import base_test class GetElementAttributeTest(base_test.WebDriverBaseTest): def test_get_element_attribute(self): self.driver.get(self.webserver.where_is("element_state/res/element-with-id-attribute.html")) - el = self.driver.find_element_by_css("div") + el = self.driver.find_element_by_css_selector("div") self.assertEqual("myId", el.get_attribute("id")) def test_style_attribute(self): self.driver.get(self.webserver.where_is("element_state/res/element-with-style-attribute.html")) - el = self.driver.find_element_by_css("div") + el = self.driver.find_element_by_css_selector("div") expected_style = """ font-family: \"Gill Sans Extrabold\",Helvetica,sans-serif; line-height: 1.2; font-weight: bold; @@ -23,47 +23,47 @@ class GetElementAttributeTest(base_test.WebDriverBaseTest): def test_color_serialization_of_style_attribute(self): self.driver.get(self.webserver.where_is("element_state/res/element-with-color-style-attribute.html")) - el = self.driver.find_element_by_css("div") + el = self.driver.find_element_by_css_selector("div") self.assertEqual("color: rgba(255, 0, 0, 1.0);", el.get_attribute("style")) def test_true_if_boolean_attribute_present(self): self.driver.get(self.webserver.where_is("element_state/res/input-with-checked-attribute.html")) - el = self.driver.find_element_by_css("input") + el = self.driver.find_element_by_css_selector("input") self.assertEqual("true", el.get_attribute("checked")) def test_none_if_boolean_attribute_absent(self): self.driver.get(self.webserver.where_is("element_state/res/input-without-checked-attribute.html")) - el = self.driver.find_element_by_css("input") + el = self.driver.find_element_by_css_selector("input") self.assertIsNone(el.get_attribute("checked")) def test_option_with_attribute_value(self): self.driver.get(self.webserver.where_is("element_state/res/option-with-value-attribute.html")) - el = self.driver.find_element_by_css("option") + el = self.driver.find_element_by_css_selector("option") self.assertEqual("value1", el.get_attribute("value")) def test_option_without_value_attribute(self): self.driver.get(self.webserver.where_is("element_state/res/option-without-value-attribute.html")) - el = self.driver.find_element_by_css("option") + el = self.driver.find_element_by_css_selector("option") self.assertEqual("Value 1", el.get_attribute("value")) def test_a_href_attribute(self): self.driver.get(self.webserver.where_is("element_state/res/a-with-href-attribute.html")) - el = self.driver.find_element_by_css("a") + el = self.driver.find_element_by_css_selector("a") self.assertEqual("http://web-platform.test:8000/path#fragment", el.get_attribute("href")) def test_img_src_attribute(self): self.driver.get(self.webserver.where_is("element_state/res/img-with-src-attribute.html")) - el = self.driver.find_element_by_css("img") + el = self.driver.find_element_by_css_selector("img") self.assertEqual("http://web-platform.test:8000/images/blue.png", el.get_attribute("src")) def test_custom_attribute(self): self.driver.get(self.webserver.where_is("element_state/res/element-with-custom-attribute.html")) - el = self.driver.find_element_by_css("div") + el = self.driver.find_element_by_css_selector("div") self.assertEqual("attribute value", el.get_attribute("webdriver-custom-attribute")) def test_attribute_not_present(self): self.driver.get(self.webserver.where_is("element_state/res/element-without-attribute.html")) - el = self.driver.find_element_by_css("div") + el = self.driver.find_element_by_css_selector("div") self.assertIsNone(el.get_attribute("class")) diff --git a/tests/wpt/web-platform-tests/webdriver/element_state/properties.py b/tests/wpt/web-platform-tests/webdriver/element_state/properties.py new file mode 100644 index 00000000000..a767700852e --- /dev/null +++ b/tests/wpt/web-platform-tests/webdriver/element_state/properties.py @@ -0,0 +1,17 @@ +import os +import sys +import unittest + +sys.path.insert(1, os.path.abspath(os.path.join(__file__, "../.."))) +import base_test + + +class GetElementPropertiesTest(base_test.WebDriverBaseTest): + def test_get_element_text(self): + self.driver.get(self.webserver.where_is("element_state/res/elements_text.html")) + e = self.driver.find_element_by_name("name") + self.assertEquals("name", e.text) + + +if __name__ == "__main__": + unittest.main() diff --git a/tests/wpt/web-platform-tests/webdriver/element_state/res/elements_text.html b/tests/wpt/web-platform-tests/webdriver/element_state/res/elements_text.html new file mode 100644 index 00000000000..45b7c237012 --- /dev/null +++ b/tests/wpt/web-platform-tests/webdriver/element_state/res/elements_text.html @@ -0,0 +1,10 @@ +<!DOCTYPE html> +<meta charset="utf-8"> + +<title>Element location</title> + +<body> + <div id="id">id</div> + <div id="name" name="name">name</div> + <a id="link">link text</a> +</body> diff --git a/tests/wpt/web-platform-tests/webdriver/element_state/visibility_test.py b/tests/wpt/web-platform-tests/webdriver/element_state/visibility_test.py index 02efadb0aca..58218a7ff2e 100644 --- a/tests/wpt/web-platform-tests/webdriver/element_state/visibility_test.py +++ b/tests/wpt/web-platform-tests/webdriver/element_state/visibility_test.py @@ -4,41 +4,41 @@ import unittest sys.path.insert(1, os.path.abspath(os.path.join(__file__, "../.."))) import base_test -from webdriver import exceptions +from selenium.common import exceptions class NaturalNonVisibleElementsTest(base_test.WebDriverBaseTest): def test_0x0_pixel_element_is_not_visible(self): self.driver.get(self.webserver.where_is("element_state/res/0x0-pixels.html")) - el = self.driver.find_element_by_css("div") + el = self.driver.find_element_by_css_selector("div") self.assertFalse(el.is_displayed()) def test_0x0_pixel_text_node_is_visible(self): self.driver.get(self.webserver.where_is("element_state/res/0x0-pixels-text-node.html")) - el = self.driver.find_element_by_css("p") + el = self.driver.find_element_by_css_selector("p") self.assertTrue(el.is_displayed()) def test_1x1_pixel_element(self): self.driver.get(self.webserver.where_is("element_state/res/1x1-pixels.html")) - el = self.driver.find_element_by_css("p") + el = self.driver.find_element_by_css_selector("p") self.assertTrue(el.is_displayed()) def test_zero_sized_element_is_shown_if_decendant_has_size(self): self.driver.get(self.webserver.where_is("element_state/res/zero-sized-element-with-sizable-decendant.html")) - parent = self.driver.find_element_by_css("#parent") - child = self.driver.find_element_by_css("#child") + parent = self.driver.find_element_by_css_selector("#parent") + child = self.driver.find_element_by_css_selector("#child") self.assertTrue(parent.is_displayed()) self.assertTrue(child.is_displayed()) def test_input_type_hidden_is_never_visible(self): self.driver.get(self.webserver.where_is("element_state/res/input-type-hidden.html")) - input = self.driver.find_element_by_css("input") + input = self.driver.find_element_by_css_selector("input") self.assertFalse(input.is_displayed()) def test_input_morphs_into_hidden(self): self.driver.get(self.webserver.where_is("element_state/res/input-morphs-into-hidden.html")) - input = self.driver.find_element_by_css("input") + input = self.driver.find_element_by_css_selector("input") self.assertFalse(input.is_displayed()) def test_parent_node_visible_when_all_children_are_absolutely_positioned_and_overflow_is_hidden(self): @@ -51,10 +51,10 @@ class NaturalNonVisibleElementsTest(base_test.WebDriverBaseTest): self.driver.get(self.webserver.where_is("element_state/res/absolute-children-ancestor-hidden-overflow.html")) - children = self.driver.find_elements_by_css(".child") + children = self.driver.find_elements_by_css_selector(".child") assert all(child.is_displayed() for child in children) - parent = self.driver.find_element_by_css("#parent") + parent = self.driver.find_element_by_css_selector("#parent") assert parent.is_displayed() def test_element_hidden_by_overflow_x_is_not_visible(self): @@ -66,8 +66,8 @@ class NaturalNonVisibleElementsTest(base_test.WebDriverBaseTest): for page in pages: self.driver.get(self.webserver.where_is(page)) - right = self.driver.find_element_by_css("#right") - bottom_right = self.driver.find_element_by_css("#bottom-right") + right = self.driver.find_element_by_css_selector("#right") + bottom_right = self.driver.find_element_by_css_selector("#bottom-right") self.assertFalse(right.is_displayed()) self.assertFalse(bottom_right.is_displayed()) @@ -81,8 +81,8 @@ class NaturalNonVisibleElementsTest(base_test.WebDriverBaseTest): for page in pages: self.driver.get(self.webserver.where_is(page)) - bottom = self.driver.find_element_by_css("#bottom") - bottom_right = self.driver.find_element_by_css("#bottom-right") + bottom = self.driver.find_element_by_css_selector("#bottom") + bottom_right = self.driver.find_element_by_css_selector("#bottom-right") self.assertFalse(bottom.is_displayed()) self.assertFalse(bottom_right.is_displayed()) @@ -104,78 +104,78 @@ class NaturalNonVisibleElementsTest(base_test.WebDriverBaseTest): def test_element_outside_viewport(self): self.driver.get(self.webserver.where_is("element_state/res/element-outside-viewport.html")) - hidden = self.driver.find_element_by_css("div") + hidden = self.driver.find_element_by_css_selector("div") self.assertFalse(hidden.is_displayed()) def test_element_dynamically_moved_outside_viewport(self): self.driver.get(self.webserver.where_is("element_state/res/element-dynamically-moved-outside-viewport.html")) - hidden = self.driver.find_element_by_css("div") + hidden = self.driver.find_element_by_css_selector("div") self.assertFalse(hidden.is_displayed()) def test_element_hidden_by_other_element(self): self.driver.get(self.webserver.where_is("element_state/res/element-hidden-by-other-element.html")) - overlay = self.driver.find_element_by_css("#overlay") - hidden = self.driver.find_element_by_css("#hidden") + overlay = self.driver.find_element_by_css_selector("#overlay") + hidden = self.driver.find_element_by_css_selector("#hidden") self.assertTrue(overlay.is_displayed()) self.assertFalse(hidden.is_displayed()) def test_element_partially_hidden_by_other_element(self): self.driver.get(self.webserver.where_is("element_state/res/element-partially-hidden-by-other-element.html")) - partial = self.driver.find_element_by_css("#partial") + partial = self.driver.find_element_by_css_selector("#partial") self.assertTrue(partial.is_displayed()) def test_element_hidden_by_z_index(self): self.driver.get(self.webserver.where_is("element_state/res/element-hidden-by-z-index.html")) - overlay = self.driver.find_element_by_css("#overlay") - hidden = self.driver.find_element_by_css("#hidden") + overlay = self.driver.find_element_by_css_selector("#overlay") + hidden = self.driver.find_element_by_css_selector("#hidden") self.assertTrue(overlay.is_displayed()) self.assertFalse(hidden.is_displayed()) def test_element_moved_outside_viewport_by_transform(self): self.driver.get(self.webserver.where_is("element_state/res/element-moved-outside-viewport-by-transform.html")) - el = self.driver.find_element_by_css("div") + el = self.driver.find_element_by_css_selector("div") self.assertFalse(el.is_displayed()) def test_element_moved_behind_other_element_by_transform(self): self.driver.get(self.webserver.where_is("element_state/res/element-moved-behind-other-element-by-transform.html")) - overlay = self.driver.find_element_by_css("#overlay") - hidden = self.driver.find_element_by_css("#hidden") + overlay = self.driver.find_element_by_css_selector("#overlay") + hidden = self.driver.find_element_by_css_selector("#hidden") self.assertTrue(overlay.is_displayed()) self.assertFalse(hidden.is_displayed()) def test_text_with_same_color_as_background(self): self.driver.get(self.webserver.where_is("element_state/res/text-with-same-color-as-background.html")) - p = self.driver.find_element_by_css("p") + p = self.driver.find_element_by_css_selector("p") self.assertFalse(p.is_displayed()) def test_text_with_same_color_as_parent_background(self): self.driver.get(self.webserver.where_is("element_state/res/text-with-same-color-as-parent-background.html")) - p = self.driver.find_element_by_css("p") + p = self.driver.find_element_by_css_selector("p") self.assertFalse(p.is_displayed()) def test_text_with_matching_color_and_background(self): self.driver.get(self.webserver.where_is("element_state/res/text-with-matching-color-and-background.html")) - p = self.driver.find_element_by_css("p") + p = self.driver.find_element_by_css_selector("p") self.assertTrue(p.is_displayed()) def test_element_with_same_color_as_background(self): self.driver.get(self.webserver.where_is("element_state/res/element-with-same-color-as-background.html")) - el = self.driver.find_element_by_css("div") + el = self.driver.find_element_by_css_selector("div") self.assertFalse(el.is_displayed()) def test_element_with_same_color_as_parent_background(self): self.driver.get(self.webserver.where_is("element_state/res/element-with-same-color-as-parent-background.html")) - hidden = self.driver.find_element_by_css("#hidden") + hidden = self.driver.find_element_by_css_selector("#hidden") self.assertFalse(hidden.is_displayed()) class BodyElementIsAlwaysDisplayedTest(base_test.WebDriverBaseTest): def assert_body_is_displayed_on(self, page): self.driver.get(self.webserver.where_is(page)) - body = self.driver.find_element_by_css("body") + body = self.driver.find_element_by_css_selector("body") assert body.is_displayed() def test_implicit(self): @@ -194,86 +194,86 @@ class BodyElementIsAlwaysDisplayedTest(base_test.WebDriverBaseTest): class DisplayTest(base_test.WebDriverBaseTest): def test_display_block(self): self.driver.get(self.webserver.where_is("element_state/res/display-block.html")) - el = self.driver.find_element_by_css("p") + el = self.driver.find_element_by_css_selector("p") self.assertTrue(el.is_displayed()) def test_display_none(self): self.driver.get(self.webserver.where_is("element_state/res/display-none.html")) - el = self.driver.find_element_by_css("p") + el = self.driver.find_element_by_css_selector("p") self.assertFalse(el.is_displayed()) def test_display_none_hides_child_node(self): self.driver.get(self.webserver.where_is("element_state/res/display-none-child.html")) - parent = self.driver.find_element_by_css("#parent") - child = self.driver.find_element_by_css("#child") + parent = self.driver.find_element_by_css_selector("#parent") + child = self.driver.find_element_by_css_selector("#child") self.assertFalse(parent.is_displayed()) self.assertFalse(child.is_displayed()) def test_display_none_hides_child_node_link(self): self.driver.get(self.webserver.where_is("element_state/res/display-none-child-link.html")) - child = self.driver.find_element_by_css("#child") + child = self.driver.find_element_by_css_selector("#child") self.assertFalse(child.is_displayed()) def test_display_none_hides_child_node_paragraph(self): self.driver.get(self.webserver.where_is("element_state/res/display-none-child-paragraph.html")) - child = self.driver.find_element_by_css("#child") + child = self.driver.find_element_by_css_selector("#child") self.assertFalse(child.is_displayed()) def test_display_none_on_parent_takes_presedence(self): self.driver.get(self.webserver.where_is("element_state/res/display-none-parent-presedence.html")) - child = self.driver.find_element_by_css("#child") + child = self.driver.find_element_by_css_selector("#child") self.assertFalse(child.is_displayed()) def test_display_none_on_parent_takes_presedence_over_visibility_visible(self): self.driver.get(self.webserver.where_is("element_state/res/display-none-parent-presedence-visibility.html")) - child = self.driver.find_element_by_css("#child") + child = self.driver.find_element_by_css_selector("#child") self.assertFalse(child.is_displayed()) def test_display_none_hidden_dynamically(self): self.driver.get(self.webserver.where_is("element_state/res/display-none-dynamic.html")) - hidden = self.driver.find_element_by_css("#hidden") + hidden = self.driver.find_element_by_css_selector("#hidden") self.assertFalse(hidden.is_displayed()) class VisibilityTest(base_test.WebDriverBaseTest): def test_element_state_hidden(self): self.driver.get(self.webserver.where_is("element_state/res/visibility-hidden.html")) - el = self.driver.find_element_by_css("p") + el = self.driver.find_element_by_css_selector("p") self.assertFalse(el.is_displayed()) def test_element_state_visible(self): self.driver.get(self.webserver.where_is("element_state/res/visibility-visible.html")) - el = self.driver.find_element_by_css("p") + el = self.driver.find_element_by_css_selector("p") self.assertTrue(el.is_displayed()) def test_visibility_hidden_hides_child_node(self): self.driver.get(self.webserver.where_is("element_state/res/visibility-child.html")) - parent = self.driver.find_element_by_css("#parent") - child = self.driver.find_element_by_css("#child") + parent = self.driver.find_element_by_css_selector("#parent") + child = self.driver.find_element_by_css_selector("#child") self.assertFalse(parent.is_displayed()) self.assertFalse(child.is_displayed()) def test_visibility_hidden_hides_child_node_link(self): self.driver.get(self.webserver.where_is("element_state/res/visibility-child-link.html")) - parent = self.driver.find_element_by_css("#parent") - child = self.driver.find_element_by_css("#child") + parent = self.driver.find_element_by_css_selector("#parent") + child = self.driver.find_element_by_css_selector("#child") self.assertFalse(parent.is_displayed()) self.assertFalse(child.is_displayed()) def test_visibility_hidden_hides_child_node_paragraph(self): self.driver.get(self.webserver.where_is("element_state/res/visibility-child-paragraph.html")) - parent = self.driver.find_element_by_css("#parent") - child = self.driver.find_element_by_css("#child") + parent = self.driver.find_element_by_css_selector("#parent") + child = self.driver.find_element_by_css_selector("#child") self.assertFalse(parent.is_displayed()) self.assertFalse(child.is_displayed()) def test_visibility_hidden_on_child_takes_precedence(self): self.driver.get(self.webserver.where_is("element_state/res/visibility-child-presedence.html")) - child = self.driver.find_element_by_css("#child") + child = self.driver.find_element_by_css_selector("#child") self.assertTrue(child.is_displayed()) def test_visibility_hidden_on_parent_takes_precedence_over_display_block(self): @@ -284,33 +284,33 @@ class VisibilityTest(base_test.WebDriverBaseTest): def test_should_show_element_not_visible_with_hidden_attribute(self): self.driver.get(self.webserver.where_is("element_state/res/hidden.html")) - singleHidden = self.driver.find_element_by_css('#singleHidden') + singleHidden = self.driver.find_element_by_css_selector('#singleHidden') self.assertFalse(singleHidden.is_displayed()) def test_should_show_element_not_visible_when_parent_element_has_hidden_attribute(self): self.driver.get(self.webserver.where_is("element_state/res/hidden.html")) - child = self.driver.find_element_by_css('#child') + child = self.driver.find_element_by_css_selector('#child') self.assertFalse(child.is_displayed()) class VisibilityInteractionTest(base_test.WebDriverBaseTest): def test_input_hidden_is_unclickable(self): self.driver.get(self.webserver.where_is("element_state/res/input-type-hidden-unclickable.html")) - input = self.driver.find_element_by_css("input") + input = self.driver.find_element_by_css_selector("input") with self.assertRaises(exceptions.ElementNotVisibleException): input.click() def test_hidden_input_checkbox_is_untogglable(self): self.driver.get(self.webserver.where_is("element_state/res/hidden-input-type-checkbox-untogglable.html")) - checkbox = self.driver.find_element_by_css("input") + checkbox = self.driver.find_element_by_css_selector("input") with self.assertRaises(exceptions.ElementNotVisibleException): checkbox.click() def test_typing_in_hidden_input_is_impossible(self): self.driver.get(self.webserver.where_is("element_state/res/hidden-input-type-text-writing.html")) - textfield = self.driver.find_element_by_css("input") + textfield = self.driver.find_element_by_css_selector("input") with self.assertRaises(exceptions.ElementNotVisibleException): textfield.send_keys("Koha is a popular Indian cheese") diff --git a/tests/wpt/web-platform-tests/webdriver/javascript/execute_script_test.py b/tests/wpt/web-platform-tests/webdriver/javascript/execute_script_test.py index 72810a5fe04..dd7cfca946c 100644 --- a/tests/wpt/web-platform-tests/webdriver/javascript/execute_script_test.py +++ b/tests/wpt/web-platform-tests/webdriver/javascript/execute_script_test.py @@ -4,6 +4,7 @@ import unittest sys.path.insert(1, os.path.abspath(os.path.join(__file__, "../.."))) import base_test +from selenium.webdriver.remote.webelement import WebElement class ExecuteScriptTest(base_test.WebDriverBaseTest): diff --git a/tests/wpt/web-platform-tests/webdriver/modal/alerts_quit_test.py b/tests/wpt/web-platform-tests/webdriver/modal/alerts_quit_test.py index 2650a2dc678..83f7d145001 100644 --- a/tests/wpt/web-platform-tests/webdriver/modal/alerts_quit_test.py +++ b/tests/wpt/web-platform-tests/webdriver/modal/alerts_quit_test.py @@ -4,16 +4,17 @@ import unittest sys.path.insert(1, os.path.abspath(os.path.join(__file__, "../.."))) import base_test -from webdriver import exceptions, wait +from selenium.common import exceptions +from selenium.webdriver.support import wait class AlertsQuitTest(base_test.WebDriverBaseTest): def setUp(self): - self.wait = wait.WebDriverWait(self.driver, 5, ignored_exceptions=[exceptions.NoSuchAlertException]) + self.wait = wait.WebDriverWait(self.driver, 5, ignored_exceptions=[exceptions.NoAlertPresentException]) self.driver.get(self.webserver.where_is('modal/res/alerts.html')) def test_can_quit_when_an_alert_is_present(self): - self.driver.find_element_by_css('#alert').click() + self.driver.find_element_by_css_selector('#alert').click() alert = self.wait.until(lambda x: x.switch_to_alert()) self.driver.quit() with self.assertRaises(Exception): diff --git a/tests/wpt/web-platform-tests/webdriver/modal/alerts_test.py b/tests/wpt/web-platform-tests/webdriver/modal/alerts_test.py index d4182f6d07b..b982821cba2 100644 --- a/tests/wpt/web-platform-tests/webdriver/modal/alerts_test.py +++ b/tests/wpt/web-platform-tests/webdriver/modal/alerts_test.py @@ -4,144 +4,145 @@ import unittest sys.path.insert(1, os.path.abspath(os.path.join(__file__, "../.."))) import base_test -from webdriver import exceptions, wait - +from selenium.common import exceptions +from selenium.webdriver.support import wait class AlertsTest(base_test.WebDriverBaseTest): def setUp(self): - self.wait = wait.WebDriverWait(self.driver, 5, ignored_exceptions = [exceptions.NoSuchAlertException]) + self.wait = wait.WebDriverWait(self.driver, 5, ignored_exceptions = [exceptions.NoAlertPresentException]) self.driver.get(self.webserver.where_is('modal/res/alerts.html')) def tearDown(self): try: self.driver.switch_to_alert().dismiss() - except exceptions.NoSuchAlertException: + except exceptions.NoAlertPresentException: pass # Alerts def test_should_allow_user_to_accept_an_alert(self): - self.driver.find_element_by_css('#alert').click() + self.driver.find_element_by_css_selector('#alert').click() alert = self.wait.until(lambda x: x.switch_to_alert()) alert.accept() - self.driver.get_current_url() + self.driver.current_url def test_should_allow_user_to_accept_an_alert_with_no_text(self): - self.driver.find_element_by_css('#empty-alert').click() + self.driver.find_element_by_css_selector('#empty-alert').click() alert = self.wait.until(lambda x: x.switch_to_alert()) alert.accept() - self.driver.get_current_url() + self.driver.current_url def test_should_allow_user_to_dismiss_an_alert(self): - self.driver.find_element_by_css('#alert').click() + self.driver.find_element_by_css_selector('#alert').click() alert = self.wait.until(lambda x: x.switch_to_alert()) alert.dismiss() - self.driver.get_current_url() + self.driver.current_url def test_should_allow_user_to_get_text_of_an_alert(self): - self.driver.find_element_by_css('#alert').click() + self.driver.find_element_by_css_selector('#alert').click() alert = self.wait.until(lambda x: x.switch_to_alert()) - value = alert.get_text() + value = alert.text alert.accept() self.assertEquals('cheese', value) def test_setting_the_value_of_an_alert_throws(self): - self.driver.find_element_by_css('#alert').click() + self.driver.find_element_by_css_selector('#alert').click() alert = self.wait.until(lambda x: x.switch_to_alert()) with self.assertRaises(exceptions.ElementNotVisibleException): alert.send_keys('cheese') alert.accept() def test_alert_should_not_allow_additional_commands_if_dismissed(self): - self.driver.find_element_by_css('#alert').click() + self.driver.find_element_by_css_selector('#alert').click() alert = self.wait.until(lambda x: x.switch_to_alert()) alert.accept() - with self.assertRaises(exceptions.NoSuchAlertException): - alert.get_text() + with self.assertRaises(exceptions.NoAlertPresentException): + alert.text # Prompts def test_should_allow_user_to_accept_a_prompt(self): - self.driver.find_element_by_css('#prompt').click() + self.driver.find_element_by_css_selector('#prompt').click() alert = self.wait.until(lambda x: x.switch_to_alert()) alert.accept() - self.wait.until(lambda x: x.find_element_by_css('#text').text == '') + self.wait.until(lambda x: x.find_element_by_css_selector('#text').text == '') def test_should_allow_user_to_dismiss_a_prompt(self): - self.driver.find_element_by_css('#prompt').click() + self.driver.find_element_by_css_selector('#prompt').click() alert = self.wait.until(lambda x: x.switch_to_alert()) alert.dismiss() - self.wait.until(lambda x: x.find_element_by_css('#text').text == 'null') + self.wait.until(lambda x: x.find_element_by_css_selector('#text').text == 'null') def test_should_allow_user_to_set_the_value_of_a_prompt(self): - self.driver.find_element_by_css('#prompt').click() + self.driver.find_element_by_css_selector('#prompt').click() alert = self.wait.until(lambda x: x.switch_to_alert()) alert.send_keys('cheese') alert.accept() - self.wait.until(lambda x: x.find_element_by_css('#text').text == 'cheese') + self.wait.until(lambda x: x.find_element_by_css_selector('#text').text == 'cheese') def test_should_allow_user_to_get_text_of_a_prompt(self): - self.driver.find_element_by_css('#prompt').click() + self.driver.find_element_by_css_selector('#prompt').click() alert = self.wait.until(lambda x: x.switch_to_alert()) - value = alert.get_text() + value = alert.text alert.accept() self.assertEquals('Enter something', value) def test_prompt_should_not_allow_additional_commands_if_dismissed(self): - self.driver.find_element_by_css('#prompt').click() + self.driver.find_element_by_css_selector('#prompt').click() alert = self.wait.until(lambda x: x.switch_to_alert()) alert.accept() - with self.assertRaises(exceptions.NoSuchAlertException): - alert.get_text() + with self.assertRaises(exceptions.NoAlertPresentException): + alert.text def test_prompt_should_use_default_value_if_no_keys_sent(self): - self.driver.find_element_by_css('#prompt-with-default').click() + self.driver.find_element_by_css_selector('#prompt-with-default').click() alert = self.wait.until(lambda x: x.switch_to_alert()) alert.accept() - self.wait.until(lambda x: x.find_element_by_css('#text').text == 'This is a default value') + self.wait.until(lambda x: x.find_element_by_css_selector('#text').text == 'This is a default value') def test_prompt_should_have_null_value_if_dismissed(self): - self.driver.find_element_by_css('#prompt-with-default').click() + self.driver.find_element_by_css_selector('#prompt-with-default').click() alert = self.wait.until(lambda x: x.switch_to_alert()) alert.dismiss() - self.wait.until(lambda x: x.find_element_by_css('#text').text == 'null') + self.wait.until(lambda x: x.find_element_by_css_selector('#text').text == 'null') # Confirmations def test_should_allow_user_to_accept_a_confirm(self): - self.driver.find_element_by_css('#confirm').click() + self.driver.find_element_by_css_selector('#confirm').click() alert = self.wait.until(lambda x: x.switch_to_alert()) alert.accept() - self.wait.until(lambda x: x.find_element_by_css('#text').text == 'true') + self.wait.until(lambda x: x.find_element_by_css_selector('#text').text == 'true') def test_should_allow_user_to_dismiss_a_confirm(self): - self.driver.find_element_by_css('#confirm').click() + self.driver.find_element_by_css_selector('#confirm').click() alert = self.wait.until(lambda x: x.switch_to_alert()) alert.dismiss() - self.wait.until(lambda x: x.find_element_by_css('#text').text == 'false') + self.wait.until(lambda x: x.find_element_by_css_selector('#text').text == 'false') def test_setting_the_value_of_a_confirm_throws(self): - self.driver.find_element_by_css('#confirm').click() + self.driver.find_element_by_css_selector('#confirm').click() alert = self.wait.until(lambda x: x.switch_to_alert()) with self.assertRaises(exceptions.ElementNotVisibleException): alert.send_keys('cheese') alert.accept() def test_should_allow_user_to_get_text_of_a_confirm(self): - self.driver.find_element_by_css('#confirm').click() + self.driver.find_element_by_css_selector('#confirm').click() alert = self.wait.until(lambda x: x.switch_to_alert()) - value = alert.get_text() + value = alert.text alert.accept() self.assertEquals('cheese', value) def test_confirm_should_not_allow_additional_commands_if_dismissed(self): - self.driver.find_element_by_css('#confirm').click() + self.driver.find_element_by_css_selector('#confirm').click() alert = self.wait.until(lambda x: x.switch_to_alert()) alert.accept() - with self.assertRaises(exceptions.NoSuchAlertException): - alert.get_text() + with self.assertRaises(exceptions.NoAlertPresentException): + alert.text +""" def test_switch_to_missing_alert_fails(self): - with self.assertRaises(exceptions.NoSuchAlertException): + with self.assertRaises(exceptions.NoAlertPresentException): self.driver.switch_to_alert() - +""" if __name__ == '__main__': unittest.main() diff --git a/tests/wpt/web-platform-tests/webdriver/navigation/auth_tests.py b/tests/wpt/web-platform-tests/webdriver/navigation/auth_tests.py index 068e44fe9f6..266c76e16ff 100644 --- a/tests/wpt/web-platform-tests/webdriver/navigation/auth_tests.py +++ b/tests/wpt/web-platform-tests/webdriver/navigation/auth_tests.py @@ -5,7 +5,7 @@ import ConfigParser sys.path.insert(1, os.path.abspath(os.path.join(__file__, "../.."))) import base_test -from webdriver import exceptions +from selenium.common import exceptions from wptserve import server from wptserve.router import any_method from wptserve.handlers import basic_auth_handler diff --git a/tests/wpt/web-platform-tests/webdriver/navigation/forward.py b/tests/wpt/web-platform-tests/webdriver/navigation/forward.py index 6cc77c2a458..67ca83227bf 100644 --- a/tests/wpt/web-platform-tests/webdriver/navigation/forward.py +++ b/tests/wpt/web-platform-tests/webdriver/navigation/forward.py @@ -11,12 +11,12 @@ class ForwardTest(base_test.WebDriverBaseTest): def test_forward(self): self.driver.get(self.webserver.where_is('navigation/res/forwardStart.html')) self.driver.get(self.webserver.where_is('navigation/res/forwardNext.html')) - nextbody = self.driver.find_element_by_css("body").text - self.driver.go_back() - currbody = self.driver.find_element_by_css("body").text + nextbody = self.driver.find_element_by_css_selector("body").text + self.driver.back() + currbody = self.driver.find_element_by_css_selector("body").text self.assertNotEqual(nextbody, currbody) - self.driver.go_forward() - currbody = self.driver.find_element_by_css("body").text + self.driver.forward() + currbody = self.driver.find_element_by_css_selector("body").text self.assertEqual(nextbody, currbody) diff --git a/tests/wpt/web-platform-tests/webdriver/navigation/forwardToNothing.py b/tests/wpt/web-platform-tests/webdriver/navigation/forwardToNothing.py index 057fb9c5828..99759681a0d 100644 --- a/tests/wpt/web-platform-tests/webdriver/navigation/forwardToNothing.py +++ b/tests/wpt/web-platform-tests/webdriver/navigation/forwardToNothing.py @@ -10,9 +10,9 @@ class ForwardToNothingTest(base_test.WebDriverBaseTest): # Get a static page that must be the same upon refresh def test_forwardToNothing(self): self.driver.get(self.webserver.where_is('navigation/forwardStart.html')) - body = self.driver.find_element_by_css("body").text - self.driver.go_forward() - currbody = self.driver.find_element_by_css("body").text + body = self.driver.find_element_by_css_selector("body").text + self.driver.forward() + currbody = self.driver.find_element_by_css_selector("body").text self.assertEqual(body, currbody) diff --git a/tests/wpt/web-platform-tests/webdriver/navigation/get_from_http_test.py b/tests/wpt/web-platform-tests/webdriver/navigation/get_from_http_test.py index 714e65f2b4d..d28a0d0b142 100644 --- a/tests/wpt/web-platform-tests/webdriver/navigation/get_from_http_test.py +++ b/tests/wpt/web-platform-tests/webdriver/navigation/get_from_http_test.py @@ -10,7 +10,7 @@ class GetFromHttpTest(base_test.WebDriverBaseTest): def testGetUrlWithNoRedirectionOverHttp(self): page = self.webserver.where_is('navigation/res/empty.html') self.driver.get(page) - url = self.driver.get_current_url() + url = self.driver.current_url self.assertEquals(page, url) @@ -18,7 +18,7 @@ class GetFromHttpTest(base_test.WebDriverBaseTest): page = self.webserver.where_is('navigation/redirect') self.driver.get(page) expected = self.webserver.where_is('navigation/res/empty.html') - url = self.driver.get_current_url() + url = self.driver.current_url self.assertEquals(expected, url) @@ -26,7 +26,7 @@ class GetFromHttpTest(base_test.WebDriverBaseTest): page = self.webserver.where_is('navigation/res/instant-meta-redirect.html') self.driver.get(page) expected = self.webserver.where_is('navigation/res/empty.html') - url = self.driver.get_current_url() + url = self.driver.current_url self.assertEquals(expected, url) @@ -34,14 +34,14 @@ class GetFromHttpTest(base_test.WebDriverBaseTest): page = self.webserver.where_is('navigation/res/1s-meta-redirect.html') self.driver.get(page) expected = self.webserver.where_is('navigation/res/empty.html') - url = self.driver.get_current_url() + url = self.driver.current_url self.assertEquals(expected, url) def testGetWillNotFollowMetaRefreshThatRefreshesAfterMoreThanOneSecond(self): page = self.webserver.where_is('navigation/res/60s-meta-redirect.html') self.driver.get(page) - url = self.driver.get_current_url() + url = self.driver.current_url self.assertEquals(page, url) diff --git a/tests/wpt/web-platform-tests/webdriver/navigation/invalid_cert_test.py b/tests/wpt/web-platform-tests/webdriver/navigation/invalid_cert_test.py index 5f84827966d..b980146ee2c 100644 --- a/tests/wpt/web-platform-tests/webdriver/navigation/invalid_cert_test.py +++ b/tests/wpt/web-platform-tests/webdriver/navigation/invalid_cert_test.py @@ -21,7 +21,7 @@ class InvalidCertTest(base_test.WebDriverBaseTest): 'navigation/res/empty.html').replace('http:', 'https:', 1) self.driver.get(expected) - self.assertEquals(expected, self.driver.get_current_url()) + self.assertEquals(expected, self.driver.current_url) if __name__ == '__main__': diff --git a/tests/wpt/web-platform-tests/webdriver/navigation/refresh_page.py b/tests/wpt/web-platform-tests/webdriver/navigation/refresh_page.py new file mode 100644 index 00000000000..1e1899008b0 --- /dev/null +++ b/tests/wpt/web-platform-tests/webdriver/navigation/refresh_page.py @@ -0,0 +1,27 @@ +import os +import sys +import unittest + +sys.path.insert(1, os.path.abspath(os.path.join(__file__, "../.."))) +import base_test + + +class RefreshPageTest(base_test.WebDriverBaseTest): + # Get a static page that must be the same upon refresh + def test_refreshPage(self): + self.driver.get(self.webserver.where_is('navigation/res/refreshPageStatic.html')) + body = self.driver.find_element_by_css_selector("body").text + self.driver.execute_script("document.getElementById('body').innerHTML=''") + self.driver.refresh() + newbody = self.driver.find_element_by_css_selector("body").text + self.assertEqual(body, newbody) + + self.driver.get(self.webserver.where_is('navigation/res/refreshPageDynamic.html')) + body = self.driver.find_element_by_css_selector("body").text + self.driver.refresh() + newbody = self.driver.find_element_by_css_selector("body").text + self.assertNotEqual(body, newbody) + + +if __name__ == '__main__': + unittest.main() diff --git a/tests/wpt/web-platform-tests/webdriver/runtests_p0.py b/tests/wpt/web-platform-tests/webdriver/runtests_p0.py new file mode 100644 index 00000000000..dc52c14be63 --- /dev/null +++ b/tests/wpt/web-platform-tests/webdriver/runtests_p0.py @@ -0,0 +1,42 @@ +import unittest + +from unittest import TestLoader, TextTestRunner, TestSuite + +from cookie import cookie_test +from navigation import forward +from navigation import forwardToNothing +from navigation import get_from_http_test +from navigation import refresh_page +from element_location import element_location_test +from element_state import visibility_test +from element_state import method_test +from element_state import properties +from javascript import execute_script_test +from user_input import clear_test +from windows import window_manipulation +from windows import tabbing + + + +if __name__ == "__main__": + + loader = TestLoader() + suite = TestSuite(( + loader.loadTestsFromModule(cookie_test), + loader.loadTestsFromModule(forward), + loader.loadTestsFromModule(forwardToNothing), + loader.loadTestsFromModule(element_location_test), + loader.loadTestsFromModule(visibility_test), + loader.loadTestsFromModule(execute_script_test), + loader.loadTestsFromModule(clear_test), + loader.loadTestsFromModule(method_test), + loader.loadTestsFromModule(properties), + loader.loadTestsFromModule(refresh_page), + loader.loadTestsFromModule(get_from_http_test), + loader.loadTestsFromModule(window_manipulation), + loader.loadTestsFromModule(tabbing) + )) + + runner = TextTestRunner(verbosity=2) + runner.run(suite) + unittest.main() diff --git a/tests/wpt/web-platform-tests/webdriver/screenshot/__init__.py b/tests/wpt/web-platform-tests/webdriver/screenshot/__init__.py new file mode 100644 index 00000000000..0c8107bebed --- /dev/null +++ b/tests/wpt/web-platform-tests/webdriver/screenshot/__init__.py @@ -0,0 +1 @@ +__author__ = 'b-redeg' diff --git a/tests/wpt/web-platform-tests/webdriver/screenshot/res/screenshot.html b/tests/wpt/web-platform-tests/webdriver/screenshot/res/screenshot.html new file mode 100644 index 00000000000..057bb9bf5f8 --- /dev/null +++ b/tests/wpt/web-platform-tests/webdriver/screenshot/res/screenshot.html @@ -0,0 +1,5 @@ +<!DOCTYPE html> +<meta charset="utf-8" /> +<title>"img" element with not fully qualified url</title> + +<img src="//web-platform.test:8000/images/blue.png">&nbsp;</a> \ No newline at end of file diff --git a/tests/wpt/web-platform-tests/webdriver/screenshot/take_screenshot.py b/tests/wpt/web-platform-tests/webdriver/screenshot/take_screenshot.py new file mode 100644 index 00000000000..20ff2bff2ae --- /dev/null +++ b/tests/wpt/web-platform-tests/webdriver/screenshot/take_screenshot.py @@ -0,0 +1,15 @@ +import os +import sys +import unittest + +sys.path.insert(1, os.path.abspath(os.path.join(__file__, "../.."))) +import base_test + + +class ScreenShotTest(base_test.WebDriverBaseTest): + # Get a static page that must be the same upon refresh + def test_screenShot(self): + self.driver.get(self.webserver.where_is('screenshot/res/screen.html')) + +if __name__ == '__main__': + unittest.main() diff --git a/tests/wpt/web-platform-tests/webdriver/timeouts/implicit_waits_tests.py b/tests/wpt/web-platform-tests/webdriver/timeouts/implicit_waits_tests.py index e39723c50c1..5faa0ad122d 100644 --- a/tests/wpt/web-platform-tests/webdriver/timeouts/implicit_waits_tests.py +++ b/tests/wpt/web-platform-tests/webdriver/timeouts/implicit_waits_tests.py @@ -4,7 +4,7 @@ import unittest sys.path.insert(1, os.path.abspath(os.path.join(__file__, "../.."))) import base_test -from webdriver import exceptions +from selenium.common import exceptions class ImplicitWaitsTests(base_test.WebDriverBaseTest): @@ -12,15 +12,15 @@ class ImplicitWaitsTests(base_test.WebDriverBaseTest): self.driver.get(self.webserver.where_is('timeouts/res/implicit_waits_tests.html')) def test_find_element_by_id(self): - add = self.driver.find_element_by_css("#adder") - self.driver.set_implicit_timeout(3) + add = self.driver.find_element_by_css_selector("#adder") + self.driver.implicitly_wait(3) add.click() - self.driver.find_element_by_css("#box0") # All is well if this doesn't throw. + self.driver.find_element_by_css_selector("#box0") # All is well if this doesn't throw. def test_should_still_fail_to_find_an_element_when_implicit_waits_are_enabled(self): - self.driver.set_implicit_timeout(0.5) + self.driver.implicitly_wait(0.5) try: - self.driver.find_element_by_css("#box0") + self.driver.find_element_by_css_selector("#box0") self.fail("Expected NoSuchElementException to have been thrown") except exceptions.NoSuchElementException as e: pass @@ -28,10 +28,10 @@ class ImplicitWaitsTests(base_test.WebDriverBaseTest): self.fail("Expected NoSuchElementException but got " + str(e)) def test_should_return_after_first_attempt_to_find_one_after_disabling_implicit_waits(self): - self.driver.set_implicit_timeout(3) - self.driver.set_implicit_timeout(0) + self.driver.implicitly_wait(3) + self.driver.implicitly_wait(0) try: - self.driver.find_element_by_css("#box0") + self.driver.find_element_by_css_selector("#box0") self.fail("Expected NoSuchElementException to have been thrown") except exceptions.NoSuchElementException as e: pass @@ -39,24 +39,24 @@ class ImplicitWaitsTests(base_test.WebDriverBaseTest): self.fail("Expected NoSuchElementException but got " + str(e)) def test_should_implicitly_wait_until_at_least_one_element_is_found_when_searching_for_many(self): - add = self.driver.find_element_by_css("#adder") - self.driver.set_implicit_timeout(2) + add = self.driver.find_element_by_css_selector("#adder") + self.driver.implicitly_wait(2) add.click() add.click() - elements = self.driver.find_elements_by_css(".redbox") + elements = self.driver.find_elements_by_css_selector(".redbox") self.assertTrue(len(elements) >= 1) def test_should_still_fail_to_find_an_element_by_class_when_implicit_waits_are_enabled(self): - self.driver.set_implicit_timeout(0.5) - elements = self.driver.find_elements_by_css(".redbox") + self.driver.implicitly_wait(0.5) + elements = self.driver.find_elements_by_css_selector(".redbox") self.assertEqual(0, len(elements)) def test_should_return_after_first_attempt_to_find_many_after_disabling_implicit_waits(self): - add = self.driver.find_element_by_css("#adder") - self.driver.set_implicit_timeout(1.1) - self.driver.set_implicit_timeout(0) + add = self.driver.find_element_by_css_selector("#adder") + self.driver.implicitly_wait(1.1) + self.driver.implicitly_wait(0) add.click() - elements = self.driver.find_elements_by_css(".redbox") + elements = self.driver.find_elements_by_css_selector(".redbox") self.assertEqual(0, len(elements)) diff --git a/tests/wpt/web-platform-tests/webdriver/timeouts/page_load_timeouts_tests.py b/tests/wpt/web-platform-tests/webdriver/timeouts/page_load_timeouts_tests.py index 6d8693f6c2e..2f0d3beebaa 100644 --- a/tests/wpt/web-platform-tests/webdriver/timeouts/page_load_timeouts_tests.py +++ b/tests/wpt/web-platform-tests/webdriver/timeouts/page_load_timeouts_tests.py @@ -4,7 +4,7 @@ import unittest sys.path.insert(1, os.path.abspath(os.path.join(__file__, "../.."))) import base_test -from webdriver import exceptions +from selenium.common import exceptions class PageLoadTimeoutTest(base_test.WebDriverBaseTest): diff --git a/tests/wpt/web-platform-tests/webdriver/user_input/clear_test.py b/tests/wpt/web-platform-tests/webdriver/user_input/clear_test.py index 5375725128b..34e82e15999 100644 --- a/tests/wpt/web-platform-tests/webdriver/user_input/clear_test.py +++ b/tests/wpt/web-platform-tests/webdriver/user_input/clear_test.py @@ -6,45 +6,45 @@ import unittest sys.path.insert(1, os.path.abspath(os.path.join(__file__, "../.."))) import base_test -from webdriver import exceptions +from selenium.common import exceptions class ElementClearTest(base_test.WebDriverBaseTest): def test_writable_text_input_element_should_clear(self): self.driver.get(self.webserver.where_is("user_input/res/element_clear_writable_input_page.html")) - e = self.driver.find_element_by_css("#writableTextInput") + e = self.driver.find_element_by_css_selector("#writableTextInput") e.clear() self.assertEquals("", e.get_attribute("value")) def test_disabled_text_input_element_should_not_clear(self): self.driver.get(self.webserver.where_is("user_input/res/element_clear_disabled_input_page.html")) - e = self.driver.find_element_by_css("#disabledTextInput") + e = self.driver.find_element_by_css_selector("#disabledTextInput") self.assertRaises(exceptions.InvalidElementStateException, lambda: e.clear()) def test_read_only_text_input_element_should_not_clear(self): self.driver.get(self.webserver.where_is("user_input/res/element_clear_readonly_input_page.html")) - e = self.driver.find_element_by_css("#readOnlyTextInput") + e = self.driver.find_element_by_css_selector("#readOnlyTextInput") self.assertRaises(exceptions.InvalidElementStateException, lambda: e.clear()) def test_writable_text_area_element_should_clear(self): self.driver.get(self.webserver.where_is("user_input/res/element_clear_writable_textarea_page.html")) - e = self.driver.find_element_by_css("#writableTextArea") + e = self.driver.find_element_by_css_selector("#writableTextArea") e.clear() self.assertEquals("", e.get_attribute("value")) def test_disabled_text_area_element_should_not_clear(self): self.driver.get(self.webserver.where_is("user_input/res/element_clear_disabled_textarea_page.html")) - e = self.driver.find_element_by_css("#disabledTextArea") + e = self.driver.find_element_by_css_selector("#disabledTextArea") self.assertRaises(exceptions.InvalidElementStateException, lambda: e.clear()) def test_read_only_text_input_element_should_not_clear(self): self.driver.get(self.webserver.where_is("user_input/res/element_clear_readonly_textarea_page.html")) - e = self.driver.find_element_by_css("#readOnlyTextArea") + e = self.driver.find_element_by_css_selector("#readOnlyTextArea") self.assertRaises(exceptions.InvalidElementStateException, lambda: e.clear()) def test_content_editable_area_should_clear(self): self.driver.get(self.webserver.where_is("user_input/res/element_clear_contenteditable_page.html")) - e = self.driver.find_element_by_css("#contentEditableElement") + e = self.driver.find_element_by_css_selector("#contentEditableElement") e.clear() self.assertEquals("", e.text) diff --git a/tests/wpt/web-platform-tests/webdriver/webdriver.cfg b/tests/wpt/web-platform-tests/webdriver/webdriver.cfg index 98ecde7bd7c..cb74f56ceaa 100644 --- a/tests/wpt/web-platform-tests/webdriver/webdriver.cfg +++ b/tests/wpt/web-platform-tests/webdriver/webdriver.cfg @@ -21,6 +21,10 @@ mode: compatibility capabilities: {"browserName": "ie"} mode: compatibility +[edge] +capabilities: {"browserName": "edge"} +mode: compatibility + [ios-driver] capabilities: {"browserName": "iphone"} mode: compatibility diff --git a/tests/wpt/web-platform-tests/webdriver/windows/__init__.py b/tests/wpt/web-platform-tests/webdriver/windows/__init__.py new file mode 100644 index 00000000000..0c8107bebed --- /dev/null +++ b/tests/wpt/web-platform-tests/webdriver/windows/__init__.py @@ -0,0 +1 @@ +__author__ = 'b-redeg' diff --git a/tests/wpt/web-platform-tests/webdriver/windows/res/win1.html b/tests/wpt/web-platform-tests/webdriver/windows/res/win1.html new file mode 100644 index 00000000000..b8bf7e80b5b --- /dev/null +++ b/tests/wpt/web-platform-tests/webdriver/windows/res/win1.html @@ -0,0 +1,5 @@ +<!DOCTYPE html> +<meta charset="utf-8" /> +<title>window one</title> + +<div onclick="window.open('win2.html')">win2</div> \ No newline at end of file diff --git a/tests/wpt/web-platform-tests/webdriver/windows/res/win2.html b/tests/wpt/web-platform-tests/webdriver/windows/res/win2.html new file mode 100644 index 00000000000..81a068fa888 --- /dev/null +++ b/tests/wpt/web-platform-tests/webdriver/windows/res/win2.html @@ -0,0 +1,5 @@ +<!DOCTYPE html> +<meta charset="utf-8" /> +<title>window two</title> + +<img src="//web-platform.test:8000/images/blue.png">&nbsp;</a> \ No newline at end of file diff --git a/tests/wpt/web-platform-tests/webdriver/windows/res/win3.html b/tests/wpt/web-platform-tests/webdriver/windows/res/win3.html new file mode 100644 index 00000000000..d3ee6944b57 --- /dev/null +++ b/tests/wpt/web-platform-tests/webdriver/windows/res/win3.html @@ -0,0 +1,5 @@ +<!DOCTYPE html> +<meta charset="utf-8" /> +<title>window three</title> + +<img src="//web-platform.test:8000/images/blue.png">&nbsp;</a> \ No newline at end of file diff --git a/tests/wpt/web-platform-tests/webdriver/windows/res/win4.html b/tests/wpt/web-platform-tests/webdriver/windows/res/win4.html new file mode 100644 index 00000000000..ef35f761769 --- /dev/null +++ b/tests/wpt/web-platform-tests/webdriver/windows/res/win4.html @@ -0,0 +1,5 @@ +<!DOCTYPE html> +<meta charset="utf-8" /> +<title>window four</title> + +<img src="//web-platform.test:8000/images/blue.png">&nbsp;</a> \ No newline at end of file diff --git a/tests/wpt/web-platform-tests/webdriver/windows/res/win5.html b/tests/wpt/web-platform-tests/webdriver/windows/res/win5.html new file mode 100644 index 00000000000..673d2a19a1f --- /dev/null +++ b/tests/wpt/web-platform-tests/webdriver/windows/res/win5.html @@ -0,0 +1,5 @@ +<!DOCTYPE html> +<meta charset="utf-8" /> +<title>window five</title> + +<img src="//web-platform.test:8000/images/blue.png">&nbsp;</a> \ No newline at end of file diff --git a/tests/wpt/web-platform-tests/webdriver/windows/tabbing.py b/tests/wpt/web-platform-tests/webdriver/windows/tabbing.py new file mode 100644 index 00000000000..a6b5f99bf37 --- /dev/null +++ b/tests/wpt/web-platform-tests/webdriver/windows/tabbing.py @@ -0,0 +1,30 @@ +# -*- mode: python; fill-column: 100; comment-column: 100; -*- + +import os +import sys +import unittest +import time + +sys.path.insert(1, os.path.abspath(os.path.join(__file__, "../.."))) +import base_test +from selenium.common import exceptions +from selenium.webdriver.common.keys import Keys +from selenium.webdriver.common.action_chains import ActionChains + + +class tabbingTest(base_test.WebDriverBaseTest): + def test_open_close_tab(self): + self.driver.get(self.webserver.where_is("windows/res/win1.html")) + self.driver.find_element_by_tag_name("div").click() + h = self.driver.window_handles + self.assertEquals(2, len(h)) + self.driver.switch_to.window(h[1]) + try: + self.driver.switch_to.window("does not exist") + self.fail("NoSuchWindowException expected") + except exceptions.NoSuchWindowException: + pass + self.driver.close() + +if __name__ == "__main__": + unittest.main() diff --git a/tests/wpt/web-platform-tests/webdriver/windows/window_manipulation.py b/tests/wpt/web-platform-tests/webdriver/windows/window_manipulation.py new file mode 100644 index 00000000000..02771672776 --- /dev/null +++ b/tests/wpt/web-platform-tests/webdriver/windows/window_manipulation.py @@ -0,0 +1,43 @@ +# -*- mode: python; fill-column: 100; comment-column: 100; -*- + +import os +import sys +import unittest + +sys.path.insert(1, os.path.abspath(os.path.join(__file__, "../.."))) +import base_test +from selenium.common import exceptions + + +class WindowingTest(base_test.WebDriverBaseTest): + def test_maximize(self): + #self.driver.get(self.webserver.where_is("windows/res/win1.html")) + self.driver.maximize_window() + + def test_window_size_manipulation(self): + #self.driver.get(self.webserver.where_is("windows/res/win1.html")) + self.driver.set_window_size(400, 400) + window_size = self.driver.get_window_size() + self.assertTrue("width" in window_size) + self.assertTrue("height" in window_size) + self.assertEquals({"width": 400, "height":400}, window_size) + + """ + todo: make that work + see: https://w3c.github.io/webdriver/webdriver-spec.html#setwindowsize + result = self.driver.set_window_size(100, 100) + self.assertTrue("status" in result) + self.assertEquals(result["status"], 500) + """ + + def test_window_position_manipulation(self): + #self.driver.get(self.webserver.where_is("windows/res/win1.html")) + self.driver.set_window_position(400, 400) + window_position = self.driver.get_window_position() + self.assertTrue("x" in window_position) + self.assertTrue("y" in window_position) + self.assertEquals({"x": 400, "y": 400}, window_position) + + +if __name__ == "__main__": + unittest.main() From 5450053b026bb842a00824ab0be1211ba0288540 Mon Sep 17 00:00:00 2001 From: Ms2ger <Ms2ger@gmail.com> Date: Sat, 31 Oct 2015 14:35:08 +0100 Subject: [PATCH 34/58] Update CSS tests to revision d13905941293af83ea8c3c1750dba652e0423fb0 --- .../css-break-3_dev/html/chapter-1.htm | 57 + .../css-break-3_dev/html/chapter-2.htm | 131 + .../css-break-3_dev/html/chapter-3.htm | 153 + .../css-break-3_dev/html/chapter-4.htm | 141 + .../css-break-3_dev/html/chapter-5.htm | 183 + .../css-break-3_dev/html/chapter-6.htm | 159 + .../html/floats-clear-breaks-002.htm | 86 + .../html/floats-in-named-flow-012.htm | 83 + .../html/floats-in-named-flow-029.htm | 90 + .../html/floats-in-named-flow-030.htm | 88 + .../html/position-relative-001.htm | 77 + .../reference/floats-clear-breaks-002-ref.htm | 59 + .../floats-in-named-flow-012-ref.htm | 69 + .../floats-in-named-flow-029-ref.htm | 67 + .../floats-in-named-flow-030-ref.htm | 68 + .../reference/position-relative-001-ref.htm | 56 + .../reference/regions-transforms-008-ref.htm | 35 + .../regions-transforms-013-alt-ref.htm | 20 + .../reference/regions-transforms-013-ref.htm | 21 + .../reference/regions-transforms-020-ref.htm | 21 + .../css-break-3_dev/html/reftest-toc.htm | 121 + .../css-break-3_dev/html/reftest.list | 13 + .../html/regions-transforms-008.htm | 74 + .../html/regions-transforms-009.htm | 74 + .../html/regions-transforms-013.htm | 47 + .../html/regions-transforms-020.htm | 61 + .../html/regions-transforms-021.htm | 53 + .../html/regions-transforms-022.htm | 83 + .../css-tests/css-break-3_dev/html/toc.htm | 54 + .../implementation-report-TEMPLATE.data | 27 + tests/wpt/css-tests/css-break-3_dev/index.htm | 140 + tests/wpt/css-tests/css-break-3_dev/index.xht | 140 + .../wpt/css-tests/css-break-3_dev/indices.css | 96 + .../css-tests/css-break-3_dev/testinfo.data | 12 + .../css-break-3_dev/xhtml1/chapter-1.xht | 57 + .../css-break-3_dev/xhtml1/chapter-2.xht | 131 + .../css-break-3_dev/xhtml1/chapter-3.xht | 153 + .../css-break-3_dev/xhtml1/chapter-4.xht | 141 + .../css-break-3_dev/xhtml1/chapter-5.xht | 183 + .../css-break-3_dev/xhtml1/chapter-6.xht | 159 + .../xhtml1/floats-clear-breaks-002.xht | 86 + .../xhtml1/floats-in-named-flow-012.xht | 83 + .../xhtml1/floats-in-named-flow-029.xht | 90 + .../xhtml1/floats-in-named-flow-030.xht | 88 + .../xhtml1/position-relative-001.xht | 77 + .../reference/floats-clear-breaks-002-ref.xht | 59 + .../floats-in-named-flow-012-ref.xht | 69 + .../floats-in-named-flow-029-ref.xht | 67 + .../floats-in-named-flow-030-ref.xht | 68 + .../reference/position-relative-001-ref.xht | 56 + .../reference/regions-transforms-008-ref.xht | 35 + .../regions-transforms-013-alt-ref.xht | 20 + .../reference/regions-transforms-013-ref.xht | 21 + .../reference/regions-transforms-020-ref.xht | 21 + .../css-break-3_dev/xhtml1/reftest-toc.xht | 121 + .../css-break-3_dev/xhtml1/reftest.list | 13 + .../xhtml1/regions-transforms-008.xht | 74 + .../xhtml1/regions-transforms-009.xht | 74 + .../xhtml1/regions-transforms-013.xht | 47 + .../xhtml1/regions-transforms-020.xht | 61 + .../xhtml1/regions-transforms-021.xht | 53 + .../xhtml1/regions-transforms-022.xht | 83 + .../css-tests/css-break-3_dev/xhtml1/toc.xht | 54 + .../css-break-3_dev/xhtml1print/chapter-1.xht | 57 + .../css-break-3_dev/xhtml1print/chapter-2.xht | 131 + .../css-break-3_dev/xhtml1print/chapter-3.xht | 153 + .../css-break-3_dev/xhtml1print/chapter-4.xht | 141 + .../css-break-3_dev/xhtml1print/chapter-5.xht | 183 + .../css-break-3_dev/xhtml1print/chapter-6.xht | 159 + .../xhtml1print/floats-clear-breaks-002.xht | 86 + .../xhtml1print/floats-in-named-flow-012.xht | 83 + .../xhtml1print/floats-in-named-flow-029.xht | 90 + .../xhtml1print/floats-in-named-flow-030.xht | 88 + .../xhtml1print/position-relative-001.xht | 77 + .../reference/floats-clear-breaks-002-ref.xht | 59 + .../floats-in-named-flow-012-ref.xht | 69 + .../floats-in-named-flow-029-ref.xht | 67 + .../floats-in-named-flow-030-ref.xht | 68 + .../reference/position-relative-001-ref.xht | 56 + .../reference/regions-transforms-008-ref.xht | 35 + .../regions-transforms-013-alt-ref.xht | 20 + .../reference/regions-transforms-013-ref.xht | 21 + .../reference/regions-transforms-020-ref.xht | 21 + .../xhtml1print/reftest-toc.xht | 121 + .../css-break-3_dev/xhtml1print/reftest.list | 13 + .../xhtml1print/regions-transforms-008.xht | 74 + .../xhtml1print/regions-transforms-009.xht | 74 + .../xhtml1print/regions-transforms-013.xht | 47 + .../xhtml1print/regions-transforms-020.xht | 61 + .../xhtml1print/regions-transforms-021.xht | 53 + .../xhtml1print/regions-transforms-022.xht | 83 + .../css-break-3_dev/xhtml1print/toc.xht | 54 + .../html/css3-counter-styles-016a.htm | 4 +- .../implementation-report-TEMPLATE.data | 4 +- .../css-counter-styles-3_dev/testinfo.data | 2 +- .../xhtml1/css3-counter-styles-016a.xht | 4 +- .../xhtml1print/css3-counter-styles-016a.xht | 4 +- tests/wpt/css-tests/css-gcpm-3_dev/index.htm | 4 +- tests/wpt/css-tests/css-gcpm-3_dev/index.xht | 4 +- .../css-namespaces-3_dev/html/chapter-1.htm | 39 + .../css-namespaces-3_dev/html/chapter-2.htm | 51 + .../css-namespaces-3_dev/html/chapter-3.htm | 66 + .../css-namespaces-3_dev/html/chapter-4.htm | 90 + .../css-namespaces-3_dev/html/reftest-toc.htm | 30 + .../css-namespaces-3_dev/html/reftest.list | 1 + .../css-namespaces-3_dev/html/toc.htm | 44 + .../implementation-report-TEMPLATE.data | 5 + .../css-tests/css-namespaces-3_dev/index.htm | 130 + .../css-tests/css-namespaces-3_dev/index.xht | 130 + .../css-namespaces-3_dev/indices.css | 96 + .../css-namespaces-3_dev/testinfo.data | 1 + .../css-namespaces-3_dev/xhtml1/chapter-1.xht | 39 + .../css-namespaces-3_dev/xhtml1/chapter-2.xht | 51 + .../css-namespaces-3_dev/xhtml1/chapter-3.xht | 66 + .../css-namespaces-3_dev/xhtml1/chapter-4.xht | 90 + .../xhtml1/reftest-toc.xht | 30 + .../css-namespaces-3_dev/xhtml1/reftest.list | 1 + .../css-namespaces-3_dev/xhtml1/toc.xht | 44 + .../css-pseudo-4_dev/html/chapter-1.htm | 39 + .../css-pseudo-4_dev/html/chapter-2.htm | 126 + .../css-pseudo-4_dev/html/chapter-3.htm | 111 + .../css-pseudo-4_dev/html/chapter-4.htm | 66 + .../css-pseudo-4_dev/html/chapter-5.htm | 42 + .../css-pseudo-4_dev/html/chapter-6.htm | 222 + .../html/first-letter-001.htm | 33 + .../html/first-letter-002.htm | 35 + .../html/first-letter-003.htm | 35 + .../html/reference/first-letter-001-ref.htm | 25 + .../css-pseudo-4_dev/html/reftest-toc.htm | 54 + .../css-pseudo-4_dev/html/reftest.list | 4 + .../css-tests/css-pseudo-4_dev/html/toc.htm | 54 + .../implementation-report-TEMPLATE.data | 11 + .../wpt/css-tests/css-pseudo-4_dev/index.htm | 138 + .../wpt/css-tests/css-pseudo-4_dev/index.xht | 138 + .../css-tests/css-pseudo-4_dev/indices.css | 96 + .../css-tests/css-pseudo-4_dev/testinfo.data | 4 + .../css-pseudo-4_dev/xhtml1/chapter-1.xht | 39 + .../css-pseudo-4_dev/xhtml1/chapter-2.xht | 126 + .../css-pseudo-4_dev/xhtml1/chapter-3.xht | 111 + .../css-pseudo-4_dev/xhtml1/chapter-4.xht | 66 + .../css-pseudo-4_dev/xhtml1/chapter-5.xht | 42 + .../css-pseudo-4_dev/xhtml1/chapter-6.xht | 222 + .../xhtml1/first-letter-001.xht | 33 + .../xhtml1/first-letter-002.xht | 35 + .../xhtml1/first-letter-003.xht | 35 + .../xhtml1/reference/first-letter-001-ref.xht | 25 + .../css-pseudo-4_dev/xhtml1/reftest-toc.xht | 54 + .../css-pseudo-4_dev/xhtml1/reftest.list | 4 + .../css-tests/css-pseudo-4_dev/xhtml1/toc.xht | 54 + .../xhtml1print/chapter-1.xht | 39 + .../xhtml1print/chapter-2.xht | 126 + .../xhtml1print/chapter-3.xht | 111 + .../xhtml1print/chapter-4.xht | 66 + .../xhtml1print/chapter-5.xht | 42 + .../xhtml1print/chapter-6.xht | 222 + .../xhtml1print/first-letter-001.xht | 33 + .../xhtml1print/first-letter-002.xht | 35 + .../xhtml1print/first-letter-003.xht | 35 + .../reference/first-letter-001-ref.xht | 25 + .../xhtml1print/reftest-toc.xht | 54 + .../css-pseudo-4_dev/xhtml1print/reftest.list | 4 + .../css-pseudo-4_dev/xhtml1print/toc.xht | 54 + .../html/absolute_length_units.htm | 77 + .../html/calc-background-image-gradient-1.htm | 23 + .../calc-background-linear-gradient-1.htm | 42 + .../html/calc-background-position-1.htm | 27 + .../html/calc-background-size-1.htm | 27 + .../html/calc-border-radius-1.htm | 33 + .../html/calc-height-block-1.htm | 36 + .../html/calc-height-table-1.htm | 31 + .../html/calc-margin-block-1.htm | 24 + .../html/calc-max-height-block-1.htm | 36 + .../html/calc-max-width-block-1.htm | 26 + .../html/calc-max-width-block-intrinsic-1.htm | 28 + .../html/calc-min-height-block-1.htm | 36 + .../html/calc-min-width-block-1.htm | 26 + .../html/calc-min-width-block-intrinsic-1.htm | 28 + .../html/calc-offsets-absolute-bottom-1.htm | 34 + .../html/calc-offsets-absolute-left-1.htm | 24 + .../html/calc-offsets-absolute-right-1.htm | 24 + .../html/calc-offsets-absolute-top-1.htm | 34 + .../html/calc-offsets-relative-bottom-1.htm | 33 + .../html/calc-offsets-relative-left-1.htm | 23 + .../html/calc-offsets-relative-right-1.htm | 23 + .../html/calc-offsets-relative-top-1.htm | 33 + .../html/calc-padding-block-1.htm | 25 + .../html/calc-text-indent-1.htm | 26 + .../html/calc-text-indent-intrinsic-1.htm | 27 + .../html/calc-transform-origin-1.htm | 28 + .../html/calc-unit-analysis.htm | 91 + .../html/calc-vertical-align-1.htm | 20 + .../html/calc-width-block-1.htm | 26 + .../html/calc-width-block-intrinsic-1.htm | 27 + .../html/calc-width-table-auto-1.htm | 25 + .../html/calc-width-table-fixed-1.htm | 30 + .../css-values-3_dev/html/ch-unit-001.htm | 38 + .../css-values-3_dev/html/chapter-1.htm | 45 + .../css-values-3_dev/html/chapter-2.htm | 117 + .../css-values-3_dev/html/chapter-3.htm | 156 + .../css-values-3_dev/html/chapter-4.htm | 117 + .../css-values-3_dev/html/chapter-5.htm | 468 +++ .../css-values-3_dev/html/chapter-6.htm | 136 + .../css-values-3_dev/html/chapter-7.htm | 57 + .../css-values-3_dev/html/chapter-8.htm | 418 ++ .../css-values-3_dev/html/chapter-9.htm | 207 + .../css-values-3_dev/html/min-width-001.htm | 30 + .../html/multicol-count-non-integer-001.htm | 45 + .../html/multicol-count-non-integer-002.htm | 45 + .../html/multicol-count-non-integer-003.htm | 45 + .../html/multicol-inherit-002.htm | 82 + .../html/multicol-rule-color-inherit-001.htm | 137 + .../html/multicol-rule-color-inherit-002.htm | 120 + .../css-tests/css-values-3_dev/html/ref.htm | 18 + .../html/reference/all-green.htm | 2 + .../calc-background-image-gradient-1-ref.htm | 21 + .../calc-background-linear-gradient-1-ref.htm | 39 + .../calc-background-position-1-ref.htm | 25 + .../reference/calc-background-size-1-ref.htm | 25 + .../reference/calc-border-radius-1-ref.htm | 21 + .../reference/calc-height-block-1-ref.htm | 30 + .../reference/calc-height-table-1-ref.htm | 29 + .../reference/calc-margin-block-1-ref.htm | 22 + .../reference/calc-max-height-block-1-ref.htm | 30 + .../calc-max-width-block-intrinsic-1-ref.htm | 22 + .../calc-min-width-block-intrinsic-1-ref.htm | 22 + .../calc-offsets-absolute-top-1-ref.htm | 31 + .../calc-offsets-relative-left-1-ref.htm | 21 + .../calc-offsets-relative-top-1-ref.htm | 31 + .../reference/calc-padding-block-1-ref.htm | 23 + .../html/reference/calc-text-indent-1-ref.htm | 24 + .../calc-text-indent-intrinsic-1-ref.htm | 22 + .../reference/calc-transform-origin-1-ref.htm | 26 + .../reference/calc-vertical-align-1-ref.htm | 18 + .../html/reference/calc-width-block-1-ref.htm | 24 + .../calc-width-block-intrinsic-1-ref.htm | 22 + .../reference/calc-width-table-auto-1-ref.htm | 23 + .../calc-width-table-fixed-1-ref.htm | 28 + .../html/reference/ch-unit-001-ref.htm | 19 + .../multicol-columns-invalid-001-ref.htm | 32 + .../reference/multicol-inherit-002-ref.htm | 39 + .../multicol-rule-color-inherit-001-ref.htm | 22 + .../reference/regions-resizing-001-ref.htm | 11 + .../html/reference/support/1x1-green.png | Bin 0 -> 135 bytes .../html/reference/support/1x1-lime.png | Bin 0 -> 135 bytes .../html/reference/support/1x1-maroon.png | Bin 0 -> 109 bytes .../html/reference/support/1x1-navy.png | Bin 0 -> 109 bytes .../html/reference/support/1x1-red.png | Bin 0 -> 135 bytes .../html/reference/support/1x1-white.png | Bin 0 -> 109 bytes .../reference/support/2-80px-block-ref.html | 33 + .../html/reference/support/60x60-gg-rr.png | Bin 0 -> 224 bytes .../html/reference/support/60x60-green.png | Bin 0 -> 218 bytes .../html/reference/support/60x60-red.png | Bin 0 -> 217 bytes .../support/80px-block-float-ref.html | 27 + .../reference/support/80px-block-ref.html | 26 + .../html/reference/support/README | 29 + .../html/reference/support/a-green.css | 1 + .../html/reference/support/b-green.css | 1 + .../html/reference/support/black20x20.png | Bin 0 -> 165 bytes .../html/reference/support/c-red.css | 1 + .../html/reference/support/cat.png | Bin 0 -> 1883 bytes .../reference/support/generalParallelTest.js | 231 + .../html/reference/support/helper.js | 96 + .../html/reference/support/import-green.css | 1 + .../html/reference/support/import-red.css | 1 + .../support/min-width-tables-001-iframe.html | 59 + .../html/reference/support/one.gif | Bin 0 -> 184 bytes .../html/reference/support/parsing-utils.js | 866 ++++ .../html/reference/support/pattern-gg-gr.png | Bin 0 -> 203 bytes .../reference/support/pattern-grg-rgr-grg.png | Bin 0 -> 222 bytes .../reference/support/pattern-grg-rrg-rgg.png | Bin 0 -> 231 bytes .../reference/support/pattern-rgr-grg-rgr.png | Bin 0 -> 222 bytes .../html/reference/support/pattern-tr.png | Bin 0 -> 137 bytes .../html/reference/support/properties.js | 449 ++ .../html/reference/support/red20x20.png | Bin 0 -> 160 bytes .../reference/support/region-in-body.html | 36 + .../support/region-in-container.html | 38 + .../html/reference/support/ruler-h-50%.png | Bin 0 -> 691 bytes .../html/reference/support/ruler-h-50px.png | Bin 0 -> 671 bytes .../html/reference/support/ruler-v-100px.png | Bin 0 -> 760 bytes .../html/reference/support/ruler-v-50px.png | Bin 0 -> 757 bytes .../support/runParallelAsyncHarness.js | 145 + .../html/reference/support/square-purple.png | Bin 0 -> 92 bytes .../html/reference/support/square-teal.png | Bin 0 -> 92 bytes .../html/reference/support/square-white.png | Bin 0 -> 78 bytes .../html/reference/support/swatch-blue.png | Bin 0 -> 84 bytes .../html/reference/support/swatch-gray.png | Bin 0 -> 163 bytes .../html/reference/support/swatch-green.png | Bin 0 -> 84 bytes .../html/reference/support/swatch-lime.png | Bin 0 -> 84 bytes .../html/reference/support/swatch-navy.png | Bin 0 -> 159 bytes .../html/reference/support/swatch-orange.png | Bin 0 -> 84 bytes .../html/reference/support/swatch-pink.png | Bin 0 -> 160 bytes .../html/reference/support/swatch-purple.png | Bin 0 -> 153 bytes .../html/reference/support/swatch-red.png | Bin 0 -> 84 bytes .../html/reference/support/swatch-teal.png | Bin 0 -> 156 bytes .../html/reference/support/swatch-white.png | Bin 0 -> 85 bytes .../html/reference/support/swatch-yellow.png | Bin 0 -> 84 bytes .../html/reference/support/test-bl.png | Bin 0 -> 1368 bytes .../html/reference/support/test-br.png | Bin 0 -> 1045 bytes .../support/test-inner-half-size.png | Bin 0 -> 180 bytes .../html/reference/support/test-outer.png | Bin 0 -> 2412 bytes .../html/reference/support/test-tl.png | Bin 0 -> 1025 bytes .../html/reference/support/test-tr.png | Bin 0 -> 1235 bytes .../support/two-regions-in-container.html | 38 + .../html/reference/support/two.gif | Bin 0 -> 184 bytes .../html/reference/support/util.js | 29 + .../html/reference/support/vendorPrefix.js | 86 + .../vh_not_refreshing_on_chrome-ref.htm | 49 + .../css-values-3_dev/html/reftest-toc.htm | 486 +++ .../css-values-3_dev/html/reftest.list | 58 + .../html/regions-resizing-003.htm | 33 + .../html/regions-resizing-007.htm | 41 + .../html/regions-resizing-009.htm | 39 + .../html/shape-outside-circle-002.htm | 30 + .../html/shape-outside-circle-004.htm | 26 + .../html/shape-outside-ellipse-002.htm | 30 + .../html/shape-outside-ellipse-004.htm | 26 + .../html/shape-outside-inset-003.htm | 28 + .../html/shape-outside-polygon-004.htm | 38 + .../html/support/1x1-green.png | Bin 0 -> 135 bytes .../html/support/1x1-lime.png | Bin 0 -> 135 bytes .../html/support/1x1-maroon.png | Bin 0 -> 109 bytes .../html/support/1x1-navy.png | Bin 0 -> 109 bytes .../css-values-3_dev/html/support/1x1-red.png | Bin 0 -> 135 bytes .../html/support/1x1-white.png | Bin 0 -> 109 bytes .../html/support/2-80px-block-ref.html | 33 + .../html/support/60x60-gg-rr.png | Bin 0 -> 224 bytes .../html/support/60x60-green.png | Bin 0 -> 218 bytes .../html/support/60x60-red.png | Bin 0 -> 217 bytes .../html/support/80px-block-float-ref.html | 27 + .../html/support/80px-block-ref.html | 26 + .../css-values-3_dev/html/support/README | 29 + .../css-values-3_dev/html/support/a-green.css | 1 + .../css-values-3_dev/html/support/b-green.css | 1 + .../html/support/black20x20.png | Bin 0 -> 165 bytes .../css-values-3_dev/html/support/c-red.css | 1 + .../css-values-3_dev/html/support/cat.png | Bin 0 -> 1883 bytes .../html/support/generalParallelTest.js | 231 + .../css-values-3_dev/html/support/helper.js | 96 + .../html/support/import-green.css | 1 + .../html/support/import-red.css | 1 + .../support/min-width-tables-001-iframe.html | 59 + .../css-values-3_dev/html/support/one.gif | Bin 0 -> 184 bytes .../html/support/parsing-utils.js | 866 ++++ .../html/support/pattern-gg-gr.png | Bin 0 -> 203 bytes .../html/support/pattern-grg-rgr-grg.png | Bin 0 -> 222 bytes .../html/support/pattern-grg-rrg-rgg.png | Bin 0 -> 231 bytes .../html/support/pattern-rgr-grg-rgr.png | Bin 0 -> 222 bytes .../html/support/pattern-tr.png | Bin 0 -> 137 bytes .../html/support/properties.js | 449 ++ .../html/support/red20x20.png | Bin 0 -> 160 bytes .../html/support/region-in-body.html | 36 + .../html/support/region-in-container.html | 38 + .../html/support/ruler-h-50%.png | Bin 0 -> 691 bytes .../html/support/ruler-h-50px.png | Bin 0 -> 671 bytes .../html/support/ruler-v-100px.png | Bin 0 -> 760 bytes .../html/support/ruler-v-50px.png | Bin 0 -> 757 bytes .../html/support/runParallelAsyncHarness.js | 145 + .../html/support/square-purple.png | Bin 0 -> 92 bytes .../html/support/square-teal.png | Bin 0 -> 92 bytes .../html/support/square-white.png | Bin 0 -> 78 bytes .../html/support/swatch-blue.png | Bin 0 -> 84 bytes .../html/support/swatch-gray.png | Bin 0 -> 163 bytes .../html/support/swatch-green.png | Bin 0 -> 84 bytes .../html/support/swatch-lime.png | Bin 0 -> 84 bytes .../html/support/swatch-navy.png | Bin 0 -> 159 bytes .../html/support/swatch-orange.png | Bin 0 -> 84 bytes .../html/support/swatch-pink.png | Bin 0 -> 160 bytes .../html/support/swatch-purple.png | Bin 0 -> 153 bytes .../html/support/swatch-red.png | Bin 0 -> 84 bytes .../html/support/swatch-teal.png | Bin 0 -> 156 bytes .../html/support/swatch-white.png | Bin 0 -> 85 bytes .../html/support/swatch-yellow.png | Bin 0 -> 84 bytes .../css-values-3_dev/html/support/test-bl.png | Bin 0 -> 1368 bytes .../css-values-3_dev/html/support/test-br.png | Bin 0 -> 1045 bytes .../html/support/test-inner-half-size.png | Bin 0 -> 180 bytes .../html/support/test-outer.png | Bin 0 -> 2412 bytes .../css-values-3_dev/html/support/test-tl.png | Bin 0 -> 1025 bytes .../css-values-3_dev/html/support/test-tr.png | Bin 0 -> 1235 bytes .../support/two-regions-in-container.html | 38 + .../css-values-3_dev/html/support/two.gif | Bin 0 -> 184 bytes .../css-values-3_dev/html/support/util.js | 29 + .../html/support/vendorPrefix.js | 86 + .../css-tests/css-values-3_dev/html/toc.htm | 69 + .../html/transition-delay-001.htm | 106 + .../html/transition-duration-001.htm | 107 + .../html/vh-calc-support-pct.htm | 36 + .../css-values-3_dev/html/vh-calc-support.htm | 36 + .../css-values-3_dev/html/vh-em-inherit.htm | 34 + .../css-values-3_dev/html/vh-inherit.htm | 35 + .../html/vh-interpolate-pct.htm | 41 + .../html/vh-interpolate-px.htm | 41 + .../html/vh-interpolate-vh.htm | 41 + .../html/vh-support-atviewport.htm | 37 + .../html/vh-support-margin.htm | 34 + .../html/vh-support-transform-origin.htm | 35 + .../html/vh-support-transform-translate.htm | 35 + .../css-values-3_dev/html/vh-support.htm | 32 + .../css-values-3_dev/html/vh-zero-support.htm | 34 + .../html/vh_not_refreshing_on_chrome.htm | 52 + .../vh_not_refreshing_on_chrome_iframe.htm | 84 + ...wport-relative-lengths-scaled-viewport.htm | 48 + .../html/viewport-units-css2-001.htm | 255 ++ .../implementation-report-TEMPLATE.data | 143 + .../wpt/css-tests/css-values-3_dev/index.htm | 147 + .../wpt/css-tests/css-values-3_dev/index.xht | 147 + .../css-tests/css-values-3_dev/indices.css | 96 + .../css-tests/css-values-3_dev/testinfo.data | 70 + .../xhtml1/absolute_length_units.xht | 77 + .../calc-background-image-gradient-1.xht | 23 + .../calc-background-linear-gradient-1.xht | 42 + .../xhtml1/calc-background-position-1.xht | 27 + .../xhtml1/calc-background-size-1.xht | 27 + .../xhtml1/calc-border-radius-1.xht | 33 + .../xhtml1/calc-height-block-1.xht | 36 + .../xhtml1/calc-height-table-1.xht | 31 + .../xhtml1/calc-margin-block-1.xht | 24 + .../xhtml1/calc-max-height-block-1.xht | 36 + .../xhtml1/calc-max-width-block-1.xht | 26 + .../calc-max-width-block-intrinsic-1.xht | 28 + .../xhtml1/calc-min-height-block-1.xht | 36 + .../xhtml1/calc-min-width-block-1.xht | 26 + .../calc-min-width-block-intrinsic-1.xht | 28 + .../xhtml1/calc-offsets-absolute-bottom-1.xht | 34 + .../xhtml1/calc-offsets-absolute-left-1.xht | 24 + .../xhtml1/calc-offsets-absolute-right-1.xht | 24 + .../xhtml1/calc-offsets-absolute-top-1.xht | 34 + .../xhtml1/calc-offsets-relative-bottom-1.xht | 33 + .../xhtml1/calc-offsets-relative-left-1.xht | 23 + .../xhtml1/calc-offsets-relative-right-1.xht | 23 + .../xhtml1/calc-offsets-relative-top-1.xht | 33 + .../xhtml1/calc-padding-block-1.xht | 25 + .../xhtml1/calc-text-indent-1.xht | 26 + .../xhtml1/calc-text-indent-intrinsic-1.xht | 27 + .../xhtml1/calc-transform-origin-1.xht | 28 + .../xhtml1/calc-unit-analysis.xht | 91 + .../xhtml1/calc-vertical-align-1.xht | 20 + .../xhtml1/calc-width-block-1.xht | 26 + .../xhtml1/calc-width-block-intrinsic-1.xht | 27 + .../xhtml1/calc-width-table-auto-1.xht | 25 + .../xhtml1/calc-width-table-fixed-1.xht | 30 + .../css-values-3_dev/xhtml1/ch-unit-001.xht | 38 + .../css-values-3_dev/xhtml1/chapter-1.xht | 45 + .../css-values-3_dev/xhtml1/chapter-2.xht | 117 + .../css-values-3_dev/xhtml1/chapter-3.xht | 156 + .../css-values-3_dev/xhtml1/chapter-4.xht | 117 + .../css-values-3_dev/xhtml1/chapter-5.xht | 468 +++ .../css-values-3_dev/xhtml1/chapter-6.xht | 136 + .../css-values-3_dev/xhtml1/chapter-7.xht | 57 + .../css-values-3_dev/xhtml1/chapter-8.xht | 418 ++ .../css-values-3_dev/xhtml1/chapter-9.xht | 207 + .../css-values-3_dev/xhtml1/min-width-001.xht | 30 + .../xhtml1/multicol-count-non-integer-001.xht | 45 + .../xhtml1/multicol-count-non-integer-002.xht | 45 + .../xhtml1/multicol-count-non-integer-003.xht | 45 + .../xhtml1/multicol-inherit-002.xht | 82 + .../multicol-rule-color-inherit-001.xht | 137 + .../multicol-rule-color-inherit-002.xht | 120 + .../css-tests/css-values-3_dev/xhtml1/ref.xht | 18 + .../xhtml1/reference/all-green.xht | 2 + .../calc-background-image-gradient-1-ref.xht | 21 + .../calc-background-linear-gradient-1-ref.xht | 39 + .../calc-background-position-1-ref.xht | 25 + .../reference/calc-background-size-1-ref.xht | 25 + .../reference/calc-border-radius-1-ref.xht | 21 + .../reference/calc-height-block-1-ref.xht | 30 + .../reference/calc-height-table-1-ref.xht | 29 + .../reference/calc-margin-block-1-ref.xht | 22 + .../reference/calc-max-height-block-1-ref.xht | 30 + .../calc-max-width-block-intrinsic-1-ref.xht | 22 + .../calc-min-width-block-intrinsic-1-ref.xht | 22 + .../calc-offsets-absolute-top-1-ref.xht | 31 + .../calc-offsets-relative-left-1-ref.xht | 21 + .../calc-offsets-relative-top-1-ref.xht | 31 + .../reference/calc-padding-block-1-ref.xht | 23 + .../reference/calc-text-indent-1-ref.xht | 24 + .../calc-text-indent-intrinsic-1-ref.xht | 22 + .../reference/calc-transform-origin-1-ref.xht | 26 + .../reference/calc-vertical-align-1-ref.xht | 18 + .../reference/calc-width-block-1-ref.xht | 24 + .../calc-width-block-intrinsic-1-ref.xht | 22 + .../reference/calc-width-table-auto-1-ref.xht | 23 + .../calc-width-table-fixed-1-ref.xht | 28 + .../xhtml1/reference/ch-unit-001-ref.xht | 19 + .../multicol-columns-invalid-001-ref.xht | 32 + .../reference/multicol-inherit-002-ref.xht | 39 + .../multicol-rule-color-inherit-001-ref.xht | 22 + .../reference/regions-resizing-001-ref.xht | 11 + .../xhtml1/reference/support/1x1-green.png | Bin 0 -> 135 bytes .../xhtml1/reference/support/1x1-lime.png | Bin 0 -> 135 bytes .../xhtml1/reference/support/1x1-maroon.png | Bin 0 -> 109 bytes .../xhtml1/reference/support/1x1-navy.png | Bin 0 -> 109 bytes .../xhtml1/reference/support/1x1-red.png | Bin 0 -> 135 bytes .../xhtml1/reference/support/1x1-white.png | Bin 0 -> 109 bytes .../reference/support/2-80px-block-ref.html | 33 + .../xhtml1/reference/support/60x60-gg-rr.png | Bin 0 -> 224 bytes .../xhtml1/reference/support/60x60-green.png | Bin 0 -> 218 bytes .../xhtml1/reference/support/60x60-red.png | Bin 0 -> 217 bytes .../support/80px-block-float-ref.html | 27 + .../reference/support/80px-block-ref.html | 26 + .../xhtml1/reference/support/README | 29 + .../xhtml1/reference/support/a-green.css | 1 + .../xhtml1/reference/support/b-green.css | 1 + .../xhtml1/reference/support/black20x20.png | Bin 0 -> 165 bytes .../xhtml1/reference/support/c-red.css | 1 + .../xhtml1/reference/support/cat.png | Bin 0 -> 1883 bytes .../reference/support/generalParallelTest.js | 231 + .../xhtml1/reference/support/helper.js | 96 + .../xhtml1/reference/support/import-green.css | 1 + .../xhtml1/reference/support/import-red.css | 1 + .../support/min-width-tables-001-iframe.html | 59 + .../xhtml1/reference/support/one.gif | Bin 0 -> 184 bytes .../xhtml1/reference/support/parsing-utils.js | 866 ++++ .../reference/support/pattern-gg-gr.png | Bin 0 -> 203 bytes .../reference/support/pattern-grg-rgr-grg.png | Bin 0 -> 222 bytes .../reference/support/pattern-grg-rrg-rgg.png | Bin 0 -> 231 bytes .../reference/support/pattern-rgr-grg-rgr.png | Bin 0 -> 222 bytes .../xhtml1/reference/support/pattern-tr.png | Bin 0 -> 137 bytes .../xhtml1/reference/support/properties.js | 449 ++ .../xhtml1/reference/support/red20x20.png | Bin 0 -> 160 bytes .../reference/support/region-in-body.html | 36 + .../support/region-in-container.html | 38 + .../xhtml1/reference/support/ruler-h-50%.png | Bin 0 -> 691 bytes .../xhtml1/reference/support/ruler-h-50px.png | Bin 0 -> 671 bytes .../reference/support/ruler-v-100px.png | Bin 0 -> 760 bytes .../xhtml1/reference/support/ruler-v-50px.png | Bin 0 -> 757 bytes .../support/runParallelAsyncHarness.js | 145 + .../reference/support/square-purple.png | Bin 0 -> 92 bytes .../xhtml1/reference/support/square-teal.png | Bin 0 -> 92 bytes .../xhtml1/reference/support/square-white.png | Bin 0 -> 78 bytes .../xhtml1/reference/support/swatch-blue.png | Bin 0 -> 84 bytes .../xhtml1/reference/support/swatch-gray.png | Bin 0 -> 163 bytes .../xhtml1/reference/support/swatch-green.png | Bin 0 -> 84 bytes .../xhtml1/reference/support/swatch-lime.png | Bin 0 -> 84 bytes .../xhtml1/reference/support/swatch-navy.png | Bin 0 -> 159 bytes .../reference/support/swatch-orange.png | Bin 0 -> 84 bytes .../xhtml1/reference/support/swatch-pink.png | Bin 0 -> 160 bytes .../reference/support/swatch-purple.png | Bin 0 -> 153 bytes .../xhtml1/reference/support/swatch-red.png | Bin 0 -> 84 bytes .../xhtml1/reference/support/swatch-teal.png | Bin 0 -> 156 bytes .../xhtml1/reference/support/swatch-white.png | Bin 0 -> 85 bytes .../reference/support/swatch-yellow.png | Bin 0 -> 84 bytes .../xhtml1/reference/support/test-bl.png | Bin 0 -> 1368 bytes .../xhtml1/reference/support/test-br.png | Bin 0 -> 1045 bytes .../support/test-inner-half-size.png | Bin 0 -> 180 bytes .../xhtml1/reference/support/test-outer.png | Bin 0 -> 2412 bytes .../xhtml1/reference/support/test-tl.png | Bin 0 -> 1025 bytes .../xhtml1/reference/support/test-tr.png | Bin 0 -> 1235 bytes .../support/two-regions-in-container.html | 38 + .../xhtml1/reference/support/two.gif | Bin 0 -> 184 bytes .../xhtml1/reference/support/util.js | 29 + .../xhtml1/reference/support/vendorPrefix.js | 86 + .../vh_not_refreshing_on_chrome-ref.xht | 49 + .../css-values-3_dev/xhtml1/reftest-toc.xht | 486 +++ .../css-values-3_dev/xhtml1/reftest.list | 58 + .../xhtml1/regions-resizing-003.xht | 33 + .../xhtml1/regions-resizing-007.xht | 41 + .../xhtml1/regions-resizing-009.xht | 39 + .../xhtml1/shape-outside-circle-002.xht | 30 + .../xhtml1/shape-outside-circle-004.xht | 26 + .../xhtml1/shape-outside-ellipse-002.xht | 30 + .../xhtml1/shape-outside-ellipse-004.xht | 26 + .../xhtml1/shape-outside-inset-003.xht | 28 + .../xhtml1/shape-outside-polygon-004.xht | 38 + .../xhtml1/support/1x1-green.png | Bin 0 -> 135 bytes .../xhtml1/support/1x1-lime.png | Bin 0 -> 135 bytes .../xhtml1/support/1x1-maroon.png | Bin 0 -> 109 bytes .../xhtml1/support/1x1-navy.png | Bin 0 -> 109 bytes .../xhtml1/support/1x1-red.png | Bin 0 -> 135 bytes .../xhtml1/support/1x1-white.png | Bin 0 -> 109 bytes .../xhtml1/support/2-80px-block-ref.html | 33 + .../xhtml1/support/60x60-gg-rr.png | Bin 0 -> 224 bytes .../xhtml1/support/60x60-green.png | Bin 0 -> 218 bytes .../xhtml1/support/60x60-red.png | Bin 0 -> 217 bytes .../xhtml1/support/80px-block-float-ref.html | 27 + .../xhtml1/support/80px-block-ref.html | 26 + .../css-values-3_dev/xhtml1/support/README | 29 + .../xhtml1/support/a-green.css | 1 + .../xhtml1/support/b-green.css | 1 + .../xhtml1/support/black20x20.png | Bin 0 -> 165 bytes .../css-values-3_dev/xhtml1/support/c-red.css | 1 + .../css-values-3_dev/xhtml1/support/cat.png | Bin 0 -> 1883 bytes .../xhtml1/support/generalParallelTest.js | 231 + .../css-values-3_dev/xhtml1/support/helper.js | 96 + .../xhtml1/support/import-green.css | 1 + .../xhtml1/support/import-red.css | 1 + .../support/min-width-tables-001-iframe.html | 59 + .../css-values-3_dev/xhtml1/support/one.gif | Bin 0 -> 184 bytes .../xhtml1/support/parsing-utils.js | 866 ++++ .../xhtml1/support/pattern-gg-gr.png | Bin 0 -> 203 bytes .../xhtml1/support/pattern-grg-rgr-grg.png | Bin 0 -> 222 bytes .../xhtml1/support/pattern-grg-rrg-rgg.png | Bin 0 -> 231 bytes .../xhtml1/support/pattern-rgr-grg-rgr.png | Bin 0 -> 222 bytes .../xhtml1/support/pattern-tr.png | Bin 0 -> 137 bytes .../xhtml1/support/properties.js | 449 ++ .../xhtml1/support/red20x20.png | Bin 0 -> 160 bytes .../xhtml1/support/region-in-body.html | 36 + .../xhtml1/support/region-in-container.html | 38 + .../xhtml1/support/ruler-h-50%.png | Bin 0 -> 691 bytes .../xhtml1/support/ruler-h-50px.png | Bin 0 -> 671 bytes .../xhtml1/support/ruler-v-100px.png | Bin 0 -> 760 bytes .../xhtml1/support/ruler-v-50px.png | Bin 0 -> 757 bytes .../xhtml1/support/runParallelAsyncHarness.js | 145 + .../xhtml1/support/square-purple.png | Bin 0 -> 92 bytes .../xhtml1/support/square-teal.png | Bin 0 -> 92 bytes .../xhtml1/support/square-white.png | Bin 0 -> 78 bytes .../xhtml1/support/swatch-blue.png | Bin 0 -> 84 bytes .../xhtml1/support/swatch-gray.png | Bin 0 -> 163 bytes .../xhtml1/support/swatch-green.png | Bin 0 -> 84 bytes .../xhtml1/support/swatch-lime.png | Bin 0 -> 84 bytes .../xhtml1/support/swatch-navy.png | Bin 0 -> 159 bytes .../xhtml1/support/swatch-orange.png | Bin 0 -> 84 bytes .../xhtml1/support/swatch-pink.png | Bin 0 -> 160 bytes .../xhtml1/support/swatch-purple.png | Bin 0 -> 153 bytes .../xhtml1/support/swatch-red.png | Bin 0 -> 84 bytes .../xhtml1/support/swatch-teal.png | Bin 0 -> 156 bytes .../xhtml1/support/swatch-white.png | Bin 0 -> 85 bytes .../xhtml1/support/swatch-yellow.png | Bin 0 -> 84 bytes .../xhtml1/support/test-bl.png | Bin 0 -> 1368 bytes .../xhtml1/support/test-br.png | Bin 0 -> 1045 bytes .../xhtml1/support/test-inner-half-size.png | Bin 0 -> 180 bytes .../xhtml1/support/test-outer.png | Bin 0 -> 2412 bytes .../xhtml1/support/test-tl.png | Bin 0 -> 1025 bytes .../xhtml1/support/test-tr.png | Bin 0 -> 1235 bytes .../support/two-regions-in-container.html | 38 + .../css-values-3_dev/xhtml1/support/two.gif | Bin 0 -> 184 bytes .../css-values-3_dev/xhtml1/support/util.js | 29 + .../xhtml1/support/vendorPrefix.js | 86 + .../css-tests/css-values-3_dev/xhtml1/toc.xht | 69 + .../xhtml1/transition-delay-001.xht | 106 + .../xhtml1/transition-duration-001.xht | 107 + .../xhtml1/vh-calc-support-pct.xht | 36 + .../xhtml1/vh-calc-support.xht | 36 + .../css-values-3_dev/xhtml1/vh-em-inherit.xht | 34 + .../css-values-3_dev/xhtml1/vh-inherit.xht | 35 + .../xhtml1/vh-interpolate-pct.xht | 41 + .../xhtml1/vh-interpolate-px.xht | 41 + .../xhtml1/vh-interpolate-vh.xht | 41 + .../xhtml1/vh-support-atviewport.xht | 37 + .../xhtml1/vh-support-margin.xht | 34 + .../xhtml1/vh-support-transform-origin.xht | 35 + .../xhtml1/vh-support-transform-translate.xht | 35 + .../css-values-3_dev/xhtml1/vh-support.xht | 32 + .../xhtml1/vh-zero-support.xht | 34 + .../xhtml1/vh_not_refreshing_on_chrome.xht | 52 + .../vh_not_refreshing_on_chrome_iframe.xht | 84 + ...wport-relative-lengths-scaled-viewport.xht | 48 + .../xhtml1/viewport-units-css2-001.xht | 255 ++ .../html4/before-after-selector-001.htm | 1 + .../css-tests/css21_dev/html4/chapter-5.htm | 4 +- .../css21_dev/html4/lang-selector-001.htm | 1 + .../before-after-selector-001-ref.htm | 16 + .../html4/reference/lang-selector-001-ref.htm | 18 + .../css-tests/css21_dev/html4/reftest-toc.htm | 16 + .../css-tests/css21_dev/html4/reftest.list | 2 + .../implementation-report-TEMPLATE.data | 8 +- tests/wpt/css-tests/css21_dev/testinfo.data | 4 +- .../xhtml1/before-after-selector-001.xht | 1 + .../css-tests/css21_dev/xhtml1/chapter-5.xht | 4 +- .../css21_dev/xhtml1/lang-selector-001.xht | 1 + .../before-after-selector-001-ref.xht | 16 + .../reference/lang-selector-001-ref.xht | 18 + .../css21_dev/xhtml1/reftest-toc.xht | 16 + .../css-tests/css21_dev/xhtml1/reftest.list | 2 + .../xhtml1print/before-after-selector-001.xht | 1 + .../css21_dev/xhtml1print/chapter-5.xht | 4 +- .../xhtml1print/lang-selector-001.xht | 1 + .../before-after-selector-001-ref.xht | 25 + .../reference/lang-selector-001-ref.xht | 27 + .../css21_dev/xhtml1print/reftest-toc.xht | 16 + .../css21_dev/xhtml1print/reftest.list | 2 + .../html/CaretPosition-001.htm | 43 + .../html/MediaQueryList-001.htm | 21 + ...Screen-pixelDepth-Screen-colorDepth001.htm | 32 + .../cssom-view-1_dev/html/chapter-1.htm | 39 + .../cssom-view-1_dev/html/chapter-10.htm | 45 + .../cssom-view-1_dev/html/chapter-11.htm | 69 + .../cssom-view-1_dev/html/chapter-12.htm | 72 + .../cssom-view-1_dev/html/chapter-13.htm | 51 + .../cssom-view-1_dev/html/chapter-14.htm | 108 + .../cssom-view-1_dev/html/chapter-2.htm | 48 + .../cssom-view-1_dev/html/chapter-3.htm | 141 + .../cssom-view-1_dev/html/chapter-4.htm | 63 + .../cssom-view-1_dev/html/chapter-5.htm | 333 ++ .../cssom-view-1_dev/html/chapter-6.htm | 105 + .../cssom-view-1_dev/html/chapter-7.htm | 161 + .../cssom-view-1_dev/html/chapter-8.htm | 70 + .../cssom-view-1_dev/html/chapter-9.htm | 45 + .../html/cssom-getBoundingClientRect-001.htm | 31 + .../html/cssom-getBoundingClientRect-002.htm | 27 + .../html/cssom-getClientRects.htm | 23 + .../cssom-view-window-screen-interface.htm | 39 + .../html/elementFromPoint-001.htm | 33 + .../html/elementFromPosition.htm | 144 + .../cssom-view-1_dev/html/matchMedia.htm | 186 + .../html/matchMediaAddListener.htm | 67 + .../html/media-query-list-interface.htm | 69 + .../html/offsetParent_element_test.htm | 137 + .../cssom-view-1_dev/html/reftest-toc.htm | 30 + .../cssom-view-1_dev/html/reftest.list | 1 + .../html/scrollWidthHeight.htm | 146 + .../scrollWidthHeightWhenNotScrollable.htm | 136 + .../html/support/1x1-green.png | Bin 0 -> 135 bytes .../html/support/1x1-lime.png | Bin 0 -> 135 bytes .../html/support/1x1-maroon.png | Bin 0 -> 109 bytes .../html/support/1x1-navy.png | Bin 0 -> 109 bytes .../cssom-view-1_dev/html/support/1x1-red.png | Bin 0 -> 135 bytes .../html/support/1x1-white.png | Bin 0 -> 109 bytes .../html/support/60x60-gg-rr.png | Bin 0 -> 224 bytes .../html/support/60x60-green.png | Bin 0 -> 218 bytes .../html/support/60x60-red.png | Bin 0 -> 217 bytes .../cssom-view-1_dev/html/support/README | 29 + .../cssom-view-1_dev/html/support/a-green.css | 1 + .../cssom-view-1_dev/html/support/b-green.css | 1 + .../cssom-view-1_dev/html/support/c-red.css | 1 + .../cssom-view-1_dev/html/support/cat.png | Bin 0 -> 1883 bytes .../html/support/import-green.css | 1 + .../html/support/import-red.css | 1 + .../html/support/pattern-gg-gr.png | Bin 0 -> 148 bytes .../html/support/pattern-grg-rgr-grg.png | Bin 0 -> 222 bytes .../html/support/pattern-grg-rrg-rgg.png | Bin 0 -> 231 bytes .../html/support/pattern-rgr-grg-rgr.png | Bin 0 -> 223 bytes .../html/support/pattern-tr.png | Bin 0 -> 137 bytes .../html/support/ruler-h-50%.png | Bin 0 -> 691 bytes .../html/support/ruler-h-50px.png | Bin 0 -> 671 bytes .../html/support/ruler-v-100px.png | Bin 0 -> 760 bytes .../html/support/ruler-v-50px.png | Bin 0 -> 757 bytes .../html/support/square-purple.png | Bin 0 -> 92 bytes .../html/support/square-teal.png | Bin 0 -> 92 bytes .../html/support/square-white.png | Bin 0 -> 78 bytes .../html/support/swatch-blue.png | Bin 0 -> 84 bytes .../html/support/swatch-green.png | Bin 0 -> 84 bytes .../html/support/swatch-lime.png | Bin 0 -> 84 bytes .../html/support/swatch-orange.png | Bin 0 -> 84 bytes .../html/support/swatch-red.png | Bin 0 -> 84 bytes .../html/support/swatch-teal.png | Bin 0 -> 156 bytes .../html/support/swatch-white.png | Bin 0 -> 85 bytes .../html/support/swatch-yellow.png | Bin 0 -> 84 bytes .../cssom-view-1_dev/html/support/test-bl.png | Bin 0 -> 1368 bytes .../cssom-view-1_dev/html/support/test-br.png | Bin 0 -> 1045 bytes .../html/support/test-inner-half-size.png | Bin 0 -> 180 bytes .../html/support/test-outer.png | Bin 0 -> 2412 bytes .../cssom-view-1_dev/html/support/test-tl.png | Bin 0 -> 1025 bytes .../cssom-view-1_dev/html/support/test-tr.png | Bin 0 -> 1235 bytes .../css-tests/cssom-view-1_dev/html/toc.htm | 94 + .../html/ttwf-scrollintoview.htm | 31 + .../html/window-interface.htm | 97 + .../html/window-screen-height-immutable.htm | 27 + .../window-screen-height-mutation-throws.htm | 23 + .../html/window-screen-height.htm | 37 + .../html/window-screen-width-immutable.htm | 27 + .../window-screen-width-mutation-throws.htm | 23 + .../html/window-screen-width.htm | 37 + .../implementation-report-TEMPLATE.data | 51 + .../wpt/css-tests/cssom-view-1_dev/index.htm | 140 + .../wpt/css-tests/cssom-view-1_dev/index.xht | 140 + .../css-tests/cssom-view-1_dev/indices.css | 96 + .../css-tests/cssom-view-1_dev/testinfo.data | 24 + .../xhtml1/CaretPosition-001.xht | 43 + .../xhtml1/MediaQueryList-001.xht | 21 + ...Screen-pixelDepth-Screen-colorDepth001.xht | 32 + .../cssom-view-1_dev/xhtml1/chapter-1.xht | 39 + .../cssom-view-1_dev/xhtml1/chapter-10.xht | 45 + .../cssom-view-1_dev/xhtml1/chapter-11.xht | 69 + .../cssom-view-1_dev/xhtml1/chapter-12.xht | 72 + .../cssom-view-1_dev/xhtml1/chapter-13.xht | 51 + .../cssom-view-1_dev/xhtml1/chapter-14.xht | 108 + .../cssom-view-1_dev/xhtml1/chapter-2.xht | 48 + .../cssom-view-1_dev/xhtml1/chapter-3.xht | 141 + .../cssom-view-1_dev/xhtml1/chapter-4.xht | 63 + .../cssom-view-1_dev/xhtml1/chapter-5.xht | 333 ++ .../cssom-view-1_dev/xhtml1/chapter-6.xht | 105 + .../cssom-view-1_dev/xhtml1/chapter-7.xht | 161 + .../cssom-view-1_dev/xhtml1/chapter-8.xht | 70 + .../cssom-view-1_dev/xhtml1/chapter-9.xht | 45 + .../cssom-getBoundingClientRect-001.xht | 31 + .../cssom-getBoundingClientRect-002.xht | 27 + .../xhtml1/cssom-getClientRects.xht | 23 + .../cssom-view-window-screen-interface.xht | 39 + .../xhtml1/elementFromPoint-001.xht | 33 + .../xhtml1/elementFromPosition.xht | 144 + .../cssom-view-1_dev/xhtml1/matchMedia.xht | 186 + .../xhtml1/matchMediaAddListener.xht | 67 + .../xhtml1/media-query-list-interface.xht | 69 + .../xhtml1/offsetParent_element_test.xht | 137 + .../cssom-view-1_dev/xhtml1/reftest-toc.xht | 30 + .../cssom-view-1_dev/xhtml1/reftest.list | 1 + .../xhtml1/scrollWidthHeight.xht | 146 + .../scrollWidthHeightWhenNotScrollable.xht | 136 + .../xhtml1/support/1x1-green.png | Bin 0 -> 135 bytes .../xhtml1/support/1x1-lime.png | Bin 0 -> 135 bytes .../xhtml1/support/1x1-maroon.png | Bin 0 -> 109 bytes .../xhtml1/support/1x1-navy.png | Bin 0 -> 109 bytes .../xhtml1/support/1x1-red.png | Bin 0 -> 135 bytes .../xhtml1/support/1x1-white.png | Bin 0 -> 109 bytes .../xhtml1/support/60x60-gg-rr.png | Bin 0 -> 224 bytes .../xhtml1/support/60x60-green.png | Bin 0 -> 218 bytes .../xhtml1/support/60x60-red.png | Bin 0 -> 217 bytes .../cssom-view-1_dev/xhtml1/support/README | 29 + .../xhtml1/support/a-green.css | 1 + .../xhtml1/support/b-green.css | 1 + .../cssom-view-1_dev/xhtml1/support/c-red.css | 1 + .../cssom-view-1_dev/xhtml1/support/cat.png | Bin 0 -> 1883 bytes .../xhtml1/support/import-green.css | 1 + .../xhtml1/support/import-red.css | 1 + .../xhtml1/support/pattern-gg-gr.png | Bin 0 -> 148 bytes .../xhtml1/support/pattern-grg-rgr-grg.png | Bin 0 -> 222 bytes .../xhtml1/support/pattern-grg-rrg-rgg.png | Bin 0 -> 231 bytes .../xhtml1/support/pattern-rgr-grg-rgr.png | Bin 0 -> 223 bytes .../xhtml1/support/pattern-tr.png | Bin 0 -> 137 bytes .../xhtml1/support/ruler-h-50%.png | Bin 0 -> 691 bytes .../xhtml1/support/ruler-h-50px.png | Bin 0 -> 671 bytes .../xhtml1/support/ruler-v-100px.png | Bin 0 -> 760 bytes .../xhtml1/support/ruler-v-50px.png | Bin 0 -> 757 bytes .../xhtml1/support/square-purple.png | Bin 0 -> 92 bytes .../xhtml1/support/square-teal.png | Bin 0 -> 92 bytes .../xhtml1/support/square-white.png | Bin 0 -> 78 bytes .../xhtml1/support/swatch-blue.png | Bin 0 -> 84 bytes .../xhtml1/support/swatch-green.png | Bin 0 -> 84 bytes .../xhtml1/support/swatch-lime.png | Bin 0 -> 84 bytes .../xhtml1/support/swatch-orange.png | Bin 0 -> 84 bytes .../xhtml1/support/swatch-red.png | Bin 0 -> 84 bytes .../xhtml1/support/swatch-teal.png | Bin 0 -> 156 bytes .../xhtml1/support/swatch-white.png | Bin 0 -> 85 bytes .../xhtml1/support/swatch-yellow.png | Bin 0 -> 84 bytes .../xhtml1/support/test-bl.png | Bin 0 -> 1368 bytes .../xhtml1/support/test-br.png | Bin 0 -> 1045 bytes .../xhtml1/support/test-inner-half-size.png | Bin 0 -> 180 bytes .../xhtml1/support/test-outer.png | Bin 0 -> 2412 bytes .../xhtml1/support/test-tl.png | Bin 0 -> 1025 bytes .../xhtml1/support/test-tr.png | Bin 0 -> 1235 bytes .../css-tests/cssom-view-1_dev/xhtml1/toc.xht | 94 + .../xhtml1/ttwf-scrollintoview.xht | 31 + .../xhtml1/window-interface.xht | 97 + .../xhtml1/window-screen-height-immutable.xht | 27 + .../window-screen-height-mutation-throws.xht | 23 + .../xhtml1/window-screen-height.xht | 37 + .../xhtml1/window-screen-width-immutable.xht | 27 + .../window-screen-width-mutation-throws.xht | 23 + .../xhtml1/window-screen-width.xht | 37 + tests/wpt/css-tests/source_rev | 2 +- tests/wpt/metadata-css/MANIFEST.json | 3708 ++++++++++++++++- .../css21_dev/html4/lang-selector-001.htm.ini | 3 + 842 files changed, 42936 insertions(+), 27 deletions(-) create mode 100644 tests/wpt/css-tests/css-break-3_dev/html/chapter-1.htm create mode 100644 tests/wpt/css-tests/css-break-3_dev/html/chapter-2.htm create mode 100644 tests/wpt/css-tests/css-break-3_dev/html/chapter-3.htm create mode 100644 tests/wpt/css-tests/css-break-3_dev/html/chapter-4.htm create mode 100644 tests/wpt/css-tests/css-break-3_dev/html/chapter-5.htm create mode 100644 tests/wpt/css-tests/css-break-3_dev/html/chapter-6.htm create mode 100644 tests/wpt/css-tests/css-break-3_dev/html/floats-clear-breaks-002.htm create mode 100644 tests/wpt/css-tests/css-break-3_dev/html/floats-in-named-flow-012.htm create mode 100644 tests/wpt/css-tests/css-break-3_dev/html/floats-in-named-flow-029.htm create mode 100644 tests/wpt/css-tests/css-break-3_dev/html/floats-in-named-flow-030.htm create mode 100644 tests/wpt/css-tests/css-break-3_dev/html/position-relative-001.htm create mode 100644 tests/wpt/css-tests/css-break-3_dev/html/reference/floats-clear-breaks-002-ref.htm create mode 100644 tests/wpt/css-tests/css-break-3_dev/html/reference/floats-in-named-flow-012-ref.htm create mode 100644 tests/wpt/css-tests/css-break-3_dev/html/reference/floats-in-named-flow-029-ref.htm create mode 100644 tests/wpt/css-tests/css-break-3_dev/html/reference/floats-in-named-flow-030-ref.htm create mode 100644 tests/wpt/css-tests/css-break-3_dev/html/reference/position-relative-001-ref.htm create mode 100644 tests/wpt/css-tests/css-break-3_dev/html/reference/regions-transforms-008-ref.htm create mode 100644 tests/wpt/css-tests/css-break-3_dev/html/reference/regions-transforms-013-alt-ref.htm create mode 100644 tests/wpt/css-tests/css-break-3_dev/html/reference/regions-transforms-013-ref.htm create mode 100644 tests/wpt/css-tests/css-break-3_dev/html/reference/regions-transforms-020-ref.htm create mode 100644 tests/wpt/css-tests/css-break-3_dev/html/reftest-toc.htm create mode 100644 tests/wpt/css-tests/css-break-3_dev/html/reftest.list create mode 100644 tests/wpt/css-tests/css-break-3_dev/html/regions-transforms-008.htm create mode 100644 tests/wpt/css-tests/css-break-3_dev/html/regions-transforms-009.htm create mode 100644 tests/wpt/css-tests/css-break-3_dev/html/regions-transforms-013.htm create mode 100644 tests/wpt/css-tests/css-break-3_dev/html/regions-transforms-020.htm create mode 100644 tests/wpt/css-tests/css-break-3_dev/html/regions-transforms-021.htm create mode 100644 tests/wpt/css-tests/css-break-3_dev/html/regions-transforms-022.htm create mode 100644 tests/wpt/css-tests/css-break-3_dev/html/toc.htm create mode 100644 tests/wpt/css-tests/css-break-3_dev/implementation-report-TEMPLATE.data create mode 100644 tests/wpt/css-tests/css-break-3_dev/index.htm create mode 100644 tests/wpt/css-tests/css-break-3_dev/index.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/indices.css create mode 100644 tests/wpt/css-tests/css-break-3_dev/testinfo.data create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1/chapter-1.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1/chapter-2.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1/chapter-3.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1/chapter-4.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1/chapter-5.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1/chapter-6.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1/floats-clear-breaks-002.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1/floats-in-named-flow-012.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1/floats-in-named-flow-029.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1/floats-in-named-flow-030.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1/position-relative-001.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1/reference/floats-clear-breaks-002-ref.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1/reference/floats-in-named-flow-012-ref.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1/reference/floats-in-named-flow-029-ref.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1/reference/floats-in-named-flow-030-ref.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1/reference/position-relative-001-ref.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1/reference/regions-transforms-008-ref.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1/reference/regions-transforms-013-alt-ref.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1/reference/regions-transforms-013-ref.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1/reference/regions-transforms-020-ref.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1/reftest-toc.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1/reftest.list create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1/regions-transforms-008.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1/regions-transforms-009.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1/regions-transforms-013.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1/regions-transforms-020.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1/regions-transforms-021.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1/regions-transforms-022.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1/toc.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1print/chapter-1.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1print/chapter-2.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1print/chapter-3.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1print/chapter-4.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1print/chapter-5.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1print/chapter-6.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1print/floats-clear-breaks-002.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1print/floats-in-named-flow-012.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1print/floats-in-named-flow-029.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1print/floats-in-named-flow-030.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1print/position-relative-001.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1print/reference/floats-clear-breaks-002-ref.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1print/reference/floats-in-named-flow-012-ref.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1print/reference/floats-in-named-flow-029-ref.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1print/reference/floats-in-named-flow-030-ref.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1print/reference/position-relative-001-ref.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1print/reference/regions-transforms-008-ref.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1print/reference/regions-transforms-013-alt-ref.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1print/reference/regions-transforms-013-ref.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1print/reference/regions-transforms-020-ref.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1print/reftest-toc.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1print/reftest.list create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1print/regions-transforms-008.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1print/regions-transforms-009.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1print/regions-transforms-013.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1print/regions-transforms-020.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1print/regions-transforms-021.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1print/regions-transforms-022.xht create mode 100644 tests/wpt/css-tests/css-break-3_dev/xhtml1print/toc.xht create mode 100644 tests/wpt/css-tests/css-namespaces-3_dev/html/chapter-1.htm create mode 100644 tests/wpt/css-tests/css-namespaces-3_dev/html/chapter-2.htm create mode 100644 tests/wpt/css-tests/css-namespaces-3_dev/html/chapter-3.htm create mode 100644 tests/wpt/css-tests/css-namespaces-3_dev/html/chapter-4.htm create mode 100644 tests/wpt/css-tests/css-namespaces-3_dev/html/reftest-toc.htm create mode 100644 tests/wpt/css-tests/css-namespaces-3_dev/html/reftest.list create mode 100644 tests/wpt/css-tests/css-namespaces-3_dev/html/toc.htm create mode 100644 tests/wpt/css-tests/css-namespaces-3_dev/implementation-report-TEMPLATE.data create mode 100644 tests/wpt/css-tests/css-namespaces-3_dev/index.htm create mode 100644 tests/wpt/css-tests/css-namespaces-3_dev/index.xht create mode 100644 tests/wpt/css-tests/css-namespaces-3_dev/indices.css create mode 100644 tests/wpt/css-tests/css-namespaces-3_dev/testinfo.data create mode 100644 tests/wpt/css-tests/css-namespaces-3_dev/xhtml1/chapter-1.xht create mode 100644 tests/wpt/css-tests/css-namespaces-3_dev/xhtml1/chapter-2.xht create mode 100644 tests/wpt/css-tests/css-namespaces-3_dev/xhtml1/chapter-3.xht create mode 100644 tests/wpt/css-tests/css-namespaces-3_dev/xhtml1/chapter-4.xht create mode 100644 tests/wpt/css-tests/css-namespaces-3_dev/xhtml1/reftest-toc.xht create mode 100644 tests/wpt/css-tests/css-namespaces-3_dev/xhtml1/reftest.list create mode 100644 tests/wpt/css-tests/css-namespaces-3_dev/xhtml1/toc.xht create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/html/chapter-1.htm create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/html/chapter-2.htm create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/html/chapter-3.htm create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/html/chapter-4.htm create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/html/chapter-5.htm create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/html/chapter-6.htm create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/html/first-letter-001.htm create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/html/first-letter-002.htm create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/html/first-letter-003.htm create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/html/reference/first-letter-001-ref.htm create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/html/reftest-toc.htm create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/html/reftest.list create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/html/toc.htm create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/implementation-report-TEMPLATE.data create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/index.htm create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/index.xht create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/indices.css create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/testinfo.data create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/chapter-1.xht create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/chapter-2.xht create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/chapter-3.xht create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/chapter-4.xht create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/chapter-5.xht create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/chapter-6.xht create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/first-letter-001.xht create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/first-letter-002.xht create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/first-letter-003.xht create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/reference/first-letter-001-ref.xht create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/reftest-toc.xht create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/reftest.list create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/toc.xht create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/chapter-1.xht create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/chapter-2.xht create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/chapter-3.xht create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/chapter-4.xht create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/chapter-5.xht create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/chapter-6.xht create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/first-letter-001.xht create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/first-letter-002.xht create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/first-letter-003.xht create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/reference/first-letter-001-ref.xht create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/reftest-toc.xht create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/reftest.list create mode 100644 tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/toc.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/absolute_length_units.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/calc-background-image-gradient-1.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/calc-background-linear-gradient-1.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/calc-background-position-1.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/calc-background-size-1.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/calc-border-radius-1.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/calc-height-block-1.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/calc-height-table-1.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/calc-margin-block-1.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/calc-max-height-block-1.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/calc-max-width-block-1.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/calc-max-width-block-intrinsic-1.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/calc-min-height-block-1.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/calc-min-width-block-1.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/calc-min-width-block-intrinsic-1.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/calc-offsets-absolute-bottom-1.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/calc-offsets-absolute-left-1.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/calc-offsets-absolute-right-1.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/calc-offsets-absolute-top-1.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/calc-offsets-relative-bottom-1.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/calc-offsets-relative-left-1.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/calc-offsets-relative-right-1.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/calc-offsets-relative-top-1.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/calc-padding-block-1.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/calc-text-indent-1.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/calc-text-indent-intrinsic-1.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/calc-transform-origin-1.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/calc-unit-analysis.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/calc-vertical-align-1.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/calc-width-block-1.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/calc-width-block-intrinsic-1.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/calc-width-table-auto-1.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/calc-width-table-fixed-1.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/ch-unit-001.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/chapter-1.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/chapter-2.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/chapter-3.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/chapter-4.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/chapter-5.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/chapter-6.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/chapter-7.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/chapter-8.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/chapter-9.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/min-width-001.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/multicol-count-non-integer-001.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/multicol-count-non-integer-002.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/multicol-count-non-integer-003.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/multicol-inherit-002.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/multicol-rule-color-inherit-001.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/multicol-rule-color-inherit-002.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/ref.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/all-green.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/calc-background-image-gradient-1-ref.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/calc-background-linear-gradient-1-ref.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/calc-background-position-1-ref.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/calc-background-size-1-ref.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/calc-border-radius-1-ref.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/calc-height-block-1-ref.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/calc-height-table-1-ref.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/calc-margin-block-1-ref.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/calc-max-height-block-1-ref.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/calc-max-width-block-intrinsic-1-ref.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/calc-min-width-block-intrinsic-1-ref.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/calc-offsets-absolute-top-1-ref.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/calc-offsets-relative-left-1-ref.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/calc-offsets-relative-top-1-ref.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/calc-padding-block-1-ref.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/calc-text-indent-1-ref.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/calc-text-indent-intrinsic-1-ref.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/calc-transform-origin-1-ref.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/calc-vertical-align-1-ref.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/calc-width-block-1-ref.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/calc-width-block-intrinsic-1-ref.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/calc-width-table-auto-1-ref.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/calc-width-table-fixed-1-ref.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/ch-unit-001-ref.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/multicol-columns-invalid-001-ref.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/multicol-inherit-002-ref.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/multicol-rule-color-inherit-001-ref.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/regions-resizing-001-ref.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/1x1-green.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/1x1-lime.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/1x1-maroon.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/1x1-navy.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/1x1-red.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/1x1-white.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/2-80px-block-ref.html create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/60x60-gg-rr.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/60x60-green.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/60x60-red.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/80px-block-float-ref.html create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/80px-block-ref.html create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/README create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/a-green.css create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/b-green.css create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/black20x20.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/c-red.css create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/cat.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/generalParallelTest.js create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/helper.js create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/import-green.css create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/import-red.css create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/min-width-tables-001-iframe.html create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/one.gif create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/parsing-utils.js create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/pattern-gg-gr.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/pattern-grg-rgr-grg.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/pattern-grg-rrg-rgg.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/pattern-rgr-grg-rgr.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/pattern-tr.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/properties.js create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/red20x20.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/region-in-body.html create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/region-in-container.html create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/ruler-h-50%.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/ruler-h-50px.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/ruler-v-100px.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/ruler-v-50px.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/runParallelAsyncHarness.js create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/square-purple.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/square-teal.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/square-white.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/swatch-blue.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/swatch-gray.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/swatch-green.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/swatch-lime.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/swatch-navy.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/swatch-orange.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/swatch-pink.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/swatch-purple.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/swatch-red.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/swatch-teal.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/swatch-white.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/swatch-yellow.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/test-bl.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/test-br.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/test-inner-half-size.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/test-outer.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/test-tl.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/test-tr.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/two-regions-in-container.html create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/two.gif create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/util.js create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/support/vendorPrefix.js create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reference/vh_not_refreshing_on_chrome-ref.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reftest-toc.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/reftest.list create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/regions-resizing-003.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/regions-resizing-007.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/regions-resizing-009.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/shape-outside-circle-002.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/shape-outside-circle-004.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/shape-outside-ellipse-002.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/shape-outside-ellipse-004.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/shape-outside-inset-003.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/shape-outside-polygon-004.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/1x1-green.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/1x1-lime.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/1x1-maroon.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/1x1-navy.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/1x1-red.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/1x1-white.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/2-80px-block-ref.html create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/60x60-gg-rr.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/60x60-green.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/60x60-red.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/80px-block-float-ref.html create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/80px-block-ref.html create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/README create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/a-green.css create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/b-green.css create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/black20x20.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/c-red.css create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/cat.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/generalParallelTest.js create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/helper.js create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/import-green.css create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/import-red.css create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/min-width-tables-001-iframe.html create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/one.gif create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/parsing-utils.js create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/pattern-gg-gr.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/pattern-grg-rgr-grg.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/pattern-grg-rrg-rgg.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/pattern-rgr-grg-rgr.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/pattern-tr.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/properties.js create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/red20x20.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/region-in-body.html create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/region-in-container.html create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/ruler-h-50%.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/ruler-h-50px.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/ruler-v-100px.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/ruler-v-50px.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/runParallelAsyncHarness.js create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/square-purple.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/square-teal.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/square-white.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/swatch-blue.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/swatch-gray.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/swatch-green.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/swatch-lime.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/swatch-navy.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/swatch-orange.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/swatch-pink.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/swatch-purple.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/swatch-red.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/swatch-teal.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/swatch-white.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/swatch-yellow.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/test-bl.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/test-br.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/test-inner-half-size.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/test-outer.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/test-tl.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/test-tr.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/two-regions-in-container.html create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/two.gif create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/util.js create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/support/vendorPrefix.js create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/toc.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/transition-delay-001.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/transition-duration-001.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/vh-calc-support-pct.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/vh-calc-support.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/vh-em-inherit.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/vh-inherit.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/vh-interpolate-pct.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/vh-interpolate-px.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/vh-interpolate-vh.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/vh-support-atviewport.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/vh-support-margin.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/vh-support-transform-origin.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/vh-support-transform-translate.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/vh-support.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/vh-zero-support.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/vh_not_refreshing_on_chrome.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/vh_not_refreshing_on_chrome_iframe.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/viewport-relative-lengths-scaled-viewport.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/html/viewport-units-css2-001.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/implementation-report-TEMPLATE.data create mode 100644 tests/wpt/css-tests/css-values-3_dev/index.htm create mode 100644 tests/wpt/css-tests/css-values-3_dev/index.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/indices.css create mode 100644 tests/wpt/css-tests/css-values-3_dev/testinfo.data create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/absolute_length_units.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-background-image-gradient-1.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-background-linear-gradient-1.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-background-position-1.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-background-size-1.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-border-radius-1.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-height-block-1.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-height-table-1.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-margin-block-1.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-max-height-block-1.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-max-width-block-1.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-max-width-block-intrinsic-1.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-min-height-block-1.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-min-width-block-1.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-min-width-block-intrinsic-1.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-offsets-absolute-bottom-1.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-offsets-absolute-left-1.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-offsets-absolute-right-1.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-offsets-absolute-top-1.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-offsets-relative-bottom-1.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-offsets-relative-left-1.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-offsets-relative-right-1.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-offsets-relative-top-1.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-padding-block-1.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-text-indent-1.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-text-indent-intrinsic-1.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-transform-origin-1.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-unit-analysis.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-vertical-align-1.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-width-block-1.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-width-block-intrinsic-1.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-width-table-auto-1.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-width-table-fixed-1.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/ch-unit-001.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/chapter-1.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/chapter-2.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/chapter-3.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/chapter-4.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/chapter-5.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/chapter-6.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/chapter-7.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/chapter-8.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/chapter-9.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/min-width-001.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/multicol-count-non-integer-001.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/multicol-count-non-integer-002.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/multicol-count-non-integer-003.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/multicol-inherit-002.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/multicol-rule-color-inherit-001.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/multicol-rule-color-inherit-002.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/ref.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/all-green.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-background-image-gradient-1-ref.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-background-linear-gradient-1-ref.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-background-position-1-ref.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-background-size-1-ref.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-border-radius-1-ref.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-height-block-1-ref.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-height-table-1-ref.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-margin-block-1-ref.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-max-height-block-1-ref.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-max-width-block-intrinsic-1-ref.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-min-width-block-intrinsic-1-ref.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-offsets-absolute-top-1-ref.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-offsets-relative-left-1-ref.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-offsets-relative-top-1-ref.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-padding-block-1-ref.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-text-indent-1-ref.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-text-indent-intrinsic-1-ref.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-transform-origin-1-ref.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-vertical-align-1-ref.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-width-block-1-ref.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-width-block-intrinsic-1-ref.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-width-table-auto-1-ref.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-width-table-fixed-1-ref.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/ch-unit-001-ref.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/multicol-columns-invalid-001-ref.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/multicol-inherit-002-ref.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/multicol-rule-color-inherit-001-ref.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/regions-resizing-001-ref.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/1x1-green.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/1x1-lime.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/1x1-maroon.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/1x1-navy.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/1x1-red.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/1x1-white.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/2-80px-block-ref.html create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/60x60-gg-rr.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/60x60-green.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/60x60-red.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/80px-block-float-ref.html create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/80px-block-ref.html create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/README create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/a-green.css create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/b-green.css create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/black20x20.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/c-red.css create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/cat.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/generalParallelTest.js create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/helper.js create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/import-green.css create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/import-red.css create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/min-width-tables-001-iframe.html create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/one.gif create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/parsing-utils.js create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/pattern-gg-gr.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/pattern-grg-rgr-grg.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/pattern-grg-rrg-rgg.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/pattern-rgr-grg-rgr.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/pattern-tr.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/properties.js create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/red20x20.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/region-in-body.html create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/region-in-container.html create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/ruler-h-50%.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/ruler-h-50px.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/ruler-v-100px.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/ruler-v-50px.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/runParallelAsyncHarness.js create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/square-purple.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/square-teal.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/square-white.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/swatch-blue.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/swatch-gray.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/swatch-green.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/swatch-lime.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/swatch-navy.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/swatch-orange.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/swatch-pink.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/swatch-purple.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/swatch-red.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/swatch-teal.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/swatch-white.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/swatch-yellow.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/test-bl.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/test-br.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/test-inner-half-size.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/test-outer.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/test-tl.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/test-tr.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/two-regions-in-container.html create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/two.gif create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/util.js create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/vendorPrefix.js create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/vh_not_refreshing_on_chrome-ref.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reftest-toc.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/reftest.list create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/regions-resizing-003.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/regions-resizing-007.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/regions-resizing-009.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/shape-outside-circle-002.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/shape-outside-circle-004.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/shape-outside-ellipse-002.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/shape-outside-ellipse-004.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/shape-outside-inset-003.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/shape-outside-polygon-004.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/1x1-green.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/1x1-lime.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/1x1-maroon.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/1x1-navy.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/1x1-red.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/1x1-white.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/2-80px-block-ref.html create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/60x60-gg-rr.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/60x60-green.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/60x60-red.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/80px-block-float-ref.html create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/80px-block-ref.html create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/README create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/a-green.css create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/b-green.css create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/black20x20.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/c-red.css create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/cat.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/generalParallelTest.js create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/helper.js create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/import-green.css create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/import-red.css create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/min-width-tables-001-iframe.html create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/one.gif create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/parsing-utils.js create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/pattern-gg-gr.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/pattern-grg-rgr-grg.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/pattern-grg-rrg-rgg.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/pattern-rgr-grg-rgr.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/pattern-tr.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/properties.js create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/red20x20.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/region-in-body.html create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/region-in-container.html create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/ruler-h-50%.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/ruler-h-50px.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/ruler-v-100px.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/ruler-v-50px.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/runParallelAsyncHarness.js create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/square-purple.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/square-teal.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/square-white.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/swatch-blue.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/swatch-gray.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/swatch-green.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/swatch-lime.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/swatch-navy.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/swatch-orange.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/swatch-pink.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/swatch-purple.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/swatch-red.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/swatch-teal.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/swatch-white.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/swatch-yellow.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/test-bl.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/test-br.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/test-inner-half-size.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/test-outer.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/test-tl.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/test-tr.png create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/two-regions-in-container.html create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/two.gif create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/util.js create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/support/vendorPrefix.js create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/toc.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/transition-delay-001.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/transition-duration-001.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-calc-support-pct.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-calc-support.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-em-inherit.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-inherit.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-interpolate-pct.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-interpolate-px.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-interpolate-vh.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-support-atviewport.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-support-margin.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-support-transform-origin.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-support-transform-translate.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-support.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-zero-support.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/vh_not_refreshing_on_chrome.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/vh_not_refreshing_on_chrome_iframe.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/viewport-relative-lengths-scaled-viewport.xht create mode 100644 tests/wpt/css-tests/css-values-3_dev/xhtml1/viewport-units-css2-001.xht create mode 100644 tests/wpt/css-tests/css21_dev/html4/reference/before-after-selector-001-ref.htm create mode 100644 tests/wpt/css-tests/css21_dev/html4/reference/lang-selector-001-ref.htm create mode 100644 tests/wpt/css-tests/css21_dev/xhtml1/reference/before-after-selector-001-ref.xht create mode 100644 tests/wpt/css-tests/css21_dev/xhtml1/reference/lang-selector-001-ref.xht create mode 100644 tests/wpt/css-tests/css21_dev/xhtml1print/reference/before-after-selector-001-ref.xht create mode 100644 tests/wpt/css-tests/css21_dev/xhtml1print/reference/lang-selector-001-ref.xht create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/CaretPosition-001.htm create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/MediaQueryList-001.htm create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/Screen-pixelDepth-Screen-colorDepth001.htm create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/chapter-1.htm create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/chapter-10.htm create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/chapter-11.htm create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/chapter-12.htm create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/chapter-13.htm create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/chapter-14.htm create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/chapter-2.htm create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/chapter-3.htm create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/chapter-4.htm create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/chapter-5.htm create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/chapter-6.htm create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/chapter-7.htm create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/chapter-8.htm create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/chapter-9.htm create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/cssom-getBoundingClientRect-001.htm create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/cssom-getBoundingClientRect-002.htm create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/cssom-getClientRects.htm create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/cssom-view-window-screen-interface.htm create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/elementFromPoint-001.htm create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/elementFromPosition.htm create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/matchMedia.htm create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/matchMediaAddListener.htm create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/media-query-list-interface.htm create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/offsetParent_element_test.htm create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/reftest-toc.htm create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/reftest.list create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/scrollWidthHeight.htm create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/scrollWidthHeightWhenNotScrollable.htm create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/support/1x1-green.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/support/1x1-lime.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/support/1x1-maroon.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/support/1x1-navy.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/support/1x1-red.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/support/1x1-white.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/support/60x60-gg-rr.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/support/60x60-green.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/support/60x60-red.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/support/README create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/support/a-green.css create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/support/b-green.css create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/support/c-red.css create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/support/cat.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/support/import-green.css create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/support/import-red.css create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/support/pattern-gg-gr.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/support/pattern-grg-rgr-grg.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/support/pattern-grg-rrg-rgg.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/support/pattern-rgr-grg-rgr.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/support/pattern-tr.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/support/ruler-h-50%.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/support/ruler-h-50px.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/support/ruler-v-100px.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/support/ruler-v-50px.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/support/square-purple.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/support/square-teal.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/support/square-white.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/support/swatch-blue.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/support/swatch-green.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/support/swatch-lime.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/support/swatch-orange.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/support/swatch-red.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/support/swatch-teal.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/support/swatch-white.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/support/swatch-yellow.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/support/test-bl.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/support/test-br.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/support/test-inner-half-size.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/support/test-outer.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/support/test-tl.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/support/test-tr.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/toc.htm create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/ttwf-scrollintoview.htm create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/window-interface.htm create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/window-screen-height-immutable.htm create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/window-screen-height-mutation-throws.htm create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/window-screen-height.htm create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/window-screen-width-immutable.htm create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/window-screen-width-mutation-throws.htm create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/html/window-screen-width.htm create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/implementation-report-TEMPLATE.data create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/index.htm create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/index.xht create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/indices.css create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/testinfo.data create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/CaretPosition-001.xht create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/MediaQueryList-001.xht create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/Screen-pixelDepth-Screen-colorDepth001.xht create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-1.xht create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-10.xht create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-11.xht create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-12.xht create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-13.xht create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-14.xht create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-2.xht create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-3.xht create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-4.xht create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-5.xht create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-6.xht create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-7.xht create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-8.xht create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-9.xht create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/cssom-getBoundingClientRect-001.xht create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/cssom-getBoundingClientRect-002.xht create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/cssom-getClientRects.xht create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/cssom-view-window-screen-interface.xht create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/elementFromPoint-001.xht create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/elementFromPosition.xht create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/matchMedia.xht create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/matchMediaAddListener.xht create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/media-query-list-interface.xht create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/offsetParent_element_test.xht create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/reftest-toc.xht create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/reftest.list create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/scrollWidthHeight.xht create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/scrollWidthHeightWhenNotScrollable.xht create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/1x1-green.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/1x1-lime.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/1x1-maroon.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/1x1-navy.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/1x1-red.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/1x1-white.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/60x60-gg-rr.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/60x60-green.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/60x60-red.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/README create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/a-green.css create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/b-green.css create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/c-red.css create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/cat.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/import-green.css create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/import-red.css create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/pattern-gg-gr.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/pattern-grg-rgr-grg.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/pattern-grg-rrg-rgg.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/pattern-rgr-grg-rgr.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/pattern-tr.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/ruler-h-50%.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/ruler-h-50px.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/ruler-v-100px.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/ruler-v-50px.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/square-purple.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/square-teal.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/square-white.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/swatch-blue.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/swatch-green.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/swatch-lime.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/swatch-orange.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/swatch-red.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/swatch-teal.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/swatch-white.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/swatch-yellow.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/test-bl.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/test-br.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/test-inner-half-size.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/test-outer.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/test-tl.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/test-tr.png create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/toc.xht create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/ttwf-scrollintoview.xht create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/window-interface.xht create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/window-screen-height-immutable.xht create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/window-screen-height-mutation-throws.xht create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/window-screen-height.xht create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/window-screen-width-immutable.xht create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/window-screen-width-mutation-throws.xht create mode 100644 tests/wpt/css-tests/cssom-view-1_dev/xhtml1/window-screen-width.xht create mode 100644 tests/wpt/metadata-css/css21_dev/html4/lang-selector-001.htm.ini diff --git a/tests/wpt/css-tests/css-break-3_dev/html/chapter-1.htm b/tests/wpt/css-tests/css-break-3_dev/html/chapter-1.htm new file mode 100644 index 00000000000..ec7e0365eed --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/html/chapter-1.htm @@ -0,0 +1,57 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>Introduction - CSS Fragmentation Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Fragmentation Module Level 3 CR Test Suite</h1> + <h2>Introduction (0 tests)</h2> + <table width="100%"> + <col id="test-column"> + <col id="refs-column"> + <col id="flags-column"> + <col id="info-column"> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s1">+</a> + <a href="http://www.w3.org/TR/css3-break/#intro">1 Introduction</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s1.#fragmentation"> + <!-- 0 tests --> + </tbody> + <tbody id="s1.#pagination"> + <!-- 0 tests --> + </tbody> + <tbody id="s1.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s1.1">+</a> + <a href="http://www.w3.org/TR/css3-break/#placement">1.1 Module Interactions</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s1.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s1.2">+</a> + <a href="http://www.w3.org/TR/css3-break/#values">1.2 Values</a></th></tr> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/html/chapter-2.htm b/tests/wpt/css-tests/css-break-3_dev/html/chapter-2.htm new file mode 100644 index 00000000000..69c4544e959 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/html/chapter-2.htm @@ -0,0 +1,131 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>Fragmentation Model and Terminology - CSS Fragmentation Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Fragmentation Module Level 3 CR Test Suite</h1> + <h2>Fragmentation Model and Terminology (4 tests)</h2> + <table width="100%"> + <col id="test-column"> + <col id="refs-column"> + <col id="flags-column"> + <col id="info-column"> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2">+</a> + <a href="http://www.w3.org/TR/css3-break/#fragmentation-model">2 Fragmentation Model and Terminology</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s2.#box-fragment"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.#break"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.#fragment"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.#fragmentainer"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.#fragmentation-break"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.#fragmentation-container"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.#fragmentation-context"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.#fragmentation-direction"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.#fragmentation-root"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.#fragmentation0"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.#fragmented-flow"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.#remaining-fragmentainer-extent"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.1">+</a> + <a href="http://www.w3.org/TR/css3-break/#parallel-flows">2.1 Parallel Fragmentation Flows</a></th></tr> + <!-- 4 tests --> + <tr id="floats-clear-breaks-002-2.1" class="ahem"> + <td> + <a href="floats-clear-breaks-002.htm">floats-clear-breaks-002</a></td> + <td><a href="reference/floats-clear-breaks-002-ref.htm">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + <td>CSS Regions: forced region breaks and clear on floats inside named flow contents + <ul class="assert"> + <li>Test checks that no regions are left empty when setting a forced region break on a cleared float.</li> + </ul> + </td> + </tr> + <tr id="floats-in-named-flow-012-2.1" class="ahem"> + <td> + <a href="floats-in-named-flow-012.htm">floats-in-named-flow-012</a></td> + <td><a href="reference/floats-in-named-flow-012-ref.htm">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + <td>floats with forced region breaks inside them + <ul class="assert"> + <li>Test checks that floats in named flow contents are floated relative to the region container and not their initial container, even when multiple regions are involved.</li> + </ul> + </td> + </tr> + <tr id="floats-in-named-flow-029-2.1" class="ahem"> + <td> + <a href="floats-in-named-flow-029.htm">floats-in-named-flow-029</a></td> + <td><a href="reference/floats-in-named-flow-029-ref.htm">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + <td>CSS Regions: margins around forced breaks when break is around float + <ul class="assert"> + <li>Test checks that margins are correctly preserved when content has floats and is fragmented via forced breaks.</li> + </ul> + </td> + </tr> + <tr id="floats-in-named-flow-030-2.1" class="ahem"> + <td> + <a href="floats-in-named-flow-030.htm">floats-in-named-flow-030</a></td> + <td><a href="reference/floats-in-named-flow-030-ref.htm">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + <td>CSS Regions: margins around unforced breaks when break is around float + <ul class="assert"> + <li>Test checks that margins are correctly preserved when content has floats and is fragmented via unforced breaks.</li> + </ul> + </td> + </tr> + </tbody> + <tbody id="s2.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.2">+</a> + <a href="http://www.w3.org/TR/css3-break/#nested-flows">2.2 Nested Fragmentation Flows</a></th></tr> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/html/chapter-3.htm b/tests/wpt/css-tests/css-break-3_dev/html/chapter-3.htm new file mode 100644 index 00000000000..616d01894c0 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/html/chapter-3.htm @@ -0,0 +1,153 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>Controlling Breaks - CSS Fragmentation Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Fragmentation Module Level 3 CR Test Suite</h1> + <h2>Controlling Breaks (0 tests)</h2> + <table width="100%"> + <col id="test-column"> + <col id="refs-column"> + <col id="flags-column"> + <col id="info-column"> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3">+</a> + <a href="http://www.w3.org/TR/css3-break/#breaking-controls">3 Controlling Breaks</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.1">+</a> + <a href="http://www.w3.org/TR/css3-break/#break-between">3.1 Breaks Between Boxes: the &#8216;break-before&#8217; and &#8216;break-after&#8217; properties</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#always"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#any"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#auto"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#avoid"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#avoid-break-values"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#avoid-column"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#avoid-page"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#avoid-region"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#break-after"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#break-before"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#column"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#column-break-values"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#forced-break-values"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#generic-break-values"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#left"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#page"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#page-break-values"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#recto"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#region"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#region-break-values"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#right"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#verso"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.2">+</a> + <a href="http://www.w3.org/TR/css3-break/#break-within">3.2 Breaks Within Boxes: the &#8216;break-inside&#8217; property</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.2.#auto0"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.2.#avoid-column0"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.2.#avoid-page0"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.2.#avoid-region0"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.2.#avoid0"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.2.#break-inside"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.3">+</a> + <a href="http://www.w3.org/TR/css3-break/#widows-orphans">3.3 Breaks Between Lines: &#8216;orphans&#8217;, &#8216;widows&#8217;</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.3.#orphans"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.3.#widows"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.4"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.4">+</a> + <a href="http://www.w3.org/TR/css3-break/#page-break-properties">3.4 Page Break Aliases: the &#8216;page-break-before&#8217;, &#8216;page-break-after&#8217;, and &#8216;page-break-inside&#8217; properties</a></th></tr> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/html/chapter-4.htm b/tests/wpt/css-tests/css-break-3_dev/html/chapter-4.htm new file mode 100644 index 00000000000..f9f5de35a5e --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/html/chapter-4.htm @@ -0,0 +1,141 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>Rules for Breaking - CSS Fragmentation Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Fragmentation Module Level 3 CR Test Suite</h1> + <h2>Rules for Breaking (2 tests)</h2> + <table width="100%"> + <col id="test-column"> + <col id="refs-column"> + <col id="flags-column"> + <col id="info-column"> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s4"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4">+</a> + <a href="http://www.w3.org/TR/css3-break/#breaking-rules">4 Rules for Breaking</a></th></tr> + <!-- 2 tests --> + <tr id="regions-transforms-013-4" class=""> + <td> + <a href="regions-transforms-013.htm">regions-transforms-013</a></td> + <td><a href="reference/regions-transforms-013-alt-ref.htm">=</a> <a href="reference/regions-transforms-013-ref.htm">=</a> </td> + <td></td> + <td>CSS Regions: Transformed named flow (monolithic) content that breaks across multiple regions + <ul class="assert"> + <li>This test checks that the named flow content that is monolithic is transformed when it breaks across multiple regions whether it is sliced or overflowed at the fragmentainer edge.</li> + </ul> + </td> + </tr> + <tr id="regions-transforms-020-4" class=""> + <td> + <a href="regions-transforms-020.htm">regions-transforms-020</a></td> + <td><a href="reference/regions-transforms-020-ref.htm">=</a> </td> + <td></td> + <td>CSS Regions: Transformed region with named flow (fragmentable) content that breaks across multiple regions + <ul class="assert"> + <li>This test checks that the named flow content that is fragmentable (has a break point) is transformed when it breaks across multiple regions.</li> + </ul> + </td> + </tr> + </tbody> + <tbody id="s4.#monolithic"> + <!-- 1 tests --> + <tr id="regions-transforms-013-4.#monolithic" class=""> + <td> + <a href="regions-transforms-013.htm">regions-transforms-013</a></td> + <td><a href="reference/regions-transforms-013-alt-ref.htm">=</a> <a href="reference/regions-transforms-013-ref.htm">=</a> </td> + <td></td> + <td>CSS Regions: Transformed named flow (monolithic) content that breaks across multiple regions + <ul class="assert"> + <li>This test checks that the named flow content that is monolithic is transformed when it breaks across multiple regions whether it is sliced or overflowed at the fragmentainer edge.</li> + </ul> + </td> + </tr> + </tbody> + <tbody id="s4.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4.1">+</a> + <a href="http://www.w3.org/TR/css3-break/#possible-breaks">4.1 Possible Break Points</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s4.1.#btw-blocks"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.1.#btw-lines"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.1.#end-block"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.1.#monolithic-breaking"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4.2">+</a> + <a href="http://www.w3.org/TR/css3-break/#break-types">4.2 Types of Breaks</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s4.2.#column-break"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.2.#line-break"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.2.#page-break"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.2.#region-break"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.2.#spread-break"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4.3">+</a> + <a href="http://www.w3.org/TR/css3-break/#forced-breaks">4.3 Forced Breaks</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s4.3.#forced-break"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.4"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4.4">+</a> + <a href="http://www.w3.org/TR/css3-break/#unforced-breaks">4.4 Unforced Breaks</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s4.4.#unforced-break"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.5"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4.5">+</a> + <a href="http://www.w3.org/TR/css3-break/#best-breaks">4.5 Optimizing Unforced Breaks</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s4.5.#widows-orphans-example"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/html/chapter-5.htm b/tests/wpt/css-tests/css-break-3_dev/html/chapter-5.htm new file mode 100644 index 00000000000..cfd96dd69d7 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/html/chapter-5.htm @@ -0,0 +1,183 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>Box Model for Breaking - CSS Fragmentation Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Fragmentation Module Level 3 CR Test Suite</h1> + <h2>Box Model for Breaking (9 tests)</h2> + <table width="100%"> + <col id="test-column"> + <col id="refs-column"> + <col id="flags-column"> + <col id="info-column"> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s5"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s5">+</a> + <a href="http://www.w3.org/TR/css3-break/#breaking-boxes">5 Box Model for Breaking</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s5.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s5.1">+</a> + <a href="http://www.w3.org/TR/css3-break/#varying-size-boxes">5.1 Breaking into Varying-size Fragmentainers</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s5.2">+</a> + <a href="http://www.w3.org/TR/css3-break/#break-margins">5.2 Adjoining Margins at Breaks</a></th></tr> + <!-- 2 tests --> + <tr id="floats-in-named-flow-029-5.2" class="ahem"> + <td> + <a href="floats-in-named-flow-029.htm">floats-in-named-flow-029</a></td> + <td><a href="reference/floats-in-named-flow-029-ref.htm">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + <td>CSS Regions: margins around forced breaks when break is around float + <ul class="assert"> + <li>Test checks that margins are correctly preserved when content has floats and is fragmented via forced breaks.</li> + </ul> + </td> + </tr> + <tr id="floats-in-named-flow-030-5.2" class="ahem"> + <td> + <a href="floats-in-named-flow-030.htm">floats-in-named-flow-030</a></td> + <td><a href="reference/floats-in-named-flow-030-ref.htm">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + <td>CSS Regions: margins around unforced breaks when break is around float + <ul class="assert"> + <li>Test checks that margins are correctly preserved when content has floats and is fragmented via unforced breaks.</li> + </ul> + </td> + </tr> + </tbody> + <tbody id="s5.3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s5.3">+</a> + <a href="http://www.w3.org/TR/css3-break/#box-splitting">5.3 Splitting Boxes</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s5.4"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s5.4">+</a> + <a href="http://www.w3.org/TR/css3-break/#break-decoration">5.4 Fragmented Borders and Backgrounds: the &#8216;box-decoration-break&#8217; property</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s5.4.#box-decoration-break"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.4.#clone"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.4.#slice"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.4.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s5.4.1">+</a> + <a href="http://www.w3.org/TR/css3-break/#joining-boxes">5.4.1 Joining Boxes for &#8216;slice&#8217;</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s5.5"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s5.5">+</a> + <a href="http://www.w3.org/TR/css3-break/#transforms">5.5 Transforms, Positioning, and Pagination</a></th></tr> + <!-- 7 tests --> + <tr id="position-relative-001-5.5" class="ahem"> + <td> + <a href="position-relative-001.htm">position-relative-001</a></td> + <td><a href="reference/position-relative-001-ref.htm">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + <td>CSS Regions: flowing content that has position: relative + <ul class="assert"> + <li>Test checks that fragments of content flowed in regions are positioned independently, after the fragmentation occurs.</li> + </ul> + </td> + </tr> + <tr id="regions-transforms-008-5.5" class="ahem"> + <td> + <a href="regions-transforms-008.htm">regions-transforms-008</a></td> + <td><a href="reference/regions-transforms-008-ref.htm">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + <td>CSS Regions: Transformed named flow (text) content that breaks across multiple regions and overflows + <ul class="assert"> + <li>This test checks that named flow text content is transformed when it breaks across multiple regions and that the overflow remains visible.</li> + </ul> + </td> + </tr> + <tr id="regions-transforms-009-5.5" class="ahem"> + <td> + <a href="regions-transforms-009.htm">regions-transforms-009</a></td> + <td><a href="reference/regions-transforms-008-ref.htm">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + <td>CSS Regions: Transformed region with named flow (text) content that breaks across multiple regions and overflows + <ul class="assert"> + <li>This test checks that the regions are transformed when named flow text content breaks across multiple regions and that the overflow remains visible.</li> + </ul> + </td> + </tr> + <tr id="regions-transforms-013-5.5" class=""> + <td> + <a href="regions-transforms-013.htm">regions-transforms-013</a></td> + <td><a href="reference/regions-transforms-013-alt-ref.htm">=</a> <a href="reference/regions-transforms-013-ref.htm">=</a> </td> + <td></td> + <td>CSS Regions: Transformed named flow (monolithic) content that breaks across multiple regions + <ul class="assert"> + <li>This test checks that the named flow content that is monolithic is transformed when it breaks across multiple regions whether it is sliced or overflowed at the fragmentainer edge.</li> + </ul> + </td> + </tr> + <tr id="regions-transforms-020-5.5" class=""> + <td> + <a href="regions-transforms-020.htm">regions-transforms-020</a></td> + <td><a href="reference/regions-transforms-020-ref.htm">=</a> </td> + <td></td> + <td>CSS Regions: Transformed region with named flow (fragmentable) content that breaks across multiple regions + <ul class="assert"> + <li>This test checks that the named flow content that is fragmentable (has a break point) is transformed when it breaks across multiple regions.</li> + </ul> + </td> + </tr> + <tr id="regions-transforms-021-5.5" class=""> + <td> + <a href="regions-transforms-021.htm">regions-transforms-021</a></td> + <td><a href="reference/regions-transforms-020-ref.htm">=</a> </td> + <td></td> + <td>CSS Regions: Transforms on multiple named flow (non-text) content nodes that break across multiple regions + <ul class="assert"> + <li>This test checks that separate transforms can be applied to each named flow content node that breaks across multiple regions and that each fragment has its own transform origin.</li> + </ul> + </td> + </tr> + <tr id="regions-transforms-022-5.5" class="ahem"> + <td> + <a href="regions-transforms-022.htm">regions-transforms-022</a></td> + <td><a href="reference/regions-transforms-020-ref.htm">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + <td>CSS Regions: Transforms on multiple named flow (text) content nodes that break across multiple regions + <ul class="assert"> + <li>This test checks that separate transforms can be applied to each named flow content text node that breaks across multiple regions</li> + </ul> + </td> + </tr> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/html/chapter-6.htm b/tests/wpt/css-tests/css-break-3_dev/html/chapter-6.htm new file mode 100644 index 00000000000..a28e755495a --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/html/chapter-6.htm @@ -0,0 +1,159 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>Conformance - CSS Fragmentation Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Fragmentation Module Level 3 CR Test Suite</h1> + <h2>Conformance (0 tests)</h2> + <table width="100%"> + <col id="test-column"> + <col id="refs-column"> + <col id="flags-column"> + <col id="info-column"> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s6"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6">+</a> + <a href="http://www.w3.org/TR/css3-break/#conformance">6 Conformance</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6.1">+</a> + <a href="http://www.w3.org/TR/css3-break/#conventions">6.1 Document Conventions</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6.2">+</a> + <a href="http://www.w3.org/TR/css3-break/#conformance-classes">6.2 Conformance Classes</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2.#authoring-tool"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2.#renderer"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2.#style-sheet"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6.3">+</a> + <a href="http://www.w3.org/TR/css3-break/#partial">6.3 Partial Implementations</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s6.4"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6.4">+</a> + <a href="http://www.w3.org/TR/css3-break/#experimental">6.4 Experimental Implementations</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s6.5"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6.5">+</a> + <a href="http://www.w3.org/TR/css3-break/#testing">6.5 Non-Experimental Implementations</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s6.6"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6.6">+</a> + <a href="http://www.w3.org/TR/css3-break/#cr-exit-criteria">6.6 CR Exit Criteria</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s.#abstract"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#acknowledgments"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#changes"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#contents"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#css-fragmentation-module"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#index"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#normative-references"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#other-references"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#property-index"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#ref-CSS-REGIONS-1"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#ref-CSS-TEXT-3"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#ref-CSS-WRITING-MODES-3"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#ref-CSS21"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#ref-CSS3-FLEXBOX"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#ref-CSS3-SIZING"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#ref-CSS3-TRANSFORMS"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#ref-CSS3BG"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#ref-CSS3COL"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#ref-CSS3PAGE"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#ref-CSS3VAL"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#ref-RFC2119"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#references"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#status"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#subtitle"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#w3c_process_revision"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/html/floats-clear-breaks-002.htm b/tests/wpt/css-tests/css-break-3_dev/html/floats-clear-breaks-002.htm new file mode 100644 index 00000000000..244a1e4d11c --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/html/floats-clear-breaks-002.htm @@ -0,0 +1,86 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Regions: forced region breaks and clear on floats inside named flow contents</title> + <link href="mailto:mibalan@adobe.com" rel="author" title="Mihai Balan"> + <link href="http://www.w3.org/TR/css3-regions/#the-flow-into-property" rel="help"> + <link href="http://www.w3.org/TR/css3-break/#parallel-flows" rel="help"> + <meta content="ahem" name="flags"> + <meta content="Test checks that no regions are left empty when setting + a forced region break on a cleared float." name="assert"> + <link href="reference/floats-clear-breaks-002-ref.htm" rel="match"> + <style> + article { + font-family: Ahem; + font-size: 20px; + line-height: 1em; + } + + .flow { + flow-into: f; + } + + .float { + float: left; + color: blue; + } + .break { + break-before: region; + } + + .clear { + clear: left; + color: green; + } + + .bordered { + border: 10px solid black; + } + + .region { + flow-from: f; + max-width: 100px; + margin-bottom: 10px; + } + + .region > p { + background: red; + } + </style> + </head> + <body> + <p> + Test passes if you see two squares separated by a small vertical space. The squares should + have a black outline, the top square should be blue and the bottom one should be green.<br> + You should see no red. + </p> + + <div class="bordered region"> + <p>&nbsp;</p> + </div> + <div class="bordered region"> + <p>&nbsp;</p> + </div> + <!-- In case the clear + forced break lead to an empty region, the content will flow in this + third region ending up without a border. --> + <div class="region"> + <p>&nbsp;</p> + </div> + + <article class="flow"> + <div class="float"> + xxxxx + xxxxx + xxxxx + xxxxx + xxxxx + </div> + <div class="break clear"> + xxxxx + xxxxx + xxxxx + xxxxx + xxxxx + </div> + </article> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/html/floats-in-named-flow-012.htm b/tests/wpt/css-tests/css-break-3_dev/html/floats-in-named-flow-012.htm new file mode 100644 index 00000000000..bc6740d843d --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/html/floats-in-named-flow-012.htm @@ -0,0 +1,83 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Test: floats with forced region breaks inside them</title> + <link href="mailto:mibalan@adobe.com" rel="author" title="Mihai Balan"> + <link href="http://www.w3.org/TR/css3-regions/#the-flow-into-property" rel="help"> + <link href="http://www.w3.org/TR/css3-break/#parallel-flows" rel="help"> + <meta content="ahem" name="flags"> + <meta content="Test checks that floats in named flow contents are floated relative + to the region container and not their initial container, even when multiple regions + are involved." name="assert"> + <link href="reference/floats-in-named-flow-012-ref.htm" rel="match"> + <style> + article { + color: blue; + font-family: Ahem; + font-size: 20px; + line-height: 1em; + } + .flow { + flow-into: f; + } + .float { + color: green; + float: left; + } + .break { + break-before: region; + } + .region { + flow-from: f; + margin: 10px; + width: 200px; + background: red; + } + + .region > p { + background: red; + } + </style> + </head> + <body> + <p> + Test passes if you see two identical rows of colored squares. Each row should have three + squares, from left to right as follows: blue, gray, green. The squares in a row should + be flush to each other, but the two rows should have some space between them.<br> + Test fails is you see any red. + </p> + + <article> + <div class="flow"> + <div class="float"> + <div> + xxxxx<br> + xxxxx<br> + xxxxx<br> + xxxxx<br> + xxxxx + </div> + <div class="break"> + xxxxx<br> + xxxxx<br> + xxxxx<br> + xxxxx<br> + xxxxx + </div> + </div> + <div> + xxxxx xxxxx xxxxx xxxxx xxxxx + </div> + <div class="break"> + xxxxx xxxxx xxxxx xxxxx xxxxx + </div> + </div> + </article> + + <div class="region"> + <p>&nbsp;</p> + </div> + <div class="region"> + <p>&nbsp;</p> + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/html/floats-in-named-flow-029.htm b/tests/wpt/css-tests/css-break-3_dev/html/floats-in-named-flow-029.htm new file mode 100644 index 00000000000..62c430a3b0c --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/html/floats-in-named-flow-029.htm @@ -0,0 +1,90 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Regions: margins around forced breaks when break is around float</title> + <link href="mailto:mibalan@adobe.com" rel="author" title="Mihai Balan"> + <link href="http://www.w3.org/TR/css3-regions/#the-flow-into-property" rel="help"> + <link href="http://www.w3.org/TR/css3-break/#break-margins" rel="help"> + <link href="http://www.w3.org/TR/css3-break/#parallel-flows" rel="help"> + <meta content="ahem" name="flags"> + <meta content="Test checks that margins are correctly preserved when content + has floats and is fragmented via forced breaks." name="assert"> + <link href="reference/floats-in-named-flow-029-ref.htm" rel="match"> + <style> + article { + font-family: Ahem; + font-size: 20px; + line-height: 1em; + } + + .flow { + flow-into: f; + } + + .break { + break-before: region; + } + + .spaced { + margin: 1em 2em 3em 5em; + color: green; + } + + .float { + float: left; + color: blue; + } + .bordered { + border: 10px solid black; + } + + .region { + flow-from: f; + float: left; + margin-left: 10px; + } + + .region > p { + background: red; + } + </style> + </head> + <body> + <p> + <!-- TODO Determine what the outcome should be - currently expecting a resolution on + the issue on www-style/css3-break --> + Test passes if you see two colored squares each inside a black-bordered rectangle: + </p><ul> + <li>The black-bordered rectangles should be separated by a small horizontal space</li> + <li>The colored squares should be positioned roughly in the top-left area of their + rectangles, but without being flush to any of its sides</li> + </ul><br> + You should see no red. + <p></p> + + <div class="bordered region"> + <p>&nbsp;</p> + </div><div class="bordered region"> + <p>&nbsp;</p> + </div> + <div class="region"> + <p>&nbsp;</p> + </div> + + <article class="flow"> + <div class="spaced float"> + xxxxx<br> + xxxxx<br> + xxxxx<br> + xxxxx<br> + xxxxx + </div> + <div class="break spaced"> + xxxxx<br> + xxxxx<br> + xxxxx<br> + xxxxx<br> + xxxxx + </div> + </article> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/html/floats-in-named-flow-030.htm b/tests/wpt/css-tests/css-break-3_dev/html/floats-in-named-flow-030.htm new file mode 100644 index 00000000000..1851c85894e --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/html/floats-in-named-flow-030.htm @@ -0,0 +1,88 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Regions: margins around unforced breaks when break is around float</title> + <link href="mailto:mibalan@adobe.com" rel="author" title="Mihai Balan"> + <link href="http://www.w3.org/TR/css3-regions/#the-flow-into-property" rel="help"> + <link href="http://www.w3.org/TR/css3-break/#break-margins" rel="help"> + <link href="http://www.w3.org/TR/css3-break/#parallel-flows" rel="help"> + <meta content="ahem" name="flags"> + <meta content="Test checks that margins are correctly preserved when content + has floats and is fragmented via unforced breaks." name="assert"> + <link href="reference/floats-in-named-flow-030-ref.htm" rel="match"> + <style> + article { + font-family: Ahem; + font-size: 20px; + line-height: 1em; + } + + .flow { + flow-into: f; + } + + .spaced { + margin: 1em 2em 3em 5em; + color: green; + } + + .float { + float: left; + color: blue; + } + + .bordered { + border: 10px solid black; + } + + .region { + flow-from: f; + /* float: left; is used to trigger shrink-to-fit sizing */ + float: left; + margin-left: 10px; + } + + .region > p { + background: red; + } + </style> + </head> + <body> + <p> + <!-- TODO Determine what the outcome should be - currently expecting a resolution on + the issue on www-style/css3-break --> + Test passes if you see two colored squares each inside a black-bordered rectangle: + </p><ul> + <li>The black-bordered rectangles should be separated by a small vertical space</li> + <li>The green square should have its top edge flush with the top border of its + containing rectangle</li> + </ul> + You should see no red. + <p></p> + + <div style="height: 125px;" class="bordered region"> + <p>&nbsp;</p> + </div><div class="bordered region"> + <p>&nbsp;</p> + </div> + <div class="region"> + <p>&nbsp;</p> + </div> + + <article class="flow"> + <div class="spaced float"> + xxxxx<br> + xxxxx<br> + xxxxx<br> + xxxxx<br> + xxxxx + </div> + <div class="spaced"> + xxxxx<br> + xxxxx<br> + xxxxx<br> + xxxxx<br> + xxxxx + </div> + </article> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/html/position-relative-001.htm b/tests/wpt/css-tests/css-break-3_dev/html/position-relative-001.htm new file mode 100644 index 00000000000..228eeeb333f --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/html/position-relative-001.htm @@ -0,0 +1,77 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Regions: flowing content that has position: relative</title> + <link href="mailto:mibalan@adobe.com" rel="author" title="Mihai Balan"> + <link href="http://www.w3.org/TR/css3-regions/#the-flow-into-property" rel="help"> + <link href="http://www.w3.org/TR/css3-regions/#flow-from" rel="help"> + <!-- Section points to section in the ED. Eventually this should be kept in the WD, too. --> + <link href="http://www.w3.org/TR/css3-break/#transforms" rel="help"> + <meta content="Test checks that fragments of content flowed in regions are positioned independently, after the fragmentation occurs." name="assert"> + <meta content="ahem" name="flags"> + <link href="reference/position-relative-001-ref.htm" rel="match"> + <style> + .flow { + flow-into: f; + font-family: Ahem; + font-size: 20px; + line-height: 1em; + color: green; + position: relative; + top: 20px; + left: -20px; + } + + .container { + display: inline-block; + } + + .region { + flow-from: f; + margin: 0 0 0 20px; + } + .region p { + background-color: red; + height: 50%; + } + .big { + width: 100px; + height: 100px; + } + .small { + width: 60px; + height: 60px; + } + + .marker { + background: red; + width: 20px; + height: 20px; + } + </style> + </head> + <body> + <p>Test passes if you see two green squares (one bigger and one smaller) and no red.</p> + <div class="flow"> + xxxxx + xxxxx + xxxxx + xxxxx + xxxxx + xxx + xxx + xxx + </div> + <div class="container"> + <div class="big region"> + <p>&nbsp;</p> + </div> + <div class="marker"></div> + </div> + <div class="container"> + <div class="small region"> + <p>&nbsp;</p> + </div> + <div class="marker"></div> + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/html/reference/floats-clear-breaks-002-ref.htm b/tests/wpt/css-tests/css-break-3_dev/html/reference/floats-clear-breaks-002-ref.htm new file mode 100644 index 00000000000..3ba70f0537f --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/html/reference/floats-clear-breaks-002-ref.htm @@ -0,0 +1,59 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Reftest Reference</title> + <link href="mailto:mibalan@adobe.com" rel="author" title="Mihai Balan"> + <style> + article { + font-family: Ahem; + font-size: 20px; + line-height: 1em; + color: green; + } + + .float { + float: left; + color: blue; + } + + .bordered { + border: 10px solid black; + } + + .region { + overflow: hidden; + max-width: 100px; + margin-bottom: 10px; + } + </style> + </head> + <body> + <p> + Test passes if you see two squares separated by a small vertical space. The squares should + have a black outline, the top square should be blue and the bottom one should be green.<br> + You should see no red. + </p> + + <div class="bordered region"> + <article> + <div class="float"> + xxxxx + xxxxx + xxxxx + xxxxx + xxxxx + </div> + </article> + </div> + <div class="bordered region"> + <article> + <div> + xxxxx + xxxxx + xxxxx + xxxxx + xxxxx + </div> + </article> + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/html/reference/floats-in-named-flow-012-ref.htm b/tests/wpt/css-tests/css-break-3_dev/html/reference/floats-in-named-flow-012-ref.htm new file mode 100644 index 00000000000..8fdf2dc5390 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/html/reference/floats-in-named-flow-012-ref.htm @@ -0,0 +1,69 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Reftest Reference</title> + <link href="mailto:mibalan@adobe.com" rel="author" title="Mihai Balan"> + <style> + article { + color: blue; + font-family: Ahem; + font-size: 20px; + line-height: 1em; + } + .float { + color: green; + float: left; + } + .region { + margin: 10px; + width: 200px; + background: red; + } + </style> + </head> + <body> + <p> + Test passes if you see two identical rows of colored squares. Each row should have three + squares, from left to right as follows: blue, gray, green. The squares in a row should + be flush to each other, but the two rows should have some space between them.<br> + Test fails is you see any red. + </p> + + + <div class="region"> + <article> + <div class="flow"> + <div class="float"> + <div> + xxxxx<br> + xxxxx<br> + xxxxx<br> + xxxxx<br> + xxxxx + </div> + </div> + <div> + xxxxx xxxxx xxxxx xxxxx xxxxx + </div> + </div> + </article> + </div> + <div class="region"> + <article> + <div class="flow"> + <div class="float"> + <div> + xxxxx<br> + xxxxx<br> + xxxxx<br> + xxxxx<br> + xxxxx + </div> + </div> + <div> + xxxxx xxxxx xxxxx xxxxx xxxxx + </div> + </div> + </article> + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/html/reference/floats-in-named-flow-029-ref.htm b/tests/wpt/css-tests/css-break-3_dev/html/reference/floats-in-named-flow-029-ref.htm new file mode 100644 index 00000000000..ce9eca89863 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/html/reference/floats-in-named-flow-029-ref.htm @@ -0,0 +1,67 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Reftest Reference</title> + <link href="mailto:mibalan@adobe.com" rel="author" title="Mihai Balan"> + <style> + article { + font-family: Ahem; + font-size: 20px; + line-height: 1em; + } + + .spaced { + margin: 1em 2em 3em 5em; + color: green; + } + + .float { + float: left; + color: blue; + } + .bordered { + border: 10px solid black; + } + + .region { + display: inline-block; + float: left; + margin-left: 10px; + } + </style> + </head> + <body> + <p> + <!-- TODO Determine what the outcome should be - currently expecting a resolution on + the issue on www-style/css3-break --> + Test passes if you see two colored squares each inside a black-bordered rectangle: + </p><ul> + <li>The black-bordered rectangles should be separated by a small horizontal space</li> + <li>The colored squares should be positioned roughly in the top-left area of their + rectangles, but without being flush to any of its sides</li> + </ul><br> + You should see no red. + <p></p> + + <div class="bordered region"> + <article> + <div class="spaced float"> + xxxxx<br> + xxxxx<br> + xxxxx<br> + xxxxx<br> + xxxxx + </div> + </article> + </div><div class="bordered region"> + <article> + <div class="break spaced"> + xxxxx<br> + xxxxx<br> + xxxxx<br> + xxxxx<br> + xxxxx + </div> + </article> + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/html/reference/floats-in-named-flow-030-ref.htm b/tests/wpt/css-tests/css-break-3_dev/html/reference/floats-in-named-flow-030-ref.htm new file mode 100644 index 00000000000..013b13978a0 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/html/reference/floats-in-named-flow-030-ref.htm @@ -0,0 +1,68 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Reftest Reference</title> + <link href="mailto:mibalan@adobe.com" rel="author" title="Mihai Balan"> + <style> + article { + font-family: Ahem; + font-size: 20px; + line-height: 1em; + } + + .spaced { + margin: 0 2em 3em 5em; + color: green; + } + .float { + margin-top: 1em; + float: left; + color: blue; + } + + .bordered { + border: 10px solid black; + } + + .region { + /* float: left; is used to trigger shrink-to-fit sizing */ + float: left;; + margin-left: 10px; + } + </style> + </head> + <body> + <p> + <!-- TODO Determine what the outcome should be - currently expecting a resolution on + the issue on www-style/css3-break --> + Test passes if you see two colored squares each inside a black-bordered rectangle: + </p><ul> + <li>The black-bordered rectangles should be separated by a small vertical space</li> + <li>The green square should have its top edge flush with the top border of its + containing rectangle</li> + </ul> + You should see no red. + <p></p> + + <div style="height: 125px;" class="bordered region"> + <article> + <div class="spaced float"> + xxxxx<br> + xxxxx<br> + xxxxx<br> + xxxxx<br> + xxxxx + </div> + </article> + </div><div class="bordered region"> + <article> + <div class="spaced"> + xxxxx<br> + xxxxx<br> + xxxxx<br> + xxxxx<br> + xxxxx + </div> + </article> + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/html/reference/position-relative-001-ref.htm b/tests/wpt/css-tests/css-break-3_dev/html/reference/position-relative-001-ref.htm new file mode 100644 index 00000000000..46cd94fc7a2 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/html/reference/position-relative-001-ref.htm @@ -0,0 +1,56 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Reftest Reference</title> + <link href="mailto:mibalan@adobe.com" rel="author" title="Mihai Balan"> + <style> + .flow { + font-family: Ahem; + font-size: 20px; + line-height: 1em; + color: green; + position: relative; + top: 20px; + left: -20px; + } + + .container { + display: inline-block; + } + + .region { + margin: 0 0 0 20px; + } + .big { + width: 100px; + height: 100px; + } + .small { + width: 60px; + height: 60px; + } + </style> + </head> + <body> + <p>Test passes if you see two green squares (one bigger and one smaller) and no red.</p> + <div class="container"> + <div class="big region"> + <div class="flow"> + xxxxx + xxxxx + xxxxx + xxxxx + xxxxx + </div> + </div> + </div> + <div class="container"> + <div class="small region"> + <div class="flow"> + xxx + xxx + xxx + </div> + </div> + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/html/reference/regions-transforms-008-ref.htm b/tests/wpt/css-tests/css-break-3_dev/html/reference/regions-transforms-008-ref.htm new file mode 100644 index 00000000000..ce9108ff292 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/html/reference/regions-transforms-008-ref.htm @@ -0,0 +1,35 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Reftest Reference</title> + <link href="mailto:rhauck@adobe.com" rel="author" title="Rebecca Hauck"> + <link href="mailto:mibalan@adobe.com" rel="reviewer" title="Mihai Balan"> <!-- 2013-07-24 --> + <style type="text/css"> + .square { + float: left; + font-family: Ahem; + font-size: 10px; + line-height: 20px; + margin-left: 10px; + color: green; + width: 100px; + height: 100px; + border: 1px solid black; + } + + </style> +</head> +<body> + <p>The test passes if:</p> + <ul> + <li>The two squares each contain five green horizontal stripes</li> + <li>There are two green horizontal stripes below the square on right</li> + <li>There is no red</li> + </ul> + <div class="square"> + XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX + </div> + <div class="square"> + XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/html/reference/regions-transforms-013-alt-ref.htm b/tests/wpt/css-tests/css-break-3_dev/html/reference/regions-transforms-013-alt-ref.htm new file mode 100644 index 00000000000..0eace8442ab --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/html/reference/regions-transforms-013-alt-ref.htm @@ -0,0 +1,20 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Reftest Reference</title> + <link href="mailto:rhauck@adobe.com" rel="author" title="Rebecca Hauck"> + <link href="mailto:mibalan@adobe.com" rel="reviewer" title="Mihai Balan"> <!-- 2013-07-24 --> + <style type="text/css"> + .green-rect { + width: 100px; + height: 200px; + margin-left: 10px; + float: left; + background-color: green; + } + </style> +</head> +<body> + <p>The test passes if you see either two green squares or one vertical green rectangle. There should be no red.</p> + <div class="green-rect"></div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/html/reference/regions-transforms-013-ref.htm b/tests/wpt/css-tests/css-break-3_dev/html/reference/regions-transforms-013-ref.htm new file mode 100644 index 00000000000..3e94de81be9 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/html/reference/regions-transforms-013-ref.htm @@ -0,0 +1,21 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Reftest Reference</title> + <link href="mailto:dalcala@adobe.com" rel="author" title="David Alcala"> + <link href="mailto:mibalan@adobe.com" rel="reviewer" title="Mihai Balan"> <!-- 2013-07-24 --> + <style type="text/css"> + .green-square { + width: 100px; + height: 100px; + margin-left: 10px; + float: left; + background-color: green; + } + </style> +</head> +<body> + <p>The test passes if you see either two green squares or one vertical green rectangle. There should be no red.</p> + <div class="green-square"></div> + <div class="green-square"></div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/html/reference/regions-transforms-020-ref.htm b/tests/wpt/css-tests/css-break-3_dev/html/reference/regions-transforms-020-ref.htm new file mode 100644 index 00000000000..1064759b018 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/html/reference/regions-transforms-020-ref.htm @@ -0,0 +1,21 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Reftest Reference</title> + <link href="mailto:rhauck@adobe.com" rel="author" title="Rebecca Hauck"> + <link href="mailto:mibalan@adobe.com" rel="reviewer" title="Mihai Balan"> <!-- 2013-07-24 --> + <style type="text/css"> + .green-square { + width: 100px; + height: 100px; + margin-left: 10px; + float: left; + background-color: green; + } + </style> +</head> +<body> + <p>The test passes if you see two green squares and no red.</p> + <div class="green-square"></div> + <div class="green-square"></div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/html/reftest-toc.htm b/tests/wpt/css-tests/css-break-3_dev/html/reftest-toc.htm new file mode 100644 index 00000000000..e365643ca9a --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/html/reftest-toc.htm @@ -0,0 +1,121 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>CSS Fragmentation Module Level 3 CR Test Suite Reftest Index</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Fragmentation Module Level 3 CR Test Suite Reftest Index</h1> + <table width="100%"> + <col id="test-column"> + <col id="ref-column"> + <col id="flags-column"> + <thead> + <tr> + <th>Test</th> + <th>Reference</th> + <th>Flags</th> + </tr> + </thead> + <tbody id="floats-clear-breaks-002" class="ahem"> + <tr> + <td rowspan="1" title="CSS Regions: forced region breaks and clear on floats inside named flow contents"> + <a href="floats-clear-breaks-002.htm">floats-clear-breaks-002</a></td> + <td><a href="reference/floats-clear-breaks-002-ref.htm">=</a> </td> + <td rowspan="1"><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + </tr> + </tbody> + <tbody id="floats-in-named-flow-012" class="ahem"> + <tr> + <td rowspan="1" title="floats with forced region breaks inside them"> + <a href="floats-in-named-flow-012.htm">floats-in-named-flow-012</a></td> + <td><a href="reference/floats-in-named-flow-012-ref.htm">=</a> </td> + <td rowspan="1"><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + </tr> + </tbody> + <tbody id="floats-in-named-flow-029" class="ahem"> + <tr> + <td rowspan="1" title="CSS Regions: margins around forced breaks when break is around float"> + <a href="floats-in-named-flow-029.htm">floats-in-named-flow-029</a></td> + <td><a href="reference/floats-in-named-flow-029-ref.htm">=</a> </td> + <td rowspan="1"><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + </tr> + </tbody> + <tbody id="floats-in-named-flow-030" class="ahem"> + <tr> + <td rowspan="1" title="CSS Regions: margins around unforced breaks when break is around float"> + <a href="floats-in-named-flow-030.htm">floats-in-named-flow-030</a></td> + <td><a href="reference/floats-in-named-flow-030-ref.htm">=</a> </td> + <td rowspan="1"><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + </tr> + </tbody> + <tbody id="position-relative-001" class="ahem"> + <tr> + <td rowspan="1" title="CSS Regions: flowing content that has position: relative"> + <a href="position-relative-001.htm">position-relative-001</a></td> + <td><a href="reference/position-relative-001-ref.htm">=</a> </td> + <td rowspan="1"><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + </tr> + </tbody> + <tbody id="regions-transforms-008" class="ahem"> + <tr> + <td rowspan="1" title="CSS Regions: Transformed named flow (text) content that breaks across multiple regions and overflows"> + <a href="regions-transforms-008.htm">regions-transforms-008</a></td> + <td><a href="reference/regions-transforms-008-ref.htm">=</a> </td> + <td rowspan="1"><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + </tr> + </tbody> + <tbody id="regions-transforms-009" class="ahem"> + <tr> + <td rowspan="1" title="CSS Regions: Transformed region with named flow (text) content that breaks across multiple regions and overflows"> + <a href="regions-transforms-009.htm">regions-transforms-009</a></td> + <td><a href="reference/regions-transforms-008-ref.htm">=</a> </td> + <td rowspan="1"><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + </tr> + </tbody> + <tbody id="regions-transforms-013" class=""> + <tr> + <td rowspan="2" title="CSS Regions: Transformed named flow (monolithic) content that breaks across multiple regions"> + <a href="regions-transforms-013.htm">regions-transforms-013</a></td> + <td><a href="reference/regions-transforms-013-alt-ref.htm">=</a> </td> + <td rowspan="2"></td> + </tr> + <tr> + <td><a href="reference/regions-transforms-013-alt-ref.htm">=</a></td> + </tr> + </tbody> + <tbody id="regions-transforms-020" class=""> + <tr> + <td rowspan="1" title="CSS Regions: Transformed region with named flow (fragmentable) content that breaks across multiple regions"> + <a href="regions-transforms-020.htm">regions-transforms-020</a></td> + <td><a href="reference/regions-transforms-020-ref.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="regions-transforms-021" class=""> + <tr> + <td rowspan="1" title="CSS Regions: Transforms on multiple named flow (non-text) content nodes that break across multiple regions"> + <a href="regions-transforms-021.htm">regions-transforms-021</a></td> + <td><a href="reference/regions-transforms-020-ref.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="regions-transforms-022" class="ahem"> + <tr> + <td rowspan="1" title="CSS Regions: Transforms on multiple named flow (text) content nodes that break across multiple regions"> + <a href="regions-transforms-022.htm">regions-transforms-022</a></td> + <td><a href="reference/regions-transforms-020-ref.htm">=</a> </td> + <td rowspan="1"><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + </tr> + </tbody> + </table> + + </body> +</html> diff --git a/tests/wpt/css-tests/css-break-3_dev/html/reftest.list b/tests/wpt/css-tests/css-break-3_dev/html/reftest.list new file mode 100644 index 00000000000..f57885750a6 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/html/reftest.list @@ -0,0 +1,13 @@ + +floats-clear-breaks-002.htm == reference/floats-clear-breaks-002-ref.htm +floats-in-named-flow-012.htm == reference/floats-in-named-flow-012-ref.htm +floats-in-named-flow-029.htm == reference/floats-in-named-flow-029-ref.htm +floats-in-named-flow-030.htm == reference/floats-in-named-flow-030-ref.htm +position-relative-001.htm == reference/position-relative-001-ref.htm +regions-transforms-008.htm == reference/regions-transforms-008-ref.htm +regions-transforms-009.htm == reference/regions-transforms-008-ref.htm +regions-transforms-013.htm == reference/regions-transforms-013-alt-ref.htm +regions-transforms-013.htm == reference/regions-transforms-013-ref.htm +regions-transforms-020.htm == reference/regions-transforms-020-ref.htm +regions-transforms-021.htm == reference/regions-transforms-020-ref.htm +regions-transforms-022.htm == reference/regions-transforms-020-ref.htm diff --git a/tests/wpt/css-tests/css-break-3_dev/html/regions-transforms-008.htm b/tests/wpt/css-tests/css-break-3_dev/html/regions-transforms-008.htm new file mode 100644 index 00000000000..6ccf4375168 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/html/regions-transforms-008.htm @@ -0,0 +1,74 @@ +<!DOCTYPE html> +<html><head> + <meta charset="UTF-8"> + <title>CSS Regions: Transformed named flow (text) content that breaks across multiple regions and overflows</title> + <link href="mailto:rhauck@adobe.com" rel="author" title="Rebecca Hauck"> + <link href="mailto:dalcala@adobe.com" rel="author" title="David Alcala"> + <link href="mailto:mibalan@adobe.com" rel="reviewer author" title="Mihai Balan"> <!-- 2013-07-24 --> + <link href="http://www.w3.org/TR/css3-regions/#the-flow-into-property" rel="help"> + <link href="http://www.w3.org/TR/css3-regions/#flow-from" rel="help"> + <link href="http://www.w3.org/TR/css-transforms-1/#two-d-transform-functions" rel="help"> + <link href="http://www.w3.org/TR/css3-break/#transforms" rel="help"> + <link href="reference/regions-transforms-008-ref.htm" rel="match"> + <meta content="ahem" name="flags"> + <meta content="This test checks that named flow text content is transformed when it breaks across + multiple regions and that the overflow remains visible." name="assert"> + <style> + .ahem { + font-family: Ahem; + font-size: 10px; + line-height: 20px; + } + #named-flow { + color: green; + margin-left: -50px; + transform: translateX(50px); + flow-into: f; + } + .region { + width: 100px; + height: 100px; + margin-left: 10px; + float: left; + border: 1px solid black; + flow-from: f; + } + .failure { + position: absolute; + width: 102px; + height: 102px; + margin-top: 1px; + margin-left: 10px; + padding-left: 1px; + color: red; + z-index: -1; + } + .left { + left: 8px; + } + .right { + left: 120px; + } + </style> +</head> +<body> + <p>The test passes if:</p> + <ul> + <li>The two squares each contain five green horizontal stripes</li> + <li>There are two green horizontal stripes below the square on right</li> + <li>There is no red</li> + </ul> + <div class="ahem" id="named-flow">XXXXXXXXXXX XXXXXXXXXXX XXXXXXXXXXX XXXXXXXXXXX XXXXXXXXXXX XXXXXXXXXXX XXXXXXXXXXX XXXXXXXXXXX XXXXXXXXXXX XXXXXXXXXXX XXXXXXXXXXX XXXXXXXXXXX</div> + <div class="region"></div> + <div class="region"></div> + + <div class="ahem failure left"> + XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX + </div> + <div class="ahem failure right"> + XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX + </div> + + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/html/regions-transforms-009.htm b/tests/wpt/css-tests/css-break-3_dev/html/regions-transforms-009.htm new file mode 100644 index 00000000000..bee9566e45d --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/html/regions-transforms-009.htm @@ -0,0 +1,74 @@ +<!DOCTYPE html> +<html><head> + <meta charset="UTF-8"> + <title>CSS Regions: Transformed region with named flow (text) content that breaks across multiple regions and overflows</title> + <link href="mailto:rhauck@adobe.com" rel="author" title="Rebecca Hauck"> + <link href="mailto:dalcala@adobe.com" rel="author" title="David Alcala"> + <link href="mailto:mibalan@adobe.com" rel="reviewer" title="Mihai Balan"> <!-- 2013-07-24 --> + <link href="http://www.w3.org/TR/css3-regions/#the-flow-into-property" rel="help"> + <link href="http://www.w3.org/TR/css3-regions/#flow-from" rel="help"> + <link href="http://www.w3.org/TR/css-transforms-1/#two-d-transform-functions" rel="help"> + <link href="http://www.w3.org/TR/css3-break/#transforms" rel="help"> + <link href="reference/regions-transforms-008-ref.htm" rel="match"> + <meta content="ahem" name="flags"> + <meta content="This test checks that the regions are transformed when named flow text content breaks + across multiple regions and that the overflow remains visible." name="assert"> + <style> + .ahem { + font-family: Ahem; + font-size: 10px; + line-height: 20px; + } + #named-flow { + color: green; + flow-into: f; + } + .region { + width: 100px; + height: 100px; + float: left; + margin-left: 10px; + border: 1px solid black; + flow-from: f; + transform: translateX(50px); + } + .failure-left, + .failure-right { + position: absolute; + width: 102px; + height: 102px; + margin-top: 1px; + margin-left: 10px; + padding-left: 1px; + color: red; + z-index: -1; + } + .left { + margin-left: -40px; + } + .failure-left { + left: 8px; + } + .failure-right { + left: 120px; + } + </style> +</head> +<body> + <p>The test passes if:</p> + <ul> + <li>The two squares each contain five green horizontal stripes</li> + <li>There are two green horizontal stripes below the square on right</li> + <li>There is no red</li> + </ul> + <div class="ahem" id="named-flow">XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX</div> + <div class="region left"></div> + <div class="region"></div> + <div class="ahem failure-left"> + XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX + </div> + <div class="ahem failure-right"> + XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/html/regions-transforms-013.htm b/tests/wpt/css-tests/css-break-3_dev/html/regions-transforms-013.htm new file mode 100644 index 00000000000..8a5feb9737a --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/html/regions-transforms-013.htm @@ -0,0 +1,47 @@ +<!DOCTYPE html> +<html><head> + <meta charset="UTF-8"> + <title>CSS Regions: Transformed named flow (monolithic) content that breaks across multiple regions</title> + <link href="mailto:rhauck@adobe.com" rel="author" title="Rebecca Hauck"> + <link href="mailto:dalcala@adobe.com" rel="author" title="David Alcala"> + <link href="mailto:mibalan@adobe.com" rel="reviewer" title="Mihai Balan"> <!-- 2013-07-24 --> + <link href="http://www.w3.org/TR/css3-regions/#the-flow-into-property" rel="help"> + <link href="http://www.w3.org/TR/css3-regions/#flow-from" rel="help"> + <link href="http://www.w3.org/TR/css-transforms-1/#two-d-transform-functions" rel="help"> + <link href="http://www.w3.org/TR/css3-break/#transforms" rel="help"> + <link href="http://www.w3.org/TR/css3-break/#breaking-rules" rel="help"> + <link href="http://www.w3.org/TR/css3-break/#monolithic" rel="help"> + <!-- This reference is for UAs that slice monolithic content --> + <link href="reference/regions-transforms-013-ref.htm" rel="match"> + <!-- This reference is for UAs that overflow monolithic content --> + <link href="reference/regions-transforms-013-alt-ref.htm" rel="match"> + <meta content="This test checks that the named flow content that is monolithic is transformed when it + breaks across multiple regions whether it is sliced or overflowed at the fragmentainer edge." name="assert"> + <style> + #named-flow { + width: 100px; + height: 100px; + background-color: green; + transform: scaleY(2); + transform-origin: top left; + flow-into: f; + } + .region { + width: 100px; + height: 100px; + margin-left: 10px; + float: left; + flow-from: f; + } + #region1 { + background-color: red; + } + </style> +</head> +<body> + <p>The test passes if you see either two green squares or one vertical green rectangle. There should be no red.</p> + <div id="named-flow"></div> + <div class="region" id="region1"></div> + <div class="region"></div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/html/regions-transforms-020.htm b/tests/wpt/css-tests/css-break-3_dev/html/regions-transforms-020.htm new file mode 100644 index 00000000000..a6c0af09d5b --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/html/regions-transforms-020.htm @@ -0,0 +1,61 @@ +<!DOCTYPE html> +<html><head> + <meta charset="UTF-8"> + <title>CSS Regions: Transformed region with named flow (fragmentable) content that breaks across multiple regions</title> + <link href="mailto:dalcala@adobe.com" rel="author" title="David Alcala"> + <link href="mailto:rhauck@adobe.com" rel="author" title="Rebecca Hauck"> + <link href="mailto:mibalan@adobe.com" rel="reviewer" title="Mihai Balan"> <!-- 2013-07-24 --> + <link href="http://www.w3.org/TR/css3-regions/#the-flow-into-property" rel="help"> + <link href="http://www.w3.org/TR/css3-regions/#flow-from" rel="help"> + <link href="http://www.w3.org/TR/css-transforms-1/#two-d-transform-functions" rel="help"> + <link href="http://www.w3.org/TR/css3-break/#transforms" rel="help"> + <link href="http://www.w3.org/TR/css3-break/#breaking-rules" rel="help"> + <link href="reference/regions-transforms-020-ref.htm" rel="match"> + <meta content="This test checks that the named flow content that is fragmentable (has a break point) + is transformed when it breaks across multiple regions." name="assert"> + <style> + #named-flow { + width: 100px; + height: 100px; + flow-into: f; + } + .src-child { + height: 50px; + background-color: green; + } + .region { + width: 100px; + height: 50px; + margin-left: 10px; + float: left; + background-color: red; + flow-from: f; + transform: scaleY(2); + transform-origin: top left; + } + + .failure-div { + position: absolute; + margin-left: 10px; + background-color: red; + width: 98px; + height: 98px; + } + .right { + left: 119px; + } + </style> +</head> +<body> + <p>The test passes if you see two green squares and no red.</p> + <div class="failure-div"></div> + <div class="failure-div right"></div> + <div id="named-flow"> + <div class="src-child"></div> + <div class="src-child"></div> + </div> + <div class="region"></div> + <div class="region"></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/html/regions-transforms-021.htm b/tests/wpt/css-tests/css-break-3_dev/html/regions-transforms-021.htm new file mode 100644 index 00000000000..814129c4906 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/html/regions-transforms-021.htm @@ -0,0 +1,53 @@ +<!DOCTYPE html> +<html><head> + <meta charset="UTF-8"> + <title>CSS Regions: Transforms on multiple named flow (non-text) content nodes that break across multiple regions</title> + <link href="mailto:dalcala@adobe.com" rel="author" title="David Alcala"> + <link href="mailto:rhauck@adobe.com" rel="author" title="Rebecca Hauck"> + <link href="mailto:mibalan@adobe.com" rel="reviewer" title="Mihai Balan"> <!-- 2013-07-24 --> + <link href="http://www.w3.org/TR/css3-regions/#the-flow-into-property" rel="help"> + <link href="http://www.w3.org/TR/css3-regions/#flow-from" rel="help"> + <link href="http://www.w3.org/TR/css-transforms-1/#two-d-transform-functions" rel="help"> + <link href="http://www.w3.org/TR/css3-break/#transforms" rel="help"> + <link href="reference/regions-transforms-020-ref.htm" rel="match"> + <meta content="This test checks that separate transforms can be applied to each named flow content + node that breaks across multiple regions and that each fragment has its own transform origin." name="assert"> + <style> + .named-flow { + float: left; + background-color: green; + flow-into: f; + } + #named-flow-1 { + margin-top: 25px; + margin-left: 25px; + width: 50px; + height: 50px; + transform: scale(2); + transform-origin: center center; + } + #named-flow-2 { + width: 100px; + height: 50px; + margin-top: 25px; + transform-origin: top left; + transform: scaleY(2); + } + .region { + width: 100px; + height: 100px; + margin-left: 10px; + float: left; + background-color: red; + flow-from: f; + } + </style> +</head> +<body> + <p>The test passes if you see two green squares and no red.</p> + <div id="named-flow-1" class="named-flow"></div> + <div id="named-flow-2" class="named-flow"></div> + <div class="region"></div> + <div class="region"></div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/html/regions-transforms-022.htm b/tests/wpt/css-tests/css-break-3_dev/html/regions-transforms-022.htm new file mode 100644 index 00000000000..e433da77ff4 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/html/regions-transforms-022.htm @@ -0,0 +1,83 @@ +<!DOCTYPE html> +<html><head> + <meta charset="UTF-8"> + <title>CSS Regions: Transforms on multiple named flow (text) content nodes that break across multiple regions</title> + <link href="mailto:dalcala@adobe.com" rel="author" title="David Alcala"> + <link href="mailto:rhauck@adobe.com" rel="author" title="Rebecca Hauck"> + <link href="mailto:mibalan@adobe.com" rel="reviewer" title="Mihai Balan"> <!-- 2013-07-24 --> + <link href="http://www.w3.org/TR/css3-regions/#the-flow-into-property" rel="help"> + <link href="http://www.w3.org/TR/css3-regions/#flow-from" rel="help"> + <link href="http://www.w3.org/TR/css-transforms-1/#two-d-transform-functions" rel="help"> + <link href="http://www.w3.org/TR/css3-break/#transforms" rel="help"> + <link href="reference/regions-transforms-020-ref.htm" rel="match"> + <meta content="ahem" name="flags"> + <meta content="This test checks that separate transforms can be applied to each named flow content + text node that breaks across multiple regions" name="assert"> + <style> + .ahem { + font-family: Ahem; + font-size: 10px; + line-height: 20px; + } + .named-flow { + width: 100px; + color: green; + flow-into: f; + } + #named-flow-1 { + margin-left: -50px; + transform: translateX(50px); + } + #named-flow-2 { + transform: rotate(90deg); + } + .region { + width: 100px; + height: 100px; + margin-left: 10px; + float: left; + flow-from: f; + } + .failure { + width: 100px; + height: 100px; + position: absolute; + float: left; + margin-left: 10px; + background-color: green; + z-index: -1; + } + .left { + color: red; + } + .right { + left: 118px; + } + .vertical-bar { + width: 10px; + height: 100px; + float: left; + background-color: red; + margin-left: 5px; + margin-right: 5px; + } + </style> +</head> +<body> + <p>The test passes if you see two green squares and no red.</p> + <div id="named-flow-1" class="ahem named-flow">XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX</div> + <div id="named-flow-2" class="ahem named-flow">XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX</div> + <div class="region"></div> + <div class="region"></div> + <div class="ahem failure left"> + XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX + </div> + <div class="ahem failure right"> + <div class="vertical-bar"></div> + <div class="vertical-bar"></div> + <div class="vertical-bar"></div> + <div class="vertical-bar"></div> + <div class="vertical-bar"></div> + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/html/toc.htm b/tests/wpt/css-tests/css-break-3_dev/html/toc.htm new file mode 100644 index 00000000000..ce47a1dbe86 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/html/toc.htm @@ -0,0 +1,54 @@ + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>CSS Fragmentation Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> +<body> + <h1>CSS Fragmentation Module Level 3 CR Test Suite By Chapter</h1> + + <p>This index contains both + <a href="http://wiki.csswg.org/test/selftest">self-describing tests</a> + and reftests. + A separate <a href="reftest-toc.htm">alphabetical reftest index</a> + is provided for tests in <a href="http://wiki.csswg.org/test/reftest">reftest + format</a> along with the <a href="reftest.list">reftest manifest</a>.</p> + + <table> + <tbody id="s1"> + <tr><th><a href="chapter-1.htm">Chapter 1 - + Introduction</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s2"> + <tr><th><a href="chapter-2.htm">Chapter 2 - + Fragmentation Model and Terminology</a></th> + <td>(4 Tests)</td></tr> + </tbody> + <tbody id="s3"> + <tr><th><a href="chapter-3.htm">Chapter 3 - + Controlling Breaks</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s4"> + <tr><th><a href="chapter-4.htm">Chapter 4 - + Rules for Breaking</a></th> + <td>(2 Tests)</td></tr> + </tbody> + <tbody id="s5"> + <tr><th><a href="chapter-5.htm">Chapter 5 - + Box Model for Breaking</a></th> + <td>(9 Tests)</td></tr> + </tbody> + <tbody id="s6"> + <tr><th><a href="chapter-6.htm">Chapter 6 - + Conformance</a></th> + <td>(0 Tests)</td></tr> + </tbody> + </table> +</body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/implementation-report-TEMPLATE.data b/tests/wpt/css-tests/css-break-3_dev/implementation-report-TEMPLATE.data new file mode 100644 index 00000000000..ab33f718135 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/implementation-report-TEMPLATE.data @@ -0,0 +1,27 @@ +# UA version OS version +# UA string (if applicable) +# http://test.csswg.org/suites/css-break-3_dev/DATESTAMP/ +# See http://wiki.csswg.org/test/implementation-report for instructions +testname revision result comment +html/floats-clear-breaks-002.htm 66e95858ed37b82eeb7e8e883d8f1b3a1b51f8a4 ? +xhtml1/floats-clear-breaks-002.xht 66e95858ed37b82eeb7e8e883d8f1b3a1b51f8a4 ? +html/floats-in-named-flow-012.htm eafba0507ab9b5fb89bea9e14f8256691bfd2891 ? +xhtml1/floats-in-named-flow-012.xht eafba0507ab9b5fb89bea9e14f8256691bfd2891 ? +html/floats-in-named-flow-029.htm 3a5945dba8044ac56ae8d27832493141b8e556c6 ? +xhtml1/floats-in-named-flow-029.xht 3a5945dba8044ac56ae8d27832493141b8e556c6 ? +html/floats-in-named-flow-030.htm 3ed67f145da3817c1a9fe305372efcfca35292cc ? +xhtml1/floats-in-named-flow-030.xht 3ed67f145da3817c1a9fe305372efcfca35292cc ? +html/position-relative-001.htm d5b56444d0e5b6a788abe05b11f6dd25076c10d2 ? +xhtml1/position-relative-001.xht d5b56444d0e5b6a788abe05b11f6dd25076c10d2 ? +html/regions-transforms-008.htm d8a4209344da1bc8fceaf310ad275d0c3bb56fb6 ? +xhtml1/regions-transforms-008.xht d8a4209344da1bc8fceaf310ad275d0c3bb56fb6 ? +html/regions-transforms-009.htm 14c43707256b41cd6dfc0e25dddd2bdf0131ce64 ? +xhtml1/regions-transforms-009.xht 14c43707256b41cd6dfc0e25dddd2bdf0131ce64 ? +html/regions-transforms-013.htm be1b126597c212f49292d68542edfe8c2a2fe844 ? +xhtml1/regions-transforms-013.xht be1b126597c212f49292d68542edfe8c2a2fe844 ? +html/regions-transforms-020.htm e73e7a72635a5605583e23fde99f54047a81c339 ? +xhtml1/regions-transforms-020.xht e73e7a72635a5605583e23fde99f54047a81c339 ? +html/regions-transforms-021.htm 0870c65471db6185829589066be514d54fe2d274 ? +xhtml1/regions-transforms-021.xht 0870c65471db6185829589066be514d54fe2d274 ? +html/regions-transforms-022.htm 9aa8e9bb44f895b0429ea824b447abdcb9f533e3 ? +xhtml1/regions-transforms-022.xht 9aa8e9bb44f895b0429ea824b447abdcb9f533e3 ? diff --git a/tests/wpt/css-tests/css-break-3_dev/index.htm b/tests/wpt/css-tests/css-break-3_dev/index.htm new file mode 100644 index 00000000000..50eb5d31b48 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/index.htm @@ -0,0 +1,140 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html lang="en"> + <head> + <title>CSS Fragmentation Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "indices.css"; + </style> + </head> + <body> + + + <h1>CSS Fragmentation Module Level 3 CR Test Suite</h1> + <dt>Test Coordinator:</dt> + <dd>None Yet</dd> + + <p>This is a <strong>Development</strong> + version of the CSS Fragmentation Module Level 3 CR Test Suite.</p> + + <p>You can provide test data or review the testing results for this test suite:</p> + <dt><a href="http://test.csswg.org/harness/suite/css-break-3_dev">Enter Data</a></dt> + <dt><a href="http://test.csswg.org/harness/review/css-break-3_dev">Review Results</a></dt> + + + <p>Some tests in the test suite may contain errors. + Please check the latest version of the + <a href="http://www.w3.org/TR/css3-break/">CSS Fragmentation 3 specification</a> + <strong>and its errata</strong> + before assuming a failure is due to an implementation bug and + not a test suite bug.</p> + + + <p> + In time we hope to correct all errors and extend this test suite to + cover all of CSS Fragmentation 3. Your help is welcome in this effort. + The appropriate mailing list for submitting tests and bug reports is + <a href="http://lists.w3.org/Archives/Public/public-css-testsuite/">public-css-testsuite@w3.org</a>. + More information on the contribution process and test guidelines is + available on the <a href="http://wiki.csswg.org/test">wiki + page</a>.</p> + + <p>Tests are currently available in these formats:</p> + + <dl> + <dt><a href="html/toc.htm">HTML 5</a></dt> + <dd>HTML 5 tests sent as <code>text/html</code></dd> + <dt><a href="xhtml1/toc.xht">XHTML 1.1</a></dt> + <dd>XHTML 1.1 tests sent as <code>application/xhtml+xml</code></dd> + <dt><a href="xhtml1print/toc.xht">XHTML 1.1 for Printers</a></dt> + <dd>XHTML 1.1 tests with all images converted from PNG to JPEG + and formatted with headers and footers to ease testing of + embedded printer software. This is not a canonical format, + and some tests may fail due to the format conversion that + would otherwise pass in the above XHTML 1.1 format.</dd> + </dl> + + + <p>Unless the test instructions explicitly indicate otherwise, + any occurrence of red in a test indicates test failure.</p> + +<h2 id="implement">Implementation Reports</h2> + <p>An <a href="implementation-report-TEMPLATE.data">implementation report template</a> + is available to help with creating implementation reports. See also the + <a href="http://lists.w3.org/Archives/Public/public-css-testsuite/2010Aug/0020.html">explanation</a> + of its format.</p> + +<h2 id="common">Common Assumptions</h2> + + <p>Most of the test suite makes the following assumptions:</p> + <ul> + <li>The X/HTML <code>div</code> element is assigned <code>display: block;</code> + and no other property declaration.</li> + <li>The X/HTML <code>span</code> element is assigned <code>display: inline;</code> + and no other property declaration.</li> + <li>The X/HTML <code>p</code> element is assigned <code>display: block;</code></li> + <li>The X/HTML <code>li</code> element is assigned <code>display: list-item;</code></li> + <li>The X/HTML table elements <code>table</code>, <code>tbody</code>, + <code>tr</code>, and <code>td</code> are assigned the <code>display</code> + values <code>table</code>, <code>table-row-group</code>, + <code>table-row</code>, and <code>table-cell</code>, respectively.</li> + <li>The device can display the sixteen color values associated with the color + keywords <code>black</code>, <code>white</code>, <code>gray</code>, + <code>silver</code>, <code>red</code>, <code>green</code>, <code>blue</code>, + <code>purple</code>, <code>yellow</code>, <code>orange</code>, <code>teal</code>, + <code>fuchsia</code>, <code>maroon</code>, <code>navy</code>, <code>aqua</code>, + and <code>lime</code> as distinct colors.</li> + <li>The UA is set to print background colors and, if it supports graphics, + background images.</li> + <li>The UA implements reasonable page-breaking behavior; e.g., it is assumed + that UAs will not break at every opportunity, but only near the end of + a page unless a page break is forced.</li> + <li>The UA implements reasonable line-breaking behavior; e.g., it is assumed + that spaces between alphanumeric characters provide line breaking + opportunities and that UAs will not break at every opportunity, but only + near the end of a line unless a line break is forced.</li> + </ul> + +<h2 id="uncommon">Uncommon Assumptions</h2> + + <p>In addition, some of the tests make one or more of the following + assumptions:</p> + + <ul> + <li>The device is a full-color device.</li> + <li>The device has a viewport width of at least 640px (approx).</li> + <li>The resolution of the device is 96 CSS pixels per inch.</li> + <li>The UA imposes no minimum font size.</li> + <li>The 'medium' font-size computes to 16px.</li> + <li>The initial value of 'color' is black.</li> + <li>The canvas background is white.</li> + <li>The user stylesheet is empty (except where indicated by the tests).</li> + <li>The device is interactive and uses scroll bars.</li> + </ul> + + <p>The tests that need these assumptions to be true have not yet been + marked, but it is likely that we will add a way to identify these + tests in due course. Tests should avoid relying on these assumptions + unless necessary.</p> + +<h2>License</h2> + + <p>This test suite is licensed under both the + <a href="http://www.w3.org/Consortium/Legal/2008/04-testsuite-license">W3C + Test Suite License</a> and the <a href="http://www.w3.org/Consortium/Legal/2008/03-bsd-license">W3C + 3-clause BSD License</a>. See W3C Legal's <a href="http://www.w3.org/Consortium/Legal/2008/04-testsuite-copyright">explanation + of the licenses</a>.</p> + +<h2>Acknowledgements</h2> + + <p>Many thanks to the following for their contributions:</p> + <ul> + <li>David Alcala</li> + <li>Mihai Balan</li> + <li>Rebecca Hauck</li> + </ul> + +</body> +</html> diff --git a/tests/wpt/css-tests/css-break-3_dev/index.xht b/tests/wpt/css-tests/css-break-3_dev/index.xht new file mode 100644 index 00000000000..c90a9c03bc4 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/index.xht @@ -0,0 +1,140 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> + <head> + <title>CSS Fragmentation Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "indices.css"; + </style> + </head> + <body> + + + <h1>CSS Fragmentation Module Level 3 CR Test Suite</h1> + <dt>Test Coordinator:</dt> + <dd>None Yet</dd> + + <p>This is a <strong>Development</strong> + version of the CSS Fragmentation Module Level 3 CR Test Suite.</p> + + <p>You can provide test data or review the testing results for this test suite:</p> + <dt><a href="http://test.csswg.org/harness/suite/css-break-3_dev">Enter Data</a></dt> + <dt><a href="http://test.csswg.org/harness/review/css-break-3_dev">Review Results</a></dt> + + + <p>Some tests in the test suite may contain errors. + Please check the latest version of the + <a href="http://www.w3.org/TR/css3-break/">CSS Fragmentation 3 specification</a> + <strong>and its errata</strong> + before assuming a failure is due to an implementation bug and + not a test suite bug.</p> + + + <p> + In time we hope to correct all errors and extend this test suite to + cover all of CSS Fragmentation 3. Your help is welcome in this effort. + The appropriate mailing list for submitting tests and bug reports is + <a href="http://lists.w3.org/Archives/Public/public-css-testsuite/">public-css-testsuite@w3.org</a>. + More information on the contribution process and test guidelines is + available on the <a href="http://wiki.csswg.org/test">wiki + page</a>.</p> + + <p>Tests are currently available in these formats:</p> + + <dl> + <dt><a href="html/toc.htm">HTML 5</a></dt> + <dd>HTML 5 tests sent as <code>text/html</code></dd> + <dt><a href="xhtml1/toc.xht">XHTML 1.1</a></dt> + <dd>XHTML 1.1 tests sent as <code>application/xhtml+xml</code></dd> + <dt><a href="xhtml1print/toc.xht">XHTML 1.1 for Printers</a></dt> + <dd>XHTML 1.1 tests with all images converted from PNG to JPEG + and formatted with headers and footers to ease testing of + embedded printer software. This is not a canonical format, + and some tests may fail due to the format conversion that + would otherwise pass in the above XHTML 1.1 format.</dd> + </dl> + + + <p>Unless the test instructions explicitly indicate otherwise, + any occurrence of red in a test indicates test failure.</p> + +<h2 id="implement">Implementation Reports</h2> + <p>An <a href="implementation-report-TEMPLATE.data">implementation report template</a> + is available to help with creating implementation reports. See also the + <a href="http://lists.w3.org/Archives/Public/public-css-testsuite/2010Aug/0020.html">explanation</a> + of its format.</p> + +<h2 id="common">Common Assumptions</h2> + + <p>Most of the test suite makes the following assumptions:</p> + <ul> + <li>The X/HTML <code>div</code> element is assigned <code>display: block;</code> + and no other property declaration.</li> + <li>The X/HTML <code>span</code> element is assigned <code>display: inline;</code> + and no other property declaration.</li> + <li>The X/HTML <code>p</code> element is assigned <code>display: block;</code></li> + <li>The X/HTML <code>li</code> element is assigned <code>display: list-item;</code></li> + <li>The X/HTML table elements <code>table</code>, <code>tbody</code>, + <code>tr</code>, and <code>td</code> are assigned the <code>display</code> + values <code>table</code>, <code>table-row-group</code>, + <code>table-row</code>, and <code>table-cell</code>, respectively.</li> + <li>The device can display the sixteen color values associated with the color + keywords <code>black</code>, <code>white</code>, <code>gray</code>, + <code>silver</code>, <code>red</code>, <code>green</code>, <code>blue</code>, + <code>purple</code>, <code>yellow</code>, <code>orange</code>, <code>teal</code>, + <code>fuchsia</code>, <code>maroon</code>, <code>navy</code>, <code>aqua</code>, + and <code>lime</code> as distinct colors.</li> + <li>The UA is set to print background colors and, if it supports graphics, + background images.</li> + <li>The UA implements reasonable page-breaking behavior; e.g., it is assumed + that UAs will not break at every opportunity, but only near the end of + a page unless a page break is forced.</li> + <li>The UA implements reasonable line-breaking behavior; e.g., it is assumed + that spaces between alphanumeric characters provide line breaking + opportunities and that UAs will not break at every opportunity, but only + near the end of a line unless a line break is forced.</li> + </ul> + +<h2 id="uncommon">Uncommon Assumptions</h2> + + <p>In addition, some of the tests make one or more of the following + assumptions:</p> + + <ul> + <li>The device is a full-color device.</li> + <li>The device has a viewport width of at least 640px (approx).</li> + <li>The resolution of the device is 96 CSS pixels per inch.</li> + <li>The UA imposes no minimum font size.</li> + <li>The 'medium' font-size computes to 16px.</li> + <li>The initial value of 'color' is black.</li> + <li>The canvas background is white.</li> + <li>The user stylesheet is empty (except where indicated by the tests).</li> + <li>The device is interactive and uses scroll bars.</li> + </ul> + + <p>The tests that need these assumptions to be true have not yet been + marked, but it is likely that we will add a way to identify these + tests in due course. Tests should avoid relying on these assumptions + unless necessary.</p> + +<h2>License</h2> + + <p>This test suite is licensed under both the + <a href="http://www.w3.org/Consortium/Legal/2008/04-testsuite-license">W3C + Test Suite License</a> and the <a href="http://www.w3.org/Consortium/Legal/2008/03-bsd-license">W3C + 3-clause BSD License</a>. See W3C Legal's <a href="http://www.w3.org/Consortium/Legal/2008/04-testsuite-copyright">explanation + of the licenses</a>.</p> + +<h2>Acknowledgements</h2> + + <p>Many thanks to the following for their contributions:</p> + <ul> + <li>David Alcala</li> + <li>Mihai Balan</li> + <li>Rebecca Hauck</li> + </ul> + +</body> +</html> diff --git a/tests/wpt/css-tests/css-break-3_dev/indices.css b/tests/wpt/css-tests/css-break-3_dev/indices.css new file mode 100644 index 00000000000..7bc70eeef94 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/indices.css @@ -0,0 +1,96 @@ +/* CSS for CSS Conformance Test Indices */ +/* Written by fantasai */ + +/* Test Tables */ + + table { + border-collapse: collapse; + } + + thead { + border-bottom: 0.2em solid; + } + + tbody { + border: thin solid; + border-style: solid none; + } + + tbody.ch { + border-top: 0.2em solid; + } + tbody.ch th { + font-weight: bold; + } + + tbody th { + border-bottom: silver dotted thin; + background: #EEE; + color: black; + font-weight: normal; + font-style: italic; + } + tbody th :link { + color: gray; + background: transparent; + } + tbody th :visited { + color: #333; + background: transparent; + } + + th, td { + padding: 0.2em; + text-align: left; + vertical-align: baseline; + } + + td { + font-size: 0.9em; + } + + /* flags */ + td abbr { + border: solid thin gray; + padding: 0 0.1em; + cursor: help; + } + td abbr:hover { + background: #ffa; + color: black; + } + + + tr:hover { + background: #F9F9F9; + color: navy; + } + + th a, + td a { + text-decoration: none; + } + th a:hover, + td a:hover, + th a:focus, + td a:focus { + text-decoration: underline; + } + + td a { + display: block; + padding-left: 2em; + text-indent: -1em; + } + .refs { + font-weight: bold; + font-size: larger; + } + .assert, .assert > li { + list-style-type: none; + font-style: italic; + color: gray; + margin: 0; + padding: 0; + text-indent: 0; + } diff --git a/tests/wpt/css-tests/css-break-3_dev/testinfo.data b/tests/wpt/css-tests/css-break-3_dev/testinfo.data new file mode 100644 index 00000000000..6f5a5df130e --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/testinfo.data @@ -0,0 +1,12 @@ +id references title flags links revision credits assertion +floats-clear-breaks-002 reference/floats-clear-breaks-002-ref CSS Regions: forced region breaks and clear on floats inside named flow contents ahem http://www.w3.org/TR/css3-regions/#the-flow-into-property,http://www.w3.org/TR/css3-break/#parallel-flows 66e95858ed37b82eeb7e8e883d8f1b3a1b51f8a4 `Mihai Balan`<mailto:mibalan@adobe.com> Test checks that no regions are left empty when setting a forced region break on a cleared float. +floats-in-named-flow-012 reference/floats-in-named-flow-012-ref floats with forced region breaks inside them ahem http://www.w3.org/TR/css3-regions/#the-flow-into-property,http://www.w3.org/TR/css3-break/#parallel-flows eafba0507ab9b5fb89bea9e14f8256691bfd2891 `Mihai Balan`<mailto:mibalan@adobe.com> Test checks that floats in named flow contents are floated relative to the region container and not their initial container, even when multiple regions are involved. +floats-in-named-flow-029 reference/floats-in-named-flow-029-ref CSS Regions: margins around forced breaks when break is around float ahem http://www.w3.org/TR/css3-regions/#the-flow-into-property,http://www.w3.org/TR/css3-break/#break-margins,http://www.w3.org/TR/css3-break/#parallel-flows 3a5945dba8044ac56ae8d27832493141b8e556c6 `Mihai Balan`<mailto:mibalan@adobe.com> Test checks that margins are correctly preserved when content has floats and is fragmented via forced breaks. +floats-in-named-flow-030 reference/floats-in-named-flow-030-ref CSS Regions: margins around unforced breaks when break is around float ahem http://www.w3.org/TR/css3-regions/#the-flow-into-property,http://www.w3.org/TR/css3-break/#break-margins,http://www.w3.org/TR/css3-break/#parallel-flows 3ed67f145da3817c1a9fe305372efcfca35292cc `Mihai Balan`<mailto:mibalan@adobe.com> Test checks that margins are correctly preserved when content has floats and is fragmented via unforced breaks. +position-relative-001 reference/position-relative-001-ref CSS Regions: flowing content that has position: relative ahem http://www.w3.org/TR/css3-regions/#the-flow-into-property,http://www.w3.org/TR/css3-regions/#flow-from,http://www.w3.org/TR/css3-break/#transforms d5b56444d0e5b6a788abe05b11f6dd25076c10d2 `Mihai Balan`<mailto:mibalan@adobe.com> Test checks that fragments of content flowed in regions are positioned independently, after the fragmentation occurs. +regions-transforms-008 reference/regions-transforms-008-ref CSS Regions: Transformed named flow (text) content that breaks across multiple regions and overflows ahem http://www.w3.org/TR/css3-regions/#the-flow-into-property,http://www.w3.org/TR/css3-regions/#flow-from,http://www.w3.org/TR/css-transforms-1/#two-d-transform-functions,http://www.w3.org/TR/css3-break/#transforms d8a4209344da1bc8fceaf310ad275d0c3bb56fb6 `Rebecca Hauck`<mailto:rhauck@adobe.com>,`David Alcala`<mailto:dalcala@adobe.com>,`Mihai Balan`<mailto:mibalan@adobe.com> This test checks that named flow text content is transformed when it breaks across multiple regions and that the overflow remains visible. +regions-transforms-009 reference/regions-transforms-008-ref CSS Regions: Transformed region with named flow (text) content that breaks across multiple regions and overflows ahem http://www.w3.org/TR/css3-regions/#the-flow-into-property,http://www.w3.org/TR/css3-regions/#flow-from,http://www.w3.org/TR/css-transforms-1/#two-d-transform-functions,http://www.w3.org/TR/css3-break/#transforms 14c43707256b41cd6dfc0e25dddd2bdf0131ce64 `Rebecca Hauck`<mailto:rhauck@adobe.com>,`David Alcala`<mailto:dalcala@adobe.com> This test checks that the regions are transformed when named flow text content breaks across multiple regions and that the overflow remains visible. +regions-transforms-013 reference/regions-transforms-013-alt-ref;reference/regions-transforms-013-ref CSS Regions: Transformed named flow (monolithic) content that breaks across multiple regions http://www.w3.org/TR/css3-regions/#the-flow-into-property,http://www.w3.org/TR/css3-regions/#flow-from,http://www.w3.org/TR/css-transforms-1/#two-d-transform-functions,http://www.w3.org/TR/css3-break/#transforms,http://www.w3.org/TR/css3-break/#breaking-rules,http://www.w3.org/TR/css3-break/#monolithic be1b126597c212f49292d68542edfe8c2a2fe844 `Rebecca Hauck`<mailto:rhauck@adobe.com>,`David Alcala`<mailto:dalcala@adobe.com> This test checks that the named flow content that is monolithic is transformed when it breaks across multiple regions whether it is sliced or overflowed at the fragmentainer edge. +regions-transforms-020 reference/regions-transforms-020-ref CSS Regions: Transformed region with named flow (fragmentable) content that breaks across multiple regions http://www.w3.org/TR/css3-regions/#the-flow-into-property,http://www.w3.org/TR/css3-regions/#flow-from,http://www.w3.org/TR/css-transforms-1/#two-d-transform-functions,http://www.w3.org/TR/css3-break/#transforms,http://www.w3.org/TR/css3-break/#breaking-rules e73e7a72635a5605583e23fde99f54047a81c339 `David Alcala`<mailto:dalcala@adobe.com>,`Rebecca Hauck`<mailto:rhauck@adobe.com> This test checks that the named flow content that is fragmentable (has a break point) is transformed when it breaks across multiple regions. +regions-transforms-021 reference/regions-transforms-020-ref CSS Regions: Transforms on multiple named flow (non-text) content nodes that break across multiple regions http://www.w3.org/TR/css3-regions/#the-flow-into-property,http://www.w3.org/TR/css3-regions/#flow-from,http://www.w3.org/TR/css-transforms-1/#two-d-transform-functions,http://www.w3.org/TR/css3-break/#transforms 0870c65471db6185829589066be514d54fe2d274 `David Alcala`<mailto:dalcala@adobe.com>,`Rebecca Hauck`<mailto:rhauck@adobe.com> This test checks that separate transforms can be applied to each named flow content node that breaks across multiple regions and that each fragment has its own transform origin. +regions-transforms-022 reference/regions-transforms-020-ref CSS Regions: Transforms on multiple named flow (text) content nodes that break across multiple regions ahem http://www.w3.org/TR/css3-regions/#the-flow-into-property,http://www.w3.org/TR/css3-regions/#flow-from,http://www.w3.org/TR/css-transforms-1/#two-d-transform-functions,http://www.w3.org/TR/css3-break/#transforms 9aa8e9bb44f895b0429ea824b447abdcb9f533e3 `David Alcala`<mailto:dalcala@adobe.com>,`Rebecca Hauck`<mailto:rhauck@adobe.com> This test checks that separate transforms can be applied to each named flow content text node that breaks across multiple regions diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1/chapter-1.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1/chapter-1.xht new file mode 100644 index 00000000000..71d90c11cca --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1/chapter-1.xht @@ -0,0 +1,57 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Introduction - CSS Fragmentation Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Fragmentation Module Level 3 CR Test Suite</h1> + <h2>Introduction (0 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s1">+</a> + <a href="http://www.w3.org/TR/css3-break/#intro">1 Introduction</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s1.#fragmentation"> + <!-- 0 tests --> + </tbody> + <tbody id="s1.#pagination"> + <!-- 0 tests --> + </tbody> + <tbody id="s1.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s1.1">+</a> + <a href="http://www.w3.org/TR/css3-break/#placement">1.1 Module Interactions</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s1.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s1.2">+</a> + <a href="http://www.w3.org/TR/css3-break/#values">1.2 Values</a></th></tr> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1/chapter-2.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1/chapter-2.xht new file mode 100644 index 00000000000..f84166dea78 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1/chapter-2.xht @@ -0,0 +1,131 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Fragmentation Model and Terminology - CSS Fragmentation Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Fragmentation Module Level 3 CR Test Suite</h1> + <h2>Fragmentation Model and Terminology (4 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2">+</a> + <a href="http://www.w3.org/TR/css3-break/#fragmentation-model">2 Fragmentation Model and Terminology</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s2.#box-fragment"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.#break"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.#fragment"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.#fragmentainer"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.#fragmentation-break"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.#fragmentation-container"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.#fragmentation-context"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.#fragmentation-direction"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.#fragmentation-root"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.#fragmentation0"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.#fragmented-flow"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.#remaining-fragmentainer-extent"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.1">+</a> + <a href="http://www.w3.org/TR/css3-break/#parallel-flows">2.1 Parallel Fragmentation Flows</a></th></tr> + <!-- 4 tests --> + <tr id="floats-clear-breaks-002-2.1" class="ahem"> + <td> + <a href="floats-clear-breaks-002.xht">floats-clear-breaks-002</a></td> + <td><a href="reference/floats-clear-breaks-002-ref.xht">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + <td>CSS Regions: forced region breaks and clear on floats inside named flow contents + <ul class="assert"> + <li>Test checks that no regions are left empty when setting a forced region break on a cleared float.</li> + </ul> + </td> + </tr> + <tr id="floats-in-named-flow-012-2.1" class="ahem"> + <td> + <a href="floats-in-named-flow-012.xht">floats-in-named-flow-012</a></td> + <td><a href="reference/floats-in-named-flow-012-ref.xht">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + <td>floats with forced region breaks inside them + <ul class="assert"> + <li>Test checks that floats in named flow contents are floated relative to the region container and not their initial container, even when multiple regions are involved.</li> + </ul> + </td> + </tr> + <tr id="floats-in-named-flow-029-2.1" class="ahem"> + <td> + <a href="floats-in-named-flow-029.xht">floats-in-named-flow-029</a></td> + <td><a href="reference/floats-in-named-flow-029-ref.xht">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + <td>CSS Regions: margins around forced breaks when break is around float + <ul class="assert"> + <li>Test checks that margins are correctly preserved when content has floats and is fragmented via forced breaks.</li> + </ul> + </td> + </tr> + <tr id="floats-in-named-flow-030-2.1" class="ahem"> + <td> + <a href="floats-in-named-flow-030.xht">floats-in-named-flow-030</a></td> + <td><a href="reference/floats-in-named-flow-030-ref.xht">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + <td>CSS Regions: margins around unforced breaks when break is around float + <ul class="assert"> + <li>Test checks that margins are correctly preserved when content has floats and is fragmented via unforced breaks.</li> + </ul> + </td> + </tr> + </tbody> + <tbody id="s2.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.2">+</a> + <a href="http://www.w3.org/TR/css3-break/#nested-flows">2.2 Nested Fragmentation Flows</a></th></tr> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1/chapter-3.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1/chapter-3.xht new file mode 100644 index 00000000000..a55eecd1d7e --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1/chapter-3.xht @@ -0,0 +1,153 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Controlling Breaks - CSS Fragmentation Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Fragmentation Module Level 3 CR Test Suite</h1> + <h2>Controlling Breaks (0 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3">+</a> + <a href="http://www.w3.org/TR/css3-break/#breaking-controls">3 Controlling Breaks</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.1">+</a> + <a href="http://www.w3.org/TR/css3-break/#break-between">3.1 Breaks Between Boxes: the &#8216;break-before&#8217; and &#8216;break-after&#8217; properties</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#always"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#any"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#auto"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#avoid"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#avoid-break-values"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#avoid-column"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#avoid-page"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#avoid-region"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#break-after"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#break-before"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#column"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#column-break-values"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#forced-break-values"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#generic-break-values"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#left"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#page"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#page-break-values"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#recto"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#region"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#region-break-values"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#right"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#verso"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.2">+</a> + <a href="http://www.w3.org/TR/css3-break/#break-within">3.2 Breaks Within Boxes: the &#8216;break-inside&#8217; property</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.2.#auto0"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.2.#avoid-column0"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.2.#avoid-page0"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.2.#avoid-region0"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.2.#avoid0"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.2.#break-inside"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.3">+</a> + <a href="http://www.w3.org/TR/css3-break/#widows-orphans">3.3 Breaks Between Lines: &#8216;orphans&#8217;, &#8216;widows&#8217;</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.3.#orphans"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.3.#widows"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.4"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.4">+</a> + <a href="http://www.w3.org/TR/css3-break/#page-break-properties">3.4 Page Break Aliases: the &#8216;page-break-before&#8217;, &#8216;page-break-after&#8217;, and &#8216;page-break-inside&#8217; properties</a></th></tr> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1/chapter-4.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1/chapter-4.xht new file mode 100644 index 00000000000..ec92f8f91d4 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1/chapter-4.xht @@ -0,0 +1,141 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Rules for Breaking - CSS Fragmentation Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Fragmentation Module Level 3 CR Test Suite</h1> + <h2>Rules for Breaking (2 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s4"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4">+</a> + <a href="http://www.w3.org/TR/css3-break/#breaking-rules">4 Rules for Breaking</a></th></tr> + <!-- 2 tests --> + <tr id="regions-transforms-013-4" class=""> + <td> + <a href="regions-transforms-013.xht">regions-transforms-013</a></td> + <td><a href="reference/regions-transforms-013-alt-ref.xht">=</a> <a href="reference/regions-transforms-013-ref.xht">=</a> </td> + <td></td> + <td>CSS Regions: Transformed named flow (monolithic) content that breaks across multiple regions + <ul class="assert"> + <li>This test checks that the named flow content that is monolithic is transformed when it breaks across multiple regions whether it is sliced or overflowed at the fragmentainer edge.</li> + </ul> + </td> + </tr> + <tr id="regions-transforms-020-4" class=""> + <td> + <a href="regions-transforms-020.xht">regions-transforms-020</a></td> + <td><a href="reference/regions-transforms-020-ref.xht">=</a> </td> + <td></td> + <td>CSS Regions: Transformed region with named flow (fragmentable) content that breaks across multiple regions + <ul class="assert"> + <li>This test checks that the named flow content that is fragmentable (has a break point) is transformed when it breaks across multiple regions.</li> + </ul> + </td> + </tr> + </tbody> + <tbody id="s4.#monolithic"> + <!-- 1 tests --> + <tr id="regions-transforms-013-4.#monolithic" class=""> + <td> + <a href="regions-transforms-013.xht">regions-transforms-013</a></td> + <td><a href="reference/regions-transforms-013-alt-ref.xht">=</a> <a href="reference/regions-transforms-013-ref.xht">=</a> </td> + <td></td> + <td>CSS Regions: Transformed named flow (monolithic) content that breaks across multiple regions + <ul class="assert"> + <li>This test checks that the named flow content that is monolithic is transformed when it breaks across multiple regions whether it is sliced or overflowed at the fragmentainer edge.</li> + </ul> + </td> + </tr> + </tbody> + <tbody id="s4.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4.1">+</a> + <a href="http://www.w3.org/TR/css3-break/#possible-breaks">4.1 Possible Break Points</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s4.1.#btw-blocks"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.1.#btw-lines"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.1.#end-block"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.1.#monolithic-breaking"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4.2">+</a> + <a href="http://www.w3.org/TR/css3-break/#break-types">4.2 Types of Breaks</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s4.2.#column-break"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.2.#line-break"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.2.#page-break"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.2.#region-break"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.2.#spread-break"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4.3">+</a> + <a href="http://www.w3.org/TR/css3-break/#forced-breaks">4.3 Forced Breaks</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s4.3.#forced-break"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.4"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4.4">+</a> + <a href="http://www.w3.org/TR/css3-break/#unforced-breaks">4.4 Unforced Breaks</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s4.4.#unforced-break"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.5"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4.5">+</a> + <a href="http://www.w3.org/TR/css3-break/#best-breaks">4.5 Optimizing Unforced Breaks</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s4.5.#widows-orphans-example"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1/chapter-5.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1/chapter-5.xht new file mode 100644 index 00000000000..6d8b802393c --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1/chapter-5.xht @@ -0,0 +1,183 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Box Model for Breaking - CSS Fragmentation Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Fragmentation Module Level 3 CR Test Suite</h1> + <h2>Box Model for Breaking (9 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s5"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s5">+</a> + <a href="http://www.w3.org/TR/css3-break/#breaking-boxes">5 Box Model for Breaking</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s5.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s5.1">+</a> + <a href="http://www.w3.org/TR/css3-break/#varying-size-boxes">5.1 Breaking into Varying-size Fragmentainers</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s5.2">+</a> + <a href="http://www.w3.org/TR/css3-break/#break-margins">5.2 Adjoining Margins at Breaks</a></th></tr> + <!-- 2 tests --> + <tr id="floats-in-named-flow-029-5.2" class="ahem"> + <td> + <a href="floats-in-named-flow-029.xht">floats-in-named-flow-029</a></td> + <td><a href="reference/floats-in-named-flow-029-ref.xht">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + <td>CSS Regions: margins around forced breaks when break is around float + <ul class="assert"> + <li>Test checks that margins are correctly preserved when content has floats and is fragmented via forced breaks.</li> + </ul> + </td> + </tr> + <tr id="floats-in-named-flow-030-5.2" class="ahem"> + <td> + <a href="floats-in-named-flow-030.xht">floats-in-named-flow-030</a></td> + <td><a href="reference/floats-in-named-flow-030-ref.xht">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + <td>CSS Regions: margins around unforced breaks when break is around float + <ul class="assert"> + <li>Test checks that margins are correctly preserved when content has floats and is fragmented via unforced breaks.</li> + </ul> + </td> + </tr> + </tbody> + <tbody id="s5.3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s5.3">+</a> + <a href="http://www.w3.org/TR/css3-break/#box-splitting">5.3 Splitting Boxes</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s5.4"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s5.4">+</a> + <a href="http://www.w3.org/TR/css3-break/#break-decoration">5.4 Fragmented Borders and Backgrounds: the &#8216;box-decoration-break&#8217; property</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s5.4.#box-decoration-break"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.4.#clone"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.4.#slice"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.4.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s5.4.1">+</a> + <a href="http://www.w3.org/TR/css3-break/#joining-boxes">5.4.1 Joining Boxes for &#8216;slice&#8217;</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s5.5"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s5.5">+</a> + <a href="http://www.w3.org/TR/css3-break/#transforms">5.5 Transforms, Positioning, and Pagination</a></th></tr> + <!-- 7 tests --> + <tr id="position-relative-001-5.5" class="ahem"> + <td> + <a href="position-relative-001.xht">position-relative-001</a></td> + <td><a href="reference/position-relative-001-ref.xht">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + <td>CSS Regions: flowing content that has position: relative + <ul class="assert"> + <li>Test checks that fragments of content flowed in regions are positioned independently, after the fragmentation occurs.</li> + </ul> + </td> + </tr> + <tr id="regions-transforms-008-5.5" class="ahem"> + <td> + <a href="regions-transforms-008.xht">regions-transforms-008</a></td> + <td><a href="reference/regions-transforms-008-ref.xht">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + <td>CSS Regions: Transformed named flow (text) content that breaks across multiple regions and overflows + <ul class="assert"> + <li>This test checks that named flow text content is transformed when it breaks across multiple regions and that the overflow remains visible.</li> + </ul> + </td> + </tr> + <tr id="regions-transforms-009-5.5" class="ahem"> + <td> + <a href="regions-transforms-009.xht">regions-transforms-009</a></td> + <td><a href="reference/regions-transforms-008-ref.xht">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + <td>CSS Regions: Transformed region with named flow (text) content that breaks across multiple regions and overflows + <ul class="assert"> + <li>This test checks that the regions are transformed when named flow text content breaks across multiple regions and that the overflow remains visible.</li> + </ul> + </td> + </tr> + <tr id="regions-transforms-013-5.5" class=""> + <td> + <a href="regions-transforms-013.xht">regions-transforms-013</a></td> + <td><a href="reference/regions-transforms-013-alt-ref.xht">=</a> <a href="reference/regions-transforms-013-ref.xht">=</a> </td> + <td></td> + <td>CSS Regions: Transformed named flow (monolithic) content that breaks across multiple regions + <ul class="assert"> + <li>This test checks that the named flow content that is monolithic is transformed when it breaks across multiple regions whether it is sliced or overflowed at the fragmentainer edge.</li> + </ul> + </td> + </tr> + <tr id="regions-transforms-020-5.5" class=""> + <td> + <a href="regions-transforms-020.xht">regions-transforms-020</a></td> + <td><a href="reference/regions-transforms-020-ref.xht">=</a> </td> + <td></td> + <td>CSS Regions: Transformed region with named flow (fragmentable) content that breaks across multiple regions + <ul class="assert"> + <li>This test checks that the named flow content that is fragmentable (has a break point) is transformed when it breaks across multiple regions.</li> + </ul> + </td> + </tr> + <tr id="regions-transforms-021-5.5" class=""> + <td> + <a href="regions-transforms-021.xht">regions-transforms-021</a></td> + <td><a href="reference/regions-transforms-020-ref.xht">=</a> </td> + <td></td> + <td>CSS Regions: Transforms on multiple named flow (non-text) content nodes that break across multiple regions + <ul class="assert"> + <li>This test checks that separate transforms can be applied to each named flow content node that breaks across multiple regions and that each fragment has its own transform origin.</li> + </ul> + </td> + </tr> + <tr id="regions-transforms-022-5.5" class="ahem"> + <td> + <a href="regions-transforms-022.xht">regions-transforms-022</a></td> + <td><a href="reference/regions-transforms-020-ref.xht">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + <td>CSS Regions: Transforms on multiple named flow (text) content nodes that break across multiple regions + <ul class="assert"> + <li>This test checks that separate transforms can be applied to each named flow content text node that breaks across multiple regions</li> + </ul> + </td> + </tr> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1/chapter-6.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1/chapter-6.xht new file mode 100644 index 00000000000..4e010584986 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1/chapter-6.xht @@ -0,0 +1,159 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Conformance - CSS Fragmentation Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Fragmentation Module Level 3 CR Test Suite</h1> + <h2>Conformance (0 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s6"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6">+</a> + <a href="http://www.w3.org/TR/css3-break/#conformance">6 Conformance</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6.1">+</a> + <a href="http://www.w3.org/TR/css3-break/#conventions">6.1 Document Conventions</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6.2">+</a> + <a href="http://www.w3.org/TR/css3-break/#conformance-classes">6.2 Conformance Classes</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2.#authoring-tool"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2.#renderer"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2.#style-sheet"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6.3">+</a> + <a href="http://www.w3.org/TR/css3-break/#partial">6.3 Partial Implementations</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s6.4"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6.4">+</a> + <a href="http://www.w3.org/TR/css3-break/#experimental">6.4 Experimental Implementations</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s6.5"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6.5">+</a> + <a href="http://www.w3.org/TR/css3-break/#testing">6.5 Non-Experimental Implementations</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s6.6"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6.6">+</a> + <a href="http://www.w3.org/TR/css3-break/#cr-exit-criteria">6.6 CR Exit Criteria</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s.#abstract"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#acknowledgments"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#changes"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#contents"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#css-fragmentation-module"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#index"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#normative-references"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#other-references"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#property-index"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#ref-CSS-REGIONS-1"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#ref-CSS-TEXT-3"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#ref-CSS-WRITING-MODES-3"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#ref-CSS21"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#ref-CSS3-FLEXBOX"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#ref-CSS3-SIZING"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#ref-CSS3-TRANSFORMS"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#ref-CSS3BG"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#ref-CSS3COL"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#ref-CSS3PAGE"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#ref-CSS3VAL"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#ref-RFC2119"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#references"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#status"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#subtitle"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#w3c_process_revision"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1/floats-clear-breaks-002.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1/floats-clear-breaks-002.xht new file mode 100644 index 00000000000..013f6292e66 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1/floats-clear-breaks-002.xht @@ -0,0 +1,86 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Regions: forced region breaks and clear on floats inside named flow contents</title> + <link href="mailto:mibalan@adobe.com" rel="author" title="Mihai Balan" /> + <link href="http://www.w3.org/TR/css3-regions/#the-flow-into-property" rel="help" /> + <link href="http://www.w3.org/TR/css3-break/#parallel-flows" rel="help" /> + <meta content="ahem" name="flags" /> + <meta content="Test checks that no regions are left empty when setting + a forced region break on a cleared float." name="assert" /> + <link href="reference/floats-clear-breaks-002-ref.xht" rel="match" /> + <style> + article { + font-family: Ahem; + font-size: 20px; + line-height: 1em; + } + + .flow { + flow-into: f; + } + + .float { + float: left; + color: blue; + } + .break { + break-before: region; + } + + .clear { + clear: left; + color: green; + } + + .bordered { + border: 10px solid black; + } + + .region { + flow-from: f; + max-width: 100px; + margin-bottom: 10px; + } + + .region &gt; p { + background: red; + } + </style> + </head> + <body> + <p> + Test passes if you see two squares separated by a small vertical space. The squares should + have a black outline, the top square should be blue and the bottom one should be green.<br /> + You should see no red. + </p> + + <div class="bordered region"> + <p>&#xA0;</p> + </div> + <div class="bordered region"> + <p>&#xA0;</p> + </div> + <!-- In case the clear + forced break lead to an empty region, the content will flow in this + third region ending up without a border. --> + <div class="region"> + <p>&#xA0;</p> + </div> + + <article class="flow"> + <div class="float"> + xxxxx + xxxxx + xxxxx + xxxxx + xxxxx + </div> + <div class="break clear"> + xxxxx + xxxxx + xxxxx + xxxxx + xxxxx + </div> + </article> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1/floats-in-named-flow-012.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1/floats-in-named-flow-012.xht new file mode 100644 index 00000000000..9841dedb3a0 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1/floats-in-named-flow-012.xht @@ -0,0 +1,83 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Test: floats with forced region breaks inside them</title> + <link href="mailto:mibalan@adobe.com" rel="author" title="Mihai Balan" /> + <link href="http://www.w3.org/TR/css3-regions/#the-flow-into-property" rel="help" /> + <link href="http://www.w3.org/TR/css3-break/#parallel-flows" rel="help" /> + <meta content="ahem" name="flags" /> + <meta content="Test checks that floats in named flow contents are floated relative + to the region container and not their initial container, even when multiple regions + are involved." name="assert" /> + <link href="reference/floats-in-named-flow-012-ref.xht" rel="match" /> + <style> + article { + color: blue; + font-family: Ahem; + font-size: 20px; + line-height: 1em; + } + .flow { + flow-into: f; + } + .float { + color: green; + float: left; + } + .break { + break-before: region; + } + .region { + flow-from: f; + margin: 10px; + width: 200px; + background: red; + } + + .region &gt; p { + background: red; + } + </style> + </head> + <body> + <p> + Test passes if you see two identical rows of colored squares. Each row should have three + squares, from left to right as follows: blue, gray, green. The squares in a row should + be flush to each other, but the two rows should have some space between them.<br /> + Test fails is you see any red. + </p> + + <article> + <div class="flow"> + <div class="float"> + <div> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx + </div> + <div class="break"> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx + </div> + </div> + <div> + xxxxx xxxxx xxxxx xxxxx xxxxx + </div> + <div class="break"> + xxxxx xxxxx xxxxx xxxxx xxxxx + </div> + </div> + </article> + + <div class="region"> + <p>&#xA0;</p> + </div> + <div class="region"> + <p>&#xA0;</p> + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1/floats-in-named-flow-029.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1/floats-in-named-flow-029.xht new file mode 100644 index 00000000000..e0dcbfb7fcf --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1/floats-in-named-flow-029.xht @@ -0,0 +1,90 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Regions: margins around forced breaks when break is around float</title> + <link href="mailto:mibalan@adobe.com" rel="author" title="Mihai Balan" /> + <link href="http://www.w3.org/TR/css3-regions/#the-flow-into-property" rel="help" /> + <link href="http://www.w3.org/TR/css3-break/#break-margins" rel="help" /> + <link href="http://www.w3.org/TR/css3-break/#parallel-flows" rel="help" /> + <meta content="ahem" name="flags" /> + <meta content="Test checks that margins are correctly preserved when content + has floats and is fragmented via forced breaks." name="assert" /> + <link href="reference/floats-in-named-flow-029-ref.xht" rel="match" /> + <style> + article { + font-family: Ahem; + font-size: 20px; + line-height: 1em; + } + + .flow { + flow-into: f; + } + + .break { + break-before: region; + } + + .spaced { + margin: 1em 2em 3em 5em; + color: green; + } + + .float { + float: left; + color: blue; + } + .bordered { + border: 10px solid black; + } + + .region { + flow-from: f; + float: left; + margin-left: 10px; + } + + .region &gt; p { + background: red; + } + </style> + </head> + <body> + <p> + <!-- TODO Determine what the outcome should be - currently expecting a resolution on + the issue on www-style/css3-break --> + Test passes if you see two colored squares each inside a black-bordered rectangle: + </p><ul> + <li>The black-bordered rectangles should be separated by a small horizontal space</li> + <li>The colored squares should be positioned roughly in the top-left area of their + rectangles, but without being flush to any of its sides</li> + </ul><br /> + You should see no red. + <p></p> + + <div class="bordered region"> + <p>&#xA0;</p> + </div><div class="bordered region"> + <p>&#xA0;</p> + </div> + <div class="region"> + <p>&#xA0;</p> + </div> + + <article class="flow"> + <div class="spaced float"> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx + </div> + <div class="break spaced"> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx + </div> + </article> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1/floats-in-named-flow-030.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1/floats-in-named-flow-030.xht new file mode 100644 index 00000000000..f5395288e60 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1/floats-in-named-flow-030.xht @@ -0,0 +1,88 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Regions: margins around unforced breaks when break is around float</title> + <link href="mailto:mibalan@adobe.com" rel="author" title="Mihai Balan" /> + <link href="http://www.w3.org/TR/css3-regions/#the-flow-into-property" rel="help" /> + <link href="http://www.w3.org/TR/css3-break/#break-margins" rel="help" /> + <link href="http://www.w3.org/TR/css3-break/#parallel-flows" rel="help" /> + <meta content="ahem" name="flags" /> + <meta content="Test checks that margins are correctly preserved when content + has floats and is fragmented via unforced breaks." name="assert" /> + <link href="reference/floats-in-named-flow-030-ref.xht" rel="match" /> + <style> + article { + font-family: Ahem; + font-size: 20px; + line-height: 1em; + } + + .flow { + flow-into: f; + } + + .spaced { + margin: 1em 2em 3em 5em; + color: green; + } + + .float { + float: left; + color: blue; + } + + .bordered { + border: 10px solid black; + } + + .region { + flow-from: f; + /* float: left; is used to trigger shrink-to-fit sizing */ + float: left; + margin-left: 10px; + } + + .region &gt; p { + background: red; + } + </style> + </head> + <body> + <p> + <!-- TODO Determine what the outcome should be - currently expecting a resolution on + the issue on www-style/css3-break --> + Test passes if you see two colored squares each inside a black-bordered rectangle: + </p><ul> + <li>The black-bordered rectangles should be separated by a small vertical space</li> + <li>The green square should have its top edge flush with the top border of its + containing rectangle</li> + </ul> + You should see no red. + <p></p> + + <div style="height: 125px;" class="bordered region"> + <p>&#xA0;</p> + </div><div class="bordered region"> + <p>&#xA0;</p> + </div> + <div class="region"> + <p>&#xA0;</p> + </div> + + <article class="flow"> + <div class="spaced float"> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx + </div> + <div class="spaced"> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx + </div> + </article> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1/position-relative-001.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1/position-relative-001.xht new file mode 100644 index 00000000000..164308e3c52 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1/position-relative-001.xht @@ -0,0 +1,77 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Regions: flowing content that has position: relative</title> + <link href="mailto:mibalan@adobe.com" rel="author" title="Mihai Balan" /> + <link href="http://www.w3.org/TR/css3-regions/#the-flow-into-property" rel="help" /> + <link href="http://www.w3.org/TR/css3-regions/#flow-from" rel="help" /> + <!-- Section points to section in the ED. Eventually this should be kept in the WD, too. --> + <link href="http://www.w3.org/TR/css3-break/#transforms" rel="help" /> + <meta content="Test checks that fragments of content flowed in regions are positioned independently, after the fragmentation occurs." name="assert" /> + <meta content="ahem" name="flags" /> + <link href="reference/position-relative-001-ref.xht" rel="match" /> + <style> + .flow { + flow-into: f; + font-family: Ahem; + font-size: 20px; + line-height: 1em; + color: green; + position: relative; + top: 20px; + left: -20px; + } + + .container { + display: inline-block; + } + + .region { + flow-from: f; + margin: 0 0 0 20px; + } + .region p { + background-color: red; + height: 50%; + } + .big { + width: 100px; + height: 100px; + } + .small { + width: 60px; + height: 60px; + } + + .marker { + background: red; + width: 20px; + height: 20px; + } + </style> + </head> + <body> + <p>Test passes if you see two green squares (one bigger and one smaller) and no red.</p> + <div class="flow"> + xxxxx + xxxxx + xxxxx + xxxxx + xxxxx + xxx + xxx + xxx + </div> + <div class="container"> + <div class="big region"> + <p>&#xA0;</p> + </div> + <div class="marker"></div> + </div> + <div class="container"> + <div class="small region"> + <p>&#xA0;</p> + </div> + <div class="marker"></div> + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1/reference/floats-clear-breaks-002-ref.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1/reference/floats-clear-breaks-002-ref.xht new file mode 100644 index 00000000000..c30f67c556a --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1/reference/floats-clear-breaks-002-ref.xht @@ -0,0 +1,59 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reftest Reference</title> + <link href="mailto:mibalan@adobe.com" rel="author" title="Mihai Balan" /> + <style> + article { + font-family: Ahem; + font-size: 20px; + line-height: 1em; + color: green; + } + + .float { + float: left; + color: blue; + } + + .bordered { + border: 10px solid black; + } + + .region { + overflow: hidden; + max-width: 100px; + margin-bottom: 10px; + } + </style> + </head> + <body> + <p> + Test passes if you see two squares separated by a small vertical space. The squares should + have a black outline, the top square should be blue and the bottom one should be green.<br /> + You should see no red. + </p> + + <div class="bordered region"> + <article> + <div class="float"> + xxxxx + xxxxx + xxxxx + xxxxx + xxxxx + </div> + </article> + </div> + <div class="bordered region"> + <article> + <div> + xxxxx + xxxxx + xxxxx + xxxxx + xxxxx + </div> + </article> + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1/reference/floats-in-named-flow-012-ref.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1/reference/floats-in-named-flow-012-ref.xht new file mode 100644 index 00000000000..a2e7363432e --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1/reference/floats-in-named-flow-012-ref.xht @@ -0,0 +1,69 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reftest Reference</title> + <link href="mailto:mibalan@adobe.com" rel="author" title="Mihai Balan" /> + <style> + article { + color: blue; + font-family: Ahem; + font-size: 20px; + line-height: 1em; + } + .float { + color: green; + float: left; + } + .region { + margin: 10px; + width: 200px; + background: red; + } + </style> + </head> + <body> + <p> + Test passes if you see two identical rows of colored squares. Each row should have three + squares, from left to right as follows: blue, gray, green. The squares in a row should + be flush to each other, but the two rows should have some space between them.<br /> + Test fails is you see any red. + </p> + + + <div class="region"> + <article> + <div class="flow"> + <div class="float"> + <div> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx + </div> + </div> + <div> + xxxxx xxxxx xxxxx xxxxx xxxxx + </div> + </div> + </article> + </div> + <div class="region"> + <article> + <div class="flow"> + <div class="float"> + <div> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx + </div> + </div> + <div> + xxxxx xxxxx xxxxx xxxxx xxxxx + </div> + </div> + </article> + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1/reference/floats-in-named-flow-029-ref.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1/reference/floats-in-named-flow-029-ref.xht new file mode 100644 index 00000000000..bfa00b38045 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1/reference/floats-in-named-flow-029-ref.xht @@ -0,0 +1,67 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reftest Reference</title> + <link href="mailto:mibalan@adobe.com" rel="author" title="Mihai Balan" /> + <style> + article { + font-family: Ahem; + font-size: 20px; + line-height: 1em; + } + + .spaced { + margin: 1em 2em 3em 5em; + color: green; + } + + .float { + float: left; + color: blue; + } + .bordered { + border: 10px solid black; + } + + .region { + display: inline-block; + float: left; + margin-left: 10px; + } + </style> + </head> + <body> + <p> + <!-- TODO Determine what the outcome should be - currently expecting a resolution on + the issue on www-style/css3-break --> + Test passes if you see two colored squares each inside a black-bordered rectangle: + </p><ul> + <li>The black-bordered rectangles should be separated by a small horizontal space</li> + <li>The colored squares should be positioned roughly in the top-left area of their + rectangles, but without being flush to any of its sides</li> + </ul><br /> + You should see no red. + <p></p> + + <div class="bordered region"> + <article> + <div class="spaced float"> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx + </div> + </article> + </div><div class="bordered region"> + <article> + <div class="break spaced"> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx + </div> + </article> + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1/reference/floats-in-named-flow-030-ref.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1/reference/floats-in-named-flow-030-ref.xht new file mode 100644 index 00000000000..8add5da17f8 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1/reference/floats-in-named-flow-030-ref.xht @@ -0,0 +1,68 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reftest Reference</title> + <link href="mailto:mibalan@adobe.com" rel="author" title="Mihai Balan" /> + <style> + article { + font-family: Ahem; + font-size: 20px; + line-height: 1em; + } + + .spaced { + margin: 0 2em 3em 5em; + color: green; + } + .float { + margin-top: 1em; + float: left; + color: blue; + } + + .bordered { + border: 10px solid black; + } + + .region { + /* float: left; is used to trigger shrink-to-fit sizing */ + float: left;; + margin-left: 10px; + } + </style> + </head> + <body> + <p> + <!-- TODO Determine what the outcome should be - currently expecting a resolution on + the issue on www-style/css3-break --> + Test passes if you see two colored squares each inside a black-bordered rectangle: + </p><ul> + <li>The black-bordered rectangles should be separated by a small vertical space</li> + <li>The green square should have its top edge flush with the top border of its + containing rectangle</li> + </ul> + You should see no red. + <p></p> + + <div style="height: 125px;" class="bordered region"> + <article> + <div class="spaced float"> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx + </div> + </article> + </div><div class="bordered region"> + <article> + <div class="spaced"> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx + </div> + </article> + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1/reference/position-relative-001-ref.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1/reference/position-relative-001-ref.xht new file mode 100644 index 00000000000..7162ce35318 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1/reference/position-relative-001-ref.xht @@ -0,0 +1,56 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reftest Reference</title> + <link href="mailto:mibalan@adobe.com" rel="author" title="Mihai Balan" /> + <style> + .flow { + font-family: Ahem; + font-size: 20px; + line-height: 1em; + color: green; + position: relative; + top: 20px; + left: -20px; + } + + .container { + display: inline-block; + } + + .region { + margin: 0 0 0 20px; + } + .big { + width: 100px; + height: 100px; + } + .small { + width: 60px; + height: 60px; + } + </style> + </head> + <body> + <p>Test passes if you see two green squares (one bigger and one smaller) and no red.</p> + <div class="container"> + <div class="big region"> + <div class="flow"> + xxxxx + xxxxx + xxxxx + xxxxx + xxxxx + </div> + </div> + </div> + <div class="container"> + <div class="small region"> + <div class="flow"> + xxx + xxx + xxx + </div> + </div> + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1/reference/regions-transforms-008-ref.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1/reference/regions-transforms-008-ref.xht new file mode 100644 index 00000000000..aab004e44bb --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1/reference/regions-transforms-008-ref.xht @@ -0,0 +1,35 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reftest Reference</title> + <link href="mailto:rhauck@adobe.com" rel="author" title="Rebecca Hauck" /> + <link href="mailto:mibalan@adobe.com" rel="reviewer" title="Mihai Balan" /> <!-- 2013-07-24 --> + <style type="text/css"> + .square { + float: left; + font-family: Ahem; + font-size: 10px; + line-height: 20px; + margin-left: 10px; + color: green; + width: 100px; + height: 100px; + border: 1px solid black; + } + + </style> +</head> +<body> + <p>The test passes if:</p> + <ul> + <li>The two squares each contain five green horizontal stripes</li> + <li>There are two green horizontal stripes below the square on right</li> + <li>There is no red</li> + </ul> + <div class="square"> + XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX + </div> + <div class="square"> + XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1/reference/regions-transforms-013-alt-ref.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1/reference/regions-transforms-013-alt-ref.xht new file mode 100644 index 00000000000..e393e082bf9 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1/reference/regions-transforms-013-alt-ref.xht @@ -0,0 +1,20 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reftest Reference</title> + <link href="mailto:rhauck@adobe.com" rel="author" title="Rebecca Hauck" /> + <link href="mailto:mibalan@adobe.com" rel="reviewer" title="Mihai Balan" /> <!-- 2013-07-24 --> + <style type="text/css"> + .green-rect { + width: 100px; + height: 200px; + margin-left: 10px; + float: left; + background-color: green; + } + </style> +</head> +<body> + <p>The test passes if you see either two green squares or one vertical green rectangle. There should be no red.</p> + <div class="green-rect"></div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1/reference/regions-transforms-013-ref.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1/reference/regions-transforms-013-ref.xht new file mode 100644 index 00000000000..5a6a3049a08 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1/reference/regions-transforms-013-ref.xht @@ -0,0 +1,21 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reftest Reference</title> + <link href="mailto:dalcala@adobe.com" rel="author" title="David Alcala" /> + <link href="mailto:mibalan@adobe.com" rel="reviewer" title="Mihai Balan" /> <!-- 2013-07-24 --> + <style type="text/css"> + .green-square { + width: 100px; + height: 100px; + margin-left: 10px; + float: left; + background-color: green; + } + </style> +</head> +<body> + <p>The test passes if you see either two green squares or one vertical green rectangle. There should be no red.</p> + <div class="green-square"></div> + <div class="green-square"></div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1/reference/regions-transforms-020-ref.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1/reference/regions-transforms-020-ref.xht new file mode 100644 index 00000000000..aae13775fd8 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1/reference/regions-transforms-020-ref.xht @@ -0,0 +1,21 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reftest Reference</title> + <link href="mailto:rhauck@adobe.com" rel="author" title="Rebecca Hauck" /> + <link href="mailto:mibalan@adobe.com" rel="reviewer" title="Mihai Balan" /> <!-- 2013-07-24 --> + <style type="text/css"> + .green-square { + width: 100px; + height: 100px; + margin-left: 10px; + float: left; + background-color: green; + } + </style> +</head> +<body> + <p>The test passes if you see two green squares and no red.</p> + <div class="green-square"></div> + <div class="green-square"></div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1/reftest-toc.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1/reftest-toc.xht new file mode 100644 index 00000000000..48d26f46228 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1/reftest-toc.xht @@ -0,0 +1,121 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>CSS Fragmentation Module Level 3 CR Test Suite Reftest Index</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Fragmentation Module Level 3 CR Test Suite Reftest Index</h1> + <table width="100%"> + <col id="test-column"></col> + <col id="ref-column"></col> + <col id="flags-column"></col> + <thead> + <tr> + <th>Test</th> + <th>Reference</th> + <th>Flags</th> + </tr> + </thead> + <tbody id="floats-clear-breaks-002" class="ahem"> + <tr> + <td rowspan="1" title="CSS Regions: forced region breaks and clear on floats inside named flow contents"> + <a href="floats-clear-breaks-002.xht">floats-clear-breaks-002</a></td> + <td><a href="reference/floats-clear-breaks-002-ref.xht">=</a> </td> + <td rowspan="1"><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + </tr> + </tbody> + <tbody id="floats-in-named-flow-012" class="ahem"> + <tr> + <td rowspan="1" title="floats with forced region breaks inside them"> + <a href="floats-in-named-flow-012.xht">floats-in-named-flow-012</a></td> + <td><a href="reference/floats-in-named-flow-012-ref.xht">=</a> </td> + <td rowspan="1"><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + </tr> + </tbody> + <tbody id="floats-in-named-flow-029" class="ahem"> + <tr> + <td rowspan="1" title="CSS Regions: margins around forced breaks when break is around float"> + <a href="floats-in-named-flow-029.xht">floats-in-named-flow-029</a></td> + <td><a href="reference/floats-in-named-flow-029-ref.xht">=</a> </td> + <td rowspan="1"><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + </tr> + </tbody> + <tbody id="floats-in-named-flow-030" class="ahem"> + <tr> + <td rowspan="1" title="CSS Regions: margins around unforced breaks when break is around float"> + <a href="floats-in-named-flow-030.xht">floats-in-named-flow-030</a></td> + <td><a href="reference/floats-in-named-flow-030-ref.xht">=</a> </td> + <td rowspan="1"><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + </tr> + </tbody> + <tbody id="position-relative-001" class="ahem"> + <tr> + <td rowspan="1" title="CSS Regions: flowing content that has position: relative"> + <a href="position-relative-001.xht">position-relative-001</a></td> + <td><a href="reference/position-relative-001-ref.xht">=</a> </td> + <td rowspan="1"><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + </tr> + </tbody> + <tbody id="regions-transforms-008" class="ahem"> + <tr> + <td rowspan="1" title="CSS Regions: Transformed named flow (text) content that breaks across multiple regions and overflows"> + <a href="regions-transforms-008.xht">regions-transforms-008</a></td> + <td><a href="reference/regions-transforms-008-ref.xht">=</a> </td> + <td rowspan="1"><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + </tr> + </tbody> + <tbody id="regions-transforms-009" class="ahem"> + <tr> + <td rowspan="1" title="CSS Regions: Transformed region with named flow (text) content that breaks across multiple regions and overflows"> + <a href="regions-transforms-009.xht">regions-transforms-009</a></td> + <td><a href="reference/regions-transforms-008-ref.xht">=</a> </td> + <td rowspan="1"><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + </tr> + </tbody> + <tbody id="regions-transforms-013" class=""> + <tr> + <td rowspan="2" title="CSS Regions: Transformed named flow (monolithic) content that breaks across multiple regions"> + <a href="regions-transforms-013.xht">regions-transforms-013</a></td> + <td><a href="reference/regions-transforms-013-alt-ref.xht">=</a> </td> + <td rowspan="2"></td> + </tr> + <tr> + <td><a href="reference/regions-transforms-013-alt-ref.xht">=</a></td> + </tr> + </tbody> + <tbody id="regions-transforms-020" class=""> + <tr> + <td rowspan="1" title="CSS Regions: Transformed region with named flow (fragmentable) content that breaks across multiple regions"> + <a href="regions-transforms-020.xht">regions-transforms-020</a></td> + <td><a href="reference/regions-transforms-020-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="regions-transforms-021" class=""> + <tr> + <td rowspan="1" title="CSS Regions: Transforms on multiple named flow (non-text) content nodes that break across multiple regions"> + <a href="regions-transforms-021.xht">regions-transforms-021</a></td> + <td><a href="reference/regions-transforms-020-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="regions-transforms-022" class="ahem"> + <tr> + <td rowspan="1" title="CSS Regions: Transforms on multiple named flow (text) content nodes that break across multiple regions"> + <a href="regions-transforms-022.xht">regions-transforms-022</a></td> + <td><a href="reference/regions-transforms-020-ref.xht">=</a> </td> + <td rowspan="1"><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + </tr> + </tbody> + </table> + + </body> +</html> diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1/reftest.list b/tests/wpt/css-tests/css-break-3_dev/xhtml1/reftest.list new file mode 100644 index 00000000000..5e205e23727 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1/reftest.list @@ -0,0 +1,13 @@ + +floats-clear-breaks-002.xht == reference/floats-clear-breaks-002-ref.xht +floats-in-named-flow-012.xht == reference/floats-in-named-flow-012-ref.xht +floats-in-named-flow-029.xht == reference/floats-in-named-flow-029-ref.xht +floats-in-named-flow-030.xht == reference/floats-in-named-flow-030-ref.xht +position-relative-001.xht == reference/position-relative-001-ref.xht +regions-transforms-008.xht == reference/regions-transforms-008-ref.xht +regions-transforms-009.xht == reference/regions-transforms-008-ref.xht +regions-transforms-013.xht == reference/regions-transforms-013-alt-ref.xht +regions-transforms-013.xht == reference/regions-transforms-013-ref.xht +regions-transforms-020.xht == reference/regions-transforms-020-ref.xht +regions-transforms-021.xht == reference/regions-transforms-020-ref.xht +regions-transforms-022.xht == reference/regions-transforms-020-ref.xht diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1/regions-transforms-008.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1/regions-transforms-008.xht new file mode 100644 index 00000000000..bfdf2d48850 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1/regions-transforms-008.xht @@ -0,0 +1,74 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <meta charset="UTF-8" /> + <title>CSS Regions: Transformed named flow (text) content that breaks across multiple regions and overflows</title> + <link href="mailto:rhauck@adobe.com" rel="author" title="Rebecca Hauck" /> + <link href="mailto:dalcala@adobe.com" rel="author" title="David Alcala" /> + <link href="mailto:mibalan@adobe.com" rel="reviewer author" title="Mihai Balan" /> <!-- 2013-07-24 --> + <link href="http://www.w3.org/TR/css3-regions/#the-flow-into-property" rel="help" /> + <link href="http://www.w3.org/TR/css3-regions/#flow-from" rel="help" /> + <link href="http://www.w3.org/TR/css-transforms-1/#two-d-transform-functions" rel="help" /> + <link href="http://www.w3.org/TR/css3-break/#transforms" rel="help" /> + <link href="reference/regions-transforms-008-ref.xht" rel="match" /> + <meta content="ahem" name="flags" /> + <meta content="This test checks that named flow text content is transformed when it breaks across + multiple regions and that the overflow remains visible." name="assert" /> + <style> + .ahem { + font-family: Ahem; + font-size: 10px; + line-height: 20px; + } + #named-flow { + color: green; + margin-left: -50px; + transform: translateX(50px); + flow-into: f; + } + .region { + width: 100px; + height: 100px; + margin-left: 10px; + float: left; + border: 1px solid black; + flow-from: f; + } + .failure { + position: absolute; + width: 102px; + height: 102px; + margin-top: 1px; + margin-left: 10px; + padding-left: 1px; + color: red; + z-index: -1; + } + .left { + left: 8px; + } + .right { + left: 120px; + } + </style> +</head> +<body> + <p>The test passes if:</p> + <ul> + <li>The two squares each contain five green horizontal stripes</li> + <li>There are two green horizontal stripes below the square on right</li> + <li>There is no red</li> + </ul> + <div class="ahem" id="named-flow">XXXXXXXXXXX XXXXXXXXXXX XXXXXXXXXXX XXXXXXXXXXX XXXXXXXXXXX XXXXXXXXXXX XXXXXXXXXXX XXXXXXXXXXX XXXXXXXXXXX XXXXXXXXXXX XXXXXXXXXXX XXXXXXXXXXX</div> + <div class="region"></div> + <div class="region"></div> + + <div class="ahem failure left"> + XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX + </div> + <div class="ahem failure right"> + XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX + </div> + + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1/regions-transforms-009.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1/regions-transforms-009.xht new file mode 100644 index 00000000000..f0d0c48658c --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1/regions-transforms-009.xht @@ -0,0 +1,74 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <meta charset="UTF-8" /> + <title>CSS Regions: Transformed region with named flow (text) content that breaks across multiple regions and overflows</title> + <link href="mailto:rhauck@adobe.com" rel="author" title="Rebecca Hauck" /> + <link href="mailto:dalcala@adobe.com" rel="author" title="David Alcala" /> + <link href="mailto:mibalan@adobe.com" rel="reviewer" title="Mihai Balan" /> <!-- 2013-07-24 --> + <link href="http://www.w3.org/TR/css3-regions/#the-flow-into-property" rel="help" /> + <link href="http://www.w3.org/TR/css3-regions/#flow-from" rel="help" /> + <link href="http://www.w3.org/TR/css-transforms-1/#two-d-transform-functions" rel="help" /> + <link href="http://www.w3.org/TR/css3-break/#transforms" rel="help" /> + <link href="reference/regions-transforms-008-ref.xht" rel="match" /> + <meta content="ahem" name="flags" /> + <meta content="This test checks that the regions are transformed when named flow text content breaks + across multiple regions and that the overflow remains visible." name="assert" /> + <style> + .ahem { + font-family: Ahem; + font-size: 10px; + line-height: 20px; + } + #named-flow { + color: green; + flow-into: f; + } + .region { + width: 100px; + height: 100px; + float: left; + margin-left: 10px; + border: 1px solid black; + flow-from: f; + transform: translateX(50px); + } + .failure-left, + .failure-right { + position: absolute; + width: 102px; + height: 102px; + margin-top: 1px; + margin-left: 10px; + padding-left: 1px; + color: red; + z-index: -1; + } + .left { + margin-left: -40px; + } + .failure-left { + left: 8px; + } + .failure-right { + left: 120px; + } + </style> +</head> +<body> + <p>The test passes if:</p> + <ul> + <li>The two squares each contain five green horizontal stripes</li> + <li>There are two green horizontal stripes below the square on right</li> + <li>There is no red</li> + </ul> + <div class="ahem" id="named-flow">XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX</div> + <div class="region left"></div> + <div class="region"></div> + <div class="ahem failure-left"> + XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX + </div> + <div class="ahem failure-right"> + XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1/regions-transforms-013.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1/regions-transforms-013.xht new file mode 100644 index 00000000000..e711dec1af4 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1/regions-transforms-013.xht @@ -0,0 +1,47 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <meta charset="UTF-8" /> + <title>CSS Regions: Transformed named flow (monolithic) content that breaks across multiple regions</title> + <link href="mailto:rhauck@adobe.com" rel="author" title="Rebecca Hauck" /> + <link href="mailto:dalcala@adobe.com" rel="author" title="David Alcala" /> + <link href="mailto:mibalan@adobe.com" rel="reviewer" title="Mihai Balan" /> <!-- 2013-07-24 --> + <link href="http://www.w3.org/TR/css3-regions/#the-flow-into-property" rel="help" /> + <link href="http://www.w3.org/TR/css3-regions/#flow-from" rel="help" /> + <link href="http://www.w3.org/TR/css-transforms-1/#two-d-transform-functions" rel="help" /> + <link href="http://www.w3.org/TR/css3-break/#transforms" rel="help" /> + <link href="http://www.w3.org/TR/css3-break/#breaking-rules" rel="help" /> + <link href="http://www.w3.org/TR/css3-break/#monolithic" rel="help" /> + <!-- This reference is for UAs that slice monolithic content --> + <link href="reference/regions-transforms-013-ref.xht" rel="match" /> + <!-- This reference is for UAs that overflow monolithic content --> + <link href="reference/regions-transforms-013-alt-ref.xht" rel="match" /> + <meta content="This test checks that the named flow content that is monolithic is transformed when it + breaks across multiple regions whether it is sliced or overflowed at the fragmentainer edge." name="assert" /> + <style> + #named-flow { + width: 100px; + height: 100px; + background-color: green; + transform: scaleY(2); + transform-origin: top left; + flow-into: f; + } + .region { + width: 100px; + height: 100px; + margin-left: 10px; + float: left; + flow-from: f; + } + #region1 { + background-color: red; + } + </style> +</head> +<body> + <p>The test passes if you see either two green squares or one vertical green rectangle. There should be no red.</p> + <div id="named-flow"></div> + <div class="region" id="region1"></div> + <div class="region"></div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1/regions-transforms-020.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1/regions-transforms-020.xht new file mode 100644 index 00000000000..e0866521167 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1/regions-transforms-020.xht @@ -0,0 +1,61 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <meta charset="UTF-8" /> + <title>CSS Regions: Transformed region with named flow (fragmentable) content that breaks across multiple regions</title> + <link href="mailto:dalcala@adobe.com" rel="author" title="David Alcala" /> + <link href="mailto:rhauck@adobe.com" rel="author" title="Rebecca Hauck" /> + <link href="mailto:mibalan@adobe.com" rel="reviewer" title="Mihai Balan" /> <!-- 2013-07-24 --> + <link href="http://www.w3.org/TR/css3-regions/#the-flow-into-property" rel="help" /> + <link href="http://www.w3.org/TR/css3-regions/#flow-from" rel="help" /> + <link href="http://www.w3.org/TR/css-transforms-1/#two-d-transform-functions" rel="help" /> + <link href="http://www.w3.org/TR/css3-break/#transforms" rel="help" /> + <link href="http://www.w3.org/TR/css3-break/#breaking-rules" rel="help" /> + <link href="reference/regions-transforms-020-ref.xht" rel="match" /> + <meta content="This test checks that the named flow content that is fragmentable (has a break point) + is transformed when it breaks across multiple regions." name="assert" /> + <style> + #named-flow { + width: 100px; + height: 100px; + flow-into: f; + } + .src-child { + height: 50px; + background-color: green; + } + .region { + width: 100px; + height: 50px; + margin-left: 10px; + float: left; + background-color: red; + flow-from: f; + transform: scaleY(2); + transform-origin: top left; + } + + .failure-div { + position: absolute; + margin-left: 10px; + background-color: red; + width: 98px; + height: 98px; + } + .right { + left: 119px; + } + </style> +</head> +<body> + <p>The test passes if you see two green squares and no red.</p> + <div class="failure-div"></div> + <div class="failure-div right"></div> + <div id="named-flow"> + <div class="src-child"></div> + <div class="src-child"></div> + </div> + <div class="region"></div> + <div class="region"></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1/regions-transforms-021.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1/regions-transforms-021.xht new file mode 100644 index 00000000000..4e438ad285c --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1/regions-transforms-021.xht @@ -0,0 +1,53 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <meta charset="UTF-8" /> + <title>CSS Regions: Transforms on multiple named flow (non-text) content nodes that break across multiple regions</title> + <link href="mailto:dalcala@adobe.com" rel="author" title="David Alcala" /> + <link href="mailto:rhauck@adobe.com" rel="author" title="Rebecca Hauck" /> + <link href="mailto:mibalan@adobe.com" rel="reviewer" title="Mihai Balan" /> <!-- 2013-07-24 --> + <link href="http://www.w3.org/TR/css3-regions/#the-flow-into-property" rel="help" /> + <link href="http://www.w3.org/TR/css3-regions/#flow-from" rel="help" /> + <link href="http://www.w3.org/TR/css-transforms-1/#two-d-transform-functions" rel="help" /> + <link href="http://www.w3.org/TR/css3-break/#transforms" rel="help" /> + <link href="reference/regions-transforms-020-ref.xht" rel="match" /> + <meta content="This test checks that separate transforms can be applied to each named flow content + node that breaks across multiple regions and that each fragment has its own transform origin." name="assert" /> + <style> + .named-flow { + float: left; + background-color: green; + flow-into: f; + } + #named-flow-1 { + margin-top: 25px; + margin-left: 25px; + width: 50px; + height: 50px; + transform: scale(2); + transform-origin: center center; + } + #named-flow-2 { + width: 100px; + height: 50px; + margin-top: 25px; + transform-origin: top left; + transform: scaleY(2); + } + .region { + width: 100px; + height: 100px; + margin-left: 10px; + float: left; + background-color: red; + flow-from: f; + } + </style> +</head> +<body> + <p>The test passes if you see two green squares and no red.</p> + <div id="named-flow-1" class="named-flow"></div> + <div id="named-flow-2" class="named-flow"></div> + <div class="region"></div> + <div class="region"></div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1/regions-transforms-022.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1/regions-transforms-022.xht new file mode 100644 index 00000000000..0836a17cd7d --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1/regions-transforms-022.xht @@ -0,0 +1,83 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <meta charset="UTF-8" /> + <title>CSS Regions: Transforms on multiple named flow (text) content nodes that break across multiple regions</title> + <link href="mailto:dalcala@adobe.com" rel="author" title="David Alcala" /> + <link href="mailto:rhauck@adobe.com" rel="author" title="Rebecca Hauck" /> + <link href="mailto:mibalan@adobe.com" rel="reviewer" title="Mihai Balan" /> <!-- 2013-07-24 --> + <link href="http://www.w3.org/TR/css3-regions/#the-flow-into-property" rel="help" /> + <link href="http://www.w3.org/TR/css3-regions/#flow-from" rel="help" /> + <link href="http://www.w3.org/TR/css-transforms-1/#two-d-transform-functions" rel="help" /> + <link href="http://www.w3.org/TR/css3-break/#transforms" rel="help" /> + <link href="reference/regions-transforms-020-ref.xht" rel="match" /> + <meta content="ahem" name="flags" /> + <meta content="This test checks that separate transforms can be applied to each named flow content + text node that breaks across multiple regions" name="assert" /> + <style> + .ahem { + font-family: Ahem; + font-size: 10px; + line-height: 20px; + } + .named-flow { + width: 100px; + color: green; + flow-into: f; + } + #named-flow-1 { + margin-left: -50px; + transform: translateX(50px); + } + #named-flow-2 { + transform: rotate(90deg); + } + .region { + width: 100px; + height: 100px; + margin-left: 10px; + float: left; + flow-from: f; + } + .failure { + width: 100px; + height: 100px; + position: absolute; + float: left; + margin-left: 10px; + background-color: green; + z-index: -1; + } + .left { + color: red; + } + .right { + left: 118px; + } + .vertical-bar { + width: 10px; + height: 100px; + float: left; + background-color: red; + margin-left: 5px; + margin-right: 5px; + } + </style> +</head> +<body> + <p>The test passes if you see two green squares and no red.</p> + <div id="named-flow-1" class="ahem named-flow">XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX</div> + <div id="named-flow-2" class="ahem named-flow">XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX</div> + <div class="region"></div> + <div class="region"></div> + <div class="ahem failure left"> + XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX + </div> + <div class="ahem failure right"> + <div class="vertical-bar"></div> + <div class="vertical-bar"></div> + <div class="vertical-bar"></div> + <div class="vertical-bar"></div> + <div class="vertical-bar"></div> + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1/toc.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1/toc.xht new file mode 100644 index 00000000000..e55c4a236d9 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1/toc.xht @@ -0,0 +1,54 @@ + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>CSS Fragmentation Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> +<body> + <h1>CSS Fragmentation Module Level 3 CR Test Suite By Chapter</h1> + + <p>This index contains both + <a href="http://wiki.csswg.org/test/selftest">self-describing tests</a> + and reftests. + A separate <a href="reftest-toc.xht">alphabetical reftest index</a> + is provided for tests in <a href="http://wiki.csswg.org/test/reftest">reftest + format</a> along with the <a href="reftest.list">reftest manifest</a>.</p> + + <table> + <tbody id="s1"> + <tr><th><a href="chapter-1.xht">Chapter 1 - + Introduction</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s2"> + <tr><th><a href="chapter-2.xht">Chapter 2 - + Fragmentation Model and Terminology</a></th> + <td>(4 Tests)</td></tr> + </tbody> + <tbody id="s3"> + <tr><th><a href="chapter-3.xht">Chapter 3 - + Controlling Breaks</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s4"> + <tr><th><a href="chapter-4.xht">Chapter 4 - + Rules for Breaking</a></th> + <td>(2 Tests)</td></tr> + </tbody> + <tbody id="s5"> + <tr><th><a href="chapter-5.xht">Chapter 5 - + Box Model for Breaking</a></th> + <td>(9 Tests)</td></tr> + </tbody> + <tbody id="s6"> + <tr><th><a href="chapter-6.xht">Chapter 6 - + Conformance</a></th> + <td>(0 Tests)</td></tr> + </tbody> + </table> +</body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1print/chapter-1.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/chapter-1.xht new file mode 100644 index 00000000000..71d90c11cca --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/chapter-1.xht @@ -0,0 +1,57 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Introduction - CSS Fragmentation Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Fragmentation Module Level 3 CR Test Suite</h1> + <h2>Introduction (0 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s1">+</a> + <a href="http://www.w3.org/TR/css3-break/#intro">1 Introduction</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s1.#fragmentation"> + <!-- 0 tests --> + </tbody> + <tbody id="s1.#pagination"> + <!-- 0 tests --> + </tbody> + <tbody id="s1.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s1.1">+</a> + <a href="http://www.w3.org/TR/css3-break/#placement">1.1 Module Interactions</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s1.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s1.2">+</a> + <a href="http://www.w3.org/TR/css3-break/#values">1.2 Values</a></th></tr> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1print/chapter-2.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/chapter-2.xht new file mode 100644 index 00000000000..f84166dea78 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/chapter-2.xht @@ -0,0 +1,131 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Fragmentation Model and Terminology - CSS Fragmentation Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Fragmentation Module Level 3 CR Test Suite</h1> + <h2>Fragmentation Model and Terminology (4 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2">+</a> + <a href="http://www.w3.org/TR/css3-break/#fragmentation-model">2 Fragmentation Model and Terminology</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s2.#box-fragment"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.#break"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.#fragment"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.#fragmentainer"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.#fragmentation-break"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.#fragmentation-container"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.#fragmentation-context"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.#fragmentation-direction"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.#fragmentation-root"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.#fragmentation0"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.#fragmented-flow"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.#remaining-fragmentainer-extent"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.1">+</a> + <a href="http://www.w3.org/TR/css3-break/#parallel-flows">2.1 Parallel Fragmentation Flows</a></th></tr> + <!-- 4 tests --> + <tr id="floats-clear-breaks-002-2.1" class="ahem"> + <td> + <a href="floats-clear-breaks-002.xht">floats-clear-breaks-002</a></td> + <td><a href="reference/floats-clear-breaks-002-ref.xht">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + <td>CSS Regions: forced region breaks and clear on floats inside named flow contents + <ul class="assert"> + <li>Test checks that no regions are left empty when setting a forced region break on a cleared float.</li> + </ul> + </td> + </tr> + <tr id="floats-in-named-flow-012-2.1" class="ahem"> + <td> + <a href="floats-in-named-flow-012.xht">floats-in-named-flow-012</a></td> + <td><a href="reference/floats-in-named-flow-012-ref.xht">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + <td>floats with forced region breaks inside them + <ul class="assert"> + <li>Test checks that floats in named flow contents are floated relative to the region container and not their initial container, even when multiple regions are involved.</li> + </ul> + </td> + </tr> + <tr id="floats-in-named-flow-029-2.1" class="ahem"> + <td> + <a href="floats-in-named-flow-029.xht">floats-in-named-flow-029</a></td> + <td><a href="reference/floats-in-named-flow-029-ref.xht">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + <td>CSS Regions: margins around forced breaks when break is around float + <ul class="assert"> + <li>Test checks that margins are correctly preserved when content has floats and is fragmented via forced breaks.</li> + </ul> + </td> + </tr> + <tr id="floats-in-named-flow-030-2.1" class="ahem"> + <td> + <a href="floats-in-named-flow-030.xht">floats-in-named-flow-030</a></td> + <td><a href="reference/floats-in-named-flow-030-ref.xht">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + <td>CSS Regions: margins around unforced breaks when break is around float + <ul class="assert"> + <li>Test checks that margins are correctly preserved when content has floats and is fragmented via unforced breaks.</li> + </ul> + </td> + </tr> + </tbody> + <tbody id="s2.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.2">+</a> + <a href="http://www.w3.org/TR/css3-break/#nested-flows">2.2 Nested Fragmentation Flows</a></th></tr> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1print/chapter-3.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/chapter-3.xht new file mode 100644 index 00000000000..a55eecd1d7e --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/chapter-3.xht @@ -0,0 +1,153 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Controlling Breaks - CSS Fragmentation Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Fragmentation Module Level 3 CR Test Suite</h1> + <h2>Controlling Breaks (0 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3">+</a> + <a href="http://www.w3.org/TR/css3-break/#breaking-controls">3 Controlling Breaks</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.1">+</a> + <a href="http://www.w3.org/TR/css3-break/#break-between">3.1 Breaks Between Boxes: the &#8216;break-before&#8217; and &#8216;break-after&#8217; properties</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#always"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#any"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#auto"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#avoid"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#avoid-break-values"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#avoid-column"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#avoid-page"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#avoid-region"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#break-after"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#break-before"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#column"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#column-break-values"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#forced-break-values"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#generic-break-values"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#left"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#page"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#page-break-values"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#recto"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#region"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#region-break-values"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#right"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#verso"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.2">+</a> + <a href="http://www.w3.org/TR/css3-break/#break-within">3.2 Breaks Within Boxes: the &#8216;break-inside&#8217; property</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.2.#auto0"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.2.#avoid-column0"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.2.#avoid-page0"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.2.#avoid-region0"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.2.#avoid0"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.2.#break-inside"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.3">+</a> + <a href="http://www.w3.org/TR/css3-break/#widows-orphans">3.3 Breaks Between Lines: &#8216;orphans&#8217;, &#8216;widows&#8217;</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.3.#orphans"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.3.#widows"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.4"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.4">+</a> + <a href="http://www.w3.org/TR/css3-break/#page-break-properties">3.4 Page Break Aliases: the &#8216;page-break-before&#8217;, &#8216;page-break-after&#8217;, and &#8216;page-break-inside&#8217; properties</a></th></tr> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1print/chapter-4.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/chapter-4.xht new file mode 100644 index 00000000000..ec92f8f91d4 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/chapter-4.xht @@ -0,0 +1,141 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Rules for Breaking - CSS Fragmentation Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Fragmentation Module Level 3 CR Test Suite</h1> + <h2>Rules for Breaking (2 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s4"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4">+</a> + <a href="http://www.w3.org/TR/css3-break/#breaking-rules">4 Rules for Breaking</a></th></tr> + <!-- 2 tests --> + <tr id="regions-transforms-013-4" class=""> + <td> + <a href="regions-transforms-013.xht">regions-transforms-013</a></td> + <td><a href="reference/regions-transforms-013-alt-ref.xht">=</a> <a href="reference/regions-transforms-013-ref.xht">=</a> </td> + <td></td> + <td>CSS Regions: Transformed named flow (monolithic) content that breaks across multiple regions + <ul class="assert"> + <li>This test checks that the named flow content that is monolithic is transformed when it breaks across multiple regions whether it is sliced or overflowed at the fragmentainer edge.</li> + </ul> + </td> + </tr> + <tr id="regions-transforms-020-4" class=""> + <td> + <a href="regions-transforms-020.xht">regions-transforms-020</a></td> + <td><a href="reference/regions-transforms-020-ref.xht">=</a> </td> + <td></td> + <td>CSS Regions: Transformed region with named flow (fragmentable) content that breaks across multiple regions + <ul class="assert"> + <li>This test checks that the named flow content that is fragmentable (has a break point) is transformed when it breaks across multiple regions.</li> + </ul> + </td> + </tr> + </tbody> + <tbody id="s4.#monolithic"> + <!-- 1 tests --> + <tr id="regions-transforms-013-4.#monolithic" class=""> + <td> + <a href="regions-transforms-013.xht">regions-transforms-013</a></td> + <td><a href="reference/regions-transforms-013-alt-ref.xht">=</a> <a href="reference/regions-transforms-013-ref.xht">=</a> </td> + <td></td> + <td>CSS Regions: Transformed named flow (monolithic) content that breaks across multiple regions + <ul class="assert"> + <li>This test checks that the named flow content that is monolithic is transformed when it breaks across multiple regions whether it is sliced or overflowed at the fragmentainer edge.</li> + </ul> + </td> + </tr> + </tbody> + <tbody id="s4.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4.1">+</a> + <a href="http://www.w3.org/TR/css3-break/#possible-breaks">4.1 Possible Break Points</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s4.1.#btw-blocks"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.1.#btw-lines"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.1.#end-block"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.1.#monolithic-breaking"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4.2">+</a> + <a href="http://www.w3.org/TR/css3-break/#break-types">4.2 Types of Breaks</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s4.2.#column-break"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.2.#line-break"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.2.#page-break"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.2.#region-break"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.2.#spread-break"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4.3">+</a> + <a href="http://www.w3.org/TR/css3-break/#forced-breaks">4.3 Forced Breaks</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s4.3.#forced-break"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.4"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4.4">+</a> + <a href="http://www.w3.org/TR/css3-break/#unforced-breaks">4.4 Unforced Breaks</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s4.4.#unforced-break"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.5"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4.5">+</a> + <a href="http://www.w3.org/TR/css3-break/#best-breaks">4.5 Optimizing Unforced Breaks</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s4.5.#widows-orphans-example"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1print/chapter-5.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/chapter-5.xht new file mode 100644 index 00000000000..6d8b802393c --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/chapter-5.xht @@ -0,0 +1,183 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Box Model for Breaking - CSS Fragmentation Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Fragmentation Module Level 3 CR Test Suite</h1> + <h2>Box Model for Breaking (9 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s5"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s5">+</a> + <a href="http://www.w3.org/TR/css3-break/#breaking-boxes">5 Box Model for Breaking</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s5.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s5.1">+</a> + <a href="http://www.w3.org/TR/css3-break/#varying-size-boxes">5.1 Breaking into Varying-size Fragmentainers</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s5.2">+</a> + <a href="http://www.w3.org/TR/css3-break/#break-margins">5.2 Adjoining Margins at Breaks</a></th></tr> + <!-- 2 tests --> + <tr id="floats-in-named-flow-029-5.2" class="ahem"> + <td> + <a href="floats-in-named-flow-029.xht">floats-in-named-flow-029</a></td> + <td><a href="reference/floats-in-named-flow-029-ref.xht">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + <td>CSS Regions: margins around forced breaks when break is around float + <ul class="assert"> + <li>Test checks that margins are correctly preserved when content has floats and is fragmented via forced breaks.</li> + </ul> + </td> + </tr> + <tr id="floats-in-named-flow-030-5.2" class="ahem"> + <td> + <a href="floats-in-named-flow-030.xht">floats-in-named-flow-030</a></td> + <td><a href="reference/floats-in-named-flow-030-ref.xht">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + <td>CSS Regions: margins around unforced breaks when break is around float + <ul class="assert"> + <li>Test checks that margins are correctly preserved when content has floats and is fragmented via unforced breaks.</li> + </ul> + </td> + </tr> + </tbody> + <tbody id="s5.3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s5.3">+</a> + <a href="http://www.w3.org/TR/css3-break/#box-splitting">5.3 Splitting Boxes</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s5.4"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s5.4">+</a> + <a href="http://www.w3.org/TR/css3-break/#break-decoration">5.4 Fragmented Borders and Backgrounds: the &#8216;box-decoration-break&#8217; property</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s5.4.#box-decoration-break"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.4.#clone"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.4.#slice"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.4.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s5.4.1">+</a> + <a href="http://www.w3.org/TR/css3-break/#joining-boxes">5.4.1 Joining Boxes for &#8216;slice&#8217;</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s5.5"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s5.5">+</a> + <a href="http://www.w3.org/TR/css3-break/#transforms">5.5 Transforms, Positioning, and Pagination</a></th></tr> + <!-- 7 tests --> + <tr id="position-relative-001-5.5" class="ahem"> + <td> + <a href="position-relative-001.xht">position-relative-001</a></td> + <td><a href="reference/position-relative-001-ref.xht">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + <td>CSS Regions: flowing content that has position: relative + <ul class="assert"> + <li>Test checks that fragments of content flowed in regions are positioned independently, after the fragmentation occurs.</li> + </ul> + </td> + </tr> + <tr id="regions-transforms-008-5.5" class="ahem"> + <td> + <a href="regions-transforms-008.xht">regions-transforms-008</a></td> + <td><a href="reference/regions-transforms-008-ref.xht">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + <td>CSS Regions: Transformed named flow (text) content that breaks across multiple regions and overflows + <ul class="assert"> + <li>This test checks that named flow text content is transformed when it breaks across multiple regions and that the overflow remains visible.</li> + </ul> + </td> + </tr> + <tr id="regions-transforms-009-5.5" class="ahem"> + <td> + <a href="regions-transforms-009.xht">regions-transforms-009</a></td> + <td><a href="reference/regions-transforms-008-ref.xht">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + <td>CSS Regions: Transformed region with named flow (text) content that breaks across multiple regions and overflows + <ul class="assert"> + <li>This test checks that the regions are transformed when named flow text content breaks across multiple regions and that the overflow remains visible.</li> + </ul> + </td> + </tr> + <tr id="regions-transforms-013-5.5" class=""> + <td> + <a href="regions-transforms-013.xht">regions-transforms-013</a></td> + <td><a href="reference/regions-transforms-013-alt-ref.xht">=</a> <a href="reference/regions-transforms-013-ref.xht">=</a> </td> + <td></td> + <td>CSS Regions: Transformed named flow (monolithic) content that breaks across multiple regions + <ul class="assert"> + <li>This test checks that the named flow content that is monolithic is transformed when it breaks across multiple regions whether it is sliced or overflowed at the fragmentainer edge.</li> + </ul> + </td> + </tr> + <tr id="regions-transforms-020-5.5" class=""> + <td> + <a href="regions-transforms-020.xht">regions-transforms-020</a></td> + <td><a href="reference/regions-transforms-020-ref.xht">=</a> </td> + <td></td> + <td>CSS Regions: Transformed region with named flow (fragmentable) content that breaks across multiple regions + <ul class="assert"> + <li>This test checks that the named flow content that is fragmentable (has a break point) is transformed when it breaks across multiple regions.</li> + </ul> + </td> + </tr> + <tr id="regions-transforms-021-5.5" class=""> + <td> + <a href="regions-transforms-021.xht">regions-transforms-021</a></td> + <td><a href="reference/regions-transforms-020-ref.xht">=</a> </td> + <td></td> + <td>CSS Regions: Transforms on multiple named flow (non-text) content nodes that break across multiple regions + <ul class="assert"> + <li>This test checks that separate transforms can be applied to each named flow content node that breaks across multiple regions and that each fragment has its own transform origin.</li> + </ul> + </td> + </tr> + <tr id="regions-transforms-022-5.5" class="ahem"> + <td> + <a href="regions-transforms-022.xht">regions-transforms-022</a></td> + <td><a href="reference/regions-transforms-020-ref.xht">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + <td>CSS Regions: Transforms on multiple named flow (text) content nodes that break across multiple regions + <ul class="assert"> + <li>This test checks that separate transforms can be applied to each named flow content text node that breaks across multiple regions</li> + </ul> + </td> + </tr> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1print/chapter-6.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/chapter-6.xht new file mode 100644 index 00000000000..4e010584986 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/chapter-6.xht @@ -0,0 +1,159 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Conformance - CSS Fragmentation Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Fragmentation Module Level 3 CR Test Suite</h1> + <h2>Conformance (0 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s6"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6">+</a> + <a href="http://www.w3.org/TR/css3-break/#conformance">6 Conformance</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6.1">+</a> + <a href="http://www.w3.org/TR/css3-break/#conventions">6.1 Document Conventions</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6.2">+</a> + <a href="http://www.w3.org/TR/css3-break/#conformance-classes">6.2 Conformance Classes</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2.#authoring-tool"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2.#renderer"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2.#style-sheet"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6.3">+</a> + <a href="http://www.w3.org/TR/css3-break/#partial">6.3 Partial Implementations</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s6.4"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6.4">+</a> + <a href="http://www.w3.org/TR/css3-break/#experimental">6.4 Experimental Implementations</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s6.5"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6.5">+</a> + <a href="http://www.w3.org/TR/css3-break/#testing">6.5 Non-Experimental Implementations</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s6.6"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6.6">+</a> + <a href="http://www.w3.org/TR/css3-break/#cr-exit-criteria">6.6 CR Exit Criteria</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s.#abstract"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#acknowledgments"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#changes"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#contents"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#css-fragmentation-module"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#index"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#normative-references"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#other-references"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#property-index"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#ref-CSS-REGIONS-1"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#ref-CSS-TEXT-3"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#ref-CSS-WRITING-MODES-3"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#ref-CSS21"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#ref-CSS3-FLEXBOX"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#ref-CSS3-SIZING"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#ref-CSS3-TRANSFORMS"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#ref-CSS3BG"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#ref-CSS3COL"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#ref-CSS3PAGE"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#ref-CSS3VAL"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#ref-RFC2119"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#references"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#status"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#subtitle"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#w3c_process_revision"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1print/floats-clear-breaks-002.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/floats-clear-breaks-002.xht new file mode 100644 index 00000000000..013f6292e66 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/floats-clear-breaks-002.xht @@ -0,0 +1,86 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Regions: forced region breaks and clear on floats inside named flow contents</title> + <link href="mailto:mibalan@adobe.com" rel="author" title="Mihai Balan" /> + <link href="http://www.w3.org/TR/css3-regions/#the-flow-into-property" rel="help" /> + <link href="http://www.w3.org/TR/css3-break/#parallel-flows" rel="help" /> + <meta content="ahem" name="flags" /> + <meta content="Test checks that no regions are left empty when setting + a forced region break on a cleared float." name="assert" /> + <link href="reference/floats-clear-breaks-002-ref.xht" rel="match" /> + <style> + article { + font-family: Ahem; + font-size: 20px; + line-height: 1em; + } + + .flow { + flow-into: f; + } + + .float { + float: left; + color: blue; + } + .break { + break-before: region; + } + + .clear { + clear: left; + color: green; + } + + .bordered { + border: 10px solid black; + } + + .region { + flow-from: f; + max-width: 100px; + margin-bottom: 10px; + } + + .region &gt; p { + background: red; + } + </style> + </head> + <body> + <p> + Test passes if you see two squares separated by a small vertical space. The squares should + have a black outline, the top square should be blue and the bottom one should be green.<br /> + You should see no red. + </p> + + <div class="bordered region"> + <p>&#xA0;</p> + </div> + <div class="bordered region"> + <p>&#xA0;</p> + </div> + <!-- In case the clear + forced break lead to an empty region, the content will flow in this + third region ending up without a border. --> + <div class="region"> + <p>&#xA0;</p> + </div> + + <article class="flow"> + <div class="float"> + xxxxx + xxxxx + xxxxx + xxxxx + xxxxx + </div> + <div class="break clear"> + xxxxx + xxxxx + xxxxx + xxxxx + xxxxx + </div> + </article> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1print/floats-in-named-flow-012.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/floats-in-named-flow-012.xht new file mode 100644 index 00000000000..9841dedb3a0 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/floats-in-named-flow-012.xht @@ -0,0 +1,83 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Test: floats with forced region breaks inside them</title> + <link href="mailto:mibalan@adobe.com" rel="author" title="Mihai Balan" /> + <link href="http://www.w3.org/TR/css3-regions/#the-flow-into-property" rel="help" /> + <link href="http://www.w3.org/TR/css3-break/#parallel-flows" rel="help" /> + <meta content="ahem" name="flags" /> + <meta content="Test checks that floats in named flow contents are floated relative + to the region container and not their initial container, even when multiple regions + are involved." name="assert" /> + <link href="reference/floats-in-named-flow-012-ref.xht" rel="match" /> + <style> + article { + color: blue; + font-family: Ahem; + font-size: 20px; + line-height: 1em; + } + .flow { + flow-into: f; + } + .float { + color: green; + float: left; + } + .break { + break-before: region; + } + .region { + flow-from: f; + margin: 10px; + width: 200px; + background: red; + } + + .region &gt; p { + background: red; + } + </style> + </head> + <body> + <p> + Test passes if you see two identical rows of colored squares. Each row should have three + squares, from left to right as follows: blue, gray, green. The squares in a row should + be flush to each other, but the two rows should have some space between them.<br /> + Test fails is you see any red. + </p> + + <article> + <div class="flow"> + <div class="float"> + <div> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx + </div> + <div class="break"> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx + </div> + </div> + <div> + xxxxx xxxxx xxxxx xxxxx xxxxx + </div> + <div class="break"> + xxxxx xxxxx xxxxx xxxxx xxxxx + </div> + </div> + </article> + + <div class="region"> + <p>&#xA0;</p> + </div> + <div class="region"> + <p>&#xA0;</p> + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1print/floats-in-named-flow-029.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/floats-in-named-flow-029.xht new file mode 100644 index 00000000000..e0dcbfb7fcf --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/floats-in-named-flow-029.xht @@ -0,0 +1,90 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Regions: margins around forced breaks when break is around float</title> + <link href="mailto:mibalan@adobe.com" rel="author" title="Mihai Balan" /> + <link href="http://www.w3.org/TR/css3-regions/#the-flow-into-property" rel="help" /> + <link href="http://www.w3.org/TR/css3-break/#break-margins" rel="help" /> + <link href="http://www.w3.org/TR/css3-break/#parallel-flows" rel="help" /> + <meta content="ahem" name="flags" /> + <meta content="Test checks that margins are correctly preserved when content + has floats and is fragmented via forced breaks." name="assert" /> + <link href="reference/floats-in-named-flow-029-ref.xht" rel="match" /> + <style> + article { + font-family: Ahem; + font-size: 20px; + line-height: 1em; + } + + .flow { + flow-into: f; + } + + .break { + break-before: region; + } + + .spaced { + margin: 1em 2em 3em 5em; + color: green; + } + + .float { + float: left; + color: blue; + } + .bordered { + border: 10px solid black; + } + + .region { + flow-from: f; + float: left; + margin-left: 10px; + } + + .region &gt; p { + background: red; + } + </style> + </head> + <body> + <p> + <!-- TODO Determine what the outcome should be - currently expecting a resolution on + the issue on www-style/css3-break --> + Test passes if you see two colored squares each inside a black-bordered rectangle: + </p><ul> + <li>The black-bordered rectangles should be separated by a small horizontal space</li> + <li>The colored squares should be positioned roughly in the top-left area of their + rectangles, but without being flush to any of its sides</li> + </ul><br /> + You should see no red. + <p></p> + + <div class="bordered region"> + <p>&#xA0;</p> + </div><div class="bordered region"> + <p>&#xA0;</p> + </div> + <div class="region"> + <p>&#xA0;</p> + </div> + + <article class="flow"> + <div class="spaced float"> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx + </div> + <div class="break spaced"> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx + </div> + </article> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1print/floats-in-named-flow-030.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/floats-in-named-flow-030.xht new file mode 100644 index 00000000000..f5395288e60 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/floats-in-named-flow-030.xht @@ -0,0 +1,88 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Regions: margins around unforced breaks when break is around float</title> + <link href="mailto:mibalan@adobe.com" rel="author" title="Mihai Balan" /> + <link href="http://www.w3.org/TR/css3-regions/#the-flow-into-property" rel="help" /> + <link href="http://www.w3.org/TR/css3-break/#break-margins" rel="help" /> + <link href="http://www.w3.org/TR/css3-break/#parallel-flows" rel="help" /> + <meta content="ahem" name="flags" /> + <meta content="Test checks that margins are correctly preserved when content + has floats and is fragmented via unforced breaks." name="assert" /> + <link href="reference/floats-in-named-flow-030-ref.xht" rel="match" /> + <style> + article { + font-family: Ahem; + font-size: 20px; + line-height: 1em; + } + + .flow { + flow-into: f; + } + + .spaced { + margin: 1em 2em 3em 5em; + color: green; + } + + .float { + float: left; + color: blue; + } + + .bordered { + border: 10px solid black; + } + + .region { + flow-from: f; + /* float: left; is used to trigger shrink-to-fit sizing */ + float: left; + margin-left: 10px; + } + + .region &gt; p { + background: red; + } + </style> + </head> + <body> + <p> + <!-- TODO Determine what the outcome should be - currently expecting a resolution on + the issue on www-style/css3-break --> + Test passes if you see two colored squares each inside a black-bordered rectangle: + </p><ul> + <li>The black-bordered rectangles should be separated by a small vertical space</li> + <li>The green square should have its top edge flush with the top border of its + containing rectangle</li> + </ul> + You should see no red. + <p></p> + + <div style="height: 125px;" class="bordered region"> + <p>&#xA0;</p> + </div><div class="bordered region"> + <p>&#xA0;</p> + </div> + <div class="region"> + <p>&#xA0;</p> + </div> + + <article class="flow"> + <div class="spaced float"> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx + </div> + <div class="spaced"> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx + </div> + </article> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1print/position-relative-001.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/position-relative-001.xht new file mode 100644 index 00000000000..164308e3c52 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/position-relative-001.xht @@ -0,0 +1,77 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Regions: flowing content that has position: relative</title> + <link href="mailto:mibalan@adobe.com" rel="author" title="Mihai Balan" /> + <link href="http://www.w3.org/TR/css3-regions/#the-flow-into-property" rel="help" /> + <link href="http://www.w3.org/TR/css3-regions/#flow-from" rel="help" /> + <!-- Section points to section in the ED. Eventually this should be kept in the WD, too. --> + <link href="http://www.w3.org/TR/css3-break/#transforms" rel="help" /> + <meta content="Test checks that fragments of content flowed in regions are positioned independently, after the fragmentation occurs." name="assert" /> + <meta content="ahem" name="flags" /> + <link href="reference/position-relative-001-ref.xht" rel="match" /> + <style> + .flow { + flow-into: f; + font-family: Ahem; + font-size: 20px; + line-height: 1em; + color: green; + position: relative; + top: 20px; + left: -20px; + } + + .container { + display: inline-block; + } + + .region { + flow-from: f; + margin: 0 0 0 20px; + } + .region p { + background-color: red; + height: 50%; + } + .big { + width: 100px; + height: 100px; + } + .small { + width: 60px; + height: 60px; + } + + .marker { + background: red; + width: 20px; + height: 20px; + } + </style> + </head> + <body> + <p>Test passes if you see two green squares (one bigger and one smaller) and no red.</p> + <div class="flow"> + xxxxx + xxxxx + xxxxx + xxxxx + xxxxx + xxx + xxx + xxx + </div> + <div class="container"> + <div class="big region"> + <p>&#xA0;</p> + </div> + <div class="marker"></div> + </div> + <div class="container"> + <div class="small region"> + <p>&#xA0;</p> + </div> + <div class="marker"></div> + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1print/reference/floats-clear-breaks-002-ref.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/reference/floats-clear-breaks-002-ref.xht new file mode 100644 index 00000000000..c30f67c556a --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/reference/floats-clear-breaks-002-ref.xht @@ -0,0 +1,59 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reftest Reference</title> + <link href="mailto:mibalan@adobe.com" rel="author" title="Mihai Balan" /> + <style> + article { + font-family: Ahem; + font-size: 20px; + line-height: 1em; + color: green; + } + + .float { + float: left; + color: blue; + } + + .bordered { + border: 10px solid black; + } + + .region { + overflow: hidden; + max-width: 100px; + margin-bottom: 10px; + } + </style> + </head> + <body> + <p> + Test passes if you see two squares separated by a small vertical space. The squares should + have a black outline, the top square should be blue and the bottom one should be green.<br /> + You should see no red. + </p> + + <div class="bordered region"> + <article> + <div class="float"> + xxxxx + xxxxx + xxxxx + xxxxx + xxxxx + </div> + </article> + </div> + <div class="bordered region"> + <article> + <div> + xxxxx + xxxxx + xxxxx + xxxxx + xxxxx + </div> + </article> + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1print/reference/floats-in-named-flow-012-ref.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/reference/floats-in-named-flow-012-ref.xht new file mode 100644 index 00000000000..a2e7363432e --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/reference/floats-in-named-flow-012-ref.xht @@ -0,0 +1,69 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reftest Reference</title> + <link href="mailto:mibalan@adobe.com" rel="author" title="Mihai Balan" /> + <style> + article { + color: blue; + font-family: Ahem; + font-size: 20px; + line-height: 1em; + } + .float { + color: green; + float: left; + } + .region { + margin: 10px; + width: 200px; + background: red; + } + </style> + </head> + <body> + <p> + Test passes if you see two identical rows of colored squares. Each row should have three + squares, from left to right as follows: blue, gray, green. The squares in a row should + be flush to each other, but the two rows should have some space between them.<br /> + Test fails is you see any red. + </p> + + + <div class="region"> + <article> + <div class="flow"> + <div class="float"> + <div> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx + </div> + </div> + <div> + xxxxx xxxxx xxxxx xxxxx xxxxx + </div> + </div> + </article> + </div> + <div class="region"> + <article> + <div class="flow"> + <div class="float"> + <div> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx + </div> + </div> + <div> + xxxxx xxxxx xxxxx xxxxx xxxxx + </div> + </div> + </article> + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1print/reference/floats-in-named-flow-029-ref.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/reference/floats-in-named-flow-029-ref.xht new file mode 100644 index 00000000000..bfa00b38045 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/reference/floats-in-named-flow-029-ref.xht @@ -0,0 +1,67 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reftest Reference</title> + <link href="mailto:mibalan@adobe.com" rel="author" title="Mihai Balan" /> + <style> + article { + font-family: Ahem; + font-size: 20px; + line-height: 1em; + } + + .spaced { + margin: 1em 2em 3em 5em; + color: green; + } + + .float { + float: left; + color: blue; + } + .bordered { + border: 10px solid black; + } + + .region { + display: inline-block; + float: left; + margin-left: 10px; + } + </style> + </head> + <body> + <p> + <!-- TODO Determine what the outcome should be - currently expecting a resolution on + the issue on www-style/css3-break --> + Test passes if you see two colored squares each inside a black-bordered rectangle: + </p><ul> + <li>The black-bordered rectangles should be separated by a small horizontal space</li> + <li>The colored squares should be positioned roughly in the top-left area of their + rectangles, but without being flush to any of its sides</li> + </ul><br /> + You should see no red. + <p></p> + + <div class="bordered region"> + <article> + <div class="spaced float"> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx + </div> + </article> + </div><div class="bordered region"> + <article> + <div class="break spaced"> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx + </div> + </article> + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1print/reference/floats-in-named-flow-030-ref.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/reference/floats-in-named-flow-030-ref.xht new file mode 100644 index 00000000000..8add5da17f8 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/reference/floats-in-named-flow-030-ref.xht @@ -0,0 +1,68 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reftest Reference</title> + <link href="mailto:mibalan@adobe.com" rel="author" title="Mihai Balan" /> + <style> + article { + font-family: Ahem; + font-size: 20px; + line-height: 1em; + } + + .spaced { + margin: 0 2em 3em 5em; + color: green; + } + .float { + margin-top: 1em; + float: left; + color: blue; + } + + .bordered { + border: 10px solid black; + } + + .region { + /* float: left; is used to trigger shrink-to-fit sizing */ + float: left;; + margin-left: 10px; + } + </style> + </head> + <body> + <p> + <!-- TODO Determine what the outcome should be - currently expecting a resolution on + the issue on www-style/css3-break --> + Test passes if you see two colored squares each inside a black-bordered rectangle: + </p><ul> + <li>The black-bordered rectangles should be separated by a small vertical space</li> + <li>The green square should have its top edge flush with the top border of its + containing rectangle</li> + </ul> + You should see no red. + <p></p> + + <div style="height: 125px;" class="bordered region"> + <article> + <div class="spaced float"> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx + </div> + </article> + </div><div class="bordered region"> + <article> + <div class="spaced"> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx<br /> + xxxxx + </div> + </article> + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1print/reference/position-relative-001-ref.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/reference/position-relative-001-ref.xht new file mode 100644 index 00000000000..7162ce35318 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/reference/position-relative-001-ref.xht @@ -0,0 +1,56 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reftest Reference</title> + <link href="mailto:mibalan@adobe.com" rel="author" title="Mihai Balan" /> + <style> + .flow { + font-family: Ahem; + font-size: 20px; + line-height: 1em; + color: green; + position: relative; + top: 20px; + left: -20px; + } + + .container { + display: inline-block; + } + + .region { + margin: 0 0 0 20px; + } + .big { + width: 100px; + height: 100px; + } + .small { + width: 60px; + height: 60px; + } + </style> + </head> + <body> + <p>Test passes if you see two green squares (one bigger and one smaller) and no red.</p> + <div class="container"> + <div class="big region"> + <div class="flow"> + xxxxx + xxxxx + xxxxx + xxxxx + xxxxx + </div> + </div> + </div> + <div class="container"> + <div class="small region"> + <div class="flow"> + xxx + xxx + xxx + </div> + </div> + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1print/reference/regions-transforms-008-ref.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/reference/regions-transforms-008-ref.xht new file mode 100644 index 00000000000..aab004e44bb --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/reference/regions-transforms-008-ref.xht @@ -0,0 +1,35 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reftest Reference</title> + <link href="mailto:rhauck@adobe.com" rel="author" title="Rebecca Hauck" /> + <link href="mailto:mibalan@adobe.com" rel="reviewer" title="Mihai Balan" /> <!-- 2013-07-24 --> + <style type="text/css"> + .square { + float: left; + font-family: Ahem; + font-size: 10px; + line-height: 20px; + margin-left: 10px; + color: green; + width: 100px; + height: 100px; + border: 1px solid black; + } + + </style> +</head> +<body> + <p>The test passes if:</p> + <ul> + <li>The two squares each contain five green horizontal stripes</li> + <li>There are two green horizontal stripes below the square on right</li> + <li>There is no red</li> + </ul> + <div class="square"> + XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX + </div> + <div class="square"> + XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1print/reference/regions-transforms-013-alt-ref.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/reference/regions-transforms-013-alt-ref.xht new file mode 100644 index 00000000000..e393e082bf9 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/reference/regions-transforms-013-alt-ref.xht @@ -0,0 +1,20 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reftest Reference</title> + <link href="mailto:rhauck@adobe.com" rel="author" title="Rebecca Hauck" /> + <link href="mailto:mibalan@adobe.com" rel="reviewer" title="Mihai Balan" /> <!-- 2013-07-24 --> + <style type="text/css"> + .green-rect { + width: 100px; + height: 200px; + margin-left: 10px; + float: left; + background-color: green; + } + </style> +</head> +<body> + <p>The test passes if you see either two green squares or one vertical green rectangle. There should be no red.</p> + <div class="green-rect"></div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1print/reference/regions-transforms-013-ref.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/reference/regions-transforms-013-ref.xht new file mode 100644 index 00000000000..5a6a3049a08 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/reference/regions-transforms-013-ref.xht @@ -0,0 +1,21 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reftest Reference</title> + <link href="mailto:dalcala@adobe.com" rel="author" title="David Alcala" /> + <link href="mailto:mibalan@adobe.com" rel="reviewer" title="Mihai Balan" /> <!-- 2013-07-24 --> + <style type="text/css"> + .green-square { + width: 100px; + height: 100px; + margin-left: 10px; + float: left; + background-color: green; + } + </style> +</head> +<body> + <p>The test passes if you see either two green squares or one vertical green rectangle. There should be no red.</p> + <div class="green-square"></div> + <div class="green-square"></div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1print/reference/regions-transforms-020-ref.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/reference/regions-transforms-020-ref.xht new file mode 100644 index 00000000000..aae13775fd8 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/reference/regions-transforms-020-ref.xht @@ -0,0 +1,21 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reftest Reference</title> + <link href="mailto:rhauck@adobe.com" rel="author" title="Rebecca Hauck" /> + <link href="mailto:mibalan@adobe.com" rel="reviewer" title="Mihai Balan" /> <!-- 2013-07-24 --> + <style type="text/css"> + .green-square { + width: 100px; + height: 100px; + margin-left: 10px; + float: left; + background-color: green; + } + </style> +</head> +<body> + <p>The test passes if you see two green squares and no red.</p> + <div class="green-square"></div> + <div class="green-square"></div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1print/reftest-toc.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/reftest-toc.xht new file mode 100644 index 00000000000..48d26f46228 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/reftest-toc.xht @@ -0,0 +1,121 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>CSS Fragmentation Module Level 3 CR Test Suite Reftest Index</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Fragmentation Module Level 3 CR Test Suite Reftest Index</h1> + <table width="100%"> + <col id="test-column"></col> + <col id="ref-column"></col> + <col id="flags-column"></col> + <thead> + <tr> + <th>Test</th> + <th>Reference</th> + <th>Flags</th> + </tr> + </thead> + <tbody id="floats-clear-breaks-002" class="ahem"> + <tr> + <td rowspan="1" title="CSS Regions: forced region breaks and clear on floats inside named flow contents"> + <a href="floats-clear-breaks-002.xht">floats-clear-breaks-002</a></td> + <td><a href="reference/floats-clear-breaks-002-ref.xht">=</a> </td> + <td rowspan="1"><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + </tr> + </tbody> + <tbody id="floats-in-named-flow-012" class="ahem"> + <tr> + <td rowspan="1" title="floats with forced region breaks inside them"> + <a href="floats-in-named-flow-012.xht">floats-in-named-flow-012</a></td> + <td><a href="reference/floats-in-named-flow-012-ref.xht">=</a> </td> + <td rowspan="1"><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + </tr> + </tbody> + <tbody id="floats-in-named-flow-029" class="ahem"> + <tr> + <td rowspan="1" title="CSS Regions: margins around forced breaks when break is around float"> + <a href="floats-in-named-flow-029.xht">floats-in-named-flow-029</a></td> + <td><a href="reference/floats-in-named-flow-029-ref.xht">=</a> </td> + <td rowspan="1"><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + </tr> + </tbody> + <tbody id="floats-in-named-flow-030" class="ahem"> + <tr> + <td rowspan="1" title="CSS Regions: margins around unforced breaks when break is around float"> + <a href="floats-in-named-flow-030.xht">floats-in-named-flow-030</a></td> + <td><a href="reference/floats-in-named-flow-030-ref.xht">=</a> </td> + <td rowspan="1"><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + </tr> + </tbody> + <tbody id="position-relative-001" class="ahem"> + <tr> + <td rowspan="1" title="CSS Regions: flowing content that has position: relative"> + <a href="position-relative-001.xht">position-relative-001</a></td> + <td><a href="reference/position-relative-001-ref.xht">=</a> </td> + <td rowspan="1"><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + </tr> + </tbody> + <tbody id="regions-transforms-008" class="ahem"> + <tr> + <td rowspan="1" title="CSS Regions: Transformed named flow (text) content that breaks across multiple regions and overflows"> + <a href="regions-transforms-008.xht">regions-transforms-008</a></td> + <td><a href="reference/regions-transforms-008-ref.xht">=</a> </td> + <td rowspan="1"><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + </tr> + </tbody> + <tbody id="regions-transforms-009" class="ahem"> + <tr> + <td rowspan="1" title="CSS Regions: Transformed region with named flow (text) content that breaks across multiple regions and overflows"> + <a href="regions-transforms-009.xht">regions-transforms-009</a></td> + <td><a href="reference/regions-transforms-008-ref.xht">=</a> </td> + <td rowspan="1"><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + </tr> + </tbody> + <tbody id="regions-transforms-013" class=""> + <tr> + <td rowspan="2" title="CSS Regions: Transformed named flow (monolithic) content that breaks across multiple regions"> + <a href="regions-transforms-013.xht">regions-transforms-013</a></td> + <td><a href="reference/regions-transforms-013-alt-ref.xht">=</a> </td> + <td rowspan="2"></td> + </tr> + <tr> + <td><a href="reference/regions-transforms-013-alt-ref.xht">=</a></td> + </tr> + </tbody> + <tbody id="regions-transforms-020" class=""> + <tr> + <td rowspan="1" title="CSS Regions: Transformed region with named flow (fragmentable) content that breaks across multiple regions"> + <a href="regions-transforms-020.xht">regions-transforms-020</a></td> + <td><a href="reference/regions-transforms-020-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="regions-transforms-021" class=""> + <tr> + <td rowspan="1" title="CSS Regions: Transforms on multiple named flow (non-text) content nodes that break across multiple regions"> + <a href="regions-transforms-021.xht">regions-transforms-021</a></td> + <td><a href="reference/regions-transforms-020-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="regions-transforms-022" class="ahem"> + <tr> + <td rowspan="1" title="CSS Regions: Transforms on multiple named flow (text) content nodes that break across multiple regions"> + <a href="regions-transforms-022.xht">regions-transforms-022</a></td> + <td><a href="reference/regions-transforms-020-ref.xht">=</a> </td> + <td rowspan="1"><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + </tr> + </tbody> + </table> + + </body> +</html> diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1print/reftest.list b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/reftest.list new file mode 100644 index 00000000000..5e205e23727 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/reftest.list @@ -0,0 +1,13 @@ + +floats-clear-breaks-002.xht == reference/floats-clear-breaks-002-ref.xht +floats-in-named-flow-012.xht == reference/floats-in-named-flow-012-ref.xht +floats-in-named-flow-029.xht == reference/floats-in-named-flow-029-ref.xht +floats-in-named-flow-030.xht == reference/floats-in-named-flow-030-ref.xht +position-relative-001.xht == reference/position-relative-001-ref.xht +regions-transforms-008.xht == reference/regions-transforms-008-ref.xht +regions-transforms-009.xht == reference/regions-transforms-008-ref.xht +regions-transforms-013.xht == reference/regions-transforms-013-alt-ref.xht +regions-transforms-013.xht == reference/regions-transforms-013-ref.xht +regions-transforms-020.xht == reference/regions-transforms-020-ref.xht +regions-transforms-021.xht == reference/regions-transforms-020-ref.xht +regions-transforms-022.xht == reference/regions-transforms-020-ref.xht diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1print/regions-transforms-008.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/regions-transforms-008.xht new file mode 100644 index 00000000000..bfdf2d48850 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/regions-transforms-008.xht @@ -0,0 +1,74 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <meta charset="UTF-8" /> + <title>CSS Regions: Transformed named flow (text) content that breaks across multiple regions and overflows</title> + <link href="mailto:rhauck@adobe.com" rel="author" title="Rebecca Hauck" /> + <link href="mailto:dalcala@adobe.com" rel="author" title="David Alcala" /> + <link href="mailto:mibalan@adobe.com" rel="reviewer author" title="Mihai Balan" /> <!-- 2013-07-24 --> + <link href="http://www.w3.org/TR/css3-regions/#the-flow-into-property" rel="help" /> + <link href="http://www.w3.org/TR/css3-regions/#flow-from" rel="help" /> + <link href="http://www.w3.org/TR/css-transforms-1/#two-d-transform-functions" rel="help" /> + <link href="http://www.w3.org/TR/css3-break/#transforms" rel="help" /> + <link href="reference/regions-transforms-008-ref.xht" rel="match" /> + <meta content="ahem" name="flags" /> + <meta content="This test checks that named flow text content is transformed when it breaks across + multiple regions and that the overflow remains visible." name="assert" /> + <style> + .ahem { + font-family: Ahem; + font-size: 10px; + line-height: 20px; + } + #named-flow { + color: green; + margin-left: -50px; + transform: translateX(50px); + flow-into: f; + } + .region { + width: 100px; + height: 100px; + margin-left: 10px; + float: left; + border: 1px solid black; + flow-from: f; + } + .failure { + position: absolute; + width: 102px; + height: 102px; + margin-top: 1px; + margin-left: 10px; + padding-left: 1px; + color: red; + z-index: -1; + } + .left { + left: 8px; + } + .right { + left: 120px; + } + </style> +</head> +<body> + <p>The test passes if:</p> + <ul> + <li>The two squares each contain five green horizontal stripes</li> + <li>There are two green horizontal stripes below the square on right</li> + <li>There is no red</li> + </ul> + <div class="ahem" id="named-flow">XXXXXXXXXXX XXXXXXXXXXX XXXXXXXXXXX XXXXXXXXXXX XXXXXXXXXXX XXXXXXXXXXX XXXXXXXXXXX XXXXXXXXXXX XXXXXXXXXXX XXXXXXXXXXX XXXXXXXXXXX XXXXXXXXXXX</div> + <div class="region"></div> + <div class="region"></div> + + <div class="ahem failure left"> + XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX + </div> + <div class="ahem failure right"> + XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX + </div> + + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1print/regions-transforms-009.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/regions-transforms-009.xht new file mode 100644 index 00000000000..f0d0c48658c --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/regions-transforms-009.xht @@ -0,0 +1,74 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <meta charset="UTF-8" /> + <title>CSS Regions: Transformed region with named flow (text) content that breaks across multiple regions and overflows</title> + <link href="mailto:rhauck@adobe.com" rel="author" title="Rebecca Hauck" /> + <link href="mailto:dalcala@adobe.com" rel="author" title="David Alcala" /> + <link href="mailto:mibalan@adobe.com" rel="reviewer" title="Mihai Balan" /> <!-- 2013-07-24 --> + <link href="http://www.w3.org/TR/css3-regions/#the-flow-into-property" rel="help" /> + <link href="http://www.w3.org/TR/css3-regions/#flow-from" rel="help" /> + <link href="http://www.w3.org/TR/css-transforms-1/#two-d-transform-functions" rel="help" /> + <link href="http://www.w3.org/TR/css3-break/#transforms" rel="help" /> + <link href="reference/regions-transforms-008-ref.xht" rel="match" /> + <meta content="ahem" name="flags" /> + <meta content="This test checks that the regions are transformed when named flow text content breaks + across multiple regions and that the overflow remains visible." name="assert" /> + <style> + .ahem { + font-family: Ahem; + font-size: 10px; + line-height: 20px; + } + #named-flow { + color: green; + flow-into: f; + } + .region { + width: 100px; + height: 100px; + float: left; + margin-left: 10px; + border: 1px solid black; + flow-from: f; + transform: translateX(50px); + } + .failure-left, + .failure-right { + position: absolute; + width: 102px; + height: 102px; + margin-top: 1px; + margin-left: 10px; + padding-left: 1px; + color: red; + z-index: -1; + } + .left { + margin-left: -40px; + } + .failure-left { + left: 8px; + } + .failure-right { + left: 120px; + } + </style> +</head> +<body> + <p>The test passes if:</p> + <ul> + <li>The two squares each contain five green horizontal stripes</li> + <li>There are two green horizontal stripes below the square on right</li> + <li>There is no red</li> + </ul> + <div class="ahem" id="named-flow">XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX</div> + <div class="region left"></div> + <div class="region"></div> + <div class="ahem failure-left"> + XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX + </div> + <div class="ahem failure-right"> + XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1print/regions-transforms-013.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/regions-transforms-013.xht new file mode 100644 index 00000000000..e711dec1af4 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/regions-transforms-013.xht @@ -0,0 +1,47 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <meta charset="UTF-8" /> + <title>CSS Regions: Transformed named flow (monolithic) content that breaks across multiple regions</title> + <link href="mailto:rhauck@adobe.com" rel="author" title="Rebecca Hauck" /> + <link href="mailto:dalcala@adobe.com" rel="author" title="David Alcala" /> + <link href="mailto:mibalan@adobe.com" rel="reviewer" title="Mihai Balan" /> <!-- 2013-07-24 --> + <link href="http://www.w3.org/TR/css3-regions/#the-flow-into-property" rel="help" /> + <link href="http://www.w3.org/TR/css3-regions/#flow-from" rel="help" /> + <link href="http://www.w3.org/TR/css-transforms-1/#two-d-transform-functions" rel="help" /> + <link href="http://www.w3.org/TR/css3-break/#transforms" rel="help" /> + <link href="http://www.w3.org/TR/css3-break/#breaking-rules" rel="help" /> + <link href="http://www.w3.org/TR/css3-break/#monolithic" rel="help" /> + <!-- This reference is for UAs that slice monolithic content --> + <link href="reference/regions-transforms-013-ref.xht" rel="match" /> + <!-- This reference is for UAs that overflow monolithic content --> + <link href="reference/regions-transforms-013-alt-ref.xht" rel="match" /> + <meta content="This test checks that the named flow content that is monolithic is transformed when it + breaks across multiple regions whether it is sliced or overflowed at the fragmentainer edge." name="assert" /> + <style> + #named-flow { + width: 100px; + height: 100px; + background-color: green; + transform: scaleY(2); + transform-origin: top left; + flow-into: f; + } + .region { + width: 100px; + height: 100px; + margin-left: 10px; + float: left; + flow-from: f; + } + #region1 { + background-color: red; + } + </style> +</head> +<body> + <p>The test passes if you see either two green squares or one vertical green rectangle. There should be no red.</p> + <div id="named-flow"></div> + <div class="region" id="region1"></div> + <div class="region"></div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1print/regions-transforms-020.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/regions-transforms-020.xht new file mode 100644 index 00000000000..e0866521167 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/regions-transforms-020.xht @@ -0,0 +1,61 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <meta charset="UTF-8" /> + <title>CSS Regions: Transformed region with named flow (fragmentable) content that breaks across multiple regions</title> + <link href="mailto:dalcala@adobe.com" rel="author" title="David Alcala" /> + <link href="mailto:rhauck@adobe.com" rel="author" title="Rebecca Hauck" /> + <link href="mailto:mibalan@adobe.com" rel="reviewer" title="Mihai Balan" /> <!-- 2013-07-24 --> + <link href="http://www.w3.org/TR/css3-regions/#the-flow-into-property" rel="help" /> + <link href="http://www.w3.org/TR/css3-regions/#flow-from" rel="help" /> + <link href="http://www.w3.org/TR/css-transforms-1/#two-d-transform-functions" rel="help" /> + <link href="http://www.w3.org/TR/css3-break/#transforms" rel="help" /> + <link href="http://www.w3.org/TR/css3-break/#breaking-rules" rel="help" /> + <link href="reference/regions-transforms-020-ref.xht" rel="match" /> + <meta content="This test checks that the named flow content that is fragmentable (has a break point) + is transformed when it breaks across multiple regions." name="assert" /> + <style> + #named-flow { + width: 100px; + height: 100px; + flow-into: f; + } + .src-child { + height: 50px; + background-color: green; + } + .region { + width: 100px; + height: 50px; + margin-left: 10px; + float: left; + background-color: red; + flow-from: f; + transform: scaleY(2); + transform-origin: top left; + } + + .failure-div { + position: absolute; + margin-left: 10px; + background-color: red; + width: 98px; + height: 98px; + } + .right { + left: 119px; + } + </style> +</head> +<body> + <p>The test passes if you see two green squares and no red.</p> + <div class="failure-div"></div> + <div class="failure-div right"></div> + <div id="named-flow"> + <div class="src-child"></div> + <div class="src-child"></div> + </div> + <div class="region"></div> + <div class="region"></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1print/regions-transforms-021.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/regions-transforms-021.xht new file mode 100644 index 00000000000..4e438ad285c --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/regions-transforms-021.xht @@ -0,0 +1,53 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <meta charset="UTF-8" /> + <title>CSS Regions: Transforms on multiple named flow (non-text) content nodes that break across multiple regions</title> + <link href="mailto:dalcala@adobe.com" rel="author" title="David Alcala" /> + <link href="mailto:rhauck@adobe.com" rel="author" title="Rebecca Hauck" /> + <link href="mailto:mibalan@adobe.com" rel="reviewer" title="Mihai Balan" /> <!-- 2013-07-24 --> + <link href="http://www.w3.org/TR/css3-regions/#the-flow-into-property" rel="help" /> + <link href="http://www.w3.org/TR/css3-regions/#flow-from" rel="help" /> + <link href="http://www.w3.org/TR/css-transforms-1/#two-d-transform-functions" rel="help" /> + <link href="http://www.w3.org/TR/css3-break/#transforms" rel="help" /> + <link href="reference/regions-transforms-020-ref.xht" rel="match" /> + <meta content="This test checks that separate transforms can be applied to each named flow content + node that breaks across multiple regions and that each fragment has its own transform origin." name="assert" /> + <style> + .named-flow { + float: left; + background-color: green; + flow-into: f; + } + #named-flow-1 { + margin-top: 25px; + margin-left: 25px; + width: 50px; + height: 50px; + transform: scale(2); + transform-origin: center center; + } + #named-flow-2 { + width: 100px; + height: 50px; + margin-top: 25px; + transform-origin: top left; + transform: scaleY(2); + } + .region { + width: 100px; + height: 100px; + margin-left: 10px; + float: left; + background-color: red; + flow-from: f; + } + </style> +</head> +<body> + <p>The test passes if you see two green squares and no red.</p> + <div id="named-flow-1" class="named-flow"></div> + <div id="named-flow-2" class="named-flow"></div> + <div class="region"></div> + <div class="region"></div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1print/regions-transforms-022.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/regions-transforms-022.xht new file mode 100644 index 00000000000..0836a17cd7d --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/regions-transforms-022.xht @@ -0,0 +1,83 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <meta charset="UTF-8" /> + <title>CSS Regions: Transforms on multiple named flow (text) content nodes that break across multiple regions</title> + <link href="mailto:dalcala@adobe.com" rel="author" title="David Alcala" /> + <link href="mailto:rhauck@adobe.com" rel="author" title="Rebecca Hauck" /> + <link href="mailto:mibalan@adobe.com" rel="reviewer" title="Mihai Balan" /> <!-- 2013-07-24 --> + <link href="http://www.w3.org/TR/css3-regions/#the-flow-into-property" rel="help" /> + <link href="http://www.w3.org/TR/css3-regions/#flow-from" rel="help" /> + <link href="http://www.w3.org/TR/css-transforms-1/#two-d-transform-functions" rel="help" /> + <link href="http://www.w3.org/TR/css3-break/#transforms" rel="help" /> + <link href="reference/regions-transforms-020-ref.xht" rel="match" /> + <meta content="ahem" name="flags" /> + <meta content="This test checks that separate transforms can be applied to each named flow content + text node that breaks across multiple regions" name="assert" /> + <style> + .ahem { + font-family: Ahem; + font-size: 10px; + line-height: 20px; + } + .named-flow { + width: 100px; + color: green; + flow-into: f; + } + #named-flow-1 { + margin-left: -50px; + transform: translateX(50px); + } + #named-flow-2 { + transform: rotate(90deg); + } + .region { + width: 100px; + height: 100px; + margin-left: 10px; + float: left; + flow-from: f; + } + .failure { + width: 100px; + height: 100px; + position: absolute; + float: left; + margin-left: 10px; + background-color: green; + z-index: -1; + } + .left { + color: red; + } + .right { + left: 118px; + } + .vertical-bar { + width: 10px; + height: 100px; + float: left; + background-color: red; + margin-left: 5px; + margin-right: 5px; + } + </style> +</head> +<body> + <p>The test passes if you see two green squares and no red.</p> + <div id="named-flow-1" class="ahem named-flow">XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX</div> + <div id="named-flow-2" class="ahem named-flow">XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX</div> + <div class="region"></div> + <div class="region"></div> + <div class="ahem failure left"> + XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX XXXXXXXXXX + </div> + <div class="ahem failure right"> + <div class="vertical-bar"></div> + <div class="vertical-bar"></div> + <div class="vertical-bar"></div> + <div class="vertical-bar"></div> + <div class="vertical-bar"></div> + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-break-3_dev/xhtml1print/toc.xht b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/toc.xht new file mode 100644 index 00000000000..e55c4a236d9 --- /dev/null +++ b/tests/wpt/css-tests/css-break-3_dev/xhtml1print/toc.xht @@ -0,0 +1,54 @@ + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>CSS Fragmentation Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> +<body> + <h1>CSS Fragmentation Module Level 3 CR Test Suite By Chapter</h1> + + <p>This index contains both + <a href="http://wiki.csswg.org/test/selftest">self-describing tests</a> + and reftests. + A separate <a href="reftest-toc.xht">alphabetical reftest index</a> + is provided for tests in <a href="http://wiki.csswg.org/test/reftest">reftest + format</a> along with the <a href="reftest.list">reftest manifest</a>.</p> + + <table> + <tbody id="s1"> + <tr><th><a href="chapter-1.xht">Chapter 1 - + Introduction</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s2"> + <tr><th><a href="chapter-2.xht">Chapter 2 - + Fragmentation Model and Terminology</a></th> + <td>(4 Tests)</td></tr> + </tbody> + <tbody id="s3"> + <tr><th><a href="chapter-3.xht">Chapter 3 - + Controlling Breaks</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s4"> + <tr><th><a href="chapter-4.xht">Chapter 4 - + Rules for Breaking</a></th> + <td>(2 Tests)</td></tr> + </tbody> + <tbody id="s5"> + <tr><th><a href="chapter-5.xht">Chapter 5 - + Box Model for Breaking</a></th> + <td>(9 Tests)</td></tr> + </tbody> + <tbody id="s6"> + <tr><th><a href="chapter-6.xht">Chapter 6 - + Conformance</a></th> + <td>(0 Tests)</td></tr> + </tbody> + </table> +</body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-counter-styles-3_dev/html/css3-counter-styles-016a.htm b/tests/wpt/css-tests/css-counter-styles-3_dev/html/css3-counter-styles-016a.htm index f3faaba9136..32c1a7d044e 100644 --- a/tests/wpt/css-tests/css-counter-styles-3_dev/html/css3-counter-styles-016a.htm +++ b/tests/wpt/css-tests/css-counter-styles-3_dev/html/css3-counter-styles-016a.htm @@ -19,8 +19,8 @@ ol { margin: 0; padding-left: 8em; } <div class="test"> <ol start="10999"> <li title="10999">ื™ืณืชืชืงืฆื˜</li> -<li title="12000">20000</li> -<li title="12โ‰ 001">20001</li> +<li title="11000">11000</li> +<li title="11001">11001</li> </ol> </div> <!--Notes: diff --git a/tests/wpt/css-tests/css-counter-styles-3_dev/implementation-report-TEMPLATE.data b/tests/wpt/css-tests/css-counter-styles-3_dev/implementation-report-TEMPLATE.data index fd15874bd60..44b4b2e1cc0 100644 --- a/tests/wpt/css-tests/css-counter-styles-3_dev/implementation-report-TEMPLATE.data +++ b/tests/wpt/css-tests/css-counter-styles-3_dev/implementation-report-TEMPLATE.data @@ -29,8 +29,8 @@ html/css3-counter-styles-015.htm b6bc6867cf7169b1d8485677a4c0ffc95a77c3e4 ? xhtml1/css3-counter-styles-015.xht b6bc6867cf7169b1d8485677a4c0ffc95a77c3e4 ? html/css3-counter-styles-016.htm 0ccf4b7900aed65308833f58f89afc03894473fc ? xhtml1/css3-counter-styles-016.xht 0ccf4b7900aed65308833f58f89afc03894473fc ? -html/css3-counter-styles-016a.htm ed5a23de0ef36a644e68a1ed79e69213c9130b07 ? -xhtml1/css3-counter-styles-016a.xht ed5a23de0ef36a644e68a1ed79e69213c9130b07 ? +html/css3-counter-styles-016a.htm bb952655e967e65c0e26acfc0d75c8aeb2a99fc8 ? +xhtml1/css3-counter-styles-016a.xht bb952655e967e65c0e26acfc0d75c8aeb2a99fc8 ? html/css3-counter-styles-017.htm e01cfb2d3f427bcdc0a2e9269e18eff990d19c6e ? xhtml1/css3-counter-styles-017.xht e01cfb2d3f427bcdc0a2e9269e18eff990d19c6e ? html/css3-counter-styles-019.htm 582953ae69a481a9ac1feb7486d127c48651e493 ? diff --git a/tests/wpt/css-tests/css-counter-styles-3_dev/testinfo.data b/tests/wpt/css-tests/css-counter-styles-3_dev/testinfo.data index 2ee7000df16..73411dd0114 100644 --- a/tests/wpt/css-tests/css-counter-styles-3_dev/testinfo.data +++ b/tests/wpt/css-tests/css-counter-styles-3_dev/testinfo.data @@ -12,7 +12,7 @@ css3-counter-styles-012 georgian, outside range font http://www.w3.org/TR/css-c css3-counter-styles-014 georgian, suffix font http://www.w3.org/TR/css-counter-styles-3/#simple-numeric 56493e8b51b0c213e17836aed9a8da0c3d11b6fb `Richard Ishida`<mailto:ishida@w3.org> list-style-type: georgian produces a suffix per the spec. css3-counter-styles-015 hebrew, 0-9 font http://www.w3.org/TR/css-counter-styles-3/#simple-numeric b6bc6867cf7169b1d8485677a4c0ffc95a77c3e4 `Richard Ishida`<mailto:ishida@w3.org> list-style: hebrew produces numbers up to 9 items per the spec. css3-counter-styles-016 hebrew, 10+ font http://www.w3.org/TR/css-counter-styles-3/#simple-numeric 0ccf4b7900aed65308833f58f89afc03894473fc `Richard Ishida`<mailto:ishida@w3.org> list-style: hebrew produces numbers after 9 items per the spec. -css3-counter-styles-016a hebrew, outside range font http://www.w3.org/TR/css-counter-styles-3/#simple-numeric ed5a23de0ef36a644e68a1ed79e69213c9130b07 `Richard Ishida`<mailto:ishida@w3.org> list-style-type: hebrew produces numbers in the fallback counter style above the limit per the spec. +css3-counter-styles-016a hebrew, outside range font http://www.w3.org/TR/css-counter-styles-3/#simple-numeric bb952655e967e65c0e26acfc0d75c8aeb2a99fc8 `Richard Ishida`<mailto:ishida@w3.org> list-style-type: hebrew produces numbers in the fallback counter style above the limit per the spec. css3-counter-styles-017 hebrew, suffix font http://www.w3.org/TR/css-counter-styles-3/#simple-numeric e01cfb2d3f427bcdc0a2e9269e18eff990d19c6e `Richard Ishida`<mailto:ishida@w3.org> list-style: hebrew produces a suffix per the spec. css3-counter-styles-019 lower-roman, 0-9 font http://www.w3.org/TR/css-counter-styles-3/#simple-numeric 582953ae69a481a9ac1feb7486d127c48651e493 `Richard Ishida`<mailto:ishida@w3.org> list-style: lower-roman produces numbers up to 9 items per the spec. css3-counter-styles-020 lower-roman, 10-3999 font http://www.w3.org/TR/css-counter-styles-3/#simple-numeric c71b7591f7f312dab252947136f47197624b90f8 `Richard Ishida`<mailto:ishida@w3.org> list-style: lower-roman produces numbers after 9 items per the spec. diff --git a/tests/wpt/css-tests/css-counter-styles-3_dev/xhtml1/css3-counter-styles-016a.xht b/tests/wpt/css-tests/css-counter-styles-3_dev/xhtml1/css3-counter-styles-016a.xht index 1928894d8ea..375410db0cc 100644 --- a/tests/wpt/css-tests/css-counter-styles-3_dev/xhtml1/css3-counter-styles-016a.xht +++ b/tests/wpt/css-tests/css-counter-styles-3_dev/xhtml1/css3-counter-styles-016a.xht @@ -19,8 +19,8 @@ ol { margin: 0; padding-left: 8em; } <div class="test"> <ol start="10999"> <li title="10999">ื™ืณืชืชืงืฆื˜</li> -<li title="12000">20000</li> -<li title="12โ‰ 001">20001</li> +<li title="11000">11000</li> +<li title="11001">11001</li> </ol> </div> <!--Notes: diff --git a/tests/wpt/css-tests/css-counter-styles-3_dev/xhtml1print/css3-counter-styles-016a.xht b/tests/wpt/css-tests/css-counter-styles-3_dev/xhtml1print/css3-counter-styles-016a.xht index 1928894d8ea..375410db0cc 100644 --- a/tests/wpt/css-tests/css-counter-styles-3_dev/xhtml1print/css3-counter-styles-016a.xht +++ b/tests/wpt/css-tests/css-counter-styles-3_dev/xhtml1print/css3-counter-styles-016a.xht @@ -19,8 +19,8 @@ ol { margin: 0; padding-left: 8em; } <div class="test"> <ol start="10999"> <li title="10999">ื™ืณืชืชืงืฆื˜</li> -<li title="12000">20000</li> -<li title="12โ‰ 001">20001</li> +<li title="11000">11000</li> +<li title="11001">11001</li> </ol> </div> <!--Notes: diff --git a/tests/wpt/css-tests/css-gcpm-3_dev/index.htm b/tests/wpt/css-tests/css-gcpm-3_dev/index.htm index 8b1b1b5d426..b1961254892 100644 --- a/tests/wpt/css-tests/css-gcpm-3_dev/index.htm +++ b/tests/wpt/css-tests/css-gcpm-3_dev/index.htm @@ -26,7 +26,7 @@ <p>Some tests in the test suite may contain errors. Please check the latest version of the - <a href="http://www.w3.org/TR/css-gcpm-3/">CSS Generated Content 3 specification</a> + <a href="http://www.w3.org/TR/css-gcpm-3/">CSS GCPM 3 specification</a> <strong>and its errata</strong> before assuming a failure is due to an implementation bug and not a test suite bug.</p> @@ -34,7 +34,7 @@ <p> In time we hope to correct all errors and extend this test suite to - cover all of CSS Generated Content 3. Your help is welcome in this effort. + cover all of CSS GCPM 3. Your help is welcome in this effort. The appropriate mailing list for submitting tests and bug reports is <a href="http://lists.w3.org/Archives/Public/public-css-testsuite/">public-css-testsuite@w3.org</a>. More information on the contribution process and test guidelines is diff --git a/tests/wpt/css-tests/css-gcpm-3_dev/index.xht b/tests/wpt/css-tests/css-gcpm-3_dev/index.xht index 8a8a7d7bafc..6eef37321f1 100644 --- a/tests/wpt/css-tests/css-gcpm-3_dev/index.xht +++ b/tests/wpt/css-tests/css-gcpm-3_dev/index.xht @@ -26,7 +26,7 @@ <p>Some tests in the test suite may contain errors. Please check the latest version of the - <a href="http://www.w3.org/TR/css-gcpm-3/">CSS Generated Content 3 specification</a> + <a href="http://www.w3.org/TR/css-gcpm-3/">CSS GCPM 3 specification</a> <strong>and its errata</strong> before assuming a failure is due to an implementation bug and not a test suite bug.</p> @@ -34,7 +34,7 @@ <p> In time we hope to correct all errors and extend this test suite to - cover all of CSS Generated Content 3. Your help is welcome in this effort. + cover all of CSS GCPM 3. Your help is welcome in this effort. The appropriate mailing list for submitting tests and bug reports is <a href="http://lists.w3.org/Archives/Public/public-css-testsuite/">public-css-testsuite@w3.org</a>. More information on the contribution process and test guidelines is diff --git a/tests/wpt/css-tests/css-namespaces-3_dev/html/chapter-1.htm b/tests/wpt/css-tests/css-namespaces-3_dev/html/chapter-1.htm new file mode 100644 index 00000000000..507c423f7a3 --- /dev/null +++ b/tests/wpt/css-tests/css-namespaces-3_dev/html/chapter-1.htm @@ -0,0 +1,39 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>Introduction - CSS Namespaces Module Level 3 Conformance Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Namespaces Module Level 3 Conformance Test Suite</h1> + <h2>Introduction (0 tests)</h2> + <table width="100%"> + <col id="test-column"> + <col id="refs-column"> + <col id="flags-column"> + <col id="info-column"> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s1">+</a> + <a href="http://www.w3.org/TR/css-namespaces-3/#intro">1 Introduction</a></th></tr> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-namespaces-3_dev/html/chapter-2.htm b/tests/wpt/css-tests/css-namespaces-3_dev/html/chapter-2.htm new file mode 100644 index 00000000000..b1107166230 --- /dev/null +++ b/tests/wpt/css-tests/css-namespaces-3_dev/html/chapter-2.htm @@ -0,0 +1,51 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>Conformance - CSS Namespaces Module Level 3 Conformance Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Namespaces Module Level 3 Conformance Test Suite</h1> + <h2>Conformance (0 tests)</h2> + <table width="100%"> + <col id="test-column"> + <col id="refs-column"> + <col id="flags-column"> + <col id="info-column"> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2">+</a> + <a href="http://www.w3.org/TR/css-namespaces-3/#conformance">2 Conformance</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s2.#interpreter"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.#style-sheet"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.1">+</a> + <a href="http://www.w3.org/TR/css-namespaces-3/#terminology">2.1 Terminology</a></th></tr> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-namespaces-3_dev/html/chapter-3.htm b/tests/wpt/css-tests/css-namespaces-3_dev/html/chapter-3.htm new file mode 100644 index 00000000000..7d844b6360e --- /dev/null +++ b/tests/wpt/css-tests/css-namespaces-3_dev/html/chapter-3.htm @@ -0,0 +1,66 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>Declaring namespaces: the @namespace rule - CSS Namespaces Module Level 3 Conformance Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Namespaces Module Level 3 Conformance Test Suite</h1> + <h2>Declaring namespaces: the @namespace rule (0 tests)</h2> + <table width="100%"> + <col id="test-column"> + <col id="refs-column"> + <col id="flags-column"> + <col id="info-column"> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3">+</a> + <a href="http://www.w3.org/TR/css-namespaces-3/#declaration">3 Declaring namespaces: the @namespace rule</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#expanded-name"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.1">+</a> + <a href="http://www.w3.org/TR/css-namespaces-3/#syntax">3.1 Syntax</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.2">+</a> + <a href="http://www.w3.org/TR/css-namespaces-3/#scope">3.2 Scope</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.3">+</a> + <a href="http://www.w3.org/TR/css-namespaces-3/#prefixes">3.3 Declaring Prefixes</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.3.#default-namespace"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.3.#namespace-prefix"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-namespaces-3_dev/html/chapter-4.htm b/tests/wpt/css-tests/css-namespaces-3_dev/html/chapter-4.htm new file mode 100644 index 00000000000..4b4adfc68e9 --- /dev/null +++ b/tests/wpt/css-tests/css-namespaces-3_dev/html/chapter-4.htm @@ -0,0 +1,90 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>CSS Qualified Names - CSS Namespaces Module Level 3 Conformance Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Namespaces Module Level 3 Conformance Test Suite</h1> + <h2>CSS Qualified Names (0 tests)</h2> + <table width="100%"> + <col id="test-column"> + <col id="refs-column"> + <col id="flags-column"> + <col id="info-column"> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s4"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4">+</a> + <a href="http://www.w3.org/TR/css-namespaces-3/#css-qnames">4 CSS Qualified Names</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s4.#css-qualified-name"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#abstract"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#acks"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#changes"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#contents"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#css21"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#index"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#informative"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#normative"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#property-index"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#references"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#rfc2119"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#select"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#status"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#subtitle"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#title"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#xml-names"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-namespaces-3_dev/html/reftest-toc.htm b/tests/wpt/css-tests/css-namespaces-3_dev/html/reftest-toc.htm new file mode 100644 index 00000000000..d28e3645d76 --- /dev/null +++ b/tests/wpt/css-tests/css-namespaces-3_dev/html/reftest-toc.htm @@ -0,0 +1,30 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>CSS Namespaces Module Level 3 Conformance Test Suite Reftest Index</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Namespaces Module Level 3 Conformance Test Suite Reftest Index</h1> + <table width="100%"> + <col id="test-column"> + <col id="ref-column"> + <col id="flags-column"> + <thead> + <tr> + <th>Test</th> + <th>Reference</th> + <th>Flags</th> + </tr> + </thead> + </table> + + </body> +</html> diff --git a/tests/wpt/css-tests/css-namespaces-3_dev/html/reftest.list b/tests/wpt/css-tests/css-namespaces-3_dev/html/reftest.list new file mode 100644 index 00000000000..8b137891791 --- /dev/null +++ b/tests/wpt/css-tests/css-namespaces-3_dev/html/reftest.list @@ -0,0 +1 @@ + diff --git a/tests/wpt/css-tests/css-namespaces-3_dev/html/toc.htm b/tests/wpt/css-tests/css-namespaces-3_dev/html/toc.htm new file mode 100644 index 00000000000..abe36b803ff --- /dev/null +++ b/tests/wpt/css-tests/css-namespaces-3_dev/html/toc.htm @@ -0,0 +1,44 @@ + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>CSS Namespaces Module Level 3 Conformance Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> +<body> + <h1>CSS Namespaces Module Level 3 Conformance Test Suite By Chapter</h1> + + <p>This index contains both + <a href="http://wiki.csswg.org/test/selftest">self-describing tests</a> + and reftests. + A separate <a href="reftest-toc.htm">alphabetical reftest index</a> + is provided for tests in <a href="http://wiki.csswg.org/test/reftest">reftest + format</a> along with the <a href="reftest.list">reftest manifest</a>.</p> + + <table> + <tbody id="s1"> + <tr><th><a href="chapter-1.htm">Chapter 1 - + Introduction</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s2"> + <tr><th><a href="chapter-2.htm">Chapter 2 - + Conformance</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s3"> + <tr><th><a href="chapter-3.htm">Chapter 3 - + Declaring namespaces: the @namespace rule</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s4"> + <tr><th><a href="chapter-4.htm">Chapter 4 - + CSS Qualified Names</a></th> + <td>(0 Tests)</td></tr> + </tbody> + </table> +</body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-namespaces-3_dev/implementation-report-TEMPLATE.data b/tests/wpt/css-tests/css-namespaces-3_dev/implementation-report-TEMPLATE.data new file mode 100644 index 00000000000..3f3cd8f5fdb --- /dev/null +++ b/tests/wpt/css-tests/css-namespaces-3_dev/implementation-report-TEMPLATE.data @@ -0,0 +1,5 @@ +# UA version OS version +# UA string (if applicable) +# http://test.csswg.org/suites/css-namespaces-3_dev/DATESTAMP/ +# See http://wiki.csswg.org/test/implementation-report for instructions +testname revision result comment diff --git a/tests/wpt/css-tests/css-namespaces-3_dev/index.htm b/tests/wpt/css-tests/css-namespaces-3_dev/index.htm new file mode 100644 index 00000000000..686577122dc --- /dev/null +++ b/tests/wpt/css-tests/css-namespaces-3_dev/index.htm @@ -0,0 +1,130 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html lang="en"> + <head> + <title>CSS Namespaces Module Level 3 Conformance Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "indices.css"; + </style> + </head> + <body> + + + <h1>CSS Namespaces Module Level 3 Conformance Test Suite</h1> + <dt>Test Coordinator:</dt> + <dd>None Yet</dd> + + <p>This is a <strong>Development</strong> + version of the CSS Namespaces Module Level 3 Conformance Test Suite.</p> + + <p>You can provide test data or review the testing results for this test suite:</p> + <dt><a href="http://test.csswg.org/harness/suite/css-namespaces-3_dev">Enter Data</a></dt> + <dt><a href="http://test.csswg.org/harness/review/css-namespaces-3_dev">Review Results</a></dt> + + + <p>Some tests in the test suite may contain errors. + Please check the latest version of the + <a href="http://www.w3.org/TR/css-namespaces-3/">CSS Namespaces 3 specification</a> + <strong>and its errata</strong> + before assuming a failure is due to an implementation bug and + not a test suite bug.</p> + + + <p> + In time we hope to correct all errors and extend this test suite to + cover all of CSS Namespaces 3. Your help is welcome in this effort. + The appropriate mailing list for submitting tests and bug reports is + <a href="http://lists.w3.org/Archives/Public/public-css-testsuite/">public-css-testsuite@w3.org</a>. + More information on the contribution process and test guidelines is + available on the <a href="http://wiki.csswg.org/test">wiki + page</a>.</p> + + <p>Tests are currently available in these formats:</p> + + <dl> + <dt><a href="html/toc.htm">HTML 5</a></dt> + <dd>HTML 5 tests sent as <code>text/html</code></dd> + <dt><a href="xhtml1/toc.xht">XHTML 1.1</a></dt> + <dd>XHTML 1.1 tests sent as <code>application/xhtml+xml</code></dd> + + + <p>Unless the test instructions explicitly indicate otherwise, + any occurrence of red in a test indicates test failure.</p> + +<h2 id="implement">Implementation Reports</h2> + <p>An <a href="implementation-report-TEMPLATE.data">implementation report template</a> + is available to help with creating implementation reports. See also the + <a href="http://lists.w3.org/Archives/Public/public-css-testsuite/2010Aug/0020.html">explanation</a> + of its format.</p> + +<h2 id="common">Common Assumptions</h2> + + <p>Most of the test suite makes the following assumptions:</p> + <ul> + <li>The X/HTML <code>div</code> element is assigned <code>display: block;</code> + and no other property declaration.</li> + <li>The X/HTML <code>span</code> element is assigned <code>display: inline;</code> + and no other property declaration.</li> + <li>The X/HTML <code>p</code> element is assigned <code>display: block;</code></li> + <li>The X/HTML <code>li</code> element is assigned <code>display: list-item;</code></li> + <li>The X/HTML table elements <code>table</code>, <code>tbody</code>, + <code>tr</code>, and <code>td</code> are assigned the <code>display</code> + values <code>table</code>, <code>table-row-group</code>, + <code>table-row</code>, and <code>table-cell</code>, respectively.</li> + <li>The device can display the sixteen color values associated with the color + keywords <code>black</code>, <code>white</code>, <code>gray</code>, + <code>silver</code>, <code>red</code>, <code>green</code>, <code>blue</code>, + <code>purple</code>, <code>yellow</code>, <code>orange</code>, <code>teal</code>, + <code>fuchsia</code>, <code>maroon</code>, <code>navy</code>, <code>aqua</code>, + and <code>lime</code> as distinct colors.</li> + <li>The UA is set to print background colors and, if it supports graphics, + background images.</li> + <li>The UA implements reasonable page-breaking behavior; e.g., it is assumed + that UAs will not break at every opportunity, but only near the end of + a page unless a page break is forced.</li> + <li>The UA implements reasonable line-breaking behavior; e.g., it is assumed + that spaces between alphanumeric characters provide line breaking + opportunities and that UAs will not break at every opportunity, but only + near the end of a line unless a line break is forced.</li> + </ul> + +<h2 id="uncommon">Uncommon Assumptions</h2> + + <p>In addition, some of the tests make one or more of the following + assumptions:</p> + + <ul> + <li>The device is a full-color device.</li> + <li>The device has a viewport width of at least 640px (approx).</li> + <li>The resolution of the device is 96 CSS pixels per inch.</li> + <li>The UA imposes no minimum font size.</li> + <li>The 'medium' font-size computes to 16px.</li> + <li>The initial value of 'color' is black.</li> + <li>The canvas background is white.</li> + <li>The user stylesheet is empty (except where indicated by the tests).</li> + <li>The device is interactive and uses scroll bars.</li> + </ul> + + <p>The tests that need these assumptions to be true have not yet been + marked, but it is likely that we will add a way to identify these + tests in due course. Tests should avoid relying on these assumptions + unless necessary.</p> + +<h2>License</h2> + + <p>This test suite is licensed under both the + <a href="http://www.w3.org/Consortium/Legal/2008/04-testsuite-license">W3C + Test Suite License</a> and the <a href="http://www.w3.org/Consortium/Legal/2008/03-bsd-license">W3C + 3-clause BSD License</a>. See W3C Legal's <a href="http://www.w3.org/Consortium/Legal/2008/04-testsuite-copyright">explanation + of the licenses</a>.</p> + +<h2>Acknowledgements</h2> + + <p>Many thanks to the following for their contributions:</p> + <ul> + </ul> + +</body> +</html> diff --git a/tests/wpt/css-tests/css-namespaces-3_dev/index.xht b/tests/wpt/css-tests/css-namespaces-3_dev/index.xht new file mode 100644 index 00000000000..8204902887a --- /dev/null +++ b/tests/wpt/css-tests/css-namespaces-3_dev/index.xht @@ -0,0 +1,130 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> + <head> + <title>CSS Namespaces Module Level 3 Conformance Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "indices.css"; + </style> + </head> + <body> + + + <h1>CSS Namespaces Module Level 3 Conformance Test Suite</h1> + <dt>Test Coordinator:</dt> + <dd>None Yet</dd> + + <p>This is a <strong>Development</strong> + version of the CSS Namespaces Module Level 3 Conformance Test Suite.</p> + + <p>You can provide test data or review the testing results for this test suite:</p> + <dt><a href="http://test.csswg.org/harness/suite/css-namespaces-3_dev">Enter Data</a></dt> + <dt><a href="http://test.csswg.org/harness/review/css-namespaces-3_dev">Review Results</a></dt> + + + <p>Some tests in the test suite may contain errors. + Please check the latest version of the + <a href="http://www.w3.org/TR/css-namespaces-3/">CSS Namespaces 3 specification</a> + <strong>and its errata</strong> + before assuming a failure is due to an implementation bug and + not a test suite bug.</p> + + + <p> + In time we hope to correct all errors and extend this test suite to + cover all of CSS Namespaces 3. Your help is welcome in this effort. + The appropriate mailing list for submitting tests and bug reports is + <a href="http://lists.w3.org/Archives/Public/public-css-testsuite/">public-css-testsuite@w3.org</a>. + More information on the contribution process and test guidelines is + available on the <a href="http://wiki.csswg.org/test">wiki + page</a>.</p> + + <p>Tests are currently available in these formats:</p> + + <dl> + <dt><a href="html/toc.htm">HTML 5</a></dt> + <dd>HTML 5 tests sent as <code>text/html</code></dd> + <dt><a href="xhtml1/toc.xht">XHTML 1.1</a></dt> + <dd>XHTML 1.1 tests sent as <code>application/xhtml+xml</code></dd> + + + <p>Unless the test instructions explicitly indicate otherwise, + any occurrence of red in a test indicates test failure.</p> + +<h2 id="implement">Implementation Reports</h2> + <p>An <a href="implementation-report-TEMPLATE.data">implementation report template</a> + is available to help with creating implementation reports. See also the + <a href="http://lists.w3.org/Archives/Public/public-css-testsuite/2010Aug/0020.html">explanation</a> + of its format.</p> + +<h2 id="common">Common Assumptions</h2> + + <p>Most of the test suite makes the following assumptions:</p> + <ul> + <li>The X/HTML <code>div</code> element is assigned <code>display: block;</code> + and no other property declaration.</li> + <li>The X/HTML <code>span</code> element is assigned <code>display: inline;</code> + and no other property declaration.</li> + <li>The X/HTML <code>p</code> element is assigned <code>display: block;</code></li> + <li>The X/HTML <code>li</code> element is assigned <code>display: list-item;</code></li> + <li>The X/HTML table elements <code>table</code>, <code>tbody</code>, + <code>tr</code>, and <code>td</code> are assigned the <code>display</code> + values <code>table</code>, <code>table-row-group</code>, + <code>table-row</code>, and <code>table-cell</code>, respectively.</li> + <li>The device can display the sixteen color values associated with the color + keywords <code>black</code>, <code>white</code>, <code>gray</code>, + <code>silver</code>, <code>red</code>, <code>green</code>, <code>blue</code>, + <code>purple</code>, <code>yellow</code>, <code>orange</code>, <code>teal</code>, + <code>fuchsia</code>, <code>maroon</code>, <code>navy</code>, <code>aqua</code>, + and <code>lime</code> as distinct colors.</li> + <li>The UA is set to print background colors and, if it supports graphics, + background images.</li> + <li>The UA implements reasonable page-breaking behavior; e.g., it is assumed + that UAs will not break at every opportunity, but only near the end of + a page unless a page break is forced.</li> + <li>The UA implements reasonable line-breaking behavior; e.g., it is assumed + that spaces between alphanumeric characters provide line breaking + opportunities and that UAs will not break at every opportunity, but only + near the end of a line unless a line break is forced.</li> + </ul> + +<h2 id="uncommon">Uncommon Assumptions</h2> + + <p>In addition, some of the tests make one or more of the following + assumptions:</p> + + <ul> + <li>The device is a full-color device.</li> + <li>The device has a viewport width of at least 640px (approx).</li> + <li>The resolution of the device is 96 CSS pixels per inch.</li> + <li>The UA imposes no minimum font size.</li> + <li>The 'medium' font-size computes to 16px.</li> + <li>The initial value of 'color' is black.</li> + <li>The canvas background is white.</li> + <li>The user stylesheet is empty (except where indicated by the tests).</li> + <li>The device is interactive and uses scroll bars.</li> + </ul> + + <p>The tests that need these assumptions to be true have not yet been + marked, but it is likely that we will add a way to identify these + tests in due course. Tests should avoid relying on these assumptions + unless necessary.</p> + +<h2>License</h2> + + <p>This test suite is licensed under both the + <a href="http://www.w3.org/Consortium/Legal/2008/04-testsuite-license">W3C + Test Suite License</a> and the <a href="http://www.w3.org/Consortium/Legal/2008/03-bsd-license">W3C + 3-clause BSD License</a>. See W3C Legal's <a href="http://www.w3.org/Consortium/Legal/2008/04-testsuite-copyright">explanation + of the licenses</a>.</p> + +<h2>Acknowledgements</h2> + + <p>Many thanks to the following for their contributions:</p> + <ul> + </ul> + +</body> +</html> diff --git a/tests/wpt/css-tests/css-namespaces-3_dev/indices.css b/tests/wpt/css-tests/css-namespaces-3_dev/indices.css new file mode 100644 index 00000000000..7bc70eeef94 --- /dev/null +++ b/tests/wpt/css-tests/css-namespaces-3_dev/indices.css @@ -0,0 +1,96 @@ +/* CSS for CSS Conformance Test Indices */ +/* Written by fantasai */ + +/* Test Tables */ + + table { + border-collapse: collapse; + } + + thead { + border-bottom: 0.2em solid; + } + + tbody { + border: thin solid; + border-style: solid none; + } + + tbody.ch { + border-top: 0.2em solid; + } + tbody.ch th { + font-weight: bold; + } + + tbody th { + border-bottom: silver dotted thin; + background: #EEE; + color: black; + font-weight: normal; + font-style: italic; + } + tbody th :link { + color: gray; + background: transparent; + } + tbody th :visited { + color: #333; + background: transparent; + } + + th, td { + padding: 0.2em; + text-align: left; + vertical-align: baseline; + } + + td { + font-size: 0.9em; + } + + /* flags */ + td abbr { + border: solid thin gray; + padding: 0 0.1em; + cursor: help; + } + td abbr:hover { + background: #ffa; + color: black; + } + + + tr:hover { + background: #F9F9F9; + color: navy; + } + + th a, + td a { + text-decoration: none; + } + th a:hover, + td a:hover, + th a:focus, + td a:focus { + text-decoration: underline; + } + + td a { + display: block; + padding-left: 2em; + text-indent: -1em; + } + .refs { + font-weight: bold; + font-size: larger; + } + .assert, .assert > li { + list-style-type: none; + font-style: italic; + color: gray; + margin: 0; + padding: 0; + text-indent: 0; + } diff --git a/tests/wpt/css-tests/css-namespaces-3_dev/testinfo.data b/tests/wpt/css-tests/css-namespaces-3_dev/testinfo.data new file mode 100644 index 00000000000..92ee8bf29d7 --- /dev/null +++ b/tests/wpt/css-tests/css-namespaces-3_dev/testinfo.data @@ -0,0 +1 @@ +id references title flags links revision credits assertion diff --git a/tests/wpt/css-tests/css-namespaces-3_dev/xhtml1/chapter-1.xht b/tests/wpt/css-tests/css-namespaces-3_dev/xhtml1/chapter-1.xht new file mode 100644 index 00000000000..c3a5752d6d0 --- /dev/null +++ b/tests/wpt/css-tests/css-namespaces-3_dev/xhtml1/chapter-1.xht @@ -0,0 +1,39 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Introduction - CSS Namespaces Module Level 3 Conformance Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Namespaces Module Level 3 Conformance Test Suite</h1> + <h2>Introduction (0 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s1">+</a> + <a href="http://www.w3.org/TR/css-namespaces-3/#intro">1 Introduction</a></th></tr> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-namespaces-3_dev/xhtml1/chapter-2.xht b/tests/wpt/css-tests/css-namespaces-3_dev/xhtml1/chapter-2.xht new file mode 100644 index 00000000000..2287e7980c2 --- /dev/null +++ b/tests/wpt/css-tests/css-namespaces-3_dev/xhtml1/chapter-2.xht @@ -0,0 +1,51 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Conformance - CSS Namespaces Module Level 3 Conformance Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Namespaces Module Level 3 Conformance Test Suite</h1> + <h2>Conformance (0 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2">+</a> + <a href="http://www.w3.org/TR/css-namespaces-3/#conformance">2 Conformance</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s2.#interpreter"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.#style-sheet"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.1">+</a> + <a href="http://www.w3.org/TR/css-namespaces-3/#terminology">2.1 Terminology</a></th></tr> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-namespaces-3_dev/xhtml1/chapter-3.xht b/tests/wpt/css-tests/css-namespaces-3_dev/xhtml1/chapter-3.xht new file mode 100644 index 00000000000..d6cd1a0202e --- /dev/null +++ b/tests/wpt/css-tests/css-namespaces-3_dev/xhtml1/chapter-3.xht @@ -0,0 +1,66 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Declaring namespaces: the @namespace rule - CSS Namespaces Module Level 3 Conformance Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Namespaces Module Level 3 Conformance Test Suite</h1> + <h2>Declaring namespaces: the @namespace rule (0 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3">+</a> + <a href="http://www.w3.org/TR/css-namespaces-3/#declaration">3 Declaring namespaces: the @namespace rule</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#expanded-name"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.1">+</a> + <a href="http://www.w3.org/TR/css-namespaces-3/#syntax">3.1 Syntax</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.2">+</a> + <a href="http://www.w3.org/TR/css-namespaces-3/#scope">3.2 Scope</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.3">+</a> + <a href="http://www.w3.org/TR/css-namespaces-3/#prefixes">3.3 Declaring Prefixes</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.3.#default-namespace"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.3.#namespace-prefix"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-namespaces-3_dev/xhtml1/chapter-4.xht b/tests/wpt/css-tests/css-namespaces-3_dev/xhtml1/chapter-4.xht new file mode 100644 index 00000000000..97f7d2b6232 --- /dev/null +++ b/tests/wpt/css-tests/css-namespaces-3_dev/xhtml1/chapter-4.xht @@ -0,0 +1,90 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>CSS Qualified Names - CSS Namespaces Module Level 3 Conformance Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Namespaces Module Level 3 Conformance Test Suite</h1> + <h2>CSS Qualified Names (0 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s4"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4">+</a> + <a href="http://www.w3.org/TR/css-namespaces-3/#css-qnames">4 CSS Qualified Names</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s4.#css-qualified-name"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#abstract"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#acks"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#changes"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#contents"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#css21"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#index"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#informative"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#normative"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#property-index"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#references"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#rfc2119"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#select"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#status"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#subtitle"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#title"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#xml-names"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-namespaces-3_dev/xhtml1/reftest-toc.xht b/tests/wpt/css-tests/css-namespaces-3_dev/xhtml1/reftest-toc.xht new file mode 100644 index 00000000000..553905b6098 --- /dev/null +++ b/tests/wpt/css-tests/css-namespaces-3_dev/xhtml1/reftest-toc.xht @@ -0,0 +1,30 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>CSS Namespaces Module Level 3 Conformance Test Suite Reftest Index</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Namespaces Module Level 3 Conformance Test Suite Reftest Index</h1> + <table width="100%"> + <col id="test-column"></col> + <col id="ref-column"></col> + <col id="flags-column"></col> + <thead> + <tr> + <th>Test</th> + <th>Reference</th> + <th>Flags</th> + </tr> + </thead> + </table> + + </body> +</html> diff --git a/tests/wpt/css-tests/css-namespaces-3_dev/xhtml1/reftest.list b/tests/wpt/css-tests/css-namespaces-3_dev/xhtml1/reftest.list new file mode 100644 index 00000000000..8b137891791 --- /dev/null +++ b/tests/wpt/css-tests/css-namespaces-3_dev/xhtml1/reftest.list @@ -0,0 +1 @@ + diff --git a/tests/wpt/css-tests/css-namespaces-3_dev/xhtml1/toc.xht b/tests/wpt/css-tests/css-namespaces-3_dev/xhtml1/toc.xht new file mode 100644 index 00000000000..78afb9d2aa4 --- /dev/null +++ b/tests/wpt/css-tests/css-namespaces-3_dev/xhtml1/toc.xht @@ -0,0 +1,44 @@ + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>CSS Namespaces Module Level 3 Conformance Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> +<body> + <h1>CSS Namespaces Module Level 3 Conformance Test Suite By Chapter</h1> + + <p>This index contains both + <a href="http://wiki.csswg.org/test/selftest">self-describing tests</a> + and reftests. + A separate <a href="reftest-toc.xht">alphabetical reftest index</a> + is provided for tests in <a href="http://wiki.csswg.org/test/reftest">reftest + format</a> along with the <a href="reftest.list">reftest manifest</a>.</p> + + <table> + <tbody id="s1"> + <tr><th><a href="chapter-1.xht">Chapter 1 - + Introduction</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s2"> + <tr><th><a href="chapter-2.xht">Chapter 2 - + Conformance</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s3"> + <tr><th><a href="chapter-3.xht">Chapter 3 - + Declaring namespaces: the @namespace rule</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s4"> + <tr><th><a href="chapter-4.xht">Chapter 4 - + CSS Qualified Names</a></th> + <td>(0 Tests)</td></tr> + </tbody> + </table> +</body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/html/chapter-1.htm b/tests/wpt/css-tests/css-pseudo-4_dev/html/chapter-1.htm new file mode 100644 index 00000000000..a4085e2d4eb --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/html/chapter-1.htm @@ -0,0 +1,39 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>Introduction - CSS Pseudo-Elements Module Level 4 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Pseudo-Elements Module Level 4 Test Suite</h1> + <h2>Introduction (0 tests)</h2> + <table width="100%"> + <col id="test-column"> + <col id="refs-column"> + <col id="flags-column"> + <col id="info-column"> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s1">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#intro">1 Introduction</a></th></tr> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/html/chapter-2.htm b/tests/wpt/css-tests/css-pseudo-4_dev/html/chapter-2.htm new file mode 100644 index 00000000000..c99393f3a43 --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/html/chapter-2.htm @@ -0,0 +1,126 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>Typographic Pseudo-elements - CSS Pseudo-Elements Module Level 4 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Pseudo-Elements Module Level 4 Test Suite</h1> + <h2>Typographic Pseudo-elements (3 tests)</h2> + <table width="100%"> + <col id="test-column"> + <col id="refs-column"> + <col id="flags-column"> + <col id="info-column"> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#typographic-pseudos">2 Typographic Pseudo-elements</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s2.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.1">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#first-line-pseudo">2.1 The ::first-line pseudo-element</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s2.1.#fictional-tag-sequence"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.1.#selectordef-first-line"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.1.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.1.1">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#first-text-line">2.1.1 Finding the First Formatted Line</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s2.1.1.#first-formatted-line"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.1.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.1.2">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#first-line-styling">2.1.2 Styling the First Line Pseudo-element</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s2.1.3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.1.3">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#first-line-inheritance">2.1.3 Inheritance and the ::first-line Pseudo-element</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s2.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.2">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#first-letter-pseudo">2.2 The ::first-letter pseudo-element</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s2.2.#issue-703eb1d7"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.2.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.2.1">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#application-in-css">2.2.1 Finding the First Letter</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s2.2.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.2.2">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#first-letter-styling">2.2.2 Styling the ::first-letter Pseudo-element</a></th></tr> + <!-- 3 tests --> + <tr id="first-letter-001-2.2.2" class="primary"> + <td><strong> + <a href="first-letter-001.htm">first-letter-001</a></strong></td> + <td><a href="reference/first-letter-001-ref.htm">=</a> </td> + <td></td> + <td>::first-letter formatting + <ul class="assert"> + <li>Test checks that a floated ::first-letter follows the usual formating rules for floats.</li> + </ul> + </td> + </tr> + <tr id="first-letter-002-2.2.2" class="primary"> + <td><strong> + <a href="first-letter-002.htm">first-letter-002</a></strong></td> + <td><a href="reference/first-letter-001-ref.htm">=</a> </td> + <td></td> + <td>::first-letter formatting + <ul class="assert"> + <li>Test checks that a floated ::first-letter is formatted identically to a floated non-pseudo element with the same content.</li> + </ul> + </td> + </tr> + <tr id="first-letter-003-2.2.2" class="primary"> + <td><strong> + <a href="first-letter-003.htm">first-letter-003</a></strong></td> + <td><a href="reference/first-letter-001-ref.htm">=</a> </td> + <td></td> + <td>::first-letter formatting + <ul class="assert"> + <li>Test checks that a floated ::first-letter is formatted identically to a floated non-pseudo element with the same content.</li> + </ul> + </td> + </tr> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/html/chapter-3.htm b/tests/wpt/css-tests/css-pseudo-4_dev/html/chapter-3.htm new file mode 100644 index 00000000000..e82a5c3f294 --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/html/chapter-3.htm @@ -0,0 +1,111 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>Highlight Pseudo-elements - CSS Pseudo-Elements Module Level 4 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Pseudo-Elements Module Level 4 Test Suite</h1> + <h2>Highlight Pseudo-elements (0 tests)</h2> + <table width="100%"> + <col id="test-column"> + <col id="refs-column"> + <col id="flags-column"> + <col id="info-column"> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#highlight-pseudos">3 Highlight Pseudo-elements</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.1">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#highlight-selectors">3.1 Selecting Highlighted Content: the ::selection, ::spelling-error, and ::grammar-error pseudo-elements</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#highlight-pseudo-elements"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#issue-43364a12"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#selectordef-grammar-error"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#selectordef-selection"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#selectordef-spelling-error"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.2">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#highlight-styling">3.2 Styling Highlights</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.2.#issue-7be57116"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.3">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#highlight-bounds">3.3 Area of a Highlight</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.3.#issue-271a1b90"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.3.#issue-b6466947"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.3.#root-highlight-overlay"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.4"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.4">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#highlight-cascade">3.4 Cascading and Per-Element Highlight Styles</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.4.#issue-d1a9f919"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.5"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.5">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#highlight-painting">3.5 Painting the Highlight</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.5.#issue-8f96bd90"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.5.#issue-a5c22c51"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.6"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.6">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#highlight-security">3.6 Security Considerations</a></th></tr> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/html/chapter-4.htm b/tests/wpt/css-tests/css-pseudo-4_dev/html/chapter-4.htm new file mode 100644 index 00000000000..f2a9c37ff9c --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/html/chapter-4.htm @@ -0,0 +1,66 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>Tree-Abiding Pseudo-elements - CSS Pseudo-Elements Module Level 4 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Pseudo-Elements Module Level 4 Test Suite</h1> + <h2>Tree-Abiding Pseudo-elements (0 tests)</h2> + <table width="100%"> + <col id="test-column"> + <col id="refs-column"> + <col id="flags-column"> + <col id="info-column"> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s4"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#treelike">4 Tree-Abiding Pseudo-elements</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s4.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4.1">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#generated-content">4.1 Generated Content Pseudo-elements: ::before and ::after</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s4.1.#selectordef-after"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.1.#selectordef-before"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4.2">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#placeholder-pseudo">4.2 Placeholder Input: the ::placeholder pseudo-element</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s4.2.#issue-44dd3703"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.2.#issue-68e6c4d7"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.2.#selectordef-placeholder"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/html/chapter-5.htm b/tests/wpt/css-tests/css-pseudo-4_dev/html/chapter-5.htm new file mode 100644 index 00000000000..60d54349899 --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/html/chapter-5.htm @@ -0,0 +1,42 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>Overlapping Pseudo-element Interactions - CSS Pseudo-Elements Module Level 4 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Pseudo-Elements Module Level 4 Test Suite</h1> + <h2>Overlapping Pseudo-element Interactions (0 tests)</h2> + <table width="100%"> + <col id="test-column"> + <col id="refs-column"> + <col id="flags-column"> + <col id="info-column"> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s5"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s5">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#interactions">5 Overlapping Pseudo-element Interactions</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#overlapping-example"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/html/chapter-6.htm b/tests/wpt/css-tests/css-pseudo-4_dev/html/chapter-6.htm new file mode 100644 index 00000000000..4a7f790da7f --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/html/chapter-6.htm @@ -0,0 +1,222 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>Additions to the CSS Object Model - CSS Pseudo-Elements Module Level 4 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Pseudo-Elements Module Level 4 Test Suite</h1> + <h2>Additions to the CSS Object Model (0 tests)</h2> + <table width="100%"> + <col id="test-column"> + <col id="refs-column"> + <col id="flags-column"> + <col id="info-column"> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s6"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#cssom">6 Additions to the CSS Object Model</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s6.#issue-116a9e33"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6.1">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#CSSPseudoElement-interface">6.1 Interface CSSPseudoElement</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#csspseudoelement"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#dom-csspseudochild-style"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#dom-csspseudochild-type"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#dom-csspseudoelement-style"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#dom-csspseudoelement-type"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#issue-65c50c19"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#issue-b008e095"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6.2">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#CSSPseudoElementList-interface">6.2 Interface CSSPseudoElementList</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2.#csspseudoelementlist"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2.#dom-csspseudochildlist-getbytype"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2.#dom-csspseudochildlist-item"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2.#dom-csspseudochildlist-length"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2.#dom-csspseudoelementlist-getbytype-type"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2.#dom-csspseudoelementlist-getbytypetype"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2.#dom-csspseudoelementlist-item-index"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2.#dom-csspseudoelementlist-itemindex"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2.#dom-csspseudoelementlist-length"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6.3">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#window-interface">6.3 Addition to the window interface</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s6.3.#dom-window-getpseudochildren"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.3.#dom-window-getpseudoelements-elt"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.3.#dom-window-getpseudoelements-type"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.3.#dom-window-getpseudoelementselt-type"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#abstract"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#acknowledgements"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css21"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css3-fonts"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css3-text-decor"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css3bg"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css3cascade"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css3color"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css3line"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css3text"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-cssom"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-dom-level-2-events"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-html5"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-rfc2119"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-selectors4"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-uax29"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-uax44"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#conformance"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#conformance-classes"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#contents"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#conventions"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#experimental"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#idl-index"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#index"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#informative"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#issues-index"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#normative"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#partial"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#references"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#status"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#subtitle"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#testing"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#title"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#w3c_process_revision"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/html/first-letter-001.htm b/tests/wpt/css-tests/css-pseudo-4_dev/html/first-letter-001.htm new file mode 100644 index 00000000000..15d9a61987a --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/html/first-letter-001.htm @@ -0,0 +1,33 @@ +<!DOCTYPE html> +<html><head> + <meta charset="utf-8"> + <title>CSS Test: ::first-letter formatting</title> + <link href="mailto:florian@rivoal.net" rel="author" title="Florian Rivoal"> + <link href="reference/first-letter-001-ref.htm" rel="match"> + <link href="https://drafts.csswg.org/css-pseudo-4/#first-letter-styling" rel="help"> + <meta content="" name="flags"> + <meta content="Test checks that a floated ::first-letter follows the usual formating rules for floats." name="assert"> + <style> + div { + font-size: 50px; + position: absolute; + left: 30px; + top: 50px; + background: red; + } + span { + background : white; + } + div::first-letter { + color: green; + background: green; + float: left; + } + </style> +</head> +<body> + <p>Test passes if there is a <strong>filled green rectangle</strong> and <strong>no red</strong>.</p> + <div>a<span>&nbsp;</span></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/html/first-letter-002.htm b/tests/wpt/css-tests/css-pseudo-4_dev/html/first-letter-002.htm new file mode 100644 index 00000000000..cac4c897cd6 --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/html/first-letter-002.htm @@ -0,0 +1,35 @@ +<!DOCTYPE html> +<html><head> + <meta charset="utf-8"> + <title>CSS Test: ::first-letter formatting</title> + <link href="mailto:florian@rivoal.net" rel="author" title="Florian Rivoal"> + <link href="reference/first-letter-001-ref.htm" rel="match"> + <link href="https://drafts.csswg.org/css-pseudo-4/#first-letter-styling" rel="help"> + <meta content="" name="flags"> + <meta content="Test checks that a floated ::first-letter is formatted identically to a floated non-pseudo element with the same content." name="assert"> + <style> + div { + font-size: 50px; + position: absolute; + left: 30px; + top: 50px; + } + #d1 span { + color: red; + background: red; + float: left; + } + #d2::first-letter { + color: green; + background: green; + float: left; + } + </style> +</head> +<body> + <p>Test passes if there is a <strong>filled green rectangle</strong> and <strong>no red</strong>.</p> + <div id="d1"><span>a</span></div> + <div id="d2">a</div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/html/first-letter-003.htm b/tests/wpt/css-tests/css-pseudo-4_dev/html/first-letter-003.htm new file mode 100644 index 00000000000..5e4a524f73e --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/html/first-letter-003.htm @@ -0,0 +1,35 @@ +<!DOCTYPE html> +<html><head> + <meta charset="utf-8"> + <title>CSS Test: ::first-letter formatting</title> + <link href="mailto:florian@rivoal.net" rel="author" title="Florian Rivoal"> + <link href="reference/first-letter-001-ref.htm" rel="match"> + <link href="https://drafts.csswg.org/css-pseudo-4/#first-letter-styling" rel="help"> + <meta content="" name="flags"> + <meta content="Test checks that a floated ::first-letter is formatted identically to a floated non-pseudo element with the same content." name="assert"> + <style> + div { + font-size: 50px; + position: absolute; + left: 30px; + top: 50px; + } + #d1::first-letter { + color: red; + background: red; + float: left; + } + #d2 span { + color: green; + background: green; + float: left; + } + </style> +</head> +<body> + <p>Test passes if there is a <strong>filled green rectangle</strong> and <strong>no red</strong>.</p> + <div id="d1">a</div> + <div id="d2"><span>a</span></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/html/reference/first-letter-001-ref.htm b/tests/wpt/css-tests/css-pseudo-4_dev/html/reference/first-letter-001-ref.htm new file mode 100644 index 00000000000..326349734b3 --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/html/reference/first-letter-001-ref.htm @@ -0,0 +1,25 @@ +<!DOCTYPE html> +<html><head> + <meta charset="utf-8"> + <title>CSS Reference File</title> + <link href="mailto:florian@rivoal.net" rel="author" title="Florian Rivoal"> + <style> + div { + font-size: 50px; + position: absolute; + left: 30px; + top: 50px; + } + div span { + color: green; + background: green; + float: left; + } + </style> +</head> +<body> + <p>Test passes if there is a <strong>filled green rectangle</strong> and <strong>no red</strong>.</p> + <div><span>a</span></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/html/reftest-toc.htm b/tests/wpt/css-tests/css-pseudo-4_dev/html/reftest-toc.htm new file mode 100644 index 00000000000..5308346f2dc --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/html/reftest-toc.htm @@ -0,0 +1,54 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>CSS Pseudo-Elements Module Level 4 Test Suite Reftest Index</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Pseudo-Elements Module Level 4 Test Suite Reftest Index</h1> + <table width="100%"> + <col id="test-column"> + <col id="ref-column"> + <col id="flags-column"> + <thead> + <tr> + <th>Test</th> + <th>Reference</th> + <th>Flags</th> + </tr> + </thead> + <tbody id="first-letter-001" class=""> + <tr> + <td rowspan="1" title="::first-letter formatting"> + <a href="first-letter-001.htm">first-letter-001</a></td> + <td><a href="reference/first-letter-001-ref.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="first-letter-002" class=""> + <tr> + <td rowspan="1" title="::first-letter formatting"> + <a href="first-letter-002.htm">first-letter-002</a></td> + <td><a href="reference/first-letter-001-ref.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="first-letter-003" class=""> + <tr> + <td rowspan="1" title="::first-letter formatting"> + <a href="first-letter-003.htm">first-letter-003</a></td> + <td><a href="reference/first-letter-001-ref.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + </table> + + </body> +</html> diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/html/reftest.list b/tests/wpt/css-tests/css-pseudo-4_dev/html/reftest.list new file mode 100644 index 00000000000..54eb43a10db --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/html/reftest.list @@ -0,0 +1,4 @@ + +first-letter-001.htm == reference/first-letter-001-ref.htm +first-letter-002.htm == reference/first-letter-001-ref.htm +first-letter-003.htm == reference/first-letter-001-ref.htm diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/html/toc.htm b/tests/wpt/css-tests/css-pseudo-4_dev/html/toc.htm new file mode 100644 index 00000000000..84fae11e9b5 --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/html/toc.htm @@ -0,0 +1,54 @@ + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>CSS Pseudo-Elements Module Level 4 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> +<body> + <h1>CSS Pseudo-Elements Module Level 4 Test Suite By Chapter</h1> + + <p>This index contains both + <a href="http://wiki.csswg.org/test/selftest">self-describing tests</a> + and reftests. + A separate <a href="reftest-toc.htm">alphabetical reftest index</a> + is provided for tests in <a href="http://wiki.csswg.org/test/reftest">reftest + format</a> along with the <a href="reftest.list">reftest manifest</a>.</p> + + <table> + <tbody id="s1"> + <tr><th><a href="chapter-1.htm">Chapter 1 - + Introduction</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s2"> + <tr><th><a href="chapter-2.htm">Chapter 2 - + Typographic Pseudo-elements</a></th> + <td>(3 Tests)</td></tr> + </tbody> + <tbody id="s3"> + <tr><th><a href="chapter-3.htm">Chapter 3 - + Highlight Pseudo-elements</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s4"> + <tr><th><a href="chapter-4.htm">Chapter 4 - + Tree-Abiding Pseudo-elements</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s5"> + <tr><th><a href="chapter-5.htm">Chapter 5 - + Overlapping Pseudo-element Interactions</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s6"> + <tr><th><a href="chapter-6.htm">Chapter 6 - + Additions to the CSS Object Model</a></th> + <td>(0 Tests)</td></tr> + </tbody> + </table> +</body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/implementation-report-TEMPLATE.data b/tests/wpt/css-tests/css-pseudo-4_dev/implementation-report-TEMPLATE.data new file mode 100644 index 00000000000..22cd3ff64bc --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/implementation-report-TEMPLATE.data @@ -0,0 +1,11 @@ +# UA version OS version +# UA string (if applicable) +# http://test.csswg.org/suites/css-pseudo-4_dev/DATESTAMP/ +# See http://wiki.csswg.org/test/implementation-report for instructions +testname revision result comment +html/first-letter-001.htm c24641384eb63b2c0aa812b52a527edfbb9055ec ? +xhtml1/first-letter-001.xht c24641384eb63b2c0aa812b52a527edfbb9055ec ? +html/first-letter-002.htm ac116d66971ad3a1f90b755f2e1f787dc438ed3d ? +xhtml1/first-letter-002.xht ac116d66971ad3a1f90b755f2e1f787dc438ed3d ? +html/first-letter-003.htm b88afcc7f30607a8d64f92e9cec01ba9f549fffe ? +xhtml1/first-letter-003.xht b88afcc7f30607a8d64f92e9cec01ba9f549fffe ? diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/index.htm b/tests/wpt/css-tests/css-pseudo-4_dev/index.htm new file mode 100644 index 00000000000..47d600ff1a2 --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/index.htm @@ -0,0 +1,138 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html lang="en"> + <head> + <title>CSS Pseudo-Elements Module Level 4 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "indices.css"; + </style> + </head> + <body> + + + <h1>CSS Pseudo-Elements Module Level 4 Test Suite</h1> + <dt>Test Coordinator:</dt> + <dd>None Yet</dd> + + <p>This is a <strong>Development</strong> + version of the CSS Pseudo-Elements Module Level 4 Test Suite.</p> + + <p>You can provide test data or review the testing results for this test suite:</p> + <dt><a href="http://test.csswg.org/harness/suite/css-pseudo-4_dev">Enter Data</a></dt> + <dt><a href="http://test.csswg.org/harness/review/css-pseudo-4_dev">Review Results</a></dt> + + + <p>Some tests in the test suite may contain errors. + Please check the latest version of the + <a href="http://www.w3.org/TR/css-pseudo-4/">CSS Pseudo-Elements 4 specification</a> + <strong>and its errata</strong> + before assuming a failure is due to an implementation bug and + not a test suite bug.</p> + + + <p> + In time we hope to correct all errors and extend this test suite to + cover all of CSS Pseudo-Elements 4. Your help is welcome in this effort. + The appropriate mailing list for submitting tests and bug reports is + <a href="http://lists.w3.org/Archives/Public/public-css-testsuite/">public-css-testsuite@w3.org</a>. + More information on the contribution process and test guidelines is + available on the <a href="http://wiki.csswg.org/test">wiki + page</a>.</p> + + <p>Tests are currently available in these formats:</p> + + <dl> + <dt><a href="html/toc.htm">HTML 5</a></dt> + <dd>HTML 5 tests sent as <code>text/html</code></dd> + <dt><a href="xhtml1/toc.xht">XHTML 1.1</a></dt> + <dd>XHTML 1.1 tests sent as <code>application/xhtml+xml</code></dd> + <dt><a href="xhtml1print/toc.xht">XHTML 1.1 for Printers</a></dt> + <dd>XHTML 1.1 tests with all images converted from PNG to JPEG + and formatted with headers and footers to ease testing of + embedded printer software. This is not a canonical format, + and some tests may fail due to the format conversion that + would otherwise pass in the above XHTML 1.1 format.</dd> + </dl> + + + <p>Unless the test instructions explicitly indicate otherwise, + any occurrence of red in a test indicates test failure.</p> + +<h2 id="implement">Implementation Reports</h2> + <p>An <a href="implementation-report-TEMPLATE.data">implementation report template</a> + is available to help with creating implementation reports. See also the + <a href="http://lists.w3.org/Archives/Public/public-css-testsuite/2010Aug/0020.html">explanation</a> + of its format.</p> + +<h2 id="common">Common Assumptions</h2> + + <p>Most of the test suite makes the following assumptions:</p> + <ul> + <li>The X/HTML <code>div</code> element is assigned <code>display: block;</code> + and no other property declaration.</li> + <li>The X/HTML <code>span</code> element is assigned <code>display: inline;</code> + and no other property declaration.</li> + <li>The X/HTML <code>p</code> element is assigned <code>display: block;</code></li> + <li>The X/HTML <code>li</code> element is assigned <code>display: list-item;</code></li> + <li>The X/HTML table elements <code>table</code>, <code>tbody</code>, + <code>tr</code>, and <code>td</code> are assigned the <code>display</code> + values <code>table</code>, <code>table-row-group</code>, + <code>table-row</code>, and <code>table-cell</code>, respectively.</li> + <li>The device can display the sixteen color values associated with the color + keywords <code>black</code>, <code>white</code>, <code>gray</code>, + <code>silver</code>, <code>red</code>, <code>green</code>, <code>blue</code>, + <code>purple</code>, <code>yellow</code>, <code>orange</code>, <code>teal</code>, + <code>fuchsia</code>, <code>maroon</code>, <code>navy</code>, <code>aqua</code>, + and <code>lime</code> as distinct colors.</li> + <li>The UA is set to print background colors and, if it supports graphics, + background images.</li> + <li>The UA implements reasonable page-breaking behavior; e.g., it is assumed + that UAs will not break at every opportunity, but only near the end of + a page unless a page break is forced.</li> + <li>The UA implements reasonable line-breaking behavior; e.g., it is assumed + that spaces between alphanumeric characters provide line breaking + opportunities and that UAs will not break at every opportunity, but only + near the end of a line unless a line break is forced.</li> + </ul> + +<h2 id="uncommon">Uncommon Assumptions</h2> + + <p>In addition, some of the tests make one or more of the following + assumptions:</p> + + <ul> + <li>The device is a full-color device.</li> + <li>The device has a viewport width of at least 640px (approx).</li> + <li>The resolution of the device is 96 CSS pixels per inch.</li> + <li>The UA imposes no minimum font size.</li> + <li>The 'medium' font-size computes to 16px.</li> + <li>The initial value of 'color' is black.</li> + <li>The canvas background is white.</li> + <li>The user stylesheet is empty (except where indicated by the tests).</li> + <li>The device is interactive and uses scroll bars.</li> + </ul> + + <p>The tests that need these assumptions to be true have not yet been + marked, but it is likely that we will add a way to identify these + tests in due course. Tests should avoid relying on these assumptions + unless necessary.</p> + +<h2>License</h2> + + <p>This test suite is licensed under both the + <a href="http://www.w3.org/Consortium/Legal/2008/04-testsuite-license">W3C + Test Suite License</a> and the <a href="http://www.w3.org/Consortium/Legal/2008/03-bsd-license">W3C + 3-clause BSD License</a>. See W3C Legal's <a href="http://www.w3.org/Consortium/Legal/2008/04-testsuite-copyright">explanation + of the licenses</a>.</p> + +<h2>Acknowledgements</h2> + + <p>Many thanks to the following for their contributions:</p> + <ul> + <li>Florian Rivoal</li> + </ul> + +</body> +</html> diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/index.xht b/tests/wpt/css-tests/css-pseudo-4_dev/index.xht new file mode 100644 index 00000000000..b5104a2b258 --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/index.xht @@ -0,0 +1,138 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> + <head> + <title>CSS Pseudo-Elements Module Level 4 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "indices.css"; + </style> + </head> + <body> + + + <h1>CSS Pseudo-Elements Module Level 4 Test Suite</h1> + <dt>Test Coordinator:</dt> + <dd>None Yet</dd> + + <p>This is a <strong>Development</strong> + version of the CSS Pseudo-Elements Module Level 4 Test Suite.</p> + + <p>You can provide test data or review the testing results for this test suite:</p> + <dt><a href="http://test.csswg.org/harness/suite/css-pseudo-4_dev">Enter Data</a></dt> + <dt><a href="http://test.csswg.org/harness/review/css-pseudo-4_dev">Review Results</a></dt> + + + <p>Some tests in the test suite may contain errors. + Please check the latest version of the + <a href="http://www.w3.org/TR/css-pseudo-4/">CSS Pseudo-Elements 4 specification</a> + <strong>and its errata</strong> + before assuming a failure is due to an implementation bug and + not a test suite bug.</p> + + + <p> + In time we hope to correct all errors and extend this test suite to + cover all of CSS Pseudo-Elements 4. Your help is welcome in this effort. + The appropriate mailing list for submitting tests and bug reports is + <a href="http://lists.w3.org/Archives/Public/public-css-testsuite/">public-css-testsuite@w3.org</a>. + More information on the contribution process and test guidelines is + available on the <a href="http://wiki.csswg.org/test">wiki + page</a>.</p> + + <p>Tests are currently available in these formats:</p> + + <dl> + <dt><a href="html/toc.htm">HTML 5</a></dt> + <dd>HTML 5 tests sent as <code>text/html</code></dd> + <dt><a href="xhtml1/toc.xht">XHTML 1.1</a></dt> + <dd>XHTML 1.1 tests sent as <code>application/xhtml+xml</code></dd> + <dt><a href="xhtml1print/toc.xht">XHTML 1.1 for Printers</a></dt> + <dd>XHTML 1.1 tests with all images converted from PNG to JPEG + and formatted with headers and footers to ease testing of + embedded printer software. This is not a canonical format, + and some tests may fail due to the format conversion that + would otherwise pass in the above XHTML 1.1 format.</dd> + </dl> + + + <p>Unless the test instructions explicitly indicate otherwise, + any occurrence of red in a test indicates test failure.</p> + +<h2 id="implement">Implementation Reports</h2> + <p>An <a href="implementation-report-TEMPLATE.data">implementation report template</a> + is available to help with creating implementation reports. See also the + <a href="http://lists.w3.org/Archives/Public/public-css-testsuite/2010Aug/0020.html">explanation</a> + of its format.</p> + +<h2 id="common">Common Assumptions</h2> + + <p>Most of the test suite makes the following assumptions:</p> + <ul> + <li>The X/HTML <code>div</code> element is assigned <code>display: block;</code> + and no other property declaration.</li> + <li>The X/HTML <code>span</code> element is assigned <code>display: inline;</code> + and no other property declaration.</li> + <li>The X/HTML <code>p</code> element is assigned <code>display: block;</code></li> + <li>The X/HTML <code>li</code> element is assigned <code>display: list-item;</code></li> + <li>The X/HTML table elements <code>table</code>, <code>tbody</code>, + <code>tr</code>, and <code>td</code> are assigned the <code>display</code> + values <code>table</code>, <code>table-row-group</code>, + <code>table-row</code>, and <code>table-cell</code>, respectively.</li> + <li>The device can display the sixteen color values associated with the color + keywords <code>black</code>, <code>white</code>, <code>gray</code>, + <code>silver</code>, <code>red</code>, <code>green</code>, <code>blue</code>, + <code>purple</code>, <code>yellow</code>, <code>orange</code>, <code>teal</code>, + <code>fuchsia</code>, <code>maroon</code>, <code>navy</code>, <code>aqua</code>, + and <code>lime</code> as distinct colors.</li> + <li>The UA is set to print background colors and, if it supports graphics, + background images.</li> + <li>The UA implements reasonable page-breaking behavior; e.g., it is assumed + that UAs will not break at every opportunity, but only near the end of + a page unless a page break is forced.</li> + <li>The UA implements reasonable line-breaking behavior; e.g., it is assumed + that spaces between alphanumeric characters provide line breaking + opportunities and that UAs will not break at every opportunity, but only + near the end of a line unless a line break is forced.</li> + </ul> + +<h2 id="uncommon">Uncommon Assumptions</h2> + + <p>In addition, some of the tests make one or more of the following + assumptions:</p> + + <ul> + <li>The device is a full-color device.</li> + <li>The device has a viewport width of at least 640px (approx).</li> + <li>The resolution of the device is 96 CSS pixels per inch.</li> + <li>The UA imposes no minimum font size.</li> + <li>The 'medium' font-size computes to 16px.</li> + <li>The initial value of 'color' is black.</li> + <li>The canvas background is white.</li> + <li>The user stylesheet is empty (except where indicated by the tests).</li> + <li>The device is interactive and uses scroll bars.</li> + </ul> + + <p>The tests that need these assumptions to be true have not yet been + marked, but it is likely that we will add a way to identify these + tests in due course. Tests should avoid relying on these assumptions + unless necessary.</p> + +<h2>License</h2> + + <p>This test suite is licensed under both the + <a href="http://www.w3.org/Consortium/Legal/2008/04-testsuite-license">W3C + Test Suite License</a> and the <a href="http://www.w3.org/Consortium/Legal/2008/03-bsd-license">W3C + 3-clause BSD License</a>. See W3C Legal's <a href="http://www.w3.org/Consortium/Legal/2008/04-testsuite-copyright">explanation + of the licenses</a>.</p> + +<h2>Acknowledgements</h2> + + <p>Many thanks to the following for their contributions:</p> + <ul> + <li>Florian Rivoal</li> + </ul> + +</body> +</html> diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/indices.css b/tests/wpt/css-tests/css-pseudo-4_dev/indices.css new file mode 100644 index 00000000000..7bc70eeef94 --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/indices.css @@ -0,0 +1,96 @@ +/* CSS for CSS Conformance Test Indices */ +/* Written by fantasai */ + +/* Test Tables */ + + table { + border-collapse: collapse; + } + + thead { + border-bottom: 0.2em solid; + } + + tbody { + border: thin solid; + border-style: solid none; + } + + tbody.ch { + border-top: 0.2em solid; + } + tbody.ch th { + font-weight: bold; + } + + tbody th { + border-bottom: silver dotted thin; + background: #EEE; + color: black; + font-weight: normal; + font-style: italic; + } + tbody th :link { + color: gray; + background: transparent; + } + tbody th :visited { + color: #333; + background: transparent; + } + + th, td { + padding: 0.2em; + text-align: left; + vertical-align: baseline; + } + + td { + font-size: 0.9em; + } + + /* flags */ + td abbr { + border: solid thin gray; + padding: 0 0.1em; + cursor: help; + } + td abbr:hover { + background: #ffa; + color: black; + } + + + tr:hover { + background: #F9F9F9; + color: navy; + } + + th a, + td a { + text-decoration: none; + } + th a:hover, + td a:hover, + th a:focus, + td a:focus { + text-decoration: underline; + } + + td a { + display: block; + padding-left: 2em; + text-indent: -1em; + } + .refs { + font-weight: bold; + font-size: larger; + } + .assert, .assert > li { + list-style-type: none; + font-style: italic; + color: gray; + margin: 0; + padding: 0; + text-indent: 0; + } diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/testinfo.data b/tests/wpt/css-tests/css-pseudo-4_dev/testinfo.data new file mode 100644 index 00000000000..50fd642c5ca --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/testinfo.data @@ -0,0 +1,4 @@ +id references title flags links revision credits assertion +first-letter-001 reference/first-letter-001-ref ::first-letter formatting https://drafts.csswg.org/css-pseudo-4/#first-letter-styling c24641384eb63b2c0aa812b52a527edfbb9055ec `Florian Rivoal`<mailto:florian@rivoal.net> Test checks that a floated ::first-letter follows the usual formating rules for floats. +first-letter-002 reference/first-letter-001-ref ::first-letter formatting https://drafts.csswg.org/css-pseudo-4/#first-letter-styling ac116d66971ad3a1f90b755f2e1f787dc438ed3d `Florian Rivoal`<mailto:florian@rivoal.net> Test checks that a floated ::first-letter is formatted identically to a floated non-pseudo element with the same content. +first-letter-003 reference/first-letter-001-ref ::first-letter formatting https://drafts.csswg.org/css-pseudo-4/#first-letter-styling b88afcc7f30607a8d64f92e9cec01ba9f549fffe `Florian Rivoal`<mailto:florian@rivoal.net> Test checks that a floated ::first-letter is formatted identically to a floated non-pseudo element with the same content. diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/chapter-1.xht b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/chapter-1.xht new file mode 100644 index 00000000000..1a2b8bc08e7 --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/chapter-1.xht @@ -0,0 +1,39 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Introduction - CSS Pseudo-Elements Module Level 4 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Pseudo-Elements Module Level 4 Test Suite</h1> + <h2>Introduction (0 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s1">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#intro">1 Introduction</a></th></tr> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/chapter-2.xht b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/chapter-2.xht new file mode 100644 index 00000000000..dc48344347f --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/chapter-2.xht @@ -0,0 +1,126 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Typographic Pseudo-elements - CSS Pseudo-Elements Module Level 4 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Pseudo-Elements Module Level 4 Test Suite</h1> + <h2>Typographic Pseudo-elements (3 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#typographic-pseudos">2 Typographic Pseudo-elements</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s2.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.1">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#first-line-pseudo">2.1 The ::first-line pseudo-element</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s2.1.#fictional-tag-sequence"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.1.#selectordef-first-line"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.1.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.1.1">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#first-text-line">2.1.1 Finding the First Formatted Line</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s2.1.1.#first-formatted-line"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.1.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.1.2">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#first-line-styling">2.1.2 Styling the First Line Pseudo-element</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s2.1.3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.1.3">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#first-line-inheritance">2.1.3 Inheritance and the ::first-line Pseudo-element</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s2.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.2">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#first-letter-pseudo">2.2 The ::first-letter pseudo-element</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s2.2.#issue-703eb1d7"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.2.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.2.1">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#application-in-css">2.2.1 Finding the First Letter</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s2.2.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.2.2">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#first-letter-styling">2.2.2 Styling the ::first-letter Pseudo-element</a></th></tr> + <!-- 3 tests --> + <tr id="first-letter-001-2.2.2" class="primary"> + <td><strong> + <a href="first-letter-001.xht">first-letter-001</a></strong></td> + <td><a href="reference/first-letter-001-ref.xht">=</a> </td> + <td></td> + <td>::first-letter formatting + <ul class="assert"> + <li>Test checks that a floated ::first-letter follows the usual formating rules for floats.</li> + </ul> + </td> + </tr> + <tr id="first-letter-002-2.2.2" class="primary"> + <td><strong> + <a href="first-letter-002.xht">first-letter-002</a></strong></td> + <td><a href="reference/first-letter-001-ref.xht">=</a> </td> + <td></td> + <td>::first-letter formatting + <ul class="assert"> + <li>Test checks that a floated ::first-letter is formatted identically to a floated non-pseudo element with the same content.</li> + </ul> + </td> + </tr> + <tr id="first-letter-003-2.2.2" class="primary"> + <td><strong> + <a href="first-letter-003.xht">first-letter-003</a></strong></td> + <td><a href="reference/first-letter-001-ref.xht">=</a> </td> + <td></td> + <td>::first-letter formatting + <ul class="assert"> + <li>Test checks that a floated ::first-letter is formatted identically to a floated non-pseudo element with the same content.</li> + </ul> + </td> + </tr> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/chapter-3.xht b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/chapter-3.xht new file mode 100644 index 00000000000..ff51bf84bad --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/chapter-3.xht @@ -0,0 +1,111 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Highlight Pseudo-elements - CSS Pseudo-Elements Module Level 4 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Pseudo-Elements Module Level 4 Test Suite</h1> + <h2>Highlight Pseudo-elements (0 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#highlight-pseudos">3 Highlight Pseudo-elements</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.1">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#highlight-selectors">3.1 Selecting Highlighted Content: the ::selection, ::spelling-error, and ::grammar-error pseudo-elements</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#highlight-pseudo-elements"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#issue-43364a12"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#selectordef-grammar-error"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#selectordef-selection"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#selectordef-spelling-error"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.2">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#highlight-styling">3.2 Styling Highlights</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.2.#issue-7be57116"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.3">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#highlight-bounds">3.3 Area of a Highlight</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.3.#issue-271a1b90"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.3.#issue-b6466947"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.3.#root-highlight-overlay"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.4"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.4">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#highlight-cascade">3.4 Cascading and Per-Element Highlight Styles</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.4.#issue-d1a9f919"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.5"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.5">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#highlight-painting">3.5 Painting the Highlight</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.5.#issue-8f96bd90"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.5.#issue-a5c22c51"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.6"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.6">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#highlight-security">3.6 Security Considerations</a></th></tr> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/chapter-4.xht b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/chapter-4.xht new file mode 100644 index 00000000000..45f63117483 --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/chapter-4.xht @@ -0,0 +1,66 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Tree-Abiding Pseudo-elements - CSS Pseudo-Elements Module Level 4 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Pseudo-Elements Module Level 4 Test Suite</h1> + <h2>Tree-Abiding Pseudo-elements (0 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s4"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#treelike">4 Tree-Abiding Pseudo-elements</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s4.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4.1">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#generated-content">4.1 Generated Content Pseudo-elements: ::before and ::after</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s4.1.#selectordef-after"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.1.#selectordef-before"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4.2">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#placeholder-pseudo">4.2 Placeholder Input: the ::placeholder pseudo-element</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s4.2.#issue-44dd3703"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.2.#issue-68e6c4d7"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.2.#selectordef-placeholder"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/chapter-5.xht b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/chapter-5.xht new file mode 100644 index 00000000000..7778d23eb53 --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/chapter-5.xht @@ -0,0 +1,42 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Overlapping Pseudo-element Interactions - CSS Pseudo-Elements Module Level 4 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Pseudo-Elements Module Level 4 Test Suite</h1> + <h2>Overlapping Pseudo-element Interactions (0 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s5"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s5">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#interactions">5 Overlapping Pseudo-element Interactions</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#overlapping-example"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/chapter-6.xht b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/chapter-6.xht new file mode 100644 index 00000000000..354669d84c0 --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/chapter-6.xht @@ -0,0 +1,222 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Additions to the CSS Object Model - CSS Pseudo-Elements Module Level 4 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Pseudo-Elements Module Level 4 Test Suite</h1> + <h2>Additions to the CSS Object Model (0 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s6"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#cssom">6 Additions to the CSS Object Model</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s6.#issue-116a9e33"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6.1">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#CSSPseudoElement-interface">6.1 Interface CSSPseudoElement</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#csspseudoelement"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#dom-csspseudochild-style"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#dom-csspseudochild-type"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#dom-csspseudoelement-style"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#dom-csspseudoelement-type"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#issue-65c50c19"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#issue-b008e095"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6.2">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#CSSPseudoElementList-interface">6.2 Interface CSSPseudoElementList</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2.#csspseudoelementlist"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2.#dom-csspseudochildlist-getbytype"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2.#dom-csspseudochildlist-item"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2.#dom-csspseudochildlist-length"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2.#dom-csspseudoelementlist-getbytype-type"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2.#dom-csspseudoelementlist-getbytypetype"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2.#dom-csspseudoelementlist-item-index"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2.#dom-csspseudoelementlist-itemindex"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2.#dom-csspseudoelementlist-length"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6.3">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#window-interface">6.3 Addition to the window interface</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s6.3.#dom-window-getpseudochildren"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.3.#dom-window-getpseudoelements-elt"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.3.#dom-window-getpseudoelements-type"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.3.#dom-window-getpseudoelementselt-type"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#abstract"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#acknowledgements"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css21"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css3-fonts"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css3-text-decor"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css3bg"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css3cascade"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css3color"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css3line"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css3text"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-cssom"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-dom-level-2-events"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-html5"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-rfc2119"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-selectors4"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-uax29"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-uax44"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#conformance"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#conformance-classes"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#contents"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#conventions"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#experimental"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#idl-index"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#index"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#informative"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#issues-index"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#normative"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#partial"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#references"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#status"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#subtitle"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#testing"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#title"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#w3c_process_revision"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/first-letter-001.xht b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/first-letter-001.xht new file mode 100644 index 00000000000..5a4aae9e7c0 --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/first-letter-001.xht @@ -0,0 +1,33 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <meta charset="utf-8" /> + <title>CSS Test: ::first-letter formatting</title> + <link href="mailto:florian@rivoal.net" rel="author" title="Florian Rivoal" /> + <link href="reference/first-letter-001-ref.xht" rel="match" /> + <link href="https://drafts.csswg.org/css-pseudo-4/#first-letter-styling" rel="help" /> + <meta content="" name="flags" /> + <meta content="Test checks that a floated ::first-letter follows the usual formating rules for floats." name="assert" /> + <style> + div { + font-size: 50px; + position: absolute; + left: 30px; + top: 50px; + background: red; + } + span { + background : white; + } + div::first-letter { + color: green; + background: green; + float: left; + } + </style> +</head> +<body> + <p>Test passes if there is a <strong>filled green rectangle</strong> and <strong>no red</strong>.</p> + <div>a<span>&#xA0;</span></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/first-letter-002.xht b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/first-letter-002.xht new file mode 100644 index 00000000000..b94a8993991 --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/first-letter-002.xht @@ -0,0 +1,35 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <meta charset="utf-8" /> + <title>CSS Test: ::first-letter formatting</title> + <link href="mailto:florian@rivoal.net" rel="author" title="Florian Rivoal" /> + <link href="reference/first-letter-001-ref.xht" rel="match" /> + <link href="https://drafts.csswg.org/css-pseudo-4/#first-letter-styling" rel="help" /> + <meta content="" name="flags" /> + <meta content="Test checks that a floated ::first-letter is formatted identically to a floated non-pseudo element with the same content." name="assert" /> + <style> + div { + font-size: 50px; + position: absolute; + left: 30px; + top: 50px; + } + #d1 span { + color: red; + background: red; + float: left; + } + #d2::first-letter { + color: green; + background: green; + float: left; + } + </style> +</head> +<body> + <p>Test passes if there is a <strong>filled green rectangle</strong> and <strong>no red</strong>.</p> + <div id="d1"><span>a</span></div> + <div id="d2">a</div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/first-letter-003.xht b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/first-letter-003.xht new file mode 100644 index 00000000000..d38012d6f7e --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/first-letter-003.xht @@ -0,0 +1,35 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <meta charset="utf-8" /> + <title>CSS Test: ::first-letter formatting</title> + <link href="mailto:florian@rivoal.net" rel="author" title="Florian Rivoal" /> + <link href="reference/first-letter-001-ref.xht" rel="match" /> + <link href="https://drafts.csswg.org/css-pseudo-4/#first-letter-styling" rel="help" /> + <meta content="" name="flags" /> + <meta content="Test checks that a floated ::first-letter is formatted identically to a floated non-pseudo element with the same content." name="assert" /> + <style> + div { + font-size: 50px; + position: absolute; + left: 30px; + top: 50px; + } + #d1::first-letter { + color: red; + background: red; + float: left; + } + #d2 span { + color: green; + background: green; + float: left; + } + </style> +</head> +<body> + <p>Test passes if there is a <strong>filled green rectangle</strong> and <strong>no red</strong>.</p> + <div id="d1">a</div> + <div id="d2"><span>a</span></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/reference/first-letter-001-ref.xht b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/reference/first-letter-001-ref.xht new file mode 100644 index 00000000000..ae26a9699f7 --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/reference/first-letter-001-ref.xht @@ -0,0 +1,25 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <meta charset="utf-8" /> + <title>CSS Reference File</title> + <link href="mailto:florian@rivoal.net" rel="author" title="Florian Rivoal" /> + <style> + div { + font-size: 50px; + position: absolute; + left: 30px; + top: 50px; + } + div span { + color: green; + background: green; + float: left; + } + </style> +</head> +<body> + <p>Test passes if there is a <strong>filled green rectangle</strong> and <strong>no red</strong>.</p> + <div><span>a</span></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/reftest-toc.xht b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/reftest-toc.xht new file mode 100644 index 00000000000..078137968dd --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/reftest-toc.xht @@ -0,0 +1,54 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>CSS Pseudo-Elements Module Level 4 Test Suite Reftest Index</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Pseudo-Elements Module Level 4 Test Suite Reftest Index</h1> + <table width="100%"> + <col id="test-column"></col> + <col id="ref-column"></col> + <col id="flags-column"></col> + <thead> + <tr> + <th>Test</th> + <th>Reference</th> + <th>Flags</th> + </tr> + </thead> + <tbody id="first-letter-001" class=""> + <tr> + <td rowspan="1" title="::first-letter formatting"> + <a href="first-letter-001.xht">first-letter-001</a></td> + <td><a href="reference/first-letter-001-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="first-letter-002" class=""> + <tr> + <td rowspan="1" title="::first-letter formatting"> + <a href="first-letter-002.xht">first-letter-002</a></td> + <td><a href="reference/first-letter-001-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="first-letter-003" class=""> + <tr> + <td rowspan="1" title="::first-letter formatting"> + <a href="first-letter-003.xht">first-letter-003</a></td> + <td><a href="reference/first-letter-001-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + </table> + + </body> +</html> diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/reftest.list b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/reftest.list new file mode 100644 index 00000000000..251bbd8aa71 --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/reftest.list @@ -0,0 +1,4 @@ + +first-letter-001.xht == reference/first-letter-001-ref.xht +first-letter-002.xht == reference/first-letter-001-ref.xht +first-letter-003.xht == reference/first-letter-001-ref.xht diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/toc.xht b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/toc.xht new file mode 100644 index 00000000000..597e02d5f5f --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1/toc.xht @@ -0,0 +1,54 @@ + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>CSS Pseudo-Elements Module Level 4 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> +<body> + <h1>CSS Pseudo-Elements Module Level 4 Test Suite By Chapter</h1> + + <p>This index contains both + <a href="http://wiki.csswg.org/test/selftest">self-describing tests</a> + and reftests. + A separate <a href="reftest-toc.xht">alphabetical reftest index</a> + is provided for tests in <a href="http://wiki.csswg.org/test/reftest">reftest + format</a> along with the <a href="reftest.list">reftest manifest</a>.</p> + + <table> + <tbody id="s1"> + <tr><th><a href="chapter-1.xht">Chapter 1 - + Introduction</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s2"> + <tr><th><a href="chapter-2.xht">Chapter 2 - + Typographic Pseudo-elements</a></th> + <td>(3 Tests)</td></tr> + </tbody> + <tbody id="s3"> + <tr><th><a href="chapter-3.xht">Chapter 3 - + Highlight Pseudo-elements</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s4"> + <tr><th><a href="chapter-4.xht">Chapter 4 - + Tree-Abiding Pseudo-elements</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s5"> + <tr><th><a href="chapter-5.xht">Chapter 5 - + Overlapping Pseudo-element Interactions</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s6"> + <tr><th><a href="chapter-6.xht">Chapter 6 - + Additions to the CSS Object Model</a></th> + <td>(0 Tests)</td></tr> + </tbody> + </table> +</body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/chapter-1.xht b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/chapter-1.xht new file mode 100644 index 00000000000..1a2b8bc08e7 --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/chapter-1.xht @@ -0,0 +1,39 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Introduction - CSS Pseudo-Elements Module Level 4 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Pseudo-Elements Module Level 4 Test Suite</h1> + <h2>Introduction (0 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s1">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#intro">1 Introduction</a></th></tr> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/chapter-2.xht b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/chapter-2.xht new file mode 100644 index 00000000000..dc48344347f --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/chapter-2.xht @@ -0,0 +1,126 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Typographic Pseudo-elements - CSS Pseudo-Elements Module Level 4 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Pseudo-Elements Module Level 4 Test Suite</h1> + <h2>Typographic Pseudo-elements (3 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#typographic-pseudos">2 Typographic Pseudo-elements</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s2.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.1">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#first-line-pseudo">2.1 The ::first-line pseudo-element</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s2.1.#fictional-tag-sequence"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.1.#selectordef-first-line"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.1.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.1.1">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#first-text-line">2.1.1 Finding the First Formatted Line</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s2.1.1.#first-formatted-line"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.1.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.1.2">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#first-line-styling">2.1.2 Styling the First Line Pseudo-element</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s2.1.3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.1.3">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#first-line-inheritance">2.1.3 Inheritance and the ::first-line Pseudo-element</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s2.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.2">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#first-letter-pseudo">2.2 The ::first-letter pseudo-element</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s2.2.#issue-703eb1d7"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.2.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.2.1">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#application-in-css">2.2.1 Finding the First Letter</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s2.2.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.2.2">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#first-letter-styling">2.2.2 Styling the ::first-letter Pseudo-element</a></th></tr> + <!-- 3 tests --> + <tr id="first-letter-001-2.2.2" class="primary"> + <td><strong> + <a href="first-letter-001.xht">first-letter-001</a></strong></td> + <td><a href="reference/first-letter-001-ref.xht">=</a> </td> + <td></td> + <td>::first-letter formatting + <ul class="assert"> + <li>Test checks that a floated ::first-letter follows the usual formating rules for floats.</li> + </ul> + </td> + </tr> + <tr id="first-letter-002-2.2.2" class="primary"> + <td><strong> + <a href="first-letter-002.xht">first-letter-002</a></strong></td> + <td><a href="reference/first-letter-001-ref.xht">=</a> </td> + <td></td> + <td>::first-letter formatting + <ul class="assert"> + <li>Test checks that a floated ::first-letter is formatted identically to a floated non-pseudo element with the same content.</li> + </ul> + </td> + </tr> + <tr id="first-letter-003-2.2.2" class="primary"> + <td><strong> + <a href="first-letter-003.xht">first-letter-003</a></strong></td> + <td><a href="reference/first-letter-001-ref.xht">=</a> </td> + <td></td> + <td>::first-letter formatting + <ul class="assert"> + <li>Test checks that a floated ::first-letter is formatted identically to a floated non-pseudo element with the same content.</li> + </ul> + </td> + </tr> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/chapter-3.xht b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/chapter-3.xht new file mode 100644 index 00000000000..ff51bf84bad --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/chapter-3.xht @@ -0,0 +1,111 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Highlight Pseudo-elements - CSS Pseudo-Elements Module Level 4 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Pseudo-Elements Module Level 4 Test Suite</h1> + <h2>Highlight Pseudo-elements (0 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#highlight-pseudos">3 Highlight Pseudo-elements</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.1">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#highlight-selectors">3.1 Selecting Highlighted Content: the ::selection, ::spelling-error, and ::grammar-error pseudo-elements</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#highlight-pseudo-elements"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#issue-43364a12"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#selectordef-grammar-error"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#selectordef-selection"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#selectordef-spelling-error"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.2">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#highlight-styling">3.2 Styling Highlights</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.2.#issue-7be57116"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.3">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#highlight-bounds">3.3 Area of a Highlight</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.3.#issue-271a1b90"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.3.#issue-b6466947"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.3.#root-highlight-overlay"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.4"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.4">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#highlight-cascade">3.4 Cascading and Per-Element Highlight Styles</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.4.#issue-d1a9f919"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.5"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.5">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#highlight-painting">3.5 Painting the Highlight</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.5.#issue-8f96bd90"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.5.#issue-a5c22c51"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.6"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.6">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#highlight-security">3.6 Security Considerations</a></th></tr> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/chapter-4.xht b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/chapter-4.xht new file mode 100644 index 00000000000..45f63117483 --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/chapter-4.xht @@ -0,0 +1,66 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Tree-Abiding Pseudo-elements - CSS Pseudo-Elements Module Level 4 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Pseudo-Elements Module Level 4 Test Suite</h1> + <h2>Tree-Abiding Pseudo-elements (0 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s4"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#treelike">4 Tree-Abiding Pseudo-elements</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s4.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4.1">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#generated-content">4.1 Generated Content Pseudo-elements: ::before and ::after</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s4.1.#selectordef-after"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.1.#selectordef-before"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4.2">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#placeholder-pseudo">4.2 Placeholder Input: the ::placeholder pseudo-element</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s4.2.#issue-44dd3703"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.2.#issue-68e6c4d7"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.2.#selectordef-placeholder"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/chapter-5.xht b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/chapter-5.xht new file mode 100644 index 00000000000..7778d23eb53 --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/chapter-5.xht @@ -0,0 +1,42 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Overlapping Pseudo-element Interactions - CSS Pseudo-Elements Module Level 4 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Pseudo-Elements Module Level 4 Test Suite</h1> + <h2>Overlapping Pseudo-element Interactions (0 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s5"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s5">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#interactions">5 Overlapping Pseudo-element Interactions</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#overlapping-example"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/chapter-6.xht b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/chapter-6.xht new file mode 100644 index 00000000000..354669d84c0 --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/chapter-6.xht @@ -0,0 +1,222 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Additions to the CSS Object Model - CSS Pseudo-Elements Module Level 4 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Pseudo-Elements Module Level 4 Test Suite</h1> + <h2>Additions to the CSS Object Model (0 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s6"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#cssom">6 Additions to the CSS Object Model</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s6.#issue-116a9e33"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6.1">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#CSSPseudoElement-interface">6.1 Interface CSSPseudoElement</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#csspseudoelement"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#dom-csspseudochild-style"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#dom-csspseudochild-type"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#dom-csspseudoelement-style"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#dom-csspseudoelement-type"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#issue-65c50c19"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#issue-b008e095"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6.2">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#CSSPseudoElementList-interface">6.2 Interface CSSPseudoElementList</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2.#csspseudoelementlist"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2.#dom-csspseudochildlist-getbytype"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2.#dom-csspseudochildlist-item"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2.#dom-csspseudochildlist-length"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2.#dom-csspseudoelementlist-getbytype-type"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2.#dom-csspseudoelementlist-getbytypetype"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2.#dom-csspseudoelementlist-item-index"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2.#dom-csspseudoelementlist-itemindex"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2.#dom-csspseudoelementlist-length"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6.3">+</a> + <a href="http://www.w3.org/TR/css-pseudo-4/#window-interface">6.3 Addition to the window interface</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s6.3.#dom-window-getpseudochildren"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.3.#dom-window-getpseudoelements-elt"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.3.#dom-window-getpseudoelements-type"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.3.#dom-window-getpseudoelementselt-type"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#abstract"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#acknowledgements"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css21"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css3-fonts"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css3-text-decor"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css3bg"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css3cascade"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css3color"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css3line"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css3text"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-cssom"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-dom-level-2-events"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-html5"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-rfc2119"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-selectors4"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-uax29"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-uax44"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#conformance"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#conformance-classes"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#contents"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#conventions"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#experimental"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#idl-index"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#index"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#informative"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#issues-index"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#normative"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#partial"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#references"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#status"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#subtitle"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#testing"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#title"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#w3c_process_revision"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/first-letter-001.xht b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/first-letter-001.xht new file mode 100644 index 00000000000..5a4aae9e7c0 --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/first-letter-001.xht @@ -0,0 +1,33 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <meta charset="utf-8" /> + <title>CSS Test: ::first-letter formatting</title> + <link href="mailto:florian@rivoal.net" rel="author" title="Florian Rivoal" /> + <link href="reference/first-letter-001-ref.xht" rel="match" /> + <link href="https://drafts.csswg.org/css-pseudo-4/#first-letter-styling" rel="help" /> + <meta content="" name="flags" /> + <meta content="Test checks that a floated ::first-letter follows the usual formating rules for floats." name="assert" /> + <style> + div { + font-size: 50px; + position: absolute; + left: 30px; + top: 50px; + background: red; + } + span { + background : white; + } + div::first-letter { + color: green; + background: green; + float: left; + } + </style> +</head> +<body> + <p>Test passes if there is a <strong>filled green rectangle</strong> and <strong>no red</strong>.</p> + <div>a<span>&#xA0;</span></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/first-letter-002.xht b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/first-letter-002.xht new file mode 100644 index 00000000000..b94a8993991 --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/first-letter-002.xht @@ -0,0 +1,35 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <meta charset="utf-8" /> + <title>CSS Test: ::first-letter formatting</title> + <link href="mailto:florian@rivoal.net" rel="author" title="Florian Rivoal" /> + <link href="reference/first-letter-001-ref.xht" rel="match" /> + <link href="https://drafts.csswg.org/css-pseudo-4/#first-letter-styling" rel="help" /> + <meta content="" name="flags" /> + <meta content="Test checks that a floated ::first-letter is formatted identically to a floated non-pseudo element with the same content." name="assert" /> + <style> + div { + font-size: 50px; + position: absolute; + left: 30px; + top: 50px; + } + #d1 span { + color: red; + background: red; + float: left; + } + #d2::first-letter { + color: green; + background: green; + float: left; + } + </style> +</head> +<body> + <p>Test passes if there is a <strong>filled green rectangle</strong> and <strong>no red</strong>.</p> + <div id="d1"><span>a</span></div> + <div id="d2">a</div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/first-letter-003.xht b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/first-letter-003.xht new file mode 100644 index 00000000000..d38012d6f7e --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/first-letter-003.xht @@ -0,0 +1,35 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <meta charset="utf-8" /> + <title>CSS Test: ::first-letter formatting</title> + <link href="mailto:florian@rivoal.net" rel="author" title="Florian Rivoal" /> + <link href="reference/first-letter-001-ref.xht" rel="match" /> + <link href="https://drafts.csswg.org/css-pseudo-4/#first-letter-styling" rel="help" /> + <meta content="" name="flags" /> + <meta content="Test checks that a floated ::first-letter is formatted identically to a floated non-pseudo element with the same content." name="assert" /> + <style> + div { + font-size: 50px; + position: absolute; + left: 30px; + top: 50px; + } + #d1::first-letter { + color: red; + background: red; + float: left; + } + #d2 span { + color: green; + background: green; + float: left; + } + </style> +</head> +<body> + <p>Test passes if there is a <strong>filled green rectangle</strong> and <strong>no red</strong>.</p> + <div id="d1">a</div> + <div id="d2"><span>a</span></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/reference/first-letter-001-ref.xht b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/reference/first-letter-001-ref.xht new file mode 100644 index 00000000000..ae26a9699f7 --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/reference/first-letter-001-ref.xht @@ -0,0 +1,25 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <meta charset="utf-8" /> + <title>CSS Reference File</title> + <link href="mailto:florian@rivoal.net" rel="author" title="Florian Rivoal" /> + <style> + div { + font-size: 50px; + position: absolute; + left: 30px; + top: 50px; + } + div span { + color: green; + background: green; + float: left; + } + </style> +</head> +<body> + <p>Test passes if there is a <strong>filled green rectangle</strong> and <strong>no red</strong>.</p> + <div><span>a</span></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/reftest-toc.xht b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/reftest-toc.xht new file mode 100644 index 00000000000..078137968dd --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/reftest-toc.xht @@ -0,0 +1,54 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>CSS Pseudo-Elements Module Level 4 Test Suite Reftest Index</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Pseudo-Elements Module Level 4 Test Suite Reftest Index</h1> + <table width="100%"> + <col id="test-column"></col> + <col id="ref-column"></col> + <col id="flags-column"></col> + <thead> + <tr> + <th>Test</th> + <th>Reference</th> + <th>Flags</th> + </tr> + </thead> + <tbody id="first-letter-001" class=""> + <tr> + <td rowspan="1" title="::first-letter formatting"> + <a href="first-letter-001.xht">first-letter-001</a></td> + <td><a href="reference/first-letter-001-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="first-letter-002" class=""> + <tr> + <td rowspan="1" title="::first-letter formatting"> + <a href="first-letter-002.xht">first-letter-002</a></td> + <td><a href="reference/first-letter-001-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="first-letter-003" class=""> + <tr> + <td rowspan="1" title="::first-letter formatting"> + <a href="first-letter-003.xht">first-letter-003</a></td> + <td><a href="reference/first-letter-001-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + </table> + + </body> +</html> diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/reftest.list b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/reftest.list new file mode 100644 index 00000000000..251bbd8aa71 --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/reftest.list @@ -0,0 +1,4 @@ + +first-letter-001.xht == reference/first-letter-001-ref.xht +first-letter-002.xht == reference/first-letter-001-ref.xht +first-letter-003.xht == reference/first-letter-001-ref.xht diff --git a/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/toc.xht b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/toc.xht new file mode 100644 index 00000000000..597e02d5f5f --- /dev/null +++ b/tests/wpt/css-tests/css-pseudo-4_dev/xhtml1print/toc.xht @@ -0,0 +1,54 @@ + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>CSS Pseudo-Elements Module Level 4 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> +<body> + <h1>CSS Pseudo-Elements Module Level 4 Test Suite By Chapter</h1> + + <p>This index contains both + <a href="http://wiki.csswg.org/test/selftest">self-describing tests</a> + and reftests. + A separate <a href="reftest-toc.xht">alphabetical reftest index</a> + is provided for tests in <a href="http://wiki.csswg.org/test/reftest">reftest + format</a> along with the <a href="reftest.list">reftest manifest</a>.</p> + + <table> + <tbody id="s1"> + <tr><th><a href="chapter-1.xht">Chapter 1 - + Introduction</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s2"> + <tr><th><a href="chapter-2.xht">Chapter 2 - + Typographic Pseudo-elements</a></th> + <td>(3 Tests)</td></tr> + </tbody> + <tbody id="s3"> + <tr><th><a href="chapter-3.xht">Chapter 3 - + Highlight Pseudo-elements</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s4"> + <tr><th><a href="chapter-4.xht">Chapter 4 - + Tree-Abiding Pseudo-elements</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s5"> + <tr><th><a href="chapter-5.xht">Chapter 5 - + Overlapping Pseudo-element Interactions</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s6"> + <tr><th><a href="chapter-6.xht">Chapter 6 - + Additions to the CSS Object Model</a></th> + <td>(0 Tests)</td></tr> + </tbody> + </table> +</body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/absolute_length_units.htm b/tests/wpt/css-tests/css-values-3_dev/html/absolute_length_units.htm new file mode 100644 index 00000000000..cbf8e61bb0b --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/absolute_length_units.htm @@ -0,0 +1,77 @@ +<!DOCTYPE html> +<html><!-- Submitted from TestTWF Paris --><head> + + <title>CSS Values and Units Test: elements should be the real world size given in mm, cm, inches...</title> + <meta content="elements are not displayed with the real world size units they should be, when specified in millimeters, centimeters, inches, ..." name="assert"> + <link href="mailto:marc@bourlon.com" rel="author" title="Marc Bourlon"> + <link href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" rel="help" title="5.1.2. Viewport-percentage lengths: the 'vw', 'vh', 'vmin', 'vmax' units"> + + <style type="text/css"> + + * { margin: 0; padding: 0; font-family: Arial, Helvetica, sans-serif; font-size: 13px; } + + .s1mm { background: #F00; width: 1mm; height: 1mm; } + .s10mm { background: #66F; width: 10mm; height: 10mm; } + .s1cm { background: #E90; width: 1cm; height: 1cm; } + .s254cm { background: #D0D; width: 2.54cm; height: 2.54cm; } + .s1in { background: #00F; width: 1in; height: 1in; } + + .inline { float: left; } + + .newline { clear: left; } + + p { clear: both; margin: 10px 0; } + + </style> + +</head> +<body> + +<p> + This should be 1mm (width) by 1mm (height) size +</p> + +<div class="s1mm"></div> + +<p> + This is 10 1mm x 1mm divs, so it should be 10mm (width) by 1mm (height) size +</p> + +<div class="s1mm newline inline"></div> +<div class="s1mm inline"></div> +<div class="s1mm inline"></div> +<div class="s1mm inline"></div> +<div class="s1mm inline"></div> +<div class="s1mm inline"></div> +<div class="s1mm inline"></div> +<div class="s1mm inline"></div> +<div class="s1mm inline"></div> +<div class="s1mm inline"></div> + +<p> + This should be 10mm (width) by 10mm (height) size. +</p> + +<div class="s10mm newline "></div> + +<p> + This should be 1cm (width) by 1cm (height) size. So, same width as the line above. +</p> + +<div class="s1cm newline "></div> + +<p> + This should be 2.54cm (width) by 2.54cm (height) size. +</p> + +<div class="s254cm newline "></div> + +<p> + This should be 1in (width) by 1in (height) size. So, same size as above. +</p> + +<div class="s1in"></div> + + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/calc-background-image-gradient-1.htm b/tests/wpt/css-tests/css-values-3_dev/html/calc-background-image-gradient-1.htm new file mode 100644 index 00000000000..c45b723ca58 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/calc-background-image-gradient-1.htm @@ -0,0 +1,23 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Test: Test for calc() on background-image gradients</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help"> + <link href="reference/calc-background-image-gradient-1-ref.htm" rel="match"> + <meta content="" name="flags"> +<style type="text/css"> + +p { + height: 50px; width: 200px; + border: thin solid; +} + +#one { background-image: radial-gradient(circle farthest-side at calc(50px + 50%) calc(100% - 30px), red, green); } + +</style> +</head> +<body> +<p id="one"></p> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/calc-background-linear-gradient-1.htm b/tests/wpt/css-tests/css-values-3_dev/html/calc-background-linear-gradient-1.htm new file mode 100644 index 00000000000..a0cc6804355 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/calc-background-linear-gradient-1.htm @@ -0,0 +1,42 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Test: Support calc() on gradient stop positions</title> + <link href="https://bugzilla.mozilla.org/show_bug.cgi?id=594935" rel="author" title="Yu-Sian (Thomasy) Liu"> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help"> + <link href="reference/calc-background-linear-gradient-1-ref.htm" rel="match"> + <meta content="" name="flags"> +<style type="text/css"> +div { + width:100px; + height:100px; + background:red; + margin:5px 0 0 5px; + float:left; +} +div#one { + background: linear-gradient(lime 0px, lime calc(100% - 10px), blue calc(100% - 10px), blue 100%); +} +div#two { + background: linear-gradient(blue calc(100% - 100px) ,green calc(10% + 20px) ,red 40px ,white calc(100% - 40px) , lime 80px); +} +div#three { + background: linear-gradient(blue calc(0px) ,purple calc(20%) ,red calc(10px + 10px + 20px) ,blue calc(30% + 30px) , lime calc(180% - 100px)); +} +div#four { + background: linear-gradient(blue calc(0% + 0px) ,green calc(10% + 20px) ,red 40px ,blue calc(200% / 2 - 40px) , yellow 80px); +} +div#five { + background: linear-gradient(red calc(100% - 100px) ,green calc(10% + 20px)); +} + +</style> +</head> +<body> +<div id="one">1</div> +<div id="two">2</div> +<div id="three">3</div> +<div id="four">4</div> +<div id="five">5</div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/calc-background-position-1.htm b/tests/wpt/css-tests/css-values-3_dev/html/calc-background-position-1.htm new file mode 100644 index 00000000000..1afe1c24d36 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/calc-background-position-1.htm @@ -0,0 +1,27 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Test: Test for calc() on background-position</title> + <link href="https://bugzilla.mozilla.org/show_bug.cgi?id=594934" rel="author" title="L. David Baron"> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help"> + <link href="reference/calc-background-position-1-ref.htm" rel="match"> + <meta content="" name="flags"> +<style type="text/css"> + +p { + height: 50px; width: 200px; + border: thin solid; + background-image: url(../backgrounds/blue-32x32.png); + background-repeat: no-repeat; +} + +#one { background-position: calc(50px + 50%) calc(100% - 30px) } +#two { background-position: calc(-12.5% + 3px) calc(-10px - 50%) } + +</style> +</head> +<body> +<p id="one"></p> +<p id="two"></p> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/calc-background-size-1.htm b/tests/wpt/css-tests/css-values-3_dev/html/calc-background-size-1.htm new file mode 100644 index 00000000000..7062dbb62b5 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/calc-background-size-1.htm @@ -0,0 +1,27 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Test: Test for calc() on background-size</title> + <link href="https://bugzilla.mozilla.org/show_bug.cgi?id=594934" rel="author" title="L. David Baron"> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help"> + <link href="reference/calc-background-size-1-ref.htm" rel="match"> + <meta content="" name="flags"> +<style type="text/css"> + +p { + height: 50px; width: 200px; + border: thin solid; + background-image: url(../backgrounds/blue-32x32.png); + background-repeat: no-repeat; +} + +#one { background-size: calc(50px + 50%) calc(100% - 30px) } +#two { background-size: calc(50px + 50%) calc(10px - 50%) } + +</style> +</head> +<body> +<p id="one"></p> +<p id="two"></p> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/calc-border-radius-1.htm b/tests/wpt/css-tests/css-values-3_dev/html/calc-border-radius-1.htm new file mode 100644 index 00000000000..b5ea5550465 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/calc-border-radius-1.htm @@ -0,0 +1,33 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Test: test for border-radius: calc()</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help"> + <link href="reference/calc-border-radius-1-ref.htm" rel="match"> + <meta content="" name="flags"> +<style type="text/css"> + +p { + /* We use powers of two here to avoid floating-point issues. + See bug 590181. */ + + height: 256px; + width: 512px; + background: blue; + border-radius: calc((1/32 * 100%) + 5px) + calc((1/64 * 100%) - 2px) + calc(10px + (1/256 * 100%)) + calc((1/16 * 100%) - 3px) / + calc((1/32 * 100%) - (1px + (1/128 * 100%))) + calc(1/16 * 100%) + calc(10px) + 3px; +} + +</style> +</head> +<body> +<p></p> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/calc-height-block-1.htm b/tests/wpt/css-tests/css-values-3_dev/html/calc-height-block-1.htm new file mode 100644 index 00000000000..1b99d74b1b9 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/calc-height-block-1.htm @@ -0,0 +1,36 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Test: Test for height:calc() on blocks</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help"> + <link href="reference/calc-height-block-1-ref.htm" rel="match"> + <meta content="" name="flags"> +<style type="text/css"> +body { margin: 0 } +body > div { float: left; height: 100px; width: 1px; } +body > div > div { background: blue } + +/* for auto-height tests */ +body > div > div > div > div { height: 10px } +</style> +</head> +<body> + +<!-- tests with a fixed-height container --> +<div><div style="height: calc(50px)"></div></div> +<div><div style="height: calc(50%)"></div></div> +<div><div style="height: calc(25px + 50%)"></div></div> +<div><div style="height: calc(150% / 2 - 30px)"></div></div> +<div><div style="height: calc(40px + 10% - 20% / 2)"></div></div> +<div><div style="height: calc(40px - 10%)"></div></div> + +<!-- tests with an auto-height container --> +<div><div><div style="height: calc(50px)"><div></div></div></div></div> +<div><div><div style="height: calc(50%)"><div></div></div></div></div> +<div><div><div style="height: calc(25px + 50%)"><div></div></div></div></div> +<div><div><div style="height: calc(150% / 2 - 30px)"><div></div></div></div></div> +<div><div><div style="height: calc(40px + 10% - 20% / 2)"><div></div></div></div></div> +<div><div><div style="height: calc(40px - 10%)"><div></div></div></div></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/calc-height-table-1.htm b/tests/wpt/css-tests/css-values-3_dev/html/calc-height-table-1.htm new file mode 100644 index 00000000000..1117ca08026 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/calc-height-table-1.htm @@ -0,0 +1,31 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Test: Test that height:calc() with no percentages has an effect on inner table elements</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help"> + <link href="reference/calc-height-table-1-ref.htm" rel="match"> + <meta content="" name="flags"> +<style type="text/css"> +tbody, tr, td { + height: calc(500px); + min-height: calc(700px); + max-height: calc(2px); +} +</style> +</head> +<body> +<table border=""> + <tbody> + <tr> + <td>cell</td> + <td>cell</td> + </tr> + <tr> + <td>cell</td> + <td>cell</td> + </tr> + </tbody> +</table> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/calc-margin-block-1.htm b/tests/wpt/css-tests/css-values-3_dev/html/calc-margin-block-1.htm new file mode 100644 index 00000000000..abced49291d --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/calc-margin-block-1.htm @@ -0,0 +1,24 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Test: Test of margin-*: calc()</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help"> + <link href="reference/calc-margin-block-1-ref.htm" rel="match"> + <meta content="" name="flags"> +<style type="text/css"> + +div { border: medium solid green; width: 500px } +p { background: yellow } + +</style> +</head> +<body> + +<div><p style="margin: calc(10px + 1%) 0 0 0">paragraph with margin</p></div> +<div><p style="margin: 0 calc(10px + 1%) 0 0">paragraph with margin</p></div> +<div><p style="margin: 0 0 calc(10px + 1%) 0">paragraph with margin</p></div> +<div><p style="margin: 0 0 0 calc(10px + 1%)">paragraph with margin</p></div> +<div><p style="margin: calc(30px - 1%)">paragraph with margin</p></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/calc-max-height-block-1.htm b/tests/wpt/css-tests/css-values-3_dev/html/calc-max-height-block-1.htm new file mode 100644 index 00000000000..5f1d9788853 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/calc-max-height-block-1.htm @@ -0,0 +1,36 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Test: Test for max-height:calc() on blocks</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help"> + <link href="reference/calc-max-height-block-1-ref.htm" rel="match"> + <meta content="" name="flags"> +<style type="text/css"> +body { margin: 0 } +body > div { float: left; height: 100px; width: 1px; } +body > div > div { background: blue } + +/* to give the max-height something to restrict */ +span { display: block; height: 300px } +</style> +</head> +<body> + +<!-- tests with a fixed-height container --> +<div><div style="max-height: calc(50px)"><span></span></div></div> +<div><div style="max-height: calc(50%)"><span></span></div></div> +<div><div style="max-height: calc(25px + 50%)"><span></span></div></div> +<div><div style="max-height: calc(150% / 2 - 30px)"><span></span></div></div> +<div><div style="max-height: calc(40px + 10% - 20% / 2)"><span></span></div></div> +<div><div style="max-height: calc(40px - 10%)"><span></span></div></div> + +<!-- tests with an auto-height container --> +<div><div><div style="max-height: calc(50px)"><span></span></div></div></div> +<div><div><div style="max-height: calc(50%)"><span></span></div></div></div> +<div><div><div style="max-height: calc(25px + 50%)"><span></span></div></div></div> +<div><div><div style="max-height: calc(150% / 2 - 30px)"><span></span></div></div></div> +<div><div><div style="max-height: calc(40px + 10% - 20% / 2)"><span></span></div></div></div> +<div><div><div style="max-height: calc(40px - 10%)"><span></span></div></div></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/calc-max-width-block-1.htm b/tests/wpt/css-tests/css-values-3_dev/html/calc-max-width-block-1.htm new file mode 100644 index 00000000000..7f3d64adb4e --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/calc-max-width-block-1.htm @@ -0,0 +1,26 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Test: max-width: calc() on blocks</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help"> + <link href="reference/calc-width-block-1-ref.htm" rel="match"> + <meta content="" name="flags"> +<style type="text/css"> + +body { width: 500px } +p { background: green; color: white; margin: 1px 0; font-size: 10px; width: 1000px; } + +</style> +</head> +<body> + +<p style="max-width: calc(50% - 3px)">50% - 3px</p> +<p style="max-width: calc(25% - 3px + 25%)">25% - 3px + 25%</p> +<p style="max-width: calc(25% - 3px + 12.5% * 2)">25% - 3px + 12.5% * 2</p> +<p style="max-width: calc(25% - 3px + 12.5%*2)">25% - 3px + 12.5%*2</p> +<p style="max-width: calc(25% - 3px + 2*12.5%)">25% - 3px + 2*12.5%</p> +<p style="max-width: calc(25% - 3px + 2 * 12.5%)">25% - 3px + 2 * 12.5%</p> +<p style="max-width: calc(30% + 20%)">30% + 20%</p> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/calc-max-width-block-intrinsic-1.htm b/tests/wpt/css-tests/css-values-3_dev/html/calc-max-width-block-intrinsic-1.htm new file mode 100644 index 00000000000..101088c0d0e --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/calc-max-width-block-intrinsic-1.htm @@ -0,0 +1,28 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Test: intrinsic width of max-width: calc() on blocks</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help"> + <link href="reference/calc-max-width-block-intrinsic-1-ref.htm" rel="match"> + <meta content="" name="flags"> +<style type="text/css"> + +body { font-size: 10px } +body > div { float: left; clear: left; + margin: 0 0 1px 0; background: blue; color: white; height: 5px } +body > div > div { width: 400px } +body > div > div > div { width: 200px } + +</style> +</head> +<body> + +<div><div style="max-width: calc(50% - 3px)"><div></div></div></div> +<div><div style="max-width: calc(5em - 3px)"><div></div></div></div> +<div><div style="max-width: calc(5em - 0%)"><div></div></div></div> +<div><div style="max-width: calc(50%)"><div></div></div></div> +<div><div style="max-width: calc(50px)"><div></div></div></div> +<div><div style="max-width: calc(25% + 25%)"><div></div></div></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/calc-min-height-block-1.htm b/tests/wpt/css-tests/css-values-3_dev/html/calc-min-height-block-1.htm new file mode 100644 index 00000000000..aca672e860b --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/calc-min-height-block-1.htm @@ -0,0 +1,36 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Test: Test for min-height:calc() on blocks</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help"> + <link href="reference/calc-height-block-1-ref.htm" rel="match"> + <meta content="" name="flags"> +<style type="text/css"> +body { margin: 0 } +body > div { float: left; height: 100px; width: 1px; } +body > div > div { background: blue } + +/* for auto-height tests */ +body > div > div > div > div { height: 10px } +</style> +</head> +<body> + +<!-- tests with a fixed-height container --> +<div><div style="min-height: calc(50px)"></div></div> +<div><div style="min-height: calc(50%)"></div></div> +<div><div style="min-height: calc(25px + 50%)"></div></div> +<div><div style="min-height: calc(150% / 2 - 30px)"></div></div> +<div><div style="min-height: calc(40px + 10% - 20% / 2)"></div></div> +<div><div style="min-height: calc(40px - 10%)"></div></div> + +<!-- tests with an auto-height container --> +<div><div><div style="min-height: calc(50px)"><div></div></div></div></div> +<div><div><div style="min-height: calc(50%)"><div></div></div></div></div> +<div><div><div style="min-height: calc(25px + 50%)"><div></div></div></div></div> +<div><div><div style="min-height: calc(150% / 2 - 30px)"><div></div></div></div></div> +<div><div><div style="min-height: calc(40px + 10% - 20% / 2)"><div></div></div></div></div> +<div><div><div style="min-height: calc(40px - 10%)"><div></div></div></div></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/calc-min-width-block-1.htm b/tests/wpt/css-tests/css-values-3_dev/html/calc-min-width-block-1.htm new file mode 100644 index 00000000000..6876d31ce6e --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/calc-min-width-block-1.htm @@ -0,0 +1,26 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Test: min-width: calc() on blocks</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help"> + <link href="reference/calc-width-block-1-ref.htm" rel="match"> + <meta content="" name="flags"> +<style type="text/css"> + +body { width: 500px } +p { background: green; color: white; margin: 1px 0; font-size: 10px; width: 0 } + +</style> +</head> +<body> + +<p style="min-width: calc(50% - 3px)">50% - 3px</p> +<p style="min-width: calc(25% - 3px + 25%)">25% - 3px + 25%</p> +<p style="min-width: calc(25% - 3px + 12.5% * 2)">25% - 3px + 12.5% * 2</p> +<p style="min-width: calc(25% - 3px + 12.5%*2)">25% - 3px + 12.5%*2</p> +<p style="min-width: calc(25% - 3px + 2*12.5%)">25% - 3px + 2*12.5%</p> +<p style="min-width: calc(25% - 3px + 2 * 12.5%)">25% - 3px + 2 * 12.5%</p> +<p style="min-width: calc(30% + 20%)">30% + 20%</p> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/calc-min-width-block-intrinsic-1.htm b/tests/wpt/css-tests/css-values-3_dev/html/calc-min-width-block-intrinsic-1.htm new file mode 100644 index 00000000000..21dd63361b4 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/calc-min-width-block-intrinsic-1.htm @@ -0,0 +1,28 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Test: intrinsic width of min-width: calc() on blocks</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help"> + <link href="reference/calc-min-width-block-intrinsic-1-ref.htm" rel="match"> + <meta content="" name="flags"> +<style type="text/css"> + +body { font-size: 10px } +body > div { float: left; clear: left; + margin: 0 0 1px 0; background: blue; color: white; height: 5px } +body > div > div { width: 1px } +body > div > div > div { width: 200px } + +</style> +</head> +<body> + +<div><div style="min-width: calc(50% - 3px)"><div></div></div></div> +<div><div style="min-width: calc(5em - 3px)"><div></div></div></div> +<div><div style="min-width: calc(5em - 0%)"><div></div></div></div> +<div><div style="min-width: calc(50%)"><div></div></div></div> +<div><div style="min-width: calc(50px)"><div></div></div></div> +<div><div style="min-width: calc(25% + 25%)"><div></div></div></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/calc-offsets-absolute-bottom-1.htm b/tests/wpt/css-tests/css-values-3_dev/html/calc-offsets-absolute-bottom-1.htm new file mode 100644 index 00000000000..13cf902a738 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/calc-offsets-absolute-bottom-1.htm @@ -0,0 +1,34 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Test: Test for bottom:calc() on absolutely positioned elements</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help"> + <link href="reference/calc-offsets-absolute-top-1-ref.htm" rel="match"> + <meta content="" name="flags"> +<style type="text/css"> +body { margin: 0 } +body > div { float: left; margin-top: -90px; height: 100px; margin-bottom: 90px; width: 3px; position: relative } +div[style] { background: blue; position: absolute; height: 10px; width: 3px } +div.space { height: 100px } +</style> +</head> +<body> + +<!-- tests with a fixed-height container --> +<div><div style="bottom: calc(-50px)"></div></div> +<div><div style="bottom: calc(-50%)"></div></div> +<div><div style="bottom: calc(-25px - 50%)"></div></div> +<div><div style="bottom: calc(-150% / 2 + 30px)"></div></div> +<div><div style="bottom: calc(-40px - 10% + 20% / 2)"></div></div> +<div><div style="bottom: calc(-40px + 10%)"></div></div> + +<!-- tests with an auto-bottom container --> +<div><div><div style="bottom: calc(-50px)"></div><div class="space"></div></div></div> +<div><div><div style="bottom: calc(-50%)"></div><div class="space"></div></div></div> +<div><div><div style="bottom: calc(-25px - 50%)"></div><div class="space"></div></div></div> +<div><div><div style="bottom: calc(-150% / 2 + 30px)"></div><div class="space"></div></div></div> +<div><div><div style="bottom: calc(-40px - 10% + 20% / 2)"></div><div class="space"></div></div></div> +<div><div><div style="bottom: calc(-40px + 10%)"></div><div class="space"></div></div></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/calc-offsets-absolute-left-1.htm b/tests/wpt/css-tests/css-values-3_dev/html/calc-offsets-absolute-left-1.htm new file mode 100644 index 00000000000..a9ff82e42c4 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/calc-offsets-absolute-left-1.htm @@ -0,0 +1,24 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Test: Test for left:calc() on absolutely positioned elements</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help"> + <link href="reference/calc-offsets-relative-left-1-ref.htm" rel="match"> + <meta content="" name="flags"> +<style type="text/css"> +body { margin: 0 100px; width: 200px } +body > div { height: 3px; position: relative } +div[style] { background: blue; position: absolute; height: 3px; width: 100px } +</style> +</head> +<body> + +<div><div style="left: calc(50px)"></div></div> +<div><div style="left: calc(-25%)"></div></div> +<div><div style="left: calc(25px + 25%)"></div></div> +<div><div style="left: calc(-75% / 2 + 30px)"></div></div> +<div><div style="left: calc(40px + 5% - 10% / 2)"></div></div> +<div><div style="left: calc(5% - 40px)"></div></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/calc-offsets-absolute-right-1.htm b/tests/wpt/css-tests/css-values-3_dev/html/calc-offsets-absolute-right-1.htm new file mode 100644 index 00000000000..a98a753f928 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/calc-offsets-absolute-right-1.htm @@ -0,0 +1,24 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Test: Test for right:calc() on absolutely positioned elements</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help"> + <link href="reference/calc-offsets-relative-left-1-ref.htm" rel="match"> + <meta content="" name="flags"> +<style type="text/css"> +body { margin: 0; width: 200px } +body > div { height: 3px; position: relative } +div[style] { background: blue; position: absolute; height: 3px; width: 100px } +</style> +</head> +<body> + +<div><div style="right: calc(-50px)"></div></div> +<div><div style="right: calc(25%)"></div></div> +<div><div style="right: calc(-25px - 25%)"></div></div> +<div><div style="right: calc(75% / 2 - 30px)"></div></div> +<div><div style="right: calc(-40px - 5% + 10% / 2)"></div></div> +<div><div style="right: calc(-5% + 40px)"></div></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/calc-offsets-absolute-top-1.htm b/tests/wpt/css-tests/css-values-3_dev/html/calc-offsets-absolute-top-1.htm new file mode 100644 index 00000000000..beb375a8d59 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/calc-offsets-absolute-top-1.htm @@ -0,0 +1,34 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Test: Test for top:calc() on absolutely positioned elements</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help"> + <link href="reference/calc-offsets-absolute-top-1-ref.htm" rel="match"> + <meta content="" name="flags"> +<style type="text/css"> +body { margin: 0 } +body > div { float: left; height: 100px; width: 3px; position: relative } +div[style] { background: blue; position: absolute; height: 10px; width: 3px } +div.space { height: 100px } +</style> +</head> +<body> + +<!-- tests with a fixed-height container --> +<div><div style="top: calc(50px)"></div></div> +<div><div style="top: calc(50%)"></div></div> +<div><div style="top: calc(25px + 50%)"></div></div> +<div><div style="top: calc(150% / 2 - 30px)"></div></div> +<div><div style="top: calc(40px + 10% - 20% / 2)"></div></div> +<div><div style="top: calc(40px - 10%)"></div></div> + +<!-- tests with an auto-top container --> +<div><div><div style="top: calc(50px)"></div><div class="space"></div></div></div> +<div><div><div style="top: calc(50%)"></div><div class="space"></div></div></div> +<div><div><div style="top: calc(25px + 50%)"></div><div class="space"></div></div></div> +<div><div><div style="top: calc(150% / 2 - 30px)"></div><div class="space"></div></div></div> +<div><div><div style="top: calc(40px + 10% - 20% / 2)"></div><div class="space"></div></div></div> +<div><div><div style="top: calc(40px - 10%)"></div><div class="space"></div></div></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/calc-offsets-relative-bottom-1.htm b/tests/wpt/css-tests/css-values-3_dev/html/calc-offsets-relative-bottom-1.htm new file mode 100644 index 00000000000..d6612e74a1c --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/calc-offsets-relative-bottom-1.htm @@ -0,0 +1,33 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Test: Test for bottom:calc() on relatively positioned elements</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help"> + <link href="reference/calc-offsets-relative-top-1-ref.htm" rel="match"> + <meta content="" name="flags"> +<style type="text/css"> +body { margin: 0 } +body > div { float: left; height: 100px; width: 3px; } +div[style] { background: blue; position: relative; height: 10px; } +</style> +</head> +<body> + +<!-- tests with a fixed-height container --> +<div><div style="bottom: calc(-50px)"></div></div> +<div><div style="bottom: calc(-50%)"></div></div> +<div><div style="bottom: calc(-25px - 50%)"></div></div> +<div><div style="bottom: calc(-150% / 2 + 30px)"></div></div> +<div><div style="bottom: calc(-40px - 10% + 20% / 2)"></div></div> +<div><div style="bottom: calc(-40px + 10%)"></div></div> + +<!-- tests with an auto-top container --> +<div><div><div style="bottom: calc(-50px)"></div></div></div> +<div><div><div style="bottom: calc(-50%)"></div></div></div> +<div><div><div style="bottom: calc(-25px - 50%)"></div></div></div> +<div><div><div style="bottom: calc(-150% / 2 + 30px)"></div></div></div> +<div><div><div style="bottom: calc(-40px - 10% + 20% / 2)"></div></div></div> +<div><div><div style="bottom: calc(-40px + 10%)"></div></div></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/calc-offsets-relative-left-1.htm b/tests/wpt/css-tests/css-values-3_dev/html/calc-offsets-relative-left-1.htm new file mode 100644 index 00000000000..f7fc52195ef --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/calc-offsets-relative-left-1.htm @@ -0,0 +1,23 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Test: Test for left:calc() on relatively positioned elements</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help"> + <link href="reference/calc-offsets-relative-left-1-ref.htm" rel="match"> + <meta content="" name="flags"> +<style type="text/css"> +body { margin: 0 100px; width: 100px } +div[style] { background: blue; position: relative; height: 3px; } +</style> +</head> +<body> + +<div style="left: calc(50px)"></div> +<div style="left: calc(-50%)"></div> +<div style="left: calc(25px + 50%)"></div> +<div style="left: calc(-150% / 2 + 30px)"></div> +<div style="left: calc(40px + 10% - 20% / 2)"></div> +<div style="left: calc(10% - 40px)"></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/calc-offsets-relative-right-1.htm b/tests/wpt/css-tests/css-values-3_dev/html/calc-offsets-relative-right-1.htm new file mode 100644 index 00000000000..d40fef9b00f --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/calc-offsets-relative-right-1.htm @@ -0,0 +1,23 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Test: Test for right:calc() on relatively positioned elements</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help"> + <link href="reference/calc-offsets-relative-left-1-ref.htm" rel="match"> + <meta content="" name="flags"> +<style type="text/css"> +body { margin: 0 100px; width: 100px } +div[style] { background: blue; position: relative; height: 3px; } +</style> +</head> +<body> + +<div style="right: calc(-50px)"></div> +<div style="right: calc(50%)"></div> +<div style="right: calc(-25px - 50%)"></div> +<div style="right: calc(150% / 2 - 30px)"></div> +<div style="right: calc(-40px - 10% + 20% / 2)"></div> +<div style="right: calc(-10% + 40px)"></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/calc-offsets-relative-top-1.htm b/tests/wpt/css-tests/css-values-3_dev/html/calc-offsets-relative-top-1.htm new file mode 100644 index 00000000000..3c4fb0f9c51 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/calc-offsets-relative-top-1.htm @@ -0,0 +1,33 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Test: Test for top:calc() on relatively positioned elements</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help"> + <link href="reference/calc-offsets-relative-top-1-ref.htm" rel="match"> + <meta content="" name="flags"> +<style type="text/css"> +body { margin: 0 } +body > div { float: left; height: 100px; width: 3px; } +div[style] { background: blue; position: relative; height: 10px; } +</style> +</head> +<body> + +<!-- tests with a fixed-height container --> +<div><div style="top: calc(50px)"></div></div> +<div><div style="top: calc(50%)"></div></div> +<div><div style="top: calc(25px + 50%)"></div></div> +<div><div style="top: calc(150% / 2 - 30px)"></div></div> +<div><div style="top: calc(40px + 10% - 20% / 2)"></div></div> +<div><div style="top: calc(40px - 10%)"></div></div> + +<!-- tests with an auto-top container --> +<div><div><div style="top: calc(50px)"></div></div></div> +<div><div><div style="top: calc(50%)"></div></div></div> +<div><div><div style="top: calc(25px + 50%)"></div></div></div> +<div><div><div style="top: calc(150% / 2 - 30px)"></div></div></div> +<div><div><div style="top: calc(40px + 10% - 20% / 2)"></div></div></div> +<div><div><div style="top: calc(40px - 10%)"></div></div></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/calc-padding-block-1.htm b/tests/wpt/css-tests/css-values-3_dev/html/calc-padding-block-1.htm new file mode 100644 index 00000000000..3721d313fbf --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/calc-padding-block-1.htm @@ -0,0 +1,25 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Test: Test of padding-*: calc()</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help"> + <link href="reference/calc-padding-block-1-ref.htm" rel="match"> + <meta content="" name="flags"> +<style type="text/css"> + +body { width: 500px } +div { border: medium solid green } +p { background: yellow; margin: 0 } + +</style> +</head> +<body> + +<div style="padding: calc(10px + 1%) 0 0 0"><p>paragraph with padding</p></div> +<div style="padding: 0 calc(10px + 1%) 0 0"><p>paragraph with padding</p></div> +<div style="padding: 0 0 calc(10px + 1%) 0"><p>paragraph with padding</p></div> +<div style="padding: 0 0 0 calc(10px + 1%)"><p>paragraph with padding</p></div> +<div style="padding: calc(30px - 1%)"><p>paragraph with padding</p></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/calc-text-indent-1.htm b/tests/wpt/css-tests/css-values-3_dev/html/calc-text-indent-1.htm new file mode 100644 index 00000000000..024c2c13bfd --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/calc-text-indent-1.htm @@ -0,0 +1,26 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Test: text-indent: calc() on blocks</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help"> + <link href="reference/calc-text-indent-1-ref.htm" rel="match"> + <meta content="" name="flags"> +<style type="text/css"> + +body { width: 500px } +p { font-size: 10px } + +</style> +</head> +<body> + +<p style="text-indent: calc(50% - 3px)">50% - 3px</p> +<p style="text-indent: calc(25% - 3px + 25%)">25% - 3px + 25%</p> +<p style="text-indent: calc(25% - 3px + 12.5% * 2)">25% - 3px + 12.5% * 2</p> +<p style="text-indent: calc(25% - 3px + 12.5%*2)">25% - 3px + 12.5%*2</p> +<p style="text-indent: calc(25% - 3px + 2*12.5%)">25% - 3px + 2*12.5%</p> +<p style="text-indent: calc(25% - 3px + 2 * 12.5%)">25% - 3px + 2 * 12.5%</p> +<p style="text-indent: calc(30% + 20%)">30% + 20%</p> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/calc-text-indent-intrinsic-1.htm b/tests/wpt/css-tests/css-values-3_dev/html/calc-text-indent-intrinsic-1.htm new file mode 100644 index 00000000000..f06dd239147 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/calc-text-indent-intrinsic-1.htm @@ -0,0 +1,27 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Test: intrinsic width of text-indent: calc() on blocks</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help"> + <link href="reference/calc-text-indent-intrinsic-1-ref.htm" rel="match"> + <meta content="" name="flags"> +<style type="text/css"> + +body { font-size: 10px } +div { float: left; clear: left; + margin: 0 0 1px 0; background: blue; color: white; height: 5px } +span { display: inline-block; width: 10px } + +</style> +</head> +<body> + +<div style="text-indent: calc(50% - 3px)"><span></span></div> +<div style="text-indent: calc(5em - 3px)"><span></span></div> +<div style="text-indent: calc(5em - 0%)"><span></span></div> +<div style="text-indent: calc(50%)"><span></span></div> +<div style="text-indent: calc(50px)"><span></span></div> +<div style="text-indent: calc(25% + 25%)"><span></span></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/calc-transform-origin-1.htm b/tests/wpt/css-tests/css-values-3_dev/html/calc-transform-origin-1.htm new file mode 100644 index 00000000000..5fd093cf0cb --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/calc-transform-origin-1.htm @@ -0,0 +1,28 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Test: Test for calc() on transform-origin</title> + <link href="https://bugzilla.mozilla.org/show_bug.cgi?id=594934" rel="author" title="L. David Baron"> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help"> + <link href="reference/calc-transform-origin-1-ref.htm" rel="match"> + <meta content="" name="flags"> +<style type="text/css"> + +body { margin: 100px } + +p { + height: 50px; width: 200px; + background: yellow; + transform: rotate(15deg); +} + +#one { transform-origin: calc(50px + 50%) calc(100% - 30px); } +#two { transform-origin: calc(-12.5% + 3px) calc(-10px - 50%); } + +</style> +</head> +<body> +<p id="one">hello</p> +<p id="two">hello</p> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/calc-unit-analysis.htm b/tests/wpt/css-tests/css-values-3_dev/html/calc-unit-analysis.htm new file mode 100644 index 00000000000..ec29491271a --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/calc-unit-analysis.htm @@ -0,0 +1,91 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Variables Allowed Syntax</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <link href="http://mozilla.com/" rel="author" title="Mozilla Corporation"> + <link href="http://www.w3.org/TR/css3-values/#lengths" rel="help"> + <link href="http://www.w3.org/TR/css3-values/#calc-type-checking" rel="help"> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> +<style id="style"></style> +<script id="metadata_cache">/* +{ + "unitless_zero_in_calc_is_a_numeric_type_not_length": { "assert": "invalid calc expression: unitless zero in calc() is a numeric type, not length" }, + "0px_in_calc": { "assert": "invalid calc expression: 0px in calc()" }, + "addition_of_length_and_number": { "assert": "invalid calc expression: addition of length and number" }, + "addition_of_number_and_length": { "assert": "invalid calc expression: addition of number and length" }, + "subtraction_of_length_and_number": { "assert": "invalid calc expression: subtraction of length and number" }, + "subtraction_of_number_and_length": { "assert": "invalid calc expression: subtraction of number and length" }, + "multiplication_of_length_and_number": { "assert": "invalid calc expression: multiplication of length and number" }, + "multiplication_of_number_and_length": { "assert": "invalid calc expression: multiplication of number and length" }, + "multiplication_of_length_and_length": { "assert": "invalid calc expression: multiplication of length and length" } +} +*/</script> +</head> +<body onload="run()"> +<div id="log"></div> +<div id="test"></div> +<script> + +function run() { + var test_elt = document.getElementById("test"); + var test_cs = window.getComputedStyle(test_elt, ""); + + function description_to_name(description) { + return description.replace(/\W+/g, "_").replace(/^_/, "").replace(/_$/, ""); + } + + function assert_invalid_value(property, value, description) { + test(function() { + test_elt.style.setProperty(property, "inherit"); + test_elt.style.setProperty(property, value); + assert_equals(test_elt.style.getPropertyValue(property), + "inherit"); + test_elt.style.setProperty(property, value); + test_elt.style.removeProperty(property); + }, + description_to_name(description), + { assert: "invalid calc expression: " + description }); + } + + function assert_valid_value(property, value, computes_to, description) { + test(function() { + test_elt.style.setProperty(property, "inherit"); + test_elt.style.setProperty(property, value); + assert_not_equals(test_elt.style.getPropertyValue(property), + "inherit"); + assert_equals(test_cs.getPropertyValue(property), + computes_to); + test_elt.style.removeProperty(property); + }, + description_to_name(description), + { assert: "valid calc expression: " + description }); + } + + assert_invalid_value("margin-left", "calc(0)", + "unitless zero in calc() is a numeric type, not length"); + assert_valid_value("margin-left", "calc(0px)", "0px", + "0px in calc()"); + assert_invalid_value("margin-left", "calc(1px + 2)", + "addition of length and number"); + assert_invalid_value("margin-left", "calc(2 + 1px)", + "addition of number and length"); + assert_invalid_value("margin-left", "calc(1px - 2)", + "subtraction of length and number"); + assert_invalid_value("margin-left", "calc(2 - 1px)", + "subtraction of number and length"); + assert_valid_value("margin-left", "calc(2px * 2)", "4px", + "multiplication of length and number"); + assert_valid_value("margin-left", "calc(2 * 2px)", "4px", + "multiplication of number and length"); + assert_invalid_value("margin-left", "calc(2px * 1px)", + "multiplication of length and length"); + +} + +run(); + +</script> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/calc-vertical-align-1.htm b/tests/wpt/css-tests/css-values-3_dev/html/calc-vertical-align-1.htm new file mode 100644 index 00000000000..41acc3d90d1 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/calc-vertical-align-1.htm @@ -0,0 +1,20 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Test: Test for vertical-align:calc()</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help"> + <link href="reference/calc-vertical-align-1-ref.htm" rel="match"> + <meta content="" name="flags"> + +</head><body><div style="line-height: 100px; margin-top: 100px"> + <span>x</span> + <span style="vertical-align: calc(50px)">x</span> + <span style="vertical-align: calc(50%)">x</span> + <span style="vertical-align: calc(25px + 50%)">x</span> + <span style="vertical-align: calc(150% / 2 - 30px)">x</span> + <span style="vertical-align: calc(40px + 10% - 20% / 2)">x</span> + <span style="vertical-align: calc(40px - 10%)">x</span> +</div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/calc-width-block-1.htm b/tests/wpt/css-tests/css-values-3_dev/html/calc-width-block-1.htm new file mode 100644 index 00000000000..99ffea3c38f --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/calc-width-block-1.htm @@ -0,0 +1,26 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Test: width: calc() on blocks</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help"> + <link href="reference/calc-width-block-1-ref.htm" rel="match"> + <meta content="" name="flags"> +<style type="text/css"> + +body { width: 500px } +p { background: green; color: white; margin: 1px 0; font-size: 10px } + +</style> +</head> +<body> + +<p style="width: calc(50% - 3px)">50% - 3px</p> +<p style="width: calc(25% - 3px + 25%)">25% - 3px + 25%</p> +<p style="width: calc(25% - 3px + 12.5% * 2)">25% - 3px + 12.5% * 2</p> +<p style="width: calc(25% - 3px + 12.5%*2)">25% - 3px + 12.5%*2</p> +<p style="width: calc(25% - 3px + 2*12.5%)">25% - 3px + 2*12.5%</p> +<p style="width: calc(25% - 3px + 2 * 12.5%)">25% - 3px + 2 * 12.5%</p> +<p style="width: calc(30% + 20%)">30% + 20%</p> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/calc-width-block-intrinsic-1.htm b/tests/wpt/css-tests/css-values-3_dev/html/calc-width-block-intrinsic-1.htm new file mode 100644 index 00000000000..80b82d5c7e6 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/calc-width-block-intrinsic-1.htm @@ -0,0 +1,27 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Test: intrinsic width of width: calc() on blocks</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help"> + <link href="reference/calc-width-block-intrinsic-1-ref.htm" rel="match"> + <meta content="" name="flags"> +<style type="text/css"> + +body { font-size: 10px } +body > div { float: left; clear: left; + margin: 0 0 1px 0; background: blue; color: white; height: 5px } +body > div > div > div { width: 200px } + +</style> +</head> +<body> + +<div><div style="width: calc(50% - 3px)"><div></div></div></div> +<div><div style="width: calc(5em - 3px)"><div></div></div></div> +<div><div style="width: calc(5em - 0%)"><div></div></div></div> +<div><div style="width: calc(50%)"><div></div></div></div> +<div><div style="width: calc(50px)"><div></div></div></div> +<div><div style="width: calc(25% + 25%)"><div></div></div></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/calc-width-table-auto-1.htm b/tests/wpt/css-tests/css-values-3_dev/html/calc-width-table-auto-1.htm new file mode 100644 index 00000000000..9604b77f350 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/calc-width-table-auto-1.htm @@ -0,0 +1,25 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Test: width: calc() on table-layout: auto tables</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help"> + <link href="reference/calc-width-table-auto-1-ref.htm" rel="match"> + <meta content="" name="flags"> +</head><body><table border=""> + <tbody><tr> + <td style="width: calc(500px)">x</td> + <td style="width: 100px">y</td> +</tr></tbody></table> +<table border=""> + <tbody><tr> + <td style="width: calc(50%)">x</td> + <td style="width: 100px">y</td> +</tr></tbody></table> +<table border=""> + <tbody><tr> + <td style="width: calc(2 * 10% + 0.5 * 500px)">x</td> + <td style="width: 100px">y</td> +</tr></tbody></table> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/calc-width-table-fixed-1.htm b/tests/wpt/css-tests/css-values-3_dev/html/calc-width-table-fixed-1.htm new file mode 100644 index 00000000000..305591378fd --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/calc-width-table-fixed-1.htm @@ -0,0 +1,30 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Test: width: calc() on table-layout: auto tables</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help"> + <link href="reference/calc-width-table-fixed-1-ref.htm" rel="match"> + <meta content="" name="flags"> +<style type="text/css"> +table { table-layout: fixed; width: 500px; border-spacing: 0 } +</style> +</head> +<body> +<table border=""> + <tbody><tr> + <td style="width: calc(500px)">x</td> + <td style="width: 100px">y</td> +</tr></tbody></table> +<table border=""> + <tbody><tr> + <td style="width: calc(50%)">x</td> + <td style="width: 100px">y</td> +</tr></tbody></table> +<table border=""> + <tbody><tr> + <td style="width: calc(2 * 10% + 0.5 * 500px)">x</td> + <td style="width: 100px">y</td> +</tr></tbody></table> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/ch-unit-001.htm b/tests/wpt/css-tests/css-values-3_dev/html/ch-unit-001.htm new file mode 100644 index 00000000000..90aff98cc0c --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/ch-unit-001.htm @@ -0,0 +1,38 @@ +<!DOCTYPE html> +<html><head><meta charset="utf-8"> +<title>CSS Values and Units Test: support for the ch unit</title> +<link href="http://florian.rivoal.net/" rel="author" title="Florian Rivoal"> +<link href="https://drafts.csswg.org/css-values-3/#font-relative-lengths" rel="help"> +<meta content="" name="flags"> +<link href="reference/ch-unit-001-ref.htm" rel="match"> +<meta content="The ch unit is equal to the used advance measure of the 0 (ZERO, U+0030) glyph found in the font used to render it." name="assert"> +<style> +span { + background: green; + color: green; + top: 0; bottom: 0; + position: absolute; +} +div { + background: red; + color: red; + position: relative; + height: 10ch; + width: 5ch; + float: left; +} + +div + div { + width: auto; +} + +div + div span { + width: 5ch; +} +</style> +</head><body> + <p>Test passes if there is a <strong>filled green square</strong> and <strong>no red</strong>.</p> + <div><span>00000</span></div> + <div><span></span>00000</div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/chapter-1.htm b/tests/wpt/css-tests/css-values-3_dev/html/chapter-1.htm new file mode 100644 index 00000000000..69790fdaed3 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/chapter-1.htm @@ -0,0 +1,45 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>Introduction - CSS Values and Units Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Values and Units Module Level 3 CR Test Suite</h1> + <h2>Introduction (0 tests)</h2> + <table width="100%"> + <col id="test-column"> + <col id="refs-column"> + <col id="flags-column"> + <col id="info-column"> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s1">+</a> + <a href="http://www.w3.org/TR/css3-values/#intro">1 Introduction</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s1.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s1.1">+</a> + <a href="http://www.w3.org/TR/css3-values/#placement">1.1 Module Interactions</a></th></tr> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/chapter-2.htm b/tests/wpt/css-tests/css-values-3_dev/html/chapter-2.htm new file mode 100644 index 00000000000..961d9967990 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/chapter-2.htm @@ -0,0 +1,117 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>Value Definition Syntax - CSS Values and Units Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Values and Units Module Level 3 CR Test Suite</h1> + <h2>Value Definition Syntax (0 tests)</h2> + <table width="100%"> + <col id="test-column"> + <col id="refs-column"> + <col id="flags-column"> + <col id="info-column"> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2">+</a> + <a href="http://www.w3.org/TR/css3-values/#value-defs">2 Value Definition Syntax</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s2.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.1">+</a> + <a href="http://www.w3.org/TR/css3-values/#component-types">2.1 Component value types</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s2.1.#comb-comma"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.1.#example-1c610a4c"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.2">+</a> + <a href="http://www.w3.org/TR/css3-values/#component-combinators">2.2 Component value combinators</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s2.2.#comb-all"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.2.#comb-any"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.2.#comb-one"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.3">+</a> + <a href="http://www.w3.org/TR/css3-values/#component-multipliers">2.3 Component value multipliers</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s2.3.#mult-comma"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.3.#mult-num"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.3.#mult-num-range"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.3.#mult-one-plus"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.3.#mult-opt"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.3.#mult-req"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.3.#mult-zero-plus"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.4"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.4">+</a> + <a href="http://www.w3.org/TR/css3-values/#combinator-multiplier-patterns">2.4 Combinator and Multiplier Patterns</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s2.5"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.5">+</a> + <a href="http://www.w3.org/TR/css3-values/#component-whitespace">2.5 Component values and white space</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s2.6"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.6">+</a> + <a href="http://www.w3.org/TR/css3-values/#value-examples">2.6 Property value examples</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s2.6.#example-ceb46dd6"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.6.#propvalues"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/chapter-3.htm b/tests/wpt/css-tests/css-values-3_dev/html/chapter-3.htm new file mode 100644 index 00000000000..c15556695a2 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/chapter-3.htm @@ -0,0 +1,156 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>Textual Data Types - CSS Values and Units Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Values and Units Module Level 3 CR Test Suite</h1> + <h2>Textual Data Types (3 tests)</h2> + <table width="100%"> + <col id="test-column"> + <col id="refs-column"> + <col id="flags-column"> + <col id="info-column"> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3">+</a> + <a href="http://www.w3.org/TR/css3-values/#textual-values">3 Textual Data Types</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#identifier"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.1">+</a> + <a href="http://www.w3.org/TR/css3-values/#keywords">3.1 Pre-defined Keywords</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#example-fefeae88"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.1.1">+</a> + <a href="http://www.w3.org/TR/css3-values/#common-keywords">3.1.1 CSS-wide keywords: initial, inherit and unset</a></th></tr> + <!-- 3 tests --> + <tr id="multicol-inherit-002-3.1.1" class="ahem"> + <td> + <a href="multicol-inherit-002.htm">multicol-inherit-002</a></td> + <td><a href="reference/multicol-inherit-002-ref.htm">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + <td>'column-count' and inherit + <ul class="assert"> + <li>This test checks that 'column-count' can be inherited by setting it with the CSS-wide keyword 'inherit'.</li> + </ul> + </td> + </tr> + <tr id="multicol-rule-color-inherit-001-3.1.1" class="ahem"> + <td> + <a href="multicol-rule-color-inherit-001.htm">multicol-rule-color-inherit-001</a></td> + <td><a href="reference/multicol-rule-color-inherit-001-ref.htm">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + <td>column-rule-color: inherit + <ul class="assert"> + <li>This test checks that, by default, column-rule-color is the current color applying to the element unless reserved keyword 'inherit' is used in which case column-rule-color will be inherited from the parent's column-rule-color value.</li> + </ul> + </td> + </tr> + <tr id="multicol-rule-color-inherit-002-3.1.1" class="ahem"> + <td> + <a href="multicol-rule-color-inherit-002.htm">multicol-rule-color-inherit-002</a></td> + <td><a href="reference/multicol-rule-color-inherit-001-ref.htm">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + <td>column-rule-color: inherit (complex) + <ul class="assert"> + <li>This test checks that, by default, column-rule-color is the current color applying to the element.</li> + </ul> + </td> + </tr> + </tbody> + <tbody id="s3.1.1.#css_wide-keywords"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.2">+</a> + <a href="http://www.w3.org/TR/css3-values/#custom-idents">3.2 Author-defined Identifiers: the <custom-ident> type</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.2.#example-4adf48cf"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.2.#identifier-value"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.3">+</a> + <a href="http://www.w3.org/TR/css3-values/#strings">3.3 Quoted Strings: the <string> type</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.3.#example-a6100cec"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.3.#example-aecae029"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.3.#string"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.3.#string-value"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.4"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.4">+</a> + <a href="http://www.w3.org/TR/css3-values/#urls">3.4 Resource Locators: the <url> type</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.4.#example-f4b87e68"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.4.#url"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.4.#url-value"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.4.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.4.1">+</a> + <a href="http://www.w3.org/TR/css3-values/#relative-urls">3.4.1 Relative URLs</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.4.1.#example-b20bc0e0"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.4.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.4.2">+</a> + <a href="http://www.w3.org/TR/css3-values/#url-modifiers">3.4.2 URL Modifiers</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.4.2.#typedef-url-modifier"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/chapter-4.htm b/tests/wpt/css-tests/css-values-3_dev/html/chapter-4.htm new file mode 100644 index 00000000000..66005f9f62b --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/chapter-4.htm @@ -0,0 +1,117 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>Numeric Data Types - CSS Values and Units Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Values and Units Module Level 3 CR Test Suite</h1> + <h2>Numeric Data Types (3 tests)</h2> + <table width="100%"> + <col id="test-column"> + <col id="refs-column"> + <col id="flags-column"> + <col id="info-column"> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s4"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4">+</a> + <a href="http://www.w3.org/TR/css3-values/#numeric-types">4 Numeric Data Types</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s4.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4.1">+</a> + <a href="http://www.w3.org/TR/css3-values/#integers">4.1 Integers: the <integer> type</a></th></tr> + <!-- 3 tests --> + <tr id="multicol-count-non-integer-001-4.1" class="ahem invalid"> + <td> + <a href="multicol-count-non-integer-001.htm">multicol-count-non-integer-001</a></td> + <td><a href="reference/multicol-columns-invalid-001-ref.htm">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr><abbr class="invalid" title="Tests invalid CSS">Invalid</abbr></td> + <td>non-integer 'column-count' value + <ul class="assert"> + <li>This test checks that a specified real 'column-count' value is invalid and ignored.</li> + </ul> + </td> + </tr> + <tr id="multicol-count-non-integer-002-4.1" class="ahem invalid"> + <td> + <a href="multicol-count-non-integer-002.htm">multicol-count-non-integer-002</a></td> + <td><a href="reference/multicol-columns-invalid-001-ref.htm">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr><abbr class="invalid" title="Tests invalid CSS">Invalid</abbr></td> + <td>non-integer 'column-count' value + <ul class="assert"> + <li>This test checks that a specified real 'column-count' value is invalid and ignored.</li> + </ul> + </td> + </tr> + <tr id="multicol-count-non-integer-003-4.1" class="ahem invalid"> + <td> + <a href="multicol-count-non-integer-003.htm">multicol-count-non-integer-003</a></td> + <td><a href="reference/multicol-columns-invalid-001-ref.htm">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr><abbr class="invalid" title="Tests invalid CSS">Invalid</abbr></td> + <td>non-integer 'column-count' value + <ul class="assert"> + <li>This test checks that a specified real 'column-count' value is invalid and ignored.</li> + </ul> + </td> + </tr> + </tbody> + <tbody id="s4.1.#integer"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.1.#integer-value"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4.2">+</a> + <a href="http://www.w3.org/TR/css3-values/#numbers">4.2 Real Numbers: the <number> type</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s4.2.#number"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.2.#number-value"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4.3">+</a> + <a href="http://www.w3.org/TR/css3-values/#percentages">4.3 Percentages: the <percentage> type</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s4.3.#percentage"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.3.#percentage-value"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.4"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4.4">+</a> + <a href="http://www.w3.org/TR/css3-values/#dimensions">4.4 Numbers with Units: dimensions</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s4.4.#dimension"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/chapter-5.htm b/tests/wpt/css-tests/css-values-3_dev/html/chapter-5.htm new file mode 100644 index 00000000000..a4d8578a69e --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/chapter-5.htm @@ -0,0 +1,468 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>Distance Units: the <length> type - CSS Values and Units Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Values and Units Module Level 3 CR Test Suite</h1> + <h2>Distance Units: the <length> type (30 tests)</h2> + <table width="100%"> + <col id="test-column"> + <col id="refs-column"> + <col id="flags-column"> + <col id="info-column"> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s5"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s5">+</a> + <a href="http://www.w3.org/TR/css3-values/#lengths">5 Distance Units: the <length> type</a></th></tr> + <!-- 7 tests --> + <tr id="calc-unit-analysis-5" class="primary script"> + <td><strong> + <a href="calc-unit-analysis.htm">calc-unit-analysis</a></strong></td> + <td></td> + <td><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>CSS Variables Allowed Syntax + </td> + </tr> + <tr id="shape-outside-circle-002-5" class="dom script"> + <td> + <a href="shape-outside-circle-002.htm">shape-outside-circle-002</a></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>Shape Outside Circle Valid Positions + <ul class="assert"> + <li>A circle's position argument may be any of the valid combinations: [ percentage|length left|center|right ] or [ percentage|length left|center|right ] [ percentage|length top|center|bottom ] or [ left|center|right ] or [ left|center|right top|center|bottom ] or [ top|center|bottom ].</li> + </ul> + </td> + </tr> + <tr id="shape-outside-circle-004-5" class="dom script"> + <td> + <a href="shape-outside-circle-004.htm">shape-outside-circle-004</a></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>Shape Outside Circle - Position Length Units + <ul class="assert"> + <li>A circle's position arguments may in any valid &lt;length&gt; unit allowed by a &lt;position&gt; value.</li> + </ul> + </td> + </tr> + <tr id="shape-outside-ellipse-002-5" class="dom script"> + <td> + <a href="shape-outside-ellipse-002.htm">shape-outside-ellipse-002</a></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>Shape Outside Ellipse Valid Positions + <ul class="assert"> + <li>An ellipse's position argument may be any of the valid combinations: [ percentage|length left|center|right ] or [ percentage|length left|center|right ] [ percentage|length top|center|bottom ] or [ left|center|right ] or [ left|center|right top|center|bottom ] or [ top|center|bottom ].</li> + </ul> + </td> + </tr> + <tr id="shape-outside-ellipse-004-5" class="dom script"> + <td> + <a href="shape-outside-ellipse-004.htm">shape-outside-ellipse-004</a></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>Shape Outside Ellipse - Position Length Units + <ul class="assert"> + <li>An ellipse's position arguments may in any valid &lt;length&gt; unit allowed by a &lt;position&gt; value.</li> + </ul> + </td> + </tr> + <tr id="shape-outside-inset-003-5" class="dom script"> + <td> + <a href="shape-outside-inset-003.htm">shape-outside-inset-003</a></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>Shape Outside Inset Valid Round Length Units + <ul class="assert"> + <li>An inset's radial component's values can be in any length unit</li> + </ul> + </td> + </tr> + <tr id="shape-outside-polygon-004-5" class="dom script"> + <td> + <a href="shape-outside-polygon-004.htm">shape-outside-polygon-004</a></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>Shape Outside Polygon - Argument Length Units + <ul class="assert"> + <li>A polygon's veritices may in percentage or any valid &lt;length&gt; units.</li> + </ul> + </td> + </tr> + </tbody> + <tbody id="s5.#length-value"> + <!-- 1 tests --> + <tr id="min-width-001-5.#length-value" class=""> + <td> + <a href="min-width-001.htm">min-width-001</a></td> + <td><a href="ref.htm">=</a> </td> + <td></td> + <td>min-width length value approximation + <ul class="assert"> + <li>min-width length values that are too large to be supported must be clamped, rounded to infinity, or approximated, but not overflowed to a small or negative value.</li> + </ul> + </td> + </tr> + </tbody> + <tbody id="s5.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s5.1">+</a> + <a href="http://www.w3.org/TR/css3-values/#relative-lengths">5.1 Relative lengths</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s5.1.#relative-length"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.1.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s5.1.1">+</a> + <a href="http://www.w3.org/TR/css3-values/#font-relative-lengths">5.1.1 Font-relative lengths: the em, ex, ch, rem units</a></th></tr> + <!-- 1 tests --> + <tr id="ch-unit-001-5.1.1" class="primary"> + <td><strong> + <a href="ch-unit-001.htm">ch-unit-001</a></strong></td> + <td><a href="reference/ch-unit-001-ref.htm">=</a> </td> + <td></td> + <td>support for the ch unit + <ul class="assert"> + <li>The ch unit is equal to the used advance measure of the 0 (ZERO, U+0030) glyph found in the font used to render it.</li> + </ul> + </td> + </tr> + </tbody> + <tbody id="s5.1.1.#ch"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.1.1.#em"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.1.1.#ex"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.1.1.#example-14cae19d"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.1.1.#font-relative-length"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.1.1.#rem"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.1.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s5.1.2">+</a> + <a href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths">5.1.2 Viewport-percentage lengths: the vw, vh, vmin, vmax units</a></th></tr> + <!-- 21 tests --> + <tr id="absolute_length_units-5.1.2" class="primary"> + <td><strong> + <a href="absolute_length_units.htm">absolute_length_units</a></strong></td> + <td></td> + <td></td> + <td>elements should be the real world size given in mm, cm, inches... + <ul class="assert"> + <li>elements are not displayed with the real world size units they should be, when specified in millimeters, centimeters, inches, ...</li> + </ul> + </td> + </tr> + <tr id="regions-resizing-003-5.1.2" class="ahem dom http"> + <td> + <a href="regions-resizing-003.htm">regions-resizing-003</a></td> + <td><a href="reference/regions-resizing-001-ref.htm">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="http" title="Requires HTTP headers">HTTP</abbr></td> + <td>CSS Regions: resizing region that is sized using viewport units + <ul class="assert"> + <li>Test checks that resizing the viewport of a page containing a region sized using viewport units correctly relayouts the region's contents.</li> + </ul> + </td> + </tr> + <tr id="regions-resizing-007-5.1.2" class="ahem dom http"> + <td> + <a href="regions-resizing-007.htm">regions-resizing-007</a></td> + <td><a href="reference/regions-resizing-001-ref.htm">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="http" title="Requires HTTP headers">HTTP</abbr></td> + <td>CSS Regions: resizing region with percentage size inside a container that has size set in viewport units + <ul class="assert"> + <li>Test checks that resizing the viewport of a page containing a region that has a percentage size relative to a parent sized using viewport units correctly relayouts the region's contents.</li> + </ul> + </td> + </tr> + <tr id="regions-resizing-009-5.1.2" class="ahem dom http"> + <td> + <a href="regions-resizing-009.htm">regions-resizing-009</a></td> + <td><a href="reference/regions-resizing-001-ref.htm">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="http" title="Requires HTTP headers">HTTP</abbr></td> + <td>CSS Regions: resizing autosized region when content flowed in it is sized with viewport units + <ul class="assert"> + <li>Test checks that resizing the viewport of a page containing an autosized region when the content flowed in it is sized with viewport units correctly relayouts the region's contents.</li> + </ul> + </td> + </tr> + <tr id="vh-calc-support-5.1.2" class="primary"> + <td><strong> + <a href="vh-calc-support.htm">vh-calc-support</a></strong></td> + <td><a href="reference/all-green.htm">=</a> </td> + <td></td> + <td>Viewport units are supported inside calc expressions. + <ul class="assert"> + <li>Check that viewport units add correctly to pixels in calc() expressions</li> + </ul> + </td> + </tr> + <tr id="vh-calc-support-pct-5.1.2" class="primary"> + <td><strong> + <a href="vh-calc-support-pct.htm">vh-calc-support-pct</a></strong></td> + <td><a href="reference/all-green.htm">=</a> </td> + <td></td> + <td>Viewport units are supported inside calc expressions. + <ul class="assert"> + <li>Check that viewport units add correctly to percentages in calc() expressions</li> + </ul> + </td> + </tr> + <tr id="vh-em-inherit-5.1.2" class="primary"> + <td><strong> + <a href="vh-em-inherit.htm">vh-em-inherit</a></strong></td> + <td><a href="reference/all-green.htm">=</a> </td> + <td></td> + <td>0vh and 0vw are correctly treated as 0px + <ul class="assert"> + <li>0vh and 0vw are correctly treated as 0px</li> + </ul> + </td> + </tr> + <tr id="vh-inherit-5.1.2" class="primary"> + <td><strong> + <a href="vh-inherit.htm">vh-inherit</a></strong></td> + <td><a href="reference/all-green.htm">=</a> </td> + <td></td> + <td>Viewport units are inherited properly + <ul class="assert"> + <li>Viewport units are inherited properly</li> + </ul> + </td> + </tr> + <tr id="vh-interpolate-pct-5.1.2" class="primary"> + <td><strong> + <a href="vh-interpolate-pct.htm">vh-interpolate-pct</a></strong></td> + <td><a href="reference/all-green.htm">=</a> </td> + <td></td> + <td>Viewport units are interpolated correctly + <ul class="assert"> + <li>The interpolated size mid-way between 0px and 200vh is 100vh (respectively for vw)</li> + </ul> + </td> + </tr> + <tr id="vh-interpolate-px-5.1.2" class="primary"> + <td><strong> + <a href="vh-interpolate-px.htm">vh-interpolate-px</a></strong></td> + <td><a href="reference/all-green.htm">=</a> </td> + <td></td> + <td>Viewport units are interpolated correctly + <ul class="assert"> + <li>The interpolated size mid-way between 0px and 200vh is 100vh (respectively for vw)</li> + </ul> + </td> + </tr> + <tr id="vh-interpolate-vh-5.1.2" class="primary"> + <td><strong> + <a href="vh-interpolate-vh.htm">vh-interpolate-vh</a></strong></td> + <td><a href="reference/all-green.htm">=</a> </td> + <td></td> + <td>Viewport units are interpolated correctly + <ul class="assert"> + <li>The interpolated size mid-way between 75vh and 125vh is 100vh (respectively for vw)</li> + </ul> + </td> + </tr> + <tr id="vh-support-5.1.2" class="primary"> + <td><strong> + <a href="vh-support.htm">vh-support</a></strong></td> + <td><a href="reference/all-green.htm">=</a> </td> + <td></td> + <td>Viewports units are supported in sizing properties + <ul class="assert"> + <li>Viewports units are supported in sizing properties</li> + </ul> + </td> + </tr> + <tr id="vh-support-atviewport-5.1.2" class="primary"> + <td><strong> + <a href="vh-support-atviewport.htm">vh-support-atviewport</a></strong></td> + <td><a href="reference/all-green.htm">=</a> </td> + <td></td> + <td>Viewports units are supported in @viewport rules + <ul class="assert"> + <li>Viewports units are supported in @viewport rules</li> + </ul> + </td> + </tr> + <tr id="vh-support-margin-5.1.2" class="primary"> + <td><strong> + <a href="vh-support-margin.htm">vh-support-margin</a></strong></td> + <td><a href="reference/all-green.htm">=</a> </td> + <td></td> + <td>Viewports units are supported in margin properties + <ul class="assert"> + <li>Viewports units are supported in margin properties</li> + </ul> + </td> + </tr> + <tr id="vh-support-transform-origin-5.1.2" class="primary"> + <td><strong> + <a href="vh-support-transform-origin.htm">vh-support-transform-origin</a></strong></td> + <td><a href="reference/all-green.htm">=</a> </td> + <td></td> + <td>Viewports units are supported in transform properties + <ul class="assert"> + <li>Viewports units are supported in transform properties</li> + </ul> + </td> + </tr> + <tr id="vh-support-transform-translate-5.1.2" class="primary"> + <td><strong> + <a href="vh-support-transform-translate.htm">vh-support-transform-translate</a></strong></td> + <td><a href="reference/all-green.htm">=</a> </td> + <td></td> + <td>Viewports units are supported in transform properties + <ul class="assert"> + <li>Viewports units are supported in transform properties (translate)</li> + </ul> + </td> + </tr> + <tr id="vh-zero-support-5.1.2" class="primary"> + <td><strong> + <a href="vh-zero-support.htm">vh-zero-support</a></strong></td> + <td><a href="reference/all-green.htm">=</a> </td> + <td></td> + <td>0vh and 0vw are correctly treated as 0px + <ul class="assert"> + <li>0vh and 0vw are correctly treated as 0px</li> + </ul> + </td> + </tr> + <tr id="vh_not_refreshing_on_chrome-5.1.2" class="primary"> + <td><strong> + <a href="vh_not_refreshing_on_chrome.htm">vh_not_refreshing_on_chrome</a></strong></td> + <td><a href="reference/vh_not_refreshing_on_chrome-ref.htm">=</a> </td> + <td></td> + <td>vh-based dimension doesn't change when the element's other dimension doesn't change. + <ul class="assert"> + <li>vh-based dimension doesn't change when the element's other dimension doesn't change.</li> + </ul> + </td> + </tr> + <tr id="vh_not_refreshing_on_chrome_iframe-5.1.2" class="primary"> + <td><strong> + <a href="vh_not_refreshing_on_chrome_iframe.htm">vh_not_refreshing_on_chrome_iframe</a></strong></td> + <td><a href="reference/vh_not_refreshing_on_chrome-ref.htm">=</a> </td> + <td></td> + <td>vh-based dimension doesn't change when the element other dimension doesn't change. + <ul class="assert"> + <li>vh-based dimension doesn't change when the element other dimension doesn't change. Bug for Chrome 19.0.1084.56 / Mac OS X 10.6.8</li> + </ul> + </td> + </tr> + <tr id="viewport-relative-lengths-scaled-viewport-5.1.2" class="primary script"> + <td><strong> + <a href="viewport-relative-lengths-scaled-viewport.htm">viewport-relative-lengths-scaled-viewport</a></strong></td> + <td></td> + <td><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>Viewport units in scaled viewport + <ul class="assert"> + <li>viewport relative units scale with viewport.</li> + </ul> + </td> + </tr> + <tr id="viewport-units-css2-001-5.1.2" class="primary script"> + <td><strong> + <a href="viewport-units-css2-001.htm">viewport-units-css2-001</a></strong></td> + <td></td> + <td><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>Checks viewport units against CSS 2.1 properties and the CSSOM + <ul class="assert"> + <li>Testing what happens when one applies and rereads viewport unit lengths to CSS 2.1 properties that accept length values</li> + </ul> + </td> + </tr> + </tbody> + <tbody id="s5.1.2.#example-74b4de35"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.1.2.#vh"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.1.2.#viewport_percentage-lengths"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.1.2.#vmax"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.1.2.#vmin"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.1.2.#vw"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s5.2">+</a> + <a href="http://www.w3.org/TR/css3-values/#absolute-lengths">5.2 Absolute lengths: the cm, mm, q, in, pt, pc, px units</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2.#absolute-length"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2.#cm"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2.#example-42a5d4eb"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2.#in"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2.#mm"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2.#pc"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2.#physical-units"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2.#pt"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2.#px"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2.#q"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2.#reference-pixel"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2.#visual-angle-unit"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/chapter-6.htm b/tests/wpt/css-tests/css-values-3_dev/html/chapter-6.htm new file mode 100644 index 00000000000..3bbea53c601 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/chapter-6.htm @@ -0,0 +1,136 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>Other Quantities - CSS Values and Units Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Values and Units Module Level 3 CR Test Suite</h1> + <h2>Other Quantities (2 tests)</h2> + <table width="100%"> + <col id="test-column"> + <col id="refs-column"> + <col id="flags-column"> + <col id="info-column"> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s6"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6">+</a> + <a href="http://www.w3.org/TR/css3-values/#other-units">6 Other Quantities</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6.1">+</a> + <a href="http://www.w3.org/TR/css3-values/#angles">6.1 Angle Units: the <angle> type and deg, grad, rad, turn units</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#angle-value"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#bearing-angle"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#deg"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#grad"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#rad"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#turn"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6.2">+</a> + <a href="http://www.w3.org/TR/css3-values/#time">6.2 Duration Units: the <time> type and s, ms units</a></th></tr> + <!-- 2 tests --> + <tr id="transition-delay-001-6.2" class="dom script"> + <td> + <a href="transition-delay-001.htm">transition-delay-001</a></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>Parsing transition-delay + <ul class="assert"> + <li>Test checks that transition-delay values are parsed properly</li> + </ul> + </td> + </tr> + <tr id="transition-duration-001-6.2" class="dom script"> + <td> + <a href="transition-duration-001.htm">transition-duration-001</a></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>Parsing transition-duration + <ul class="assert"> + <li>Test checks that transition-duration values are parsed properly</li> + </ul> + </td> + </tr> + </tbody> + <tbody id="s6.2.#ms"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2.#s"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2.#time-value"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6.3">+</a> + <a href="http://www.w3.org/TR/css3-values/#frequency">6.3 Frequency Units: the <frequency> type and Hz, kHz units</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s6.3.#frequency-value"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.3.#hz"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.3.#khz"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.4"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6.4">+</a> + <a href="http://www.w3.org/TR/css3-values/#resolution">6.4 Resolution Units: the <resolution> type and dpi, dpcm, dppx units</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s6.4.#dpcm"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.4.#dpi"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.4.#dppx"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.4.#example-0c0bf820"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.4.#resolution-value"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/chapter-7.htm b/tests/wpt/css-tests/css-values-3_dev/html/chapter-7.htm new file mode 100644 index 00000000000..6b97c6a134c --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/chapter-7.htm @@ -0,0 +1,57 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>Data Types Defined Elsewhere - CSS Values and Units Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Values and Units Module Level 3 CR Test Suite</h1> + <h2>Data Types Defined Elsewhere (0 tests)</h2> + <table width="100%"> + <col id="test-column"> + <col id="refs-column"> + <col id="flags-column"> + <col id="info-column"> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s7"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s7">+</a> + <a href="http://www.w3.org/TR/css3-values/#defined-elsewhere">7 Data Types Defined Elsewhere</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s7.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s7.1">+</a> + <a href="http://www.w3.org/TR/css3-values/#colors">7.1 Colors: the <color> type</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s7.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s7.2">+</a> + <a href="http://www.w3.org/TR/css3-values/#images">7.2 Images: the <image> type</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s7.3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s7.3">+</a> + <a href="http://www.w3.org/TR/css3-values/#position">7.3 2D Positioning: the <position> type</a></th></tr> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/chapter-8.htm b/tests/wpt/css-tests/css-values-3_dev/html/chapter-8.htm new file mode 100644 index 00000000000..d806b4647c2 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/chapter-8.htm @@ -0,0 +1,418 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>Functional Notations - CSS Values and Units Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Values and Units Module Level 3 CR Test Suite</h1> + <h2>Functional Notations (32 tests)</h2> + <table width="100%"> + <col id="test-column"> + <col id="refs-column"> + <col id="flags-column"> + <col id="info-column"> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s8"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s8">+</a> + <a href="http://www.w3.org/TR/css3-values/#functional-notations">8 Functional Notations</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s8.#example-9de05e52"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.#functional-notation"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s8.1">+</a> + <a href="http://www.w3.org/TR/css3-values/#calc-notation">8.1 Mathematical Expressions: calc()</a></th></tr> + <!-- 31 tests --> + <tr id="calc-background-image-gradient-1-8.1" class="primary"> + <td><strong> + <a href="calc-background-image-gradient-1.htm">calc-background-image-gradient-1</a></strong></td> + <td><a href="reference/calc-background-image-gradient-1-ref.htm">=</a> </td> + <td></td> + <td>Test for calc() on background-image gradients + </td> + </tr> + <tr id="calc-background-linear-gradient-1-8.1" class="primary"> + <td><strong> + <a href="calc-background-linear-gradient-1.htm">calc-background-linear-gradient-1</a></strong></td> + <td><a href="reference/calc-background-linear-gradient-1-ref.htm">=</a> </td> + <td></td> + <td>Support calc() on gradient stop positions + </td> + </tr> + <tr id="calc-background-position-1-8.1" class="primary"> + <td><strong> + <a href="calc-background-position-1.htm">calc-background-position-1</a></strong></td> + <td><a href="reference/calc-background-position-1-ref.htm">=</a> </td> + <td></td> + <td>Test for calc() on background-position + </td> + </tr> + <tr id="calc-background-size-1-8.1" class="primary"> + <td><strong> + <a href="calc-background-size-1.htm">calc-background-size-1</a></strong></td> + <td><a href="reference/calc-background-size-1-ref.htm">=</a> </td> + <td></td> + <td>Test for calc() on background-size + </td> + </tr> + <tr id="calc-border-radius-1-8.1" class="primary"> + <td><strong> + <a href="calc-border-radius-1.htm">calc-border-radius-1</a></strong></td> + <td><a href="reference/calc-border-radius-1-ref.htm">=</a> </td> + <td></td> + <td>test for border-radius: calc() + </td> + </tr> + <tr id="calc-height-block-1-8.1" class="primary"> + <td><strong> + <a href="calc-height-block-1.htm">calc-height-block-1</a></strong></td> + <td><a href="reference/calc-height-block-1-ref.htm">=</a> </td> + <td></td> + <td>Test for height:calc() on blocks + </td> + </tr> + <tr id="calc-height-table-1-8.1" class="primary"> + <td><strong> + <a href="calc-height-table-1.htm">calc-height-table-1</a></strong></td> + <td><a href="reference/calc-height-table-1-ref.htm">=</a> </td> + <td></td> + <td>Test that height:calc() with no percentages has an effect on inner table elements + </td> + </tr> + <tr id="calc-margin-block-1-8.1" class="primary"> + <td><strong> + <a href="calc-margin-block-1.htm">calc-margin-block-1</a></strong></td> + <td><a href="reference/calc-margin-block-1-ref.htm">=</a> </td> + <td></td> + <td>Test of margin-*: calc() + </td> + </tr> + <tr id="calc-max-height-block-1-8.1" class="primary"> + <td><strong> + <a href="calc-max-height-block-1.htm">calc-max-height-block-1</a></strong></td> + <td><a href="reference/calc-max-height-block-1-ref.htm">=</a> </td> + <td></td> + <td>Test for max-height:calc() on blocks + </td> + </tr> + <tr id="calc-max-width-block-1-8.1" class="primary"> + <td><strong> + <a href="calc-max-width-block-1.htm">calc-max-width-block-1</a></strong></td> + <td><a href="reference/calc-width-block-1-ref.htm">=</a> </td> + <td></td> + <td>max-width: calc() on blocks + </td> + </tr> + <tr id="calc-max-width-block-intrinsic-1-8.1" class="primary"> + <td><strong> + <a href="calc-max-width-block-intrinsic-1.htm">calc-max-width-block-intrinsic-1</a></strong></td> + <td><a href="reference/calc-max-width-block-intrinsic-1-ref.htm">=</a> </td> + <td></td> + <td>intrinsic width of max-width: calc() on blocks + </td> + </tr> + <tr id="calc-min-height-block-1-8.1" class="primary"> + <td><strong> + <a href="calc-min-height-block-1.htm">calc-min-height-block-1</a></strong></td> + <td><a href="reference/calc-height-block-1-ref.htm">=</a> </td> + <td></td> + <td>Test for min-height:calc() on blocks + </td> + </tr> + <tr id="calc-min-width-block-1-8.1" class="primary"> + <td><strong> + <a href="calc-min-width-block-1.htm">calc-min-width-block-1</a></strong></td> + <td><a href="reference/calc-width-block-1-ref.htm">=</a> </td> + <td></td> + <td>min-width: calc() on blocks + </td> + </tr> + <tr id="calc-min-width-block-intrinsic-1-8.1" class="primary"> + <td><strong> + <a href="calc-min-width-block-intrinsic-1.htm">calc-min-width-block-intrinsic-1</a></strong></td> + <td><a href="reference/calc-min-width-block-intrinsic-1-ref.htm">=</a> </td> + <td></td> + <td>intrinsic width of min-width: calc() on blocks + </td> + </tr> + <tr id="calc-offsets-absolute-bottom-1-8.1" class="primary"> + <td><strong> + <a href="calc-offsets-absolute-bottom-1.htm">calc-offsets-absolute-bottom-1</a></strong></td> + <td><a href="reference/calc-offsets-absolute-top-1-ref.htm">=</a> </td> + <td></td> + <td>Test for bottom:calc() on absolutely positioned elements + </td> + </tr> + <tr id="calc-offsets-absolute-left-1-8.1" class="primary"> + <td><strong> + <a href="calc-offsets-absolute-left-1.htm">calc-offsets-absolute-left-1</a></strong></td> + <td><a href="reference/calc-offsets-relative-left-1-ref.htm">=</a> </td> + <td></td> + <td>Test for left:calc() on absolutely positioned elements + </td> + </tr> + <tr id="calc-offsets-absolute-right-1-8.1" class="primary"> + <td><strong> + <a href="calc-offsets-absolute-right-1.htm">calc-offsets-absolute-right-1</a></strong></td> + <td><a href="reference/calc-offsets-relative-left-1-ref.htm">=</a> </td> + <td></td> + <td>Test for right:calc() on absolutely positioned elements + </td> + </tr> + <tr id="calc-offsets-absolute-top-1-8.1" class="primary"> + <td><strong> + <a href="calc-offsets-absolute-top-1.htm">calc-offsets-absolute-top-1</a></strong></td> + <td><a href="reference/calc-offsets-absolute-top-1-ref.htm">=</a> </td> + <td></td> + <td>Test for top:calc() on absolutely positioned elements + </td> + </tr> + <tr id="calc-offsets-relative-bottom-1-8.1" class="primary"> + <td><strong> + <a href="calc-offsets-relative-bottom-1.htm">calc-offsets-relative-bottom-1</a></strong></td> + <td><a href="reference/calc-offsets-relative-top-1-ref.htm">=</a> </td> + <td></td> + <td>Test for bottom:calc() on relatively positioned elements + </td> + </tr> + <tr id="calc-offsets-relative-left-1-8.1" class="primary"> + <td><strong> + <a href="calc-offsets-relative-left-1.htm">calc-offsets-relative-left-1</a></strong></td> + <td><a href="reference/calc-offsets-relative-left-1-ref.htm">=</a> </td> + <td></td> + <td>Test for left:calc() on relatively positioned elements + </td> + </tr> + <tr id="calc-offsets-relative-right-1-8.1" class="primary"> + <td><strong> + <a href="calc-offsets-relative-right-1.htm">calc-offsets-relative-right-1</a></strong></td> + <td><a href="reference/calc-offsets-relative-left-1-ref.htm">=</a> </td> + <td></td> + <td>Test for right:calc() on relatively positioned elements + </td> + </tr> + <tr id="calc-offsets-relative-top-1-8.1" class="primary"> + <td><strong> + <a href="calc-offsets-relative-top-1.htm">calc-offsets-relative-top-1</a></strong></td> + <td><a href="reference/calc-offsets-relative-top-1-ref.htm">=</a> </td> + <td></td> + <td>Test for top:calc() on relatively positioned elements + </td> + </tr> + <tr id="calc-padding-block-1-8.1" class="primary"> + <td><strong> + <a href="calc-padding-block-1.htm">calc-padding-block-1</a></strong></td> + <td><a href="reference/calc-padding-block-1-ref.htm">=</a> </td> + <td></td> + <td>Test of padding-*: calc() + </td> + </tr> + <tr id="calc-text-indent-1-8.1" class="primary"> + <td><strong> + <a href="calc-text-indent-1.htm">calc-text-indent-1</a></strong></td> + <td><a href="reference/calc-text-indent-1-ref.htm">=</a> </td> + <td></td> + <td>text-indent: calc() on blocks + </td> + </tr> + <tr id="calc-text-indent-intrinsic-1-8.1" class="primary"> + <td><strong> + <a href="calc-text-indent-intrinsic-1.htm">calc-text-indent-intrinsic-1</a></strong></td> + <td><a href="reference/calc-text-indent-intrinsic-1-ref.htm">=</a> </td> + <td></td> + <td>intrinsic width of text-indent: calc() on blocks + </td> + </tr> + <tr id="calc-transform-origin-1-8.1" class="primary"> + <td><strong> + <a href="calc-transform-origin-1.htm">calc-transform-origin-1</a></strong></td> + <td><a href="reference/calc-transform-origin-1-ref.htm">=</a> </td> + <td></td> + <td>Test for calc() on transform-origin + </td> + </tr> + <tr id="calc-vertical-align-1-8.1" class="primary"> + <td><strong> + <a href="calc-vertical-align-1.htm">calc-vertical-align-1</a></strong></td> + <td><a href="reference/calc-vertical-align-1-ref.htm">=</a> </td> + <td></td> + <td>Test for vertical-align:calc() + </td> + </tr> + <tr id="calc-width-block-1-8.1" class="primary"> + <td><strong> + <a href="calc-width-block-1.htm">calc-width-block-1</a></strong></td> + <td><a href="reference/calc-width-block-1-ref.htm">=</a> </td> + <td></td> + <td>width: calc() on blocks + </td> + </tr> + <tr id="calc-width-block-intrinsic-1-8.1" class="primary"> + <td><strong> + <a href="calc-width-block-intrinsic-1.htm">calc-width-block-intrinsic-1</a></strong></td> + <td><a href="reference/calc-width-block-intrinsic-1-ref.htm">=</a> </td> + <td></td> + <td>intrinsic width of width: calc() on blocks + </td> + </tr> + <tr id="calc-width-table-auto-1-8.1" class="primary"> + <td><strong> + <a href="calc-width-table-auto-1.htm">calc-width-table-auto-1</a></strong></td> + <td><a href="reference/calc-width-table-auto-1-ref.htm">=</a> </td> + <td></td> + <td>width: calc() on table-layout: auto tables + </td> + </tr> + <tr id="calc-width-table-fixed-1-8.1" class="primary"> + <td><strong> + <a href="calc-width-table-fixed-1.htm">calc-width-table-fixed-1</a></strong></td> + <td><a href="reference/calc-width-table-fixed-1-ref.htm">=</a> </td> + <td></td> + <td>width: calc() on table-layout: auto tables + </td> + </tr> + </tbody> + <tbody id="s8.1.#example-0bd12a8e"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.1.#example-2b4e561f"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.1.#example-6e868f9c"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.1.#example-776de6b9"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.1.#example-f570e599"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.1.#funcdef-calc"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.1.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s8.1.1">+</a> + <a href="http://www.w3.org/TR/css3-values/#calc-syntax">8.1.1 Syntax</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s8.1.1.#typedef-calc-product"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.1.1.#typedef-calc-sum"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.1.1.#typedef-calc-value"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.1.1.#typedef-dimension"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.1.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s8.1.2">+</a> + <a href="http://www.w3.org/TR/css3-values/#calc-type-checking">8.1.2 Type Checking</a></th></tr> + <!-- 1 tests --> + <tr id="calc-unit-analysis-8.1.2" class="script"> + <td> + <a href="calc-unit-analysis.htm">calc-unit-analysis</a></td> + <td></td> + <td><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>CSS Variables Allowed Syntax + </td> + </tr> + </tbody> + <tbody id="s8.1.2.#resolved-type"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.1.3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s8.1.3">+</a> + <a href="http://www.w3.org/TR/css3-values/#calc-computed-value">8.1.3 Computed Value</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s8.1.3.#example-240b0ace"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.1.4"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s8.1.4">+</a> + <a href="http://www.w3.org/TR/css3-values/#calc-range">8.1.4 Range Checking</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s8.1.4.#example-02a3b71f"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s8.2">+</a> + <a href="http://www.w3.org/TR/css3-values/#toggle-notation">8.2 Toggling Between Values: toggle()</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s8.2.#example-17046e65"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.2.#example-349c53dd"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.2.#example-851607de"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.2.#example-9492bba0"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.2.#funcdef-toggle"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.2.#typedef-toggle-value"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s8.3">+</a> + <a href="http://www.w3.org/TR/css3-values/#attr-notation">8.3 Attribute References: attr()</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s8.3.#example-0366e27a"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.3.#example-4771a1ff"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.3.#funcdef-attr"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.3.#typedef-attr-fallback"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.3.#typedef-attr-name"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.3.#typedef-type-or-unit"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/chapter-9.htm b/tests/wpt/css-tests/css-values-3_dev/html/chapter-9.htm new file mode 100644 index 00000000000..fb3b6bd487c --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/chapter-9.htm @@ -0,0 +1,207 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>Appendix A: IANA Considerations - CSS Values and Units Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Values and Units Module Level 3 CR Test Suite</h1> + <h2>Appendix A: IANA Considerations (0 tests)</h2> + <table width="100%"> + <col id="test-column"> + <col id="refs-column"> + <col id="flags-column"> + <col id="info-column"> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s9"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s9">+</a> + <a href="http://www.w3.org/TR/css3-values/#iana">9 Appendix A: IANA Considerations</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s9.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s9.1">+</a> + <a href="http://www.w3.org/TR/css3-values/#about-invalid">9.1 Registration for the about:invalid URL scheme</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s.#abstract"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#acknowledgments"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-compositing-1"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css-animations-1"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css-backgrounds-3"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css-break-3"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css-cascade-4"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css-color-3"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css-color-4"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css-counter-styles-3"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css-fonts-3"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css-images-3"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css-overflow-3"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css-syntax-3"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css-text-3"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css-text-decor-3"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css-transitions-1"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css-ui-3"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css21"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css3-fonts"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css3-images"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css3bg"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css3cascade"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css3color"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css3namespace"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css3page"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css3syn"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-dom-ls"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-filters-1"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-mediaq"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-mediaqueries-4"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-rfc2119"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-rfc6694"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-selectors-4"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-url"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#changes"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#conformance"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#conformance-classes"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#contents"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#conventions"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#example-f839f6c8"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#experimental"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#index"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#index-defined-elsewhere"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#index-defined-here"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#informative"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#normative"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#partial"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#references"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#status"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#subtitle"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#testing"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#title"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#w3c_process_revision"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/min-width-001.htm b/tests/wpt/css-tests/css-values-3_dev/html/min-width-001.htm new file mode 100644 index 00000000000..d54e7cacbe5 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/min-width-001.htm @@ -0,0 +1,30 @@ +<!DOCTYPE html SYSTEM "about:legacy-compat"> +<html> +<head> + <meta charset="utf-8"> + <title>CSS Media Queries Test: min-width length value approximation</title> + <link rel="author" title="Chris Rebert" href="http://chrisrebert.com"> + <link rel="help" href="http://www.w3.org/TR/css3-mediaqueries/#width"> + <link rel="help" href="http://www.w3.org/TR/mediaqueries-4/#width"> + <link rel="help" href="http://www.w3.org/TR/css3-values/#length-value"> + <link rel="match" href="ref.htm"> + <meta name="flags" content=""> + <meta name="assert" content="min-width length values that are too large to be supported must be clamped, rounded to infinity, or approximated, but not overflowed to a small or negative value."> + <style> +div { + width: 100px; + height: 100px; + background-color: green; +} +@media (min-width: 9999999999px) { + div { + background-color: red; + } +} + </style> +</head> +<body> + <p>Test passes if there is a <strong>filled green square</strong> and <strong>no red</strong>.</p> + <div></div> +</body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/multicol-count-non-integer-001.htm b/tests/wpt/css-tests/css-values-3_dev/html/multicol-count-non-integer-001.htm new file mode 100644 index 00000000000..dc420869df0 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/multicol-count-non-integer-001.htm @@ -0,0 +1,45 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> +<html> + <head> + <title>CSS Multi-column Layout Test: non-integer 'column-count' value</title> + <link rel="author" title="Gรฉrard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/"> + <link rel="help" href="http://www.w3.org/TR/css3-multicol/#the-number-and-width-of-columns" title="3. The number and width of columns"> + <link rel="help" href="http://www.w3.org/TR/css3-values/#integers" title="4.1. Integers: the '<integer>' type"> + <link rel="match" href="reference/multicol-columns-invalid-001-ref.htm"> + <meta name="flags" content="ahem invalid"> + <meta name="assert" content="This test checks that a specified real 'column-count' value is invalid and ignored."> + <style type="text/css"> + div + { + background: yellow; + border: gray solid 1em; + color: black; + font: 1.25em/1 Ahem; + orphans: 1; + widows: 1; + width: 12em; + + column-count: 4; + column-count: 2.1; /* invalid; must be an integer */ + column-gap: 0; + } + + span {color: blue;} + </style> + </head> + + <body> + + <div> + bl ac + <span> + bl ue + </span> + <span> + bl ue + </span> + bl ac + </div> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/multicol-count-non-integer-002.htm b/tests/wpt/css-tests/css-values-3_dev/html/multicol-count-non-integer-002.htm new file mode 100644 index 00000000000..07ba712da9c --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/multicol-count-non-integer-002.htm @@ -0,0 +1,45 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> +<html> + <head> + <title>CSS Multi-column Layout Test: non-integer 'column-count' value</title> + <link rel="author" title="Gรฉrard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/"> + <link rel="help" href="http://www.w3.org/TR/css3-multicol/#the-number-and-width-of-columns" title="3. The number and width of columns"> + <link rel="help" href="http://www.w3.org/TR/css3-values/#integers" title="4.1. Integers: the '<integer>' type"> + <link rel="match" href="reference/multicol-columns-invalid-001-ref.htm"> + <meta name="flags" content="ahem invalid"> + <meta name="assert" content="This test checks that a specified real 'column-count' value is invalid and ignored."> + <style type="text/css"> + div + { + background: yellow; + border: gray solid 1em; + color: black; + font: 1.25em/1 Ahem; + orphans: 1; + widows: 1; + width: 12em; + + column-count: 4; + column-count: 1.9; /* invalid; must be an integer */ + column-gap: 0; + } + + span {color: blue;} + </style> + </head> + + <body> + + <div> + bl ac + <span> + bl ue + </span> + <span> + bl ue + </span> + bl ac + </div> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/multicol-count-non-integer-003.htm b/tests/wpt/css-tests/css-values-3_dev/html/multicol-count-non-integer-003.htm new file mode 100644 index 00000000000..1047b5c5b74 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/multicol-count-non-integer-003.htm @@ -0,0 +1,45 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> +<html> + <head> + <title>CSS Multi-column Layout Test: non-integer 'column-count' value</title> + <link rel="author" title="Gรฉrard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/"> + <link rel="help" href="http://www.w3.org/TR/css3-multicol/#the-number-and-width-of-columns" title="3. The number and width of columns"> + <link rel="help" href="http://www.w3.org/TR/css3-values/#integers" title="4.1. Integers: the '<integer>' type"> + <link rel="match" href="reference/multicol-columns-invalid-001-ref.htm"> + <meta name="flags" content="ahem invalid"> + <meta name="assert" content="This test checks that a specified real 'column-count' value is invalid and ignored."> + <style type="text/css"> + div + { + background: yellow; + border: gray solid 1em; + color: black; + font: 1.25em/1 Ahem; + orphans: 1; + widows: 1; + width: 12em; + + column-count: 4; + column-count: 2.0; /* invalid; must be an integer */ + column-gap: 0; + } + + span {color: blue;} + </style> + </head> + + <body> + + <div> + bl ac + <span> + bl ue + </span> + <span> + bl ue + </span> + bl ac + </div> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/multicol-inherit-002.htm b/tests/wpt/css-tests/css-values-3_dev/html/multicol-inherit-002.htm new file mode 100644 index 00000000000..f3063fb4ff0 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/multicol-inherit-002.htm @@ -0,0 +1,82 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> +<html> + <head> + <title>CSS Multi-column Layout Test: 'column-count' and inherit</title> + <link rel="author" title="Opera Software ASA" href="http://www.opera.com/"> + <link rel="reviewer" title="Gรฉrard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/"> <!-- 2013-08-08 --> + <link rel="help" href="http://www.w3.org/TR/css3-multicol/#cc" title="3.2 'column-count'"> + <link rel="help" href="http://www.w3.org/TR/css3-values/#common-keywords" title="3.1.1. CSS-wide keywords: 'initial' and 'inherit'"> + <link rel="match" href="reference/multicol-inherit-002-ref.htm"> + <meta name="flags" content="ahem"> + <meta name="assert" content="This test checks that 'column-count' can be inherited by setting it with the CSS-wide keyword 'inherit'."> + <style type="text/css"> + body > div + { + background-color: blue; + column-count: 3; + column-gap: 1em; + font: 1.25em/1 Ahem; + width: 32em; + + /* + N == 3; + + 32em + - 2em : 2 column gaps + ========== + 30em : available width of the 3 inner multi-column elements + + So, W == 10em; + + 30em + - 6em : 3 mult by 2em: horizontal margin of 3 inner multi-column elements + - 6em : 3 mult by 2em: horizontal column-gaps of all 3 inner multi-column elements + ========== + 18em : 6em for each of the 3 column boxes without their own horizontal margins + So, each column boxes of inner multi-column elements is 2em wide. + */ + } + + div + { + color: black; + margin: 1em; + orphans: 1; + widows: 1; + } + + div > div + { + background-color: yellow; + column-count: inherit; + column-gap: 1em; + } + + div > div:first-child {margin-top: 0;} + </style> + </head> + <body> + + <div> + <div> + aa aa + aa aa + aa aa + aa aa + </div> + <div> + mm mm + mm mm + mm mm + mm mm + </div> + <div> + xx xx + xx xx + xx xx + xx xx + </div> + </div> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/multicol-rule-color-inherit-001.htm b/tests/wpt/css-tests/css-values-3_dev/html/multicol-rule-color-inherit-001.htm new file mode 100644 index 00000000000..6dec53517f6 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/multicol-rule-color-inherit-001.htm @@ -0,0 +1,137 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> +<html> + <head> + <title>CSS Multi-column Layout Test: column-rule-color: inherit</title> + <link rel="author" title="Opera Software ASA" href="http://www.opera.com/"> + <link rel="reviewer" title="Gรฉrard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/"> <!-- 2013-09-02 --> + <link rel="help" href="http://www.w3.org/TR/css3-multicol/#crc" title="4.2. 'column-rule-color'"> + <link rel="help" href="http://www.w3.org/TR/css3-values/#common-keywords" title="3.1.1. CSS-wide keywords: 'initial' and 'inherit'"> + <link rel="match" href="reference/multicol-rule-color-inherit-001-ref.htm"> + <meta name="flags" content="ahem"> + <meta name="assert" content="This test checks that, by default, column-rule-color is the current color applying to the element unless reserved keyword 'inherit' is used in which case column-rule-color will be inherited from the parent's column-rule-color value."> + <style type="text/css"> + div#parent + { + column-rule-color: green; + column-rule-style: none; + font: 1.25em/1 Ahem; + width: 17em; + } + + /* + + N == 3; + + W == max(0, (available-width - ((N - 1) * column-gap)) / N); + W == max(0, (17em - ((3 - 1) * 1em)) / 3); + W == max(0, (17em - (2 * 1em)) / 3); + W == max(0, (17em - 2em) / 3); + W == max(0, 15em / 3); + W == max(0, 5em); + W == 5em; + + The height of column rule depends on number of line boxes in + each outer column box which depends on number of line boxes + in each inner column box. + + N == 3; + + W == max(0, (available-width - ((N - 1) * column-gap)) / N); + W == max(0, (5em - ((3 - 1) * 1em)) / 3); + W == max(0, (5em - (2 * 1em)) / 3); + W == max(0, (5em - 2em) / 3); + W == max(0, 3em / 3); + W == max(0, 1em); + W == 1em; + + */ + + div + { + color: red; /* both div#parent and div.child have and use 'color: red' */ + orphans: 1; + widows: 1; + + column-count: 3; + column-gap: 1em; + column-rule-width: 1em; + } + + div.child + { + column-rule-color: inherit; + column-rule-style: solid; + font-size: 1em; + } + </style> + </head> + + <body> + + <p>Test passes if there are 6 vertical green stripes and <strong>no red</strong>.</p> + + <div id="parent"> + <div class="child"> + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + </div> + <div class="child"> + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + </div> + <div class="child"> + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + </div> + </div> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/multicol-rule-color-inherit-002.htm b/tests/wpt/css-tests/css-values-3_dev/html/multicol-rule-color-inherit-002.htm new file mode 100644 index 00000000000..50405c56669 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/multicol-rule-color-inherit-002.htm @@ -0,0 +1,120 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> +<html> + <head> + <title>CSS Multi-column Layout Test: column-rule-color: inherit (complex)</title> + <link rel="author" title="Gรฉrard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/"> <!-- 2013-09-03 --> + <link rel="help" href="http://www.w3.org/TR/css3-multicol/#crc" title="4.2. 'column-rule-color'"> + <link rel="help" href="http://www.w3.org/TR/css3-values/#common-keywords" title="3.1.1. CSS-wide keywords: 'initial' and 'inherit'"> + <link rel="match" href="reference/multicol-rule-color-inherit-001-ref.htm"> + <meta name="flags" content="ahem"> + <meta name="assert" content="This test checks that, by default, column-rule-color is the current color applying to the element."> + <style type="text/css"> + div#parent + { + color: green; + font: 1.25em/1 Ahem; + } + + div.child + { + color: red; + display: inline-block; + font-size: 1em; + width: 5em; + + column-count: 3; + column-gap: 1em; + column-rule-color: inherit; + column-rule-style: solid; + column-rule-width: 1em; + } + + /* + + N == 3; + + W == max(0, (available-width - ((N - 1) * column-gap)) / N); + W == max(0, (5em - ((3 - 1) * 1em)) / 3); + W == max(0, (5em - (2 * 1em)) / 3); + W == max(0, (5em - 2em) / 3); + W == max(0, 3em / 3); + W == max(0, 1em); + W == 1em; + + */ + + </style> + </head> + + <body> + + <p>Test passes if there are 6 vertical green stripes and <strong>no red</strong>.</p> + + <div id="parent"> + <div class="child"> + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + </div> + + <div class="child"> + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + </div> + + <div class="child"> + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + </div> + + </div> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/ref.htm b/tests/wpt/css-tests/css-values-3_dev/html/ref.htm new file mode 100644 index 00000000000..ed960eb4c55 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/ref.htm @@ -0,0 +1,18 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Reftest Reference</title> + <link href="http://florian.rivoal.net/" rel="author" title="Florian Rivoal"> + <style> + div { + background-color:green; + height:100px; + width:100px; + } + </style> + </head> + <body> + <p>Test passes if there is a <strong>filled green square</strong> and <strong>no red</strong>.</p> + <div></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/all-green.htm b/tests/wpt/css-tests/css-values-3_dev/html/reference/all-green.htm new file mode 100644 index 00000000000..7d0623049ec --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/all-green.htm @@ -0,0 +1,2 @@ +<!DOCTYPE html> +<html style="background: green"><head></head><body></body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-background-image-gradient-1-ref.htm b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-background-image-gradient-1-ref.htm new file mode 100644 index 00000000000..2970d8da1d7 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-background-image-gradient-1-ref.htm @@ -0,0 +1,21 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Reference: Test for calc() on background-image gradients</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <meta content="" name="flags"> +<style type="text/css"> + +p { + height: 50px; width: 200px; + border: thin solid; +} + +#one { background-image: radial-gradient(circle farthest-side at 150px 20px, red, green); } + +</style> +</head> +<body> +<p id="one"></p> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-background-linear-gradient-1-ref.htm b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-background-linear-gradient-1-ref.htm new file mode 100644 index 00000000000..beec7912ca4 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-background-linear-gradient-1-ref.htm @@ -0,0 +1,39 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Reference: Support calc() on gradient stop positions</title> + <link href="https://bugzilla.mozilla.org/show_bug.cgi?id=594935" rel="author" title="Yu-Sian (Thomasy) Liu"> + <meta content="" name="flags"> +<style type="text/css"> +div { + width:100px; + height:100px; + background:red; + margin:5px 0 0 5px; + float:left; +} +div#one { + background: linear-gradient(lime 0px, lime 90px, blue 90px, blue 100%); +} +div#two { + background: linear-gradient(blue 0px ,green 30px ,red 40px ,white 60px , lime 80px); +} +div#three { + background: linear-gradient(blue 0px ,purple 20px ,red 40px ,blue 60px , lime 80px); +} +div#four { + background: linear-gradient(blue 0px ,green 30px ,red 40px ,blue 60px , yellow 80px); +} +div#five { + background: linear-gradient(red 0px ,green 30px); +} +</style> +</head> +<body> +<div id="one">1</div> +<div id="two">2</div> +<div id="three">3</div> +<div id="four">4</div> +<div id="five">5</div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-background-position-1-ref.htm b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-background-position-1-ref.htm new file mode 100644 index 00000000000..efad51b3ef3 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-background-position-1-ref.htm @@ -0,0 +1,25 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Reference: Test for calc() on background-position</title> + <link href="https://bugzilla.mozilla.org/show_bug.cgi?id=594934" rel="author" title="L. David Baron"> + <meta content="" name="flags"> +<style type="text/css"> + +p { + height: 50px; width: 200px; + border: thin solid; + background-image: url(../backgrounds/blue-32x32.png); + background-repeat: no-repeat; +} + +#one { background-position: 134px -12px } +#two { background-position: -18px -19px } + +</style> +</head> +<body> +<p id="one"></p> +<p id="two"></p> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-background-size-1-ref.htm b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-background-size-1-ref.htm new file mode 100644 index 00000000000..5349633dd34 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-background-size-1-ref.htm @@ -0,0 +1,25 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Reference: Test for calc() on background-size</title> + <link href="https://bugzilla.mozilla.org/show_bug.cgi?id=594934" rel="author" title="L. David Baron"> + <meta content="" name="flags"> +<style type="text/css"> + +p { + height: 50px; width: 200px; + border: thin solid; + background-image: url(../backgrounds/blue-32x32.png); + background-repeat: no-repeat; +} + +#one { background-size: 150px 20px; } +#two { background-image: none } + +</style> +</head> +<body> +<p id="one"></p> +<p id="two"></p> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-border-radius-1-ref.htm b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-border-radius-1-ref.htm new file mode 100644 index 00000000000..6412e4f54e5 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-border-radius-1-ref.htm @@ -0,0 +1,21 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Reference: test for border-radius: calc()</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <meta content="" name="flags"> +<style type="text/css"> + +p { + height: 256px; + width: 512px; + background: blue; + border-radius: 21px 6px 12px 29px / 5px 16px 10px 3px; +} + +</style> +</head> +<body> +<p></p> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-height-block-1-ref.htm b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-height-block-1-ref.htm new file mode 100644 index 00000000000..b80c5c77a8b --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-height-block-1-ref.htm @@ -0,0 +1,30 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Reference: Test for height:calc() or min-height:calc() on blocks</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <meta content="" name="flags"> +<style type="text/css"> +body { margin: 0 } +body > div { float: left; width: 1px; background: blue; } +</style> +</head> +<body> + +<!-- tests with a fixed-height container --> +<div style="height: 50px"></div> +<div style="height: 50px"></div> +<div style="height: 75px"></div> +<div style="height: 45px"></div> +<div style="height: 40px"></div> +<div style="height: 30px"></div> + +<!-- tests with an auto-height container --> +<div style="height: 50px"></div> +<div style="height: 10px"></div> +<div style="height: 10px"></div> +<div style="height: 10px"></div> +<div style="height: 10px"></div> +<div style="height: 10px"></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-height-table-1-ref.htm b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-height-table-1-ref.htm new file mode 100644 index 00000000000..742fa057ccc --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-height-table-1-ref.htm @@ -0,0 +1,29 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Reference: Test that height:calc() with no percentages has an effect on inner table elements</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <meta content="" name="flags"> +<style type="text/css"> +tbody, tr, td { + height: 500px; + min-height: 700px; + max-height: 2px; +} +</style> +</head> +<body> +<table border=""> + <tbody> + <tr> + <td>cell</td> + <td>cell</td> + </tr> + <tr> + <td>cell</td> + <td>cell</td> + </tr> + </tbody> +</table> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-margin-block-1-ref.htm b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-margin-block-1-ref.htm new file mode 100644 index 00000000000..b7ba0075fd8 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-margin-block-1-ref.htm @@ -0,0 +1,22 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Reference: Test of margin-*: calc()</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <meta content="" name="flags"> +<style type="text/css"> + +div { border: medium solid green; width: 500px } +p { background: yellow } + +</style> +</head> +<body> + +<div><p style="margin: 15px 0 0 0">paragraph with margin</p></div> +<div><p style="margin: 0 15px 0 0">paragraph with margin</p></div> +<div><p style="margin: 0 0 15px 0">paragraph with margin</p></div> +<div><p style="margin: 0 0 0 15px">paragraph with margin</p></div> +<div><p style="margin: 25px 25px 25px 25px">paragraph with margin</p></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-max-height-block-1-ref.htm b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-max-height-block-1-ref.htm new file mode 100644 index 00000000000..22ef8e87b36 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-max-height-block-1-ref.htm @@ -0,0 +1,30 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Reference: Test for max-height:calc() on blocks</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <meta content="" name="flags"> +<style type="text/css"> +body { margin: 0 } +body > div { float: left; width: 1px; background: blue; } +</style> +</head> +<body> + +<!-- tests with a fixed-height container --> +<div style="height: 50px"></div> +<div style="height: 50px"></div> +<div style="height: 75px"></div> +<div style="height: 45px"></div> +<div style="height: 40px"></div> +<div style="height: 30px"></div> + +<!-- tests with an auto-height container --> +<div style="height: 50px"></div> +<div style="height: 300px"></div> +<div style="height: 300px"></div> +<div style="height: 300px"></div> +<div style="height: 300px"></div> +<div style="height: 300px"></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-max-width-block-intrinsic-1-ref.htm b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-max-width-block-intrinsic-1-ref.htm new file mode 100644 index 00000000000..30091d121dc --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-max-width-block-intrinsic-1-ref.htm @@ -0,0 +1,22 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Reference: intrinsic width of max-width: calc() on blocks</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <meta content="" name="flags"> +<style type="text/css"> + +body > div { margin: 0 0 1px 0; background: blue; color: white; height: 5px } + +</style> +</head> +<body> + +<div style="width: 400px"></div> +<div style="width: 47px"></div> +<div style="width: 400px"></div> +<div style="width: 400px"></div> +<div style="width: 50px"></div> +<div style="width: 400px"></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-min-width-block-intrinsic-1-ref.htm b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-min-width-block-intrinsic-1-ref.htm new file mode 100644 index 00000000000..e0a6fe03156 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-min-width-block-intrinsic-1-ref.htm @@ -0,0 +1,22 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Reference: intrinsic width of min-width: calc() on blocks</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <meta content="" name="flags"> +<style type="text/css"> + +body > div { margin: 0 0 1px 0; background: blue; color: white; height: 5px } + +</style> +</head> +<body> + +<div style="width: 1px"></div> +<div style="width: 47px"></div> +<div style="width: 1px"></div> +<div style="width: 1px"></div> +<div style="width: 50px"></div> +<div style="width: 1px"></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-offsets-absolute-top-1-ref.htm b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-offsets-absolute-top-1-ref.htm new file mode 100644 index 00000000000..69506b3d946 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-offsets-absolute-top-1-ref.htm @@ -0,0 +1,31 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Reference: Test for top:calc() on absolutely positioned elements</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <meta content="" name="flags"> +<style type="text/css"> +body { margin: 0 } +body > div { float: left; height: 100px; width: 3px; } +div[style] { background: blue; position: relative; height: 10px; } +</style> +</head> +<body> + +<!-- tests with a fixed-height container --> +<div><div style="top: 50px"></div></div> +<div><div style="top: 50px"></div></div> +<div><div style="top: 75px"></div></div> +<div><div style="top: 45px"></div></div> +<div><div style="top: 40px"></div></div> +<div><div style="top: 30px"></div></div> + +<!-- tests with an auto-top container --> +<div><div style="top: 50px"></div></div> +<div><div style="top: 50px"></div></div> +<div><div style="top: 75px"></div></div> +<div><div style="top: 45px"></div></div> +<div><div style="top: 40px"></div></div> +<div><div style="top: 30px"></div></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-offsets-relative-left-1-ref.htm b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-offsets-relative-left-1-ref.htm new file mode 100644 index 00000000000..b2c96b2de0e --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-offsets-relative-left-1-ref.htm @@ -0,0 +1,21 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Reference: Test for left:calc() on relatively positioned elements</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <meta content="" name="flags"> +<style type="text/css"> +body { margin: 0 100px; width: 100px } +div[style] { background: blue; position: relative; height: 3px; } +</style> +</head> +<body> + +<div style="left: 50px"></div> +<div style="left: -50px"></div> +<div style="left: 75px"></div> +<div style="left: -45px"></div> +<div style="left: 40px"></div> +<div style="left: -30px"></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-offsets-relative-top-1-ref.htm b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-offsets-relative-top-1-ref.htm new file mode 100644 index 00000000000..4585ecbce9a --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-offsets-relative-top-1-ref.htm @@ -0,0 +1,31 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Reference: Test for top:calc() on relatively positioned elements</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <meta content="" name="flags"> +<style type="text/css"> +body { margin: 0 } +body > div { float: left; height: 100px; width: 3px; } +div[style] { background: blue; position: relative; height: 10px; } +</style> +</head> +<body> + +<!-- tests with a fixed-height container --> +<div><div style="top: 50px"></div></div> +<div><div style="top: 50px"></div></div> +<div><div style="top: 75px"></div></div> +<div><div style="top: 45px"></div></div> +<div><div style="top: 40px"></div></div> +<div><div style="top: 30px"></div></div> + +<!-- tests with an auto-top container --> +<div><div style="top: 50px"></div></div> +<div><div style="top: 0px"></div></div> +<div><div style="top: 0px"></div></div> +<div><div style="top: 0px"></div></div> +<div><div style="top: 0px"></div></div> +<div><div style="top: 0px"></div></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-padding-block-1-ref.htm b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-padding-block-1-ref.htm new file mode 100644 index 00000000000..d04c843f8b0 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-padding-block-1-ref.htm @@ -0,0 +1,23 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Reference: Test of padding-*: calc()</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <meta content="" name="flags"> +<style type="text/css"> + +body { width: 500px } +div { border: medium solid green } +p { background: yellow; margin: 0 } + +</style> +</head> +<body> + +<div style="padding: 15px 0 0 0"><p>paragraph with padding</p></div> +<div style="padding: 0 15px 0 0"><p>paragraph with padding</p></div> +<div style="padding: 0 0 15px 0"><p>paragraph with padding</p></div> +<div style="padding: 0 0 0 15px"><p>paragraph with padding</p></div> +<div style="padding: 25px 25px 25px 25px"><p>paragraph with padding</p></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-text-indent-1-ref.htm b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-text-indent-1-ref.htm new file mode 100644 index 00000000000..99f7b1d7056 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-text-indent-1-ref.htm @@ -0,0 +1,24 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Reference: text-indent: calc()</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <meta content="" name="flags"> +<style type="text/css"> + +body { width: 500px } +p { font-size: 10px } + +</style> +</head> +<body> + +<p style="text-indent: 247px">50% - 3px</p> +<p style="text-indent: 247px">25% - 3px + 25%</p> +<p style="text-indent: 247px">25% - 3px + 12.5% * 2</p> +<p style="text-indent: 247px">25% - 3px + 12.5%*2</p> +<p style="text-indent: 247px">25% - 3px + 2*12.5%</p> +<p style="text-indent: 247px">25% - 3px + 2 * 12.5%</p> +<p style="text-indent: 250px">30% + 20%</p> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-text-indent-intrinsic-1-ref.htm b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-text-indent-intrinsic-1-ref.htm new file mode 100644 index 00000000000..f04c1ead38f --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-text-indent-intrinsic-1-ref.htm @@ -0,0 +1,22 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Reference: intrinsic width of text-indent: calc() on blocks</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <meta content="" name="flags"> +<style type="text/css"> + +body > div { margin: 0 0 1px 0; background: blue; color: white; height: 5px } + +</style> +</head> +<body> + +<div style="width: 10px"></div> +<div style="width: 57px"></div> +<div style="width: 10px"></div> +<div style="width: 10px"></div> +<div style="width: 60px"></div> +<div style="width: 10px"></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-transform-origin-1-ref.htm b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-transform-origin-1-ref.htm new file mode 100644 index 00000000000..6336dffc5b1 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-transform-origin-1-ref.htm @@ -0,0 +1,26 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Reference: Test for calc() on transform-origin</title> + <link href="https://bugzilla.mozilla.org/show_bug.cgi?id=594934" rel="author" title="L. David Baron"> + <meta content="" name="flags"> +<style type="text/css"> + +body { margin: 100px } + +p { + height: 50px; width: 200px; + background: yellow; + transform: rotate(15deg); +} + +#one { transform-origin: 150px 20px; } +#two { transform-origin: -22px -35px; } + +</style> +</head> +<body> +<p id="one">hello</p> +<p id="two">hello</p> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-vertical-align-1-ref.htm b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-vertical-align-1-ref.htm new file mode 100644 index 00000000000..56abae429a3 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-vertical-align-1-ref.htm @@ -0,0 +1,18 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Reference: Test for vertical-align:calc()</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <meta content="" name="flags"> + +</head><body><div style="line-height: 100px; margin-top: 100px"> + <span>x</span> + <span style="vertical-align: 50px">x</span> + <span style="vertical-align: 50px">x</span> + <span style="vertical-align: 75px">x</span> + <span style="vertical-align: 45px">x</span> + <span style="vertical-align: 40px">x</span> + <span style="vertical-align: 30px">x</span> +</div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-width-block-1-ref.htm b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-width-block-1-ref.htm new file mode 100644 index 00000000000..2969c4036d3 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-width-block-1-ref.htm @@ -0,0 +1,24 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Reference: width: calc() and min-width: calc() on blocks</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <meta content="" name="flags"> +<style type="text/css"> + +body { width: 500px } +p { background: green; color: white; margin: 1px 0; font-size: 10px } + +</style> +</head> +<body> + +<p style="width: 247px">50% - 3px</p> +<p style="width: 247px">25% - 3px + 25%</p> +<p style="width: 247px">25% - 3px + 12.5% * 2</p> +<p style="width: 247px">25% - 3px + 12.5%*2</p> +<p style="width: 247px">25% - 3px + 2*12.5%</p> +<p style="width: 247px">25% - 3px + 2 * 12.5%</p> +<p style="width: 250px">30% + 20%</p> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-width-block-intrinsic-1-ref.htm b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-width-block-intrinsic-1-ref.htm new file mode 100644 index 00000000000..41c6d7627b9 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-width-block-intrinsic-1-ref.htm @@ -0,0 +1,22 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Reference: intrinsic width of width: calc() on blocks</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <meta content="" name="flags"> +<style type="text/css"> + +body > div { margin: 0 0 1px 0; background: blue; color: white; height: 5px } + +</style> +</head> +<body> + +<div style="width: 200px"></div> +<div style="width: 47px"></div> +<div style="width: 200px"></div> +<div style="width: 200px"></div> +<div style="width: 50px"></div> +<div style="width: 200px"></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-width-table-auto-1-ref.htm b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-width-table-auto-1-ref.htm new file mode 100644 index 00000000000..9282019418e --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-width-table-auto-1-ref.htm @@ -0,0 +1,23 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Reference: width: calc() on table-layout: auto tables</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <meta content="" name="flags"> +</head><body><table border=""> + <tbody><tr> + <td style="width: 500px">x</td> + <td style="width: 100px">y</td> +</tr></tbody></table> +<table border=""> + <tbody><tr> + <td>x</td> + <td style="width: 100px">y</td> +</tr></tbody></table> +<table border=""> + <tbody><tr> + <td>x</td> + <td style="width: 100px">y</td> +</tr></tbody></table> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-width-table-fixed-1-ref.htm b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-width-table-fixed-1-ref.htm new file mode 100644 index 00000000000..bceb564126b --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/calc-width-table-fixed-1-ref.htm @@ -0,0 +1,28 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Reference: width: calc() on table-layout: auto tables</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron"> + <meta content="" name="flags"> +<style type="text/css"> +table { table-layout: fixed; width: 500px; border-spacing: 0 } +</style> +</head> +<body> +<table border=""> + <tbody><tr> + <td style="width: 500px">x</td> + <td style="width: 100px">y</td> +</tr></tbody></table> +<table border=""> + <tbody><tr> + <td>x</td> + <td style="width: 100px">y</td> +</tr></tbody></table> +<table border=""> + <tbody><tr> + <td>x</td> + <td style="width: 100px">y</td> +</tr></tbody></table> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/ch-unit-001-ref.htm b/tests/wpt/css-tests/css-values-3_dev/html/reference/ch-unit-001-ref.htm new file mode 100644 index 00000000000..1ace5ca4b55 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/ch-unit-001-ref.htm @@ -0,0 +1,19 @@ +<!DOCTYPE html> +<html><head><meta charset="utf-8"> +<title>CSS Values and Units Test Reference File</title> +<link href="http://florian.rivoal.net/" rel="author" title="Florian Rivoal"> +<meta content="" name="flags"> +<style> +div { + background: green; + height: 10ch; + width: 10ch; + float: left; +} + +</style> +</head><body> + <p>Test passes if there is a <strong>filled green square</strong> and <strong>no red</strong>.</p> + <div></div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/multicol-columns-invalid-001-ref.htm b/tests/wpt/css-tests/css-values-3_dev/html/reference/multicol-columns-invalid-001-ref.htm new file mode 100644 index 00000000000..c5aad1a7b52 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/multicol-columns-invalid-001-ref.htm @@ -0,0 +1,32 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> +<html> + <head> + <title>CSS Reftest Reference</title> + <link rel="author" title="Opera Software ASA" href="http://www.opera.com/"> + <link rel="reviewer" title="Gรฉrard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/"> <!-- 2013-07-26 --> + <meta name="flags" content="image"> + <style type="text/css"> + table + { + background-color: yellow; + border-spacing: 0px; + border: gray solid 1em; + font: 1.25em/1 serif; + } + + td {padding: 0 1em 0 0;} + + img, td {vertical-align: top;} + </style> + </head> + <body> + <table> + <tr> + <td><img src="support/black20x20.png" width="40" height="40" alt="Image download support must be enabled"></td> + <td><img src="support/swatch-blue.png" width="40" height="40" alt="Image download support must be enabled"></td> + <td><img src="support/swatch-blue.png" width="40" height="40" alt="Image download support must be enabled"></td> + <td><img src="support/black20x20.png" width="40" height="40" alt="Image download support must be enabled"></td> + </tr> + </table> + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/multicol-inherit-002-ref.htm b/tests/wpt/css-tests/css-values-3_dev/html/reference/multicol-inherit-002-ref.htm new file mode 100644 index 00000000000..4f3dd9cd8fc --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/multicol-inherit-002-ref.htm @@ -0,0 +1,39 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> +<html> +<head> + <title>CSS Reftest Reference</title> + <link rel="author" title="Opera Software ASA" href="http://www.opera.com/"> + <link rel="reviewer" title="Gรฉrard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/"> <!-- 2013-08-08 --> + <meta name="flags" content="image"> + <style type="text/css"> + div + { + background-color: blue; + font: 1.25em/1 serif; + margin: 1em; + padding: 0em 1em 1em; + width: 30em; + } + + img {vertical-align: top;} + + img.column-gap + { + margin-left: -2em; + margin-right: 3em; + vertical-align: bottom; + } + + img#last + { + margin-left: -2em; + vertical-align: bottom; + } + </style> + </head> + <body> + + <div><img src="support/black20x20.png" width="40" height="60" alt="Image download support must be enabled"><img src="support/swatch-yellow.png" width="20" height="60" alt="Image download support must be enabled"><img src="support/black20x20.png" width="40" height="60" alt="Image download support must be enabled"><img src="support/swatch-yellow.png" width="20" height="60" alt="Image download support must be enabled"><img src="support/black20x20.png" width="40" height="40" alt="Image download support must be enabled"><img class="column-gap" src="support/swatch-yellow.png" width="40" height="20" alt="Image download support must be enabled"><img src="support/black20x20.png" width="40" height="60" alt="Image download support must be enabled"><img src="support/swatch-yellow.png" width="20" height="60" alt="Image download support must be enabled"><img src="support/black20x20.png" width="40" height="60" alt="Image download support must be enabled"><img src="support/swatch-yellow.png" width="20" height="60" alt="Image download support must be enabled"><img src="support/black20x20.png" width="40" height="40" alt="Image download support must be enabled"><img class="column-gap" src="support/swatch-yellow.png" width="40" height="20" alt="Image download support must be enabled"><img src="support/black20x20.png" width="40" height="60" alt="Image download support must be enabled"><img src="support/swatch-yellow.png" width="20" height="60" alt="Image download support must be enabled"><img src="support/black20x20.png" width="40" height="60" alt="Image download support must be enabled"><img src="support/swatch-yellow.png" width="20" height="60" alt="Image download support must be enabled"><img src="support/black20x20.png" width="40" height="40" alt="Image download support must be enabled"><img id="last" src="support/swatch-yellow.png" width="40" height="20" alt="Image download support must be enabled"></div> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/multicol-rule-color-inherit-001-ref.htm b/tests/wpt/css-tests/css-values-3_dev/html/reference/multicol-rule-color-inherit-001-ref.htm new file mode 100644 index 00000000000..5b3a38288ef --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/multicol-rule-color-inherit-001-ref.htm @@ -0,0 +1,22 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> +<html> +<head> + <title>CSS Reftest Reference</title> + <link rel="author" title="Opera Software ASA" href="http://www.opera.com/"> + <link rel="reviewer" title="Gรฉrard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/"> <!-- 2013-09-03 --> + <meta name="flags" content="image"> + <style type="text/css"> + div {font-size: 1.25em;} + img {padding-left: 1em;} + </style> + </head> + <body> + + <p>Test passes if there are 6 vertical green stripes and <strong>no red</strong>.</p> + + <div> + <img src="support/swatch-green.png" width="20" height="120" alt="Image download support must be enabled"><img src="support/swatch-green.png" width="20" height="120" alt="Image download support must be enabled"><img src="support/swatch-white.png" width="20" height="120" alt="Image download support must be enabled"><img src="support/swatch-green.png" width="20" height="120" alt="Image download support must be enabled"><img src="support/swatch-green.png" width="20" height="120" alt="Image download support must be enabled"><img src="support/swatch-white.png" width="20" height="120" alt="Image download support must be enabled"><img src="support/swatch-green.png" width="20" height="120" alt="Image download support must be enabled"><img src="support/swatch-green.png" width="20" height="120" alt="Image download support must be enabled"> + </div> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/regions-resizing-001-ref.htm b/tests/wpt/css-tests/css-values-3_dev/html/reference/regions-resizing-001-ref.htm new file mode 100644 index 00000000000..5f637e85cbb --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/regions-resizing-001-ref.htm @@ -0,0 +1,11 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Reftest Reference</title> + <link href="mailto:mibalan@adobe.com" rel="author" title="Mihai Balan"> + </head> + <body> + <p>Test passes if you see a green square below and no red.</p> + <p>The test also fails if the there's a green block that is <strong>not</strong> a square (e.g. rectangle or polygon).</p> + <iframe width="160" height="400" frameborder="0" src="../support/80px-block-ref.html"></iframe> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/1x1-green.png b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/1x1-green.png new file mode 100644 index 0000000000000000000000000000000000000000..b98ca0ba0a03c580ac339e4a3653539cfa8edc71 GIT binary patch literal 135 zcmeAS@N?(olHy`uVBq!ia0vp^j3CU&3?x-=hn)gaEa{HEjtmUzPnffIy#(@^1AIbU z85$Vo{9HN_$mQ~MaSW-rm7D-%GchneRloNK$dW8^jVKAuPb(=;EJ|f?Ovz75Rq)JB bOiv9;O-!jQJeg_(RK(!v>gTe~DWM4f4{;-! literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/1x1-lime.png b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/1x1-lime.png new file mode 100644 index 0000000000000000000000000000000000000000..cb397fb090e199c51e80e4243d1ede03a79aa8d9 GIT binary patch literal 135 zcmeAS@N?(olHy`uVBq!ia0vp^j3CU&3?x-=hn)gaEa{HEjtmUzPnffIy#(@^1AIbU z8U8bv#2r`x<Z^ksIEGZ*N=^W>nHU(Ks^9wqWJ#8|MwA5Sr<If^7Ns&crsOB3DtP85 brl$s_CZ<#to=mj?Dq`?-^>bP0l+XkK_<AEq literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/1x1-maroon.png b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/1x1-maroon.png new file mode 100644 index 0000000000000000000000000000000000000000..3f86b0721955eb4e0f014102c68c2a9764ef7593 GIT binary patch literal 109 zcmeAS@N?(olHy`uVBq!ia0vp^j3CUx1|;Q0k8}blwj^(N7lsBPi@{?l_gf&vS>O>_ v4B~>Z+sSM@AcNP_#W95AdU8fW!Vi81W){YV4{giyfD#Ozu6{1-oD!M<@rf3U literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/1x1-navy.png b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/1x1-navy.png new file mode 100644 index 0000000000000000000000000000000000000000..9b9a03955baea7abde9e056e8604e18694e49b66 GIT binary patch literal 109 zcmeAS@N?(olHy`uVBq!ia0vp^j3CUx1|;Q0k8}blwj^(N7a+~R&>-^LA|6O{7I;J! w18EO1b~~AE2W0Six;Tb#Tu)9&$oRp}z{JAX(7`d=3n;<h>FVdQ&MBb@0MNe`HUIzs literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/1x1-red.png b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/1x1-red.png new file mode 100644 index 0000000000000000000000000000000000000000..6bd73ac101874f306d007e9cea8fa3a1f62dce16 GIT binary patch literal 135 zcmeAS@N?(olHy`uVBq!ia0vp^j3CU&3?x-=hn)gaEa{HEjtmUzPnffIy#(@^1AIbU z|1&U1KH@Y7a=AQR978H@B_{ycObm=q)$jcQvLs7fBT9nv(@M${i&7aJQ}UBi6+Ckj b(^G>|6H_V+Po~-c6)||a`njxgN@xNA!@(kn literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/1x1-white.png b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/1x1-white.png new file mode 100644 index 0000000000000000000000000000000000000000..dd43faec54ae60a210f1eab6ff4e7c88b8e34c97 GIT binary patch literal 109 zcmeAS@N?(olHy`uVBq!ia0vp^j3CUx1|;Q0k8}blwj^(N7l!{JxM1({$v_d#0*}aI wAngIhZYQ(tfDB$w7sn8e>&ZX<|Nmdl!1<f`@5Sbx4?qb9Pgg&ebxsLQ020p~!2kdN literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/2-80px-block-ref.html b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/2-80px-block-ref.html new file mode 100644 index 00000000000..f616001554c --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/2-80px-block-ref.html @@ -0,0 +1,33 @@ +<!DOCTYPE html> +<html lang="en"><head> + <meta charset="UTF-8"> + <title>One region in body</title> + <style> + html, body { + margin: 0; + padding: 0; + } + .content { + margin: 10px; + font-family: Ahem; + font-size: 20px; + line-height: 1em; + color: green; + } + </style> +</head> +<body> + <div class="content"> + xxxx<br> + xxxx<br> + xxxx<br> + xxxx + </div> + <div class="content"> + xxxx<br> + xxxx<br> + xxxx<br> + xxxx + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/60x60-gg-rr.png b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/60x60-gg-rr.png new file mode 100644 index 0000000000000000000000000000000000000000..84f5b2a4f1d1865d763cac875bfa6a8c5c576c91 GIT binary patch literal 224 zcmeAS@N?(olHy`uVBq!ia0vp^HXzKw1SGf4^HT*<jKx9jP7LeL$-D$|I14-?iy0WW zg+Z8+Vb&Z8pdfpRr>`sfEmlzu3&R;K0lq*X$r9Iy66gHf+|;}h2Ir#G#FEq$h4Rdj z3<Y;j-+=H&K5?KTUr!gukc@k8FBtMN81S%c^q)Ar(pb!~&BKo6T4>(2QlSh?@M7jG eOI|GCZ+2WP<2UBa)$Kro89ZJ6T-G@yGywqpiaLV; literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/60x60-green.png b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/60x60-green.png new file mode 100644 index 0000000000000000000000000000000000000000..b3c8cf3eb4c89bd8f2d1ffde051856f375e3a3de GIT binary patch literal 218 zcmeAS@N?(olHy`uVBq!ia0vp^HXzKw1SGf4^HT*<jKx9jP7LeL$-D$|I14-?iy0WW zg+Z8+Vb&Z8pdfpRr>`sfEmlzu3yE9XPACF}BuiW)N}Tg^b5rw57@Uhz6H8K46v{J8 zG8EiBeFMT9`NV;W+&x_!Lo)8YJ?F^Fz`((>;PMkU^HzRy4~NuGe(INq1>ePjdKrGS TIXtNc8p+`4>gTe~DWM4fy9-d) literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/60x60-red.png b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/60x60-red.png new file mode 100644 index 0000000000000000000000000000000000000000..823f125b8e4a60f780f00443c9c9a10b9fa1f447 GIT binary patch literal 217 zcmeAS@N?(olHy`uVBq!ia0vp^HXzKw1SGf4^HT*<jKx9jP7LeL$-D$|I14-?iy0WW zg+Z8+Vb&Z8pdfpRr>`sfEmlzuQ<1cFzubXBk|nMYCC>S|xv6<249-QVi6yBi3gww4 z84B*6z5(HleBwYwZk{fVAsP4Ho@3->VBlchkp2JMEhm9(EUQo2%VrV@UNUpX$1;`+ Ty_~-WXd;8BtDnm{r-UW|v1>m& literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/80px-block-float-ref.html b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/80px-block-float-ref.html new file mode 100644 index 00000000000..6adeeb6fa99 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/80px-block-float-ref.html @@ -0,0 +1,27 @@ +<!DOCTYPE html> +<html lang="en"><head> + <meta charset="UTF-8"> + <title>One region in body</title> + <style> + html, body { + margin: 0; + padding: 0; + } + #content { + font-family: Ahem; + font-size: 20px; + line-height: 1em; + color: green; + float: right; + } + </style> +</head> +<body> + <div id="content"> + xxxx<br> + xxxx<br> + xxxx<br> + xxxx + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/80px-block-ref.html b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/80px-block-ref.html new file mode 100644 index 00000000000..2c910e93411 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/80px-block-ref.html @@ -0,0 +1,26 @@ +<!DOCTYPE html> +<html lang="en"><head> + <meta charset="UTF-8"> + <title>One region in body</title> + <style> + html, body { + margin: 0; + padding: 0; + } + #content { + font-family: Ahem; + font-size: 20px; + line-height: 1em; + color: green; + } + </style> +</head> +<body> + <div id="content"> + xxxx<br> + xxxx<br> + xxxx<br> + xxxx + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/README b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/README new file mode 100644 index 00000000000..69d1737bead --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/README @@ -0,0 +1,29 @@ +CSS Global Support Directory +============================ + +This directory contains common support files (such as images and external +style sheets). These are sync'ed into the support directories of all our +test suites. If you have test-suite-specific support files, please add +them to the appropriate test-suite-specific support/ directory. + +If you add to a support/ directory, please run the tools/supportprop.py +script from the top of the repository to cascade support files into the +lower-level support directories. + +Description of the Common Support File Collection +------------------------------------------------- + +The 1x1-* images are all exactly one pixel. + +The swatch-* images all use 15x15 cells. + +The square-* images all use 15x15 cells with one pixel borders. + +The pattern-* images use cells of various sizes: + + pattern-gg-gr.png 20x20 + pattern-grg-rgr-grg.png 20x20 + pattern-rgr-grg-rgr.png 20x20 + pattern-tr.png 15x15 + pattern-grg-rrg-rgg.png 15x15 + diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/a-green.css b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/a-green.css new file mode 100644 index 00000000000..b0dbb071d5b --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/a-green.css @@ -0,0 +1 @@ +.a { color: green; } diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/b-green.css b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/b-green.css new file mode 100644 index 00000000000..a0473f5ca26 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/b-green.css @@ -0,0 +1 @@ +.b { color: green; } \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/black20x20.png b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/black20x20.png new file mode 100644 index 0000000000000000000000000000000000000000..ebf7027ee785af8acf0bf6c213c616b4055ee10f GIT binary patch literal 165 zcmeAS@N?(olHy`uVBq!ia0vp^A|TAc1SFYWcSQjy#^NA%Cx&(BWL^R}oCO|{#S9F5 zM?jcysy3fAP>{XE)7O>#4vV<BhIm+`Vi!<Ivcxr_#5q4VH#M(>!MP|ku_QG`p**uB zL&4qCHz2%`PaLR7$kW9!#Nu>vf&}a01d*Pmh1?7*M;I8N6kM?a$})Jm`njxgN@xNA DYH%n_ literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/c-red.css b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/c-red.css new file mode 100644 index 00000000000..d4ba5c64e95 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/c-red.css @@ -0,0 +1 @@ +.c { color: red; } \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/cat.png b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/cat.png new file mode 100644 index 0000000000000000000000000000000000000000..85dd7324815b8f8ef1a1d0496224c1a0661db9d8 GIT binary patch literal 1883 zcmV-h2c-CkP)<h;3K|Lk000e1NJLTq003eD003hM0ssI3n4EHI0000LbVXQnLvm$d zbZKvHAXI5>WdH}z3>gRm8%$Aad;kCd2XskIMF-Ff83-yN8ye1400009a7bBm000id z000id0mpBsWB>pL*-1n}RCwC$Tnn<>HVmXZK1a^ho3&SK4-(g{9GN13#R7t8y*I%m zZ)BMw!6g9VLwR{T9*v;e^Z&9e>xbnR^*7(`)-M11{_j7xFNSfJ@$>S&(_i1@5GH@m zhpeXC{afFEKhVJCt^WWpLj3iQEg77_JYJnk79anUvL0gx`(AYZ27s0x;q_WRcJD`A zg+R7jBu}y@4l@kFdQJ7DGoh@H-xD(&>S?#kV5MJwAHN8ovs16uEnknmyyLJw3_Dz} z-2t_1y-WcyWmd+)eVZDoh>C$4rk3Oju)y$mQ#%^)+P>PB74gM`GN6$$a17nlNge7- z3RmB|dPjb|$p?mh6-(D?ThB@WuYf>+sj1twj=G%GFkj5O!mZqLtqotF8cC*N$ri;H z2HQ+$17ses$k7#RTbJz}gD2-`@wiB%W8DFRH7rLV$VR8C-{$0BU^7QA)6xcOPkeLG zIC+y8#pH<ZE4DkLuB$eJu=YD09p6saU_=3B*q=j^t+sjfsKzKVsF6<N*#6N`(<ECy zIXKz+z9s_>H3S(N>pr`5y87*;bv|b^HW*-n7#c-VH5l06wfM%K8tMv%QYu1VMJ&`q zXuT9g-DjG%ok+2IhK&G~#M;r0zu4sf-`3+KmoX<0eCv7>JZuYAQ4+JlXds3Yz$`iq zO!pQ9wr}Yor1)n9bJP~%@)tD+crwU7nJ%PeORd0)1m4F<)qG~XO2nT^iMivEf)z-D zBxjR-YQ3Q3>4*f>(%TkH;D#Ki*aVYot>nkyxLr9zV62-PtQAsVZ<)M&ROZ`q=r-yb zxV0FojhaWJa00$t-zE`xTYXArX#ra%P+dk^apt~h+vO{<A@@#@ZFd70kl?YRKP5&g zb`j&Qn9|8fN_S*$P|_f3a(aM4y>N9i$&>6i;Se`Xu#!Aka_7=8lY{bL`gE8-D*^)! zY7!?ohKiqcXDjd>0jZICXBl_KZ$6sC00LyW54V5*dj5-!>hm-t>Ht(52LoWuR*1xE z2G*{@twTZxdhmIo{825j6wMk`;$*SKGZc>R!t=-#&gkXa<yH8pw79M3dp_ikAFn&8 zlrN9ORLOJsca5=ic6o}b2pc1mIER3bjmUh7pG>kkRkQfHYSKVRo~#WuBph;XemDuD z6qUJ989evMeRwkDj)54kU$UA#IGU-IZHnWTVRA#9kA1APN3ZjwA2_hn2Ug_Nvo#=1 zvdA6|8~BUnoI@62w{|P|2@lwrchE#7bJ6Kq6kBhZllSFE87tja$&a^Vsv9DzjxZA* zQVOrQc2nyJWb8G&wn4GZFkUv;Z=ATnxIprXHN_9;9UHeyvrlY2*kxbFPXGYML&r3) zen%FSp5K}|`|V@N#w>xf>JHCqGnQ($o1mTz0Za^NSrBZ!onF6dnw<3&y(VH1bndXf z391*{FlywkRueb2`q*Y`c5i|#c-`R1y$R0#>_jShsA?F))d087sWd*L&RJQPVgO6z zuKDv)`2I=hc!ut73ss<T4Sc(1p2frAo70eTGSQX~W-TmJr(%YaR!iQ`4Ur=@=?jjU zfTygMe0q~vry0lFm|`8tJ+roq*(WDI6R9%w#!|-Y#%eR(ke!N@^4>>?(GbUMv>AFu zU<y*Z1YJ38rx1Sr_(M)_9Tc=-h}Yr*n2uA=E}I+loFj7auyHJrfHI|Po@I%y`4tj7 zZ|2XgMqBeQS(s^b?xD;O6`XX77pU2u-JQEex9#}uQe_K^?kYOxRi<VJVwG%9W16&C zB}3F3+z%GVHY()dth0|pcjvht>SWGaq^ijA)f<0KH8%k6{9y7l%|MvpgU?6jsh(M$ z5N*sz^783ghS!jcq!BDms81L*G}VLWyHB!u>=8qC&htH>PmP{A<v#~L#&MqpRv4yG zw4r_l@+VBe#^s0kwg9GF@{ms(MG=X;Z*q>HB})c5>>6kFjvP9zMaPHfq~YhEr7DrH zD;~lup<3-juf%_Prr9Z-V4nORxcT&~FF{{2Nk&bqG}pd>$n(1*n4sj(w0;RH6sT{j zbhUJqyjT6iN>h5jrHP`lGXxi;LI(=%bR`2^fsT95-&yGjH)}sb@TGCA(mUti&QX<4 z{U$^U=I18hwKL%pN^cWLwM6MtTI+-Up~5fcjt@Bxe*M77{d?${Py^67eTt4eFFZ)l zh8I~nmB}UQ_u%EtP`CsPA88ZuaO!(Y>9V^z>txmUh$SjH&7r>5XT86X<2m!DSg2-= z-<rS@<i5Y4N=-ro_(K1~{gF<l7M3R7QZPDFa>~W*e9lSUNASn#NOM-@)>-Im^e@d- V<q-+yJ<<RG002ovPDHLkV1mLWjBEe^ literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/generalParallelTest.js b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/generalParallelTest.js new file mode 100644 index 00000000000..1a4bf343df0 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/generalParallelTest.js @@ -0,0 +1,231 @@ +(function(root) { +'use strict'; +// +var index = 0; +var suite = root.generalParallelTest = { + // prepare individual test + setup: function(data, options) { + suite._setupDom(data, options); + suite._setupEvents(data, options); + }, + // clone fixture and prepare data containers + _setupDom: function(data, options) { + // clone fixture into off-viewport test-canvas + data.fixture = document.getElementById('fixture').cloneNode(true); + data.fixture.id = 'test-' + (index++); + (document.getElementById('offscreen') || document.body).appendChild(data.fixture); + + // data container for #fixture > .container > .transition + data.transition = { + node: data.fixture.querySelector('.transition'), + values: [], + events: [], + computedStyle: function(property) { + return computedStyle(data.transition.node, property); + } + }; + + // data container for #fixture > .container + data.container = { + node: data.transition.node.parentNode, + values: [], + events: [], + computedStyle: function(property) { + return computedStyle(data.container.node, property); + } + }; + + // data container for #fixture > .container > .transition[:before | :after] + if (data.pseudo) { + data.pseudo = { + name: data.pseudo, + values: [], + computedStyle: function(property) { + return computedStyle(data.transition.node, property, ':' + data.pseudo.name); + } + }; + } + }, + // bind TransitionEnd event listeners + _setupEvents: function(data, options) { + ['transition', 'container'].forEach(function(elem) { + var handler = function(event) { + event.stopPropagation(); + var name = event.propertyName; + var time = Math.round(event.elapsedTime * 1000) / 1000; + var pseudo = event.pseudoElement ? (':' + event.pseudoElement) : ''; + data[elem].events.push(name + pseudo + ":" + time + "s"); + }; + data[elem].node.addEventListener('transitionend', handler, false); + data[elem]._events = {'transitionend': handler}; + }); + }, + // cleanup after individual test + teardown: function(data, options) { + // data.fixture.remove(); + if (data.fixture.parentNode) { + data.fixture.parentNode.removeChild(data.fixture); + } + }, + // invoked prior to running a slice of tests + sliceStart: function(options, tests) { + // inject styles into document + setStyle(options.styles); + // kick off value collection loop + generalParallelTest.startValueCollection(options); + }, + // invoked after running a slice of tests + sliceDone: function(options, tests) { + // stop value collection loop + generalParallelTest.stopValueCollection(options); + // reset styles cache + options.styles = {}; + }, + // called once all tests are done + done: function(options) { + // reset document styles + setStyle(); + reflow(); + }, + // add styles of individual test to slice cache + addStyles: function(data, options, styles) { + if (!options.styles) { + options.styles = {}; + } + + Object.keys(styles).forEach(function(key) { + var selector = '#' + data.fixture.id + // fixture must become #fixture.fixture rather than a child selector + + (key.substring(0, 8) === '.fixture' ? '' : ' ') + + key; + + options.styles[selector] = styles[key]; + }); + }, + // set style and compute values for container and transition + getStyle: function(data) { + reflow(); + // grab current styles: "initial state" + suite._getStyleFor(data, 'from'); + // apply target state + suite._addClass(data, 'to', true); + // grab current styles: "target state" + suite._getStyleFor(data, 'to'); + // remove target state + suite._removeClass(data, 'to', true); + + // clean up the mess created for value collection + data.container._values = []; + data.transition._values = []; + if (data.pseudo) { + data.pseudo._values = []; + } + }, + // grab current styles and store in respective element's data container + _getStyleFor: function(data, key) { + data.container[key] = data.container.computedStyle(data.property); + data.transition[key] = data.transition.computedStyle(data.property); + if (data.pseudo) { + data.pseudo[key] = data.pseudo.computedStyle(data.property); + } + }, + // add class to test's elements and possibly reflow + _addClass: function(data, className, forceReflow) { + data.container.node.classList.add(className); + data.transition.node.classList.add(className); + if (forceReflow) { + reflow(); + } + }, + // remove class from test's elements and possibly reflow + _removeClass: function(data, className, forceReflow) { + data.container.node.classList.remove(className); + data.transition.node.classList.remove(className); + if (forceReflow) { + reflow(); + } + }, + // add transition and to classes to container and transition + startTransition: function(data) { + // add transition-defining class + suite._addClass(data, 'how', true); + // add target state (without reflowing) + suite._addClass(data, 'to', false); + }, + // requestAnimationFrame runLoop to collect computed values + startValueCollection: function(options) { + var raf = window.requestAnimationFrame || function(callback){ + setTimeout(callback, 20); + }; + + // flag denoting if the runLoop should continue (true) or exit (false) + options._collectValues = true; + + function runLoop() { + if (!options._collectValues) { + // test's are done, stop annoying the CPU + return; + } + + // collect current style for test's elements + options.tests.forEach(function(data) { + if (!data.property) { + return; + } + + ['transition', 'container', 'pseudo'].forEach(function(elem) { + var pseudo = null; + if (!data[elem] || (elem === 'pseudo' && !data.pseudo)) { + return; + } + + var current = data[elem].computedStyle(data.property); + var values = data[elem].values; + var length = values.length; + if (!length || values[length - 1] !== current) { + values.push(current); + } + }); + }); + + // rinse and repeat + raf(runLoop); + } + + runLoop(); + }, + // stop requestAnimationFrame runLoop collecting computed values + stopValueCollection: function(options) { + options._collectValues = false; + }, + + // generate test.step function asserting collected events match expected + assertExpectedEventsFunc: function(data, elem, expected) { + return function() { + var _result = data[elem].events.sort().join(" "); + var _expected = typeof expected === 'string' ? expected : expected.sort().join(" "); + assert_equals(_result, _expected, "Expected TransitionEnd events triggered on ." + elem); + }; + }, + // generate test.step function asserting collected values are neither initial nor target + assertIntermediateValuesFunc: function(data, elem) { + return function() { + // the first value (index: 0) is always going to be the initial value + // the last value is always going to be the target value + var values = data[elem].values; + if (data.flags.discrete) { + // a discrete value will just switch from one state to another without having passed intermediate states. + assert_equals(values[0], data[elem].from, "must be initial value while transitioning on ." + elem); + assert_equals(values[1], data[elem].to, "must be target value after transitioning on ." + elem); + assert_equals(values.length, 2, "discrete property only has 2 values ." + elem); + } else { + assert_not_equals(values[1], data[elem].from, "may not be initial value while transitioning on ." + elem); + assert_not_equals(values[1], data[elem].to, "may not be target value while transitioning on ." + elem); + } + + // TODO: first value must be initial, last value must be target + }; + } +}; + +})(window); diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/helper.js b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/helper.js new file mode 100644 index 00000000000..242cd3ca635 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/helper.js @@ -0,0 +1,96 @@ +// +// Simple Helper Functions For Testing CSS +// + +(function(root) { +'use strict'; + +// serialize styles object and dump to dom +// appends <style id="dynamic-style"> to <head> +// setStyle("#some-selector", {"some-style" : "value"}) +// setStyle({"#some-selector": {"some-style" : "value"}}) +root.setStyle = function(selector, styles) { + var target = document.getElementById('dynamic-style'); + if (!target) { + target = document.createElement('style'); + target.id = 'dynamic-style'; + target.type = "text/css"; + document.getElementsByTagName('head')[0].appendChild(target); + } + + var data = []; + // single selector/styles + if (typeof selector === 'string' && styles !== undefined) { + data = [selector, '{', serializeStyles(styles), '}']; + target.textContent = data.join("\n"); + return; + } + // map of selector/styles + for (var key in selector) { + if (Object.prototype.hasOwnProperty.call(selector, key)) { + var _data = [key, '{', serializeStyles(selector[key]), '}']; + data.push(_data.join('\n')); + } + } + + target.textContent = data.join("\n"); +}; + +function serializeStyles(styles) { + var data = []; + for (var property in styles) { + if (Object.prototype.hasOwnProperty.call(styles, property)) { + var prefixedProperty = addVendorPrefix(property); + data.push(prefixedProperty + ":" + styles[property] + ";"); + } + } + + return data.join('\n'); +} + + +// shorthand for computed style +root.computedStyle = function(element, property, pseudo) { + var prefixedProperty = addVendorPrefix(property); + return window + .getComputedStyle(element, pseudo || null) + .getPropertyValue(prefixedProperty); +}; + +// flush rendering buffer +root.reflow = function() { + document.body.offsetWidth; +}; + +// merge objects +root.extend = function(target /*, ..rest */) { + Array.prototype.slice.call(arguments, 1).forEach(function(obj) { + Object.keys(obj).forEach(function(key) { + target[key] = obj[key]; + }); + }); + + return target; +}; + +// dom fixture helper ("resetting dom test elements") +var _domFixture; +var _domFixtureSelector; +root.domFixture = function(selector) { + var fixture = document.querySelector(selector || _domFixtureSelector); + if (!fixture) { + throw new Error('fixture ' + (selector || _domFixtureSelector) + ' not found!'); + } + if (!_domFixture && selector) { + // save a copy + _domFixture = fixture.cloneNode(true); + _domFixtureSelector = selector; + } else if (_domFixture) { + // restore the copy + var tmp = _domFixture.cloneNode(true); + fixture.parentNode.replaceChild(tmp, fixture); + } else { + throw new Error('domFixture must be initialized first!'); + } +}; +})(window); diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/import-green.css b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/import-green.css new file mode 100644 index 00000000000..537104e6633 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/import-green.css @@ -0,0 +1 @@ +.import { color: green; } diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/import-red.css b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/import-red.css new file mode 100644 index 00000000000..9945ef47114 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/import-red.css @@ -0,0 +1 @@ +.import { color: red; } diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/min-width-tables-001-iframe.html b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/min-width-tables-001-iframe.html new file mode 100644 index 00000000000..edc548a6aab --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/min-width-tables-001-iframe.html @@ -0,0 +1,59 @@ +<!DOCTYPE html> +<html><head> + <meta charset="utf-8"> + <title>iframe containing the meat of the test</title> + <style> +body { + margin: 0; + overflow: hidden; +} +/* green div that should cover the red divs */ +#green { + position: absolute; + left: 0; + top: 0; + background-color: green; + width: 100%; + height: 600px; +} +.spacer { + height: 98px; + width: 20px; +} +.item { + background-color: red; + display: block;/* property under test */ + /* border to aid understanding of boundaries between items */ + border-style: solid; + border-width: 1px; + border-color: red;/* Note: if you're trying to debug this, use a different color here */ +} +/* 100px = 10*(1 + 8 + 1) */ +@media (min-width: 100px) { + #green { + width: 100px; + height: 100px;/* = 1 + 98 + 1 */ + } + .item { + display: table-cell;/* property and value under test */ + } +} + </style> +</head> +<body> + <div> + <div class="item"><div class="spacer"></div></div> + <div class="item"><div class="spacer"></div></div> + <div class="item"><div class="spacer"></div></div> + <div class="item"><div class="spacer"></div></div> + <div class="item"><div class="spacer"></div></div> + <div class="item"><div class="spacer"></div></div> + <div class="item"><div class="spacer"></div></div> + <div class="item"><div class="spacer"></div></div> + <div class="item"><div class="spacer"></div></div> + <div class="item"><div class="spacer"></div></div> + </div> + <div id="green"></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/one.gif b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/one.gif new file mode 100644 index 0000000000000000000000000000000000000000..74cf7839c9fc0f1572d600ef559972b8e1ae57fc GIT binary patch literal 184 zcmZ?wbh9u|G-5Dfc+3C-|NsBLfB*je{rltN<K^Y$>+9?1&!2B^Zx5D4Cv-ppAiWGM zxdJCVSMRlWeRlW%1dYCw%y}8B*5$n3SD<sgB=>&By7x8j|C=6ca1apCb6WIKbpj6; z^Ah1xGH#0-ni*&B*~iu3C>+hvz?e|@qg2M`BvZ?hziHe&N0WD0?0??a(Ad=6(%RPE R(b?7A)7#fSp+S(r8UVwOMW_G( literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/parsing-utils.js b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/parsing-utils.js new file mode 100644 index 00000000000..beea4958ce8 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/parsing-utils.js @@ -0,0 +1,866 @@ +var ParsingUtils = (function() { +function testInlineStyle(value, expected) { + var div = document.createElement('div'); + div.style.setProperty('shape-outside', value); + var actual = div.style.getPropertyValue('shape-outside'); + assert_equals(actual, expected); +} + +function testComputedStyle(value, expected) { + var div = document.createElement('div'); + div.style.setProperty('shape-outside', value); + document.body.appendChild(div); + var style = getComputedStyle(div); + var actual = style.getPropertyValue('shape-outside'); + actual = roundResultStr(actual); + document.body.removeChild(div); + + // Some of the tests in this suite have either/or expected results + // so this check allows for testing that at least one of them passes. + // Description of the 2 expecteds is below near calcTestValues. + if(Object.prototype.toString.call( expected ) === '[object Array]' && expected.length == 2) { + assert_true(expected[0] == actual || expected[1] == actual) + } else { + assert_equals(actual, typeof expected !== 'undefined' ? expected : value); + } +} + +function testShapeMarginInlineStyle(value, expected) { + var div = document.createElement('div'); + div.style.setProperty('shape-outside', "border-box inset(10px)"); + div.style.setProperty('shape-margin', value); + var actual = div.style.getPropertyValue('shape-margin'); + assert_equals(actual, expected); +} + +function testShapeMarginComputedStyle(value, expected) { + + var outerDiv = document.createElement('div'); + outerDiv.style.setProperty('width', '100px'); + + var innerDiv = document.createElement('div'); + innerDiv.style.setProperty('shape-outside', "border-box inset(10px)"); + innerDiv.style.setProperty('shape-margin', value); + + outerDiv.appendChild(innerDiv); + document.body.appendChild(outerDiv); + + var style = getComputedStyle(innerDiv); + var actual = style.getPropertyValue('shape-margin'); + + assert_not_equals(actual, null); + if(actual.indexOf('calc') == -1 ) + actual = roundResultStr(actual); + document.body.removeChild(outerDiv); + + // See comment above about multiple expected results + if(Object.prototype.toString.call( expected ) === '[object Array]' && expected.length == 2) { + assert_true(expected[0] == actual || expected[1] == actual) + } else { + assert_equals(actual, !expected ? '0px' : expected); + } +} + +function testShapeThresholdInlineStyle(value, expected) { + var div = document.createElement('div'); + div.style.setProperty('shape-outside', 'url(someimage.png)'); + div.style.setProperty('shape-image-threshold', value); + var actual = div.style.getPropertyValue('shape-image-threshold'); + assert_equals(actual, expected); +} + +function testShapeThresholdComputedStyle(value, expected) { + + var div = document.createElement('div'); + div.style.setProperty('shape-outside', 'url(someimage.png)'); + div.style.setProperty('shape-image-threshold', value); + document.body.appendChild(div); + + var style = getComputedStyle(div); + var actual = style.getPropertyValue('shape-image-threshold'); + + assert_not_equals(actual, null); + if(actual.indexOf('calc') == -1 ) + actual = roundResultStr(actual); + document.body.removeChild(div); + + // See comment above about multiple expected results + if(Object.prototype.toString.call( expected ) === '[object Array]' && expected.length == 2) { + assert_true(expected[0] == actual || expected[1] == actual) + } else { + assert_equals(actual, !expected ? '0' : expected); + } +} + +// Builds an array of test cases to send to testharness.js where one test case is: [name, actual, expected] +// These test cases will verify results from testInlineStyle() or testComputedStyle() +function buildTestCases(testCases, testType) { + var results = []; + + // If test_type isn't specified, test inline style + var type = typeof testType == 'undefined' ? 'invalid': testType; + + testCases.forEach(function(test) { + oneTestCase = []; + + // name - annotated by type (inline vs. computed) + if ( test.hasOwnProperty('name') ) { + oneTestCase.push(test['name'] +' - '+ type); + } else { + // If test_name isn't specified, use the actual + oneTestCase.push(test['actual'] +' - '+ type); + } + + // actual + oneTestCase.push(test['actual']) + + // expected + if( type.indexOf('invalid') != -1 ){ + oneTestCase.push(null) + } else if( type == 'inline' ) { + oneTestCase.push(test['expected_inline']); + } else if( type == 'computed' ){ + oneTestCase.push( convertToPx(test['expected_computed']) ); + } + results.push(oneTestCase); + }); + return results; +} + + +function buildPositionTests(shape, valid, type, units) { + var results = new Array(); + var convert = type.indexOf('computed') != -1 ? true : false; + + if(Object.prototype.toString.call( units ) === '[object Array]') { + units.forEach(function(unit) { + positionTests = buildPositionTests(shape, valid, type, unit); + results = results.concat(positionTests); + }); + } else { + if (valid) { + validPositions.forEach(function(test) { + var testCase = [], testName, actual, expected; + // skip if this isn't explicitly testing length units + if( !(type.indexOf('lengthUnit') != -1 && test[0].indexOf("u1") == -1)) { + // actual + actual = shape + '(at ' + setUnit(test[0], false, units) +')'; + + // expected + // if(convert && shape == 'circle') + // expected = shape + '(at ' + setUnit(test[1], convert, units) +')'; + // else if(convert && shape == 'ellipse') + // expected = shape + '(at ' + setUnit(test[1], convert, units) +')'; + // else + expected = shape + '(at ' + setUnit(test[1], convert, units) +')'; + + // name + if (type == 'lengthUnit + inline') + testName = 'test unit (inline): ' + units +' - '+ actual; + else if (type == 'lengthUnit + computed') + testName = 'test unit (computed): ' + units +' - '+ actual; + else + testName = (actual + ' serializes as ' + expected +' - '+ type); + + testCase.push(testName) + testCase.push(actual); + testCase.push(expected); + results.push(testCase); + } + }); + } else { + invalidPositions.forEach(function(test) { + var testValue = shape + '(at ' + setUnit(test, false, units) +')'; + testCase = new Array(); + testCase.push(testValue + ' is invalid'); + testCase.push(testValue); + testCase.push(null); + results.push(testCase); + }); + } + } + return unique(results); +} + +function buildRadiiTests(shape, type, units) { + var results = new Array(); + var testUnits = typeof units == 'undefined' ? 'px': units; + var convert = type.indexOf('computed') != -1 ? true : false; + + if(Object.prototype.toString.call( testUnits ) === '[object Array]') { + testUnits.forEach(function(unit) { + radiiTests = buildRadiiTests(shape, type, unit); + results = results.concat(radiiTests); + }); + } else { + var validRadii = shape == 'circle' ? validCircleRadii : validEllipseRadii; + validRadii.forEach(function(test) { + var testCase = [], name, actual, expected; + + // skip if this isn't explicitly testing length units + if( !(type.indexOf('lengthUnit') != -1 && test[0].indexOf("u1") == -1) ) { + actual = shape + '(' + setUnit(test[0], false, testUnits) +')'; + // name + if (type.indexOf('lengthUnit') != -1) { + name = 'test unit: ' + units +' - '+ actual; + if(type.indexOf('computed') != -1) + name = name + ' - computed'; + else + name = name + ' - inline'; + } + else + name = actual +' - '+ type; + + testCase.push(name); + + // actual + testCase.push(actual); + + // expected + if(type.indexOf('computed') != -1 && test.length == 3) { + expected = shape + '(' + setUnit(test[2], convert, testUnits) +')'; + } else { + expected = shape + '(' + setUnit(test[1], convert, testUnits) +')'; + } + testCase.push(expected); + results.push(testCase); + } + }); + } + return unique(results); +} + +function buildInsetTests(unit1, unit2, type) { + var results = new Array(); + var convert = type == 'computed' ? true : false; + + if(Object.prototype.toString.call( unit1 ) === '[object Array]') { + unit1.forEach(function(unit) { + insetTests = buildInsetTests(unit, unit2, type); + results = results.concat(insetTests); + }); + } else { + validInsets.forEach(function(test) { + var testCase = [], name, actual, expected; + + name = setUnit(test[0], false, unit1, unit2) +' - '+ type; + actual = 'inset(' + setUnit(test[1], convert, unit1, unit2) +')'; + expected = actual; + + testCase.push(name); + testCase.push(actual); + testCase.push(expected); + + results.push(testCase); + }); + } + return unique(results); +} + +function buildPolygonTests(unitSet, type) { + var results = new Array(); + var convert = type == 'computed' ? true : false; + + unitSet.forEach(function(set) { + validPolygons.forEach(function(test) { + var testCase = []; + // name + testCase.push(setUnit(test[0], false, set[0], set[1], set[2]) +' - '+ type); + // actual + testCase.push('polygon(' + setUnit(test[1], false, set[0], set[1], set[2]) +')'); + // expected + testCase.push('polygon(' + setUnit(test[1], convert, set[0], set[1], set[2]) +')'); + results.push(testCase); + }); + }); + return unique(results); +} + +function buildCalcTests(testCases, type) { + var results = new Array(); + testCases.forEach(function(test){ + var testCase = []; + if(type == 'computed') { + testCase.push(test[0] + ' - computed style'); + testCase.push(test[0]); + testCase.push(test[2]); + } + else { + testCase.push(test[0] + ' - inline style'); + testCase.push(test[0]); + testCase.push(test[1]); + } + testCase.push(type); + results.push(testCase) + }); + return unique(results); +} + +function unique(tests) { + var list = tests.concat(); + for(var i = 0; i< list.length; ++i) { + for(var j = i+1; j < list.length; ++j) { + if(list[i][0] === list[j][0]) + list.splice(j--, 1); + } + } + return list; +} + +function setUnit(str, convert, unit1, unit2, unit3) { + var retStr = str; + if(typeof unit1 !== 'undefined') { + retStr = retStr.replace(new RegExp('u1', 'g'), unit1); + } + if(typeof unit2 !== 'undefined') { + retStr = retStr.replace(new RegExp("u2", 'g'), unit2); + } + if(typeof unit3 !== 'undefined') { + retStr = retStr.replace(new RegExp("u3", 'g'), unit3); + } + retStr = convert ? convertToPx(retStr) : retStr; + return retStr; +} + +function convertToPx(origValue) { + + var valuesToConvert = origValue.match(/[0-9]+(\.[0-9]+)?([a-z]{2,4}|%)/g); + if(!valuesToConvert) + return origValue; + + var retStr = origValue; + for(var i = 0; i < valuesToConvert.length; i++) { + var unit = valuesToConvert[i].match(/[a-z]{2,4}|%/).toString(); + var numberStr = valuesToConvert[i].match(/[0-9]+(\.[0-9]+)?/)[0]; + + var number = parseFloat(numberStr); + var convertedUnit = 'px'; + if( typeof number !== 'NaN' ) + { + if (unit == 'in') { + number = (96 * number); + } else if (unit == 'cm') { + number = (37.795275591 * number); + } else if (unit == 'mm') { + number = (3.779527559 * number); + } else if (unit == 'pt') { + number = (1.333333333333 * number); + } else if (unit == 'pc') { + number = (16 * number); + } else if (unit == 'em') { + number = (16 * number); + } else if (unit == 'ex') { + number = (7.1796875 * number); + } else if (unit == 'ch') { + number = (8 * number); + } else if (unit == 'rem') { + number = (16 * number); + } else if (unit == 'vw') { + number = ((.01 * window.innerWidth) * number); + } else if (unit == 'vh') { + number = ((.01 * window.innerHeight) * number); + } else if (unit == 'vmin') { + number = Math.min( (.01 * window.innerWidth), (.01 * window.innerHeight) ) * number; + } else if (unit == 'vmax') { + number = Math.max( (.01 * window.innerWidth), (.01 * window.innerHeight) ) * number; + } + else { + convertedUnit = unit; + } + number = Math.round(number * 1000) / 1000; + var find = valuesToConvert[i]; + var replace = number.toString() + convertedUnit; + retStr = retStr.replace(valuesToConvert[i], number.toString() + convertedUnit); + } + } + return retStr.replace(',,', ','); +} + +function roundResultStr(str) { + if(Object.prototype.toString.call( str ) !== '[object String]') + return str; + + var numbersToRound = str.match(/[0-9]+\.[0-9]+/g); + if(!numbersToRound) + return str; + + var retStr = str; + for(var i = 0; i < numbersToRound.length; i++) { + num = parseFloat(numbersToRound[i]); + if( !isNaN(num) ) { + roundedNum = Math.round(num*1000)/1000; + retStr = retStr.replace(numbersToRound[i].toString(), roundedNum.toString()); + } + } + + return retStr; +} + +function generateInsetRoundCases(units, testType) { + var convert = testType.indexOf('computed') != -1 ? true : false; + var testUnit = units; + var sizes = [ + '10' + units, + '20' + units, + '30' + units, + '40' + units + ]; + + function insetRound(value) { + return 'inset(10' +testUnit+ ' round ' + value + ')'; + } + + function serializedInsetRound(lhsValues, rhsValues, convert) { + var retStr = ''; + if(!rhsValues) + retStr = 'inset(10' +testUnit+ ' round ' + lhsValues +')'; + else + retStr = 'inset(10' +testUnit+ ' round ' + lhsValues +' / '+ rhsValues +')'; + + if(convert) + return convertToPx(retStr); + + return retStr; + } + + var results = [], left, lhs, right, rhs; + for (left = 1; left <= 4; left++) { + lhs = sizes.slice(0, left).join(' '); + results.push([insetRound(lhs) +' - '+ testType, insetRound(lhs), serializedInsetRound(lhs, null, convert)]); + for (right = 1; right <= 4; right++) { + rhs = sizes.slice(0, right).join(' '); + if(lhs == rhs) + results.push([insetRound(lhs + ' / ' + rhs) +' - '+ testType, insetRound(lhs + ' / ' + rhs), serializedInsetRound(lhs, null, convert)]); + else + results.push([insetRound(lhs + ' / ' + rhs) +' - '+ testType, insetRound(lhs + ' / ' + rhs), serializedInsetRound(lhs, rhs, convert)]); + } + } + return results; +} + +var validUnits = [ + "cm","mm","in","pt","pc", // Absolute length units (omitting px b/c we default to that in all tests) + "em","ex","ch","rem", // Font relative length units + "vw","vh","vmin","vmax" // Viewport percentage units + ] + +/// [actual, expected] +var validPositions = [ + +/// [ percent ], [ length ], [ percent | percent ], [ percent | length ], [ length | percent ], [ length | length ] + ["50%", "50% 50%"], + ["50u1", "50u1 50%"], + ["50% 50%", "50% 50%"], + ["50% 50u1", "50% 50u1"], + ["50u1 50%", "50u1 50%"], + ["50u1 50u1", "50u1 50u1"], + +///// [ keyword ], [ keyword keyword ] x 5 keywords + ["left", "0% 50%"], + ["top", "50% 0%"], + ["right", "100% 50%"], + ["bottom", "50% 100%"], + ["center", "50% 50%"], + + ["left top", "0% 0%"], + ["left bottom", "0% 100%"], + ["left center", "0% 50%"], + + ["top left", "0% 0%"], + ["top right", "100% 0%"], + ["top center", "50% 0%"], + + ["right top", "100% 0%"], + ["right bottom", "100% 100%"], + ["right center", "100% 50%"], + + ["bottom left", "0% 100%"], + ["bottom right", "100% 100%"], + ["bottom center", "50% 100%"], + + ["center top", "50% 0%"], + ["center left", "0% 50%"], + ["center right", "100% 50%"], + ["center bottom", "50% 100%"], + ["center center", "50% 50%"], + +////// [ keyword | percent ], [ keyword | length ], [ percent | keyword ], [ length | keyword ] x 5 keywords + ["left 50%", "0% 50%"], + ["left 50u1", "0% 50u1"], + + ["50% top", "50% 0%"], + ["50u1 top", "50u1 0%"], + + ["right 80%", "100% 80%"], + ["right 80u1", "100% 80u1"], + + ["70% bottom", "70% 100%"], + ["70u1 bottom", "70u1 100%"], + + ["center 60%", "50% 60%"], + ["center 60u1", "50% 60u1"], + ["60% center", "60% 50%"], + ["60u1 center", "60u1 50%"], + +////// [ keyword | keyword percent ], [ keyword | keyword length ] x 5 keywords + ["center top 50%", "50% 50%"], + ["center top 50u1", "50% 50u1"], + ["center left 50%", "50% 50%"], + ["center left 50u1", "50u1 50%"], + ["center right 70%", "30% 50%"], + ["center right 70u1", "right 70u1 top 50%"], + ["center bottom 70%", "50% 30%"], + ["center bottom 70u1", "left 50% bottom 70u1"], + + ["left top 50%", "0% 50%"], + ["left top 50u1", "0% 50u1"], + ["left bottom 70%", "0% 30%"], + ["left bottom 70u1", "left 0% bottom 70u1"], + + ["top left 50%", "50% 0%"], + ["top left 50u1", "50u1 0%"], + ["top right 70%", "30% 0%"], + ["top right 70u1", "right 70u1 top 0%"], + + ["bottom left 50%", "50% 100%"], + ["bottom left 50u1", "50u1 100%"], + ["bottom right 70%", "30% 100%"], + ["bottom right 70u1", "right 70u1 top 100%"], + + ["right bottom 70%", "100% 30%"], + ["right bottom 70u1", "left 100% bottom 70u1"], + ["right top 50%", "100% 50%"], + ["right top 50u1", "100% 50u1"], + +////// [ keyword percent | keyword], [ keyword length | keyword ] x 5 keywords + ["left 50% center", "50% 50%"], + ["left 50u1 center", "50u1 50%"], + ["left 50% top", "50% 0%"], + ["left 50u1 top", "50u1 0%"], + ["left 50% bottom", "50% 100%"], + ["left 50u1 bottom", "50u1 100%"], + + ["top 50% center", "50% 50%"], + ["top 50u1 center", "50% 50u1"], + ["top 50% left", "0% 50%"], + ["top 50u1 left", "0% 50u1"], + ["top 50% right", "100% 50%"], + ["top 50u1 right", "100% 50u1"], + + ["bottom 70% center", "50% 30%"], + ["bottom 70u1 center", "left 50% bottom 70u1"], + ["bottom 70% left", "0% 30%"], + ["bottom 70u1 left", "left 0% bottom 70u1"], + ["bottom 70% right", "100% 30%"], + ["bottom 70u1 right", "left 100% bottom 70u1"], + + ["right 80% center", "20% 50%"], + ["right 80u1 center", "right 80u1 top 50%"], + ["right 80% bottom", "20% 100%"], + ["right 80u1 bottom", "right 80u1 top 100%"], + ["right 80% top", "20% 0%"], + ["right 80u1 top", "right 80u1 top 0%"], + +////// [ keyword percent | keyword percent], [ keyword percent | keyword length], +////// [ keyword length | keyword length], [ keyword length | keyword percent] x 5 keywords + ["left 50% top 50%", "50% 50%"], + ["left 50% top 50u1", "50% 50u1"], + ["left 50% bottom 70%", "50% 30%"], + ["left 50% bottom 70u1", "left 50% bottom 70u1"], + ["left 50u1 top 50%", "50u1 50%"], + ["left 50u1 top 50u1", "50u1 50u1"], + ["left 50u1 bottom 70%", "50u1 30%"], + ["left 50u1 bottom 70u1", "left 50u1 bottom 70u1"], + + ["top 50% left 50%", "50% 50%"], + ["top 50% left 50u1", "50u1 50%"], + ["top 50% right 80%", "20% 50%"], + ["top 50% right 80u1", "right 80u1 top 50%"], + ["top 50u1 left 50%", "50% 50u1"], + ["top 50u1 left 50u1", "50u1 50u1"], + ["top 50u1 right 80%", "20% 50u1"], + ["top 50u1 right 80u1", "right 80u1 top 50u1"], + + ["bottom 70% left 50%", "50% 30%"], + ["bottom 70% left 50u1", "50u1 30%"], + ["bottom 70% right 80%", "20% 30%"], + ["bottom 70% right 80u1", "right 80u1 top 30%"], + ["bottom 70u1 left 50%", "left 50% bottom 70u1"], + ["bottom 70u1 left 50u1", "left 50u1 bottom 70u1"], + ["bottom 70u1 right 80%", "left 20% bottom 70u1"], + ["bottom 70u1 right 80u1", "right 80u1 bottom 70u1"], + + ["right 80% top 50%", "20% 50%"], + ["right 80% top 50u1", "20% 50u1"], + ["right 80% bottom 70%", "20% 30%"], + ["right 80% bottom 70u1", "left 20% bottom 70u1"], + ["right 80u1 top 50%", "right 80u1 top 50%"], + ["right 80u1 top 50u1", "right 80u1 top 50u1"], + ["right 80u1 bottom 70%", "right 80u1 top 30%"], + ["right 80u1 bottom 70u1", "right 80u1 bottom 70u1"], +]; + +var invalidPositions = [ +////// [ keyword | percent ], [ keyword | length ], [ percent | keyword ], [ length | keyword ] x 5 keywords + "50% left", + "50px left", + "top 50%", + "80% right", + "80px right", + "bottom 70%", + "bottom 70px", + +////// [ keyword | keyword percent ], [ keyword | keyword length ] x 5 keywords + "center center 60%", + "center center 60px", + + "left center 60%", + "left center 60px", + "left right 80%", + "left right 80px", + "left left 50%", + "left left 50px", + + "top center 60%", + "top center 60px", + "top bottom 80%", + "top bottom 80px", + "top top 50%", + "top top 50px", + + "bottom center 60%", + "bottom center 60px", + "bottom top 50%", + "bottom top 50px", + "bottom bottom 50%", + "bottom bottom 50px", + + "right center 60%", + "right center 60px", + "right left 50%", + "right left 50px", + "right right 70%", + "right right 70px", + +////// [ keyword percent | keyword], [ keyword length | keyword ] x 5 keywords + "center 60% top", + "center 60px top", + "center 60% bottom", + "center 60px bottom", + "center 60% left", + "center 60px left", + "center 60% right", + "center 60px right", + "center 60% center", + "center 60px center", + + "left 50% right", + "left 50px right", + "left 50% left", + "left 50px left", + + "top 50% bottom", + "top 50px bottom", + "top 50% top", + "top 50px top", + + "bottom 70% top", + "bottom 70px top", + "bottom 70% bottom", + "bottom 70px bottom", + + "right 80% left", + "right 80px left", + +////// [ keyword percent | keyword percent], [ keyword percent | keyword length], +////// [ keyword length | keyword length], [ keyword length | keyword percent] x 5 keywords + "center 60% top 50%", + "center 60% top 50px", + "center 60% bottom 70%", + "center 60% bottom 70px", + "center 60% left 50%", + "center 60% left 50px", + "center 60% right 70%", + "center 60% right 70px", + "center 60% center 65%", + "center 60% center 65px", + "center 60px top 50%", + "center 60px top 50px", + "center 60px bottom 70%", + "center 60px bottom 70px", + "center 60px left 50%", + "center 60px left 50px", + "center 60px right 70%", + "center 60px right 70px", + "center 60px center 65%", + "center 60px center 65px", + + "left 50% center 60%", + "left 50% center 60px", + "left 50% right 80%", + "left 50% right 80px", + "left 50% left 50%", + "left 50% left 50px", + "left 50px center 60%", + "left 50px center 60px", + "left 50px right 80%", + "left 50px right 80px", + "left 50px left 50%", + "left 50px left 50px", + + "top 50% center 60%", + "top 50% center 60px", + "top 50% bottom 50%", + "top 50% bottom 50px", + "top 50% top 50%", + "top 50% top 50px", + "top 50px center 60%", + "top 50px center 60px", + "top 50px bottom 70%", + "top 50px bottom 70px", + "top 50px top 50%", + "top 50px top 50px", + + "bottom 70% center 60%", + "bottom 70% center 60px", + "bottom 70% top 50%", + "bottom 70% top 50px", + "bottom 70% bottom 50%", + "bottom 70% bottom 50px", + "bottom 70px center 60%", + "bottom 70px center 60px", + "bottom 70px top 50%", + "bottom 70px top 50px", + "bottom 70px bottom 50%", + "bottom 70px bottom 50px", + + "right 80% center 60%", + "right 80% center 60px", + "right 80% left 50%", + "right 80% left 50px", + "right 80% right 85%", + "right 80% right 85px", + "right 80px center 60%", + "right 80px center 60px", + "right 80px left 50%", + "right 80px left 50px", + "right 80px right 85%", + "right 80px right 85px" +]; + +// valid radii values for circle + ellipse +// [value, expected_inline, [expected_computed?]] +var validCircleRadii = [ + ['', 'at 50% 50%', 'at 50% 50%'], + ['50u1', '50u1 at 50% 50%'], + ['50%', '50% at 50% 50%'], + ['closest-side', 'at 50% 50%'], + ['farthest-side', 'farthest-side at 50% 50%'] +] +var validEllipseRadii = [ + ['', 'at 50% 50%', 'at 50% 50%'], + ['50u1', '50u1 at 50% 50%', '50u1 at 50% 50%'], + ['50%', '50% at 50% 50%', '50% at 50% 50%'], + ['closest-side', 'at 50% 50%', 'at 50% 50%'], + ['farthest-side', 'farthest-side at 50% 50%', 'farthest-side at 50% 50%'], + ['50u1 100u1', '50u1 100u1 at 50% 50%'], + ['100u1 100px', '100u1 100px at 50% 50%'], + ['25% 50%', '25% 50% at 50% 50%'], + ['50u1 25%', '50u1 25% at 50% 50%'], + ['25% 50u1', '25% 50u1 at 50% 50%'], + ['25% closest-side', '25% at 50% 50%'], + ['25u1 closest-side', '25u1 at 50% 50%'], + ['closest-side 75%', 'closest-side 75% at 50% 50%'], + ['closest-side 75u1', 'closest-side 75u1 at 50% 50%'], + ['25% farthest-side', '25% farthest-side at 50% 50%'], + ['25u1 farthest-side', '25u1 farthest-side at 50% 50%'], + ['farthest-side 75%', 'farthest-side 75% at 50% 50%'], + ['farthest-side 75u1', 'farthest-side 75u1 at 50% 50%'], + ['closest-side closest-side', 'at 50% 50%'], + ['farthest-side farthest-side', 'farthest-side farthest-side at 50% 50%'], + ['closest-side farthest-side', 'closest-side farthest-side at 50% 50%'], + ['farthest-side closest-side', 'farthest-side at 50% 50%'] +] + +var validInsets = [ + ["One arg - u1", "10u1"], + ["One arg - u2", "10u2"], + ["Two args - u1 u1", "10u1 20u1"], + ["Two args - u1 u2", "10u1 20u2"], + ["Two args - u2 u1", "10u2 20u1"], + ["Two args - u2 u2", "10u2 20u2"], + ["Three args - u1 u1 u1", "10u1 20u1 30u1"], + ["Three args - u1 u1 u2", "10u1 20u1 30u2"], + ["Three args - u1 u2 u1", "10u1 20u2 30u1"], + ["Three args - u1 u2 u2 ", "10u1 20u2 30u2"], + ["Three args - u2 u1 u1", "10u2 20u1 30u1"], + ["Three args - u2 u1 u2 ", "10u2 20u1 30u2"], + ["Three args - u2 u2 u1 ", "10u2 20u2 30u1"], + ["Three args - u2 u2 u2 ","10u2 20u2 30u2"], + ["Four args - u1 u1 u1 u1", "10u1 20u1 30u1 40u1"], + ["Four args - u1 u1 u1 u2", "10u1 20u1 30u1 40u2"], + ["Four args - u1 u1 u2 u1", "10u1 20u1 30u2 40u1"], + ["Four args - u1 u1 u2 u2", "10u1 20u1 30u2 40u2"], + ["Four args - u1 u2 u1 u1", "10u1 20u2 30u1 40u1"], + ["Four args - u1 u2 u1 u2", "10u1 20u2 30u1 40u2"], + ["Four args - u1 u2 u2 u1", "10u1 20u2 30u2 40u1"], + ["Four args - u1 u2 u2 u2", "10u1 20u2 30u2 40u2"], + ["Four args - u2 u1 u1 u1", "10u2 20u1 30u1 40u1"], + ["Four args - u2 u1 u1 u2", "10u2 20u1 30u1 40u2"], + ["Four args - u2 u1 u2 u1", "10u2 20u1 30u2 40u1"], + ["Four args - u2 u1 u2 u2", "10u2 20u1 30u2 40u2"], + ["Four args - u2 u2 u1 u1", "10u2 20u2 30u1 40u1"], + ["Four args - u2 u2 u1 u2", "10u2 20u2 30u1 40u2"], + ["Four args - u2 u2 u2 u1", "10u2 20u2 30u2 40u1"], + ["Four args - u2 u2 u2 u2", "10u2 20u2 30u2 40u2"] +] + +var validPolygons = [ + ["One vertex - u1 u1", "10u1 20u1"], + ["One vertex - u1 u2", "10u1 20u2"], + ["Two vertices - u1 u1, u1 u1", "10u1 20u1, 30u1 40u1"], + ["Two vertices - u1 u1, u2 u2", "10u1 20u1, 30u2 40u2"], + ["Two vertices - u2 u2, u1 u1", "10u2 20u2, 30u1 40u1"], + ["Two vertices - u1 u2, u2 u1", "10u1 20u2, 30u2 40u1"], + ["Three vertices - u1 u1, u1 u1, u1 u1", "10u1 20u1, 30u1 40u1, 50u1 60u1"], + ["Three vertices - u2 u2, u2 u2, u2 u2", "10u2 20u2, 30u2 40u2, 50u2 60u2"], + ["Three vertices - u3 u3, u3 u3, u3 u3", "10u3 20u3, 30u3 40u3, 50u3 60u3"], + ["Three vertices - u1 u1, u2 u2, u3 u3", "10u1 20u1, 30u2 40u2, 50u3 60u3"], + ["Three vertices - u3 u3, u1, u1, u2 u2", "10u3 20u3, 30u1 40u1, 50u2 60u2"], +] + +// [test value, expected property value, expected computed style] +var calcTestValues = [ + ["calc(10in)", "calc(10in)", "960px"], + ["calc(10in + 20px)", "calc(980px)", "980px"], + ["calc(30%)", "calc(30%)", "30%"], + ["calc(100%/4)", "calc(25%)", "25%"], + ["calc(25%*3)", "calc(75%)", "75%"], + // These following two test cases represent an either/or situation in the spec + // computed value is always supposed to be, at most, a tuple of a length and a percentage. + // the computed value of a โ€˜calc()โ€™ expression can be represented as either a number or a tuple + // of a dimension and a percentage. + // http://www.w3.org/TR/css3-values/#calc-notation + ["calc(25%*3 - 10in)", "calc(75% - 10in)", ["calc(75% - 960px)", "calc(-960px + 75%)"]], + ["calc((12.5%*6 + 10in) / 4)", "calc((75% + 10in) / 4)", ["calc((75% + 960px) / 4)", "calc(240px + 18.75%)"]] +] + +return { + testInlineStyle: testInlineStyle, + testComputedStyle: testComputedStyle, + testShapeMarginInlineStyle: testShapeMarginInlineStyle, + testShapeMarginComputedStyle: testShapeMarginComputedStyle, + testShapeThresholdInlineStyle: testShapeThresholdInlineStyle, + testShapeThresholdComputedStyle: testShapeThresholdComputedStyle, + buildTestCases: buildTestCases, + buildRadiiTests: buildRadiiTests, + buildPositionTests: buildPositionTests, + buildInsetTests: buildInsetTests, + buildPolygonTests: buildPolygonTests, + generateInsetRoundCases: generateInsetRoundCases, + buildCalcTests: buildCalcTests, + validUnits: validUnits, + calcTestValues: calcTestValues, + roundResultStr: roundResultStr +} +})(); diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/pattern-gg-gr.png b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/pattern-gg-gr.png new file mode 100644 index 0000000000000000000000000000000000000000..091de70bb72541dda90cafaa4a2eb68d82fb5bdb GIT binary patch literal 203 zcmeAS@N?(olHy`uVBq!ia0vp^8X(NU1SFZ~=vx6P#^NA%Cx&(BWL^R}oCO|{#S9F5 zM?jcysy3fAP>{XE)7O>#4zs*CpV-thX~%&=k|nMYCC>S|xv6<249-QVi6yBi3gww4 z84B*6z5(HleBwYw7M?DSArXh)UO33fpdi3}P(!S4ZZ<c&U5&+WerCy)HkoP(1`<4M m%?I}%c%8QA^i?RYmoGe?DKLBT?xjF87(8A5T-G@yGywqU{5T8% literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/pattern-grg-rgr-grg.png b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/pattern-grg-rgr-grg.png new file mode 100644 index 0000000000000000000000000000000000000000..6fcfeb4883edea810f880fabb861e09df7871695 GIT binary patch literal 222 zcmV<403rX0P)<h;3K|Lk000e1NJLTq001fg001fo0ssI3J*IA&0001`Nkl<Zc-rli z!4iWo2t*%#Ie$(sX|)yGI5;(q%PA9Jmkl8?93ULP9AIK)7R>(GjOxRBMQwxx1mJBk z?aXifhV@+AVlyc!*ZYwgelQCuviAYh+_OT<gcQNg6t-;4S{PYlcfkL&YW~~R`(A2{ zSbtgn)%$nx`tP29_xaQNq4OWFf2l=xr1`(fKl$`TFZx42zT!BA22b>&*N-Q9(T_&| Y0MVE_0ae*F0000007*qoM6N<$f~59g2LJ#7 literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/pattern-grg-rrg-rgg.png b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/pattern-grg-rrg-rgg.png new file mode 100644 index 0000000000000000000000000000000000000000..fcf4f3fd7d95431b8cd1bc5f5129fcb724c5e40f GIT binary patch literal 231 zcmeAS@N?(olHy`uVBq!ia0vp^x**KK#K6FKsNOXi$XVy<;uunK>uuO>p#}vW?s@X} z?5{Vn@(E1fdg>#_p5-zBiX+1VA%+4b26mx2|7={&ovNQ>6SXtcysBl-)c><WmS!Y( zv7BNEzPH=%x{1!KjWd@lmbz(awP;VviDQ{7SW3K#guH|K-#!i8$dVG=UlQ?2Ho)uu z>9DyExiv#HMbsD$XX>p~Q&Z4f6DV?h!MD37E_}{<nz@wk)ekYNY^%>svR6Ky{&{h` fDhG(UQO-Q~pMsNotNvM_%Naaf{an^LB{Ts5h3Hy_ literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/pattern-rgr-grg-rgr.png b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/pattern-rgr-grg-rgr.png new file mode 100644 index 0000000000000000000000000000000000000000..db8ed5cf7bd1837d4810f2885309f8413c6c77d5 GIT binary patch literal 222 zcmV<403rX0P)<h;3K|Lk000e1NJLTq001fg001fo0ssI3J*IA&0001`Nkl<Zc-rli z%Myby2t^NmIe$(!ZH+By>?EUcysXRv&Lsq60f0F`IKaY}8O6F)ckPNrKmh*ySgNcF zsO2B!z+X<jPG+J~4Ii%NgDF80`5mJXpl^B2u+(g0*rz5I>8xiL(f<$Mv|j(s)%z{g zX4K!E|JCbvas7AqzkC1b|Dp4ruYT+<YHHy}$v^q@gcpA3!`InPrp6Oqc)fVS3qKqF Y0cy8C_Kbk@N&o-=07*qoM6N<$g27Q_GXMYp literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/pattern-tr.png b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/pattern-tr.png new file mode 100644 index 0000000000000000000000000000000000000000..8b4b25364e0ffbe09e563e13b567fa57330e48d5 GIT binary patch literal 137 zcmeAS@N?(olHy`uVBq!ia0vp^azM<_!N$PA*s|9jBoW~0;uunKD><d1=|2z8e@O`m zi5U_X7?eM1T?jqI(8f2(=fLXOHJ)xxeNNw5J?)fkN19wc<FT&3eZzeBMQLtcCc<9q mCdFSHSg)@*x>)QnGsEKzd}=q=PizO8&EV<k=d#Wzp$Pzi&n><H literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/properties.js b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/properties.js new file mode 100644 index 00000000000..ddecfb6e336 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/properties.js @@ -0,0 +1,449 @@ +(function(root){ + +/* + * General Value Types definition + * they return an object of arrays of type { <name>: [<start-value>, <end-value>], ... } + */ +var values = { + 'length' : function() { + // http://www.w3.org/TR/css3-values/#lengths + return { + // CSS Values and Module Level 3 + // ch: ['1ch', '10ch'], + // rem: ['1rem', '10rem'], + // vw: ['1vw', '10vw'], + // vh: ['1vh', '10vh'], + // vmin: ['1vmin', '10vmin'], + // vmax: ['1vmax', '10vmax'], + // CSS Values and Module Level 2 + pt: ['1pt', '10pt'], + pc: ['1pc', '10pc'], + px: ['1px', '10px'], + // CSS Values and Module Level 1 + em: ['1em', '10em'], + ex: ['1ex', '10ex'], + mm: ['1mm', '10mm'], + cm: ['1cm', '10cm'], + 'in': ['1in', '10in'] + }; + }, + 'length-em': function() { + return { + em: ['1.1em', '1.5em'] + }; + }, + 'percentage': function() { + // http://www.w3.org/TR/css3-values/#percentages + return { + '%': ['33%', '80%'] + }; + }, + 'color': function() { + // http://www.w3.org/TR/css3-values/#colors + // http://www.w3.org/TR/css3-color/ + return { + rgba: ['rgba(100,100,100,1)', 'rgba(10,10,10,0.4)'] + }; + }, + 'rectangle': function() { + // http://www.w3.org/TR/CSS2/visufx.html#value-def-shape + return { + rectangle: ['rect(10px,10px,10px,10px)', 'rect(15px,15px,5px,5px)'] + }; + }, + 'font-weight': function() { + // http://www.w3.org/TR/css3-fonts/#font-weight-prop + return { + keyword: ["normal", "bold"], + numeric: ["100", "900"] + }; + }, + 'number': function() { + // http://www.w3.org/TR/css3-values/#number + return { + integer: ["1", "10"], + decimal: ["1.1", "9.55"] + }; + }, + 'number[0,1]': function() { + // http://www.w3.org/TR/css3-values/#number + // applies to [0,1]-ranged properties like opacity + return { + "zero-to-one": ["0.2", "0.9"] + }; + }, + 'integer': function() { + // http://www.w3.org/TR/css3-values/#integer + return { + integer: ["1", "10"] + }; + }, + 'shadow': function() { + // http://www.w3.org/TR/css-text-decor-3/#text-shadow-property + return { + shadow: ['rgba(0,0,0,0.1) 5px 6px 7px', 'rgba(10,10,10,0.9) 5px 6px 7px'] + }; + }, + 'visibility': function() { + // http://www.w3.org/TR/CSS2/visufx.html#visibility + return { + keyword: ['visible', 'hidden', {discrete: true}] + }; + }, + 'auto': function(property) { + var types = properties[property] || unspecified_properties[property]; + var val = values[types[0]](property); + var key = Object.keys(val).shift(); + return { + to: [val[key][1], 'auto'], + from: ['auto', val[key][1]] + }; + }, + // types reqired for non-specified properties + 'border-radius': function() { + return { + px: ['1px', '10px'], + "px-px": ['1px 3px', '10px 13px'] + }; + }, + 'image' : function() { + var prefix = getValueVendorPrefix('background-image', 'linear-gradient(top, hsl(0, 80%, 70%), #bada55)'); + return { + // Chrome implements this + url: ['url(support/one.gif)', 'url(support/two.gif)'], + data: ['url(data:image/gif;base64,R0lGODlhAQABAAD/ACwAAAAAAQABAAACADs=)', 'url(data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///ywAAAAAAQABAAACAUwAOw==)'], + // A hunch, as from the spec: + // http://www.w3.org/TR/css3-transitions/#animatable-types + // gradient: interpolated via the positions and colors of each stop. They must have the same type (radial or linear) and same number of stops in order to be animated. Note: [CSS3-IMAGES] may extend this definition. + gradient: [prefix + 'linear-gradient(top, hsl(0, 80%, 70%), #bada55)', prefix + 'linear-gradient(top, #bada55, hsl(0, 80%, 70%))'] + }; + }, + 'background-size': function() { + return { + keyword: ['cover', 'contain'] + }; + }, + 'box-shadow': function() { + // http://www.w3.org/TR/css3-background/#ltshadowgt + return { + shadow: ['60px -16px teal', '60px -16px red'] + }; + }, + 'vertical': function() { + return { + keyword: ['top', 'bottom'] + }; + }, + 'horizontal': function() { + return { + keyword: ['left', 'right'] + }; + }, + 'font-stretch': function() { + return { + keyword: ['condensed', 'expanded'] + }; + }, + 'transform': function() { + return { + rotate: ['rotate(10deg)', 'rotate(20deg)'] + }; + }, + 'position': function() { + return { + 'static to absolute': ['static', 'absolute', {discrete: true}], + 'relative to absolute': ['relative', 'absolute', {discrete: true}], + 'absolute to fixed': ['absolute', 'fixed', {discrete: true}] + }; + }, + 'display': function() { + return { + 'static to absolute': ['none', 'block', {discrete: true}], + 'block to inline-block': ['block', 'inline-block', {discrete: true}] + }; + } +}; + +/* + * Property to Type table + * (as stated in specification) + */ +var properties = { + 'background-color': ['color'], + 'background-position': ['length', 'percentage'], + + 'border-top-width': ['length'], + 'border-right-width': ['length'], + 'border-bottom-width': ['length'], + 'border-left-width': ['length'], + + 'border-top-color': ['color'], + 'border-right-color': ['color'], + 'border-bottom-color': ['color'], + 'border-left-color': ['color'], + + 'padding-bottom': ['length'], + 'padding-left': ['length'], + 'padding-right': ['length'], + 'padding-top': ['length'], + + 'margin-bottom': ['length'], + 'margin-left': ['length'], + 'margin-right': ['length'], + 'margin-top': ['length'], + + 'height': ['length', 'percentage'], + 'width': ['length', 'percentage'], + 'min-height': ['length', 'percentage'], + 'min-width': ['length', 'percentage'], + 'max-height': ['length', 'percentage'], + 'max-width': ['length', 'percentage'], + + 'top': ['length', 'percentage'], + 'right': ['length', 'percentage'], + 'bottom': ['length', 'percentage'], + 'left': ['length', 'percentage'], + + 'color': ['color'], + 'font-size': ['length', 'percentage'], + 'font-weight': ['font-weight'], + 'line-height': ['number', 'length', 'percentage'], + 'letter-spacing': ['length'], + // Note: percentage is Level3 and not implemented anywhere yet + // https://drafts.csswg.org/css3-text/#word-spacing + 'word-spacing': ['length', 'percentage'], + 'text-indent': ['length', 'percentage'], + 'text-shadow': ['shadow'], + + 'outline-color': ['color'], + // outline-offset <integer> used to be an error in the spec + 'outline-offset': ['length'], + 'outline-width': ['length'], + + 'clip': ['rectangle'], + // Note: doesn't seem implemented anywhere + 'crop': ['rectangle'], + + 'vertical-align': ['length', 'percentage'], + 'opacity': ['number[0,1]'], + 'visibility': ['visibility'], + 'z-index': ['integer'] +}; + +/* + * Property to auto-value mapping + * (lazily taken from http://www.siliconbaytraining.com/pages/csspv.html) + */ +var properties_auto = [ + 'margin-top', + 'margin-right', + 'margin-bottom', + 'margin-left', + 'height', + 'width', + 'clip', + 'marker-offset', + 'top', + 'right', + 'left', + 'bottom', + 'z-index' +]; + +/* + * Property to Type table + * (missing value-types of specified properties) + */ +var missing_properties = { + 'margin-bottom': ['percentage'], + 'margin-left': ['percentage'], + 'margin-right': ['percentage'], + 'margin-top': ['percentage'], + 'padding-bottom': ['percentage'], + 'padding-left': ['percentage'], + 'padding-right': ['percentage'], + 'padding-top': ['percentage'], + 'vertical-align': ['vertical'] +}; + +/* + * Property to Type table + * (properties that haven't been specified but implemented) + */ +var unspecified_properties = { + // http://oli.jp/2010/css-animatable-properties/ + 'border-top-left-radius': ['border-radius'], + 'border-top-right-radius': ['border-radius'], + 'border-bottom-left-radius': ['border-radius'], + 'border-bottom-right-radius': ['border-radius'], + 'background-image': ['image'], + 'background-size': ['background-size'], + // https://drafts.csswg.org/css3-background/#the-box-shadow + // Animatable: yes, except between inner and outer shadows (Transition to/from an absent shadow is a transition to/from โ€˜0 0 transparentโ€™ or โ€˜0 0 transparent insetโ€™, as appropriate.) + 'box-shadow': ['box-shadow'], + 'font-size-adjust': ['number'], + 'font-stretch': ['font-stretch'], + 'marker-offset': ['length'], + 'text-decoration-color': ['color'], + 'column-count': ['integer'], + 'column-gap': ['length'], + 'column-rule-color': ['color'], + 'column-rule-width': ['length'], + 'column-width': ['length'], + 'transform': ['transform'], + 'transform-origin': ['horizontal'], + 'zoom': ['number'], + 'outline-radius-topleft': ['length', 'percentage'], + 'outline-radius-topright': ['length', 'percentage'], + 'outline-radius-bottomright': ['length', 'percentage'], + 'outline-radius-bottomleft': ['length', 'percentage'], + 'display': ['display'], + 'position': ['position'] +}; + +/* + * additional styles required to actually render + * (different browsers expect different environment) + */ +var additional_styles = { + // all browsers + 'border-top-width': {'border-top-style' : 'solid'}, + 'border-right-width': {'border-right-style' : 'solid'}, + 'border-bottom-width': {'border-bottom-style' : 'solid'}, + 'border-left-width': {'border-left-style' : 'solid'}, + 'top': {'position': 'absolute'}, + 'right': {'position': 'absolute'}, + 'bottom': {'position': 'absolute'}, + 'left': {'position': 'absolute'}, + 'z-index': {'position': 'absolute'}, + 'outline-offset': {'outline-style': 'solid'}, + 'outline-width': {'outline-style': 'solid'}, + 'word-spacing': {'width': '100px', 'height': '100px'}, + // unspecified properties + 'column-rule-width': {'column-rule-style': 'solid'}, + 'position': {'width': '50px', 'height': '50px', top: '10px', left: '50px'} +}; + +/* + * additional styles required *on the parent* to actually render + * (different browsers expect different environment) + */ +var parent_styles = { + 'border-top-width': {'border-top-style' : 'solid'}, + 'border-right-width': {'border-right-style' : 'solid'}, + 'border-bottom-width': {'border-bottom-style' : 'solid'}, + 'border-left-width': {'border-left-style' : 'solid'}, + 'height': {'width': '100px', 'height': '100px'}, + 'min-height': {'width': '100px', 'height': '100px'}, + 'max-height': {'width': '100px', 'height': '100px'}, + 'width': {'width': '100px', 'height': '100px'}, + 'min-width': {'width': '100px', 'height': '100px'}, + 'max-width': {'width': '100px', 'height': '100px'}, + // unspecified properties + 'position': {'position': 'relative', 'width': '100px', 'height': '100px'}, + // inheritance tests + 'top': {'width': '100px', 'height': '100px', 'position': 'relative'}, + 'right': {'width': '100px', 'height': '100px', 'position': 'relative'}, + 'bottom': {'width': '100px', 'height': '100px', 'position': 'relative'}, + 'left': {'width': '100px', 'height': '100px', 'position': 'relative'} +}; + + +function assemble(props) { + var tests = []; + + // assemble tests + for (var property in props) { + props[property].forEach(function(type) { + var _values = values[type](property); + Object.keys(_values).forEach(function(unit) { + var data = { + name: property + ' ' + type + '(' + unit + ')', + property: property, + valueType : type, + unit : unit, + parentStyle: extend({}, parent_styles[property] || {}), + from: extend({}, additional_styles[property] || {}), + to: {} + }; + + data.from[property] = _values[unit][0]; + data.to[property] = _values[unit][1]; + data.flags = _values[unit][2] || {}; + + tests.push(data); + }); + }); + } + + return tests; +} + +root.getPropertyTests = function() { + return assemble(properties); +}; + +root.getMissingPropertyTests = function() { + return assemble(missing_properties); +}; + +root.getUnspecifiedPropertyTests = function() { + return assemble(unspecified_properties); +}; + +root.getFontSizeRelativePropertyTests = function() { + var accepted = {}; + + for (var key in properties) { + if (!Object.prototype.hasOwnProperty.call(properties, key) || key === "font-size") { + continue; + } + + if (properties[key].indexOf('length') > -1) { + accepted[key] = ['length-em']; + } + } + + return assemble(accepted); +}; + +root.getAutoPropertyTests = function() { + var accepted = {}; + + for (var i = 0, key; key = properties_auto[i]; i++) { + accepted[key] = ['auto']; + } + + return assemble(accepted); +}; + +root.filterPropertyTests = function(tests, names) { + var allowed = {}; + var accepted = []; + + if (typeof names === "string") { + names = [names]; + } + + if (!(names instanceof RegExp)) { + names.forEach(function(name) { + allowed[name] = true; + }); + } + + tests.forEach(function(test) { + if (names instanceof RegExp) { + if (!test.name.match(names)) { + return; + } + } else if (!allowed[test.name]) { + return; + } + + accepted.push(test); + }); + + return accepted; +}; + +})(window); \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/red20x20.png b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/red20x20.png new file mode 100644 index 0000000000000000000000000000000000000000..5d44ef210e1132a7de6c5442ee47d3a220dfc2ab GIT binary patch literal 160 zcmeAS@N?(olHy`uVBq!ia0vp^A|TAc1SFYWcSQjy&H|6fVg?3oVGw3ym^DWND9B#o z>FdgV7pRU^Vw#v22T(||#5JPCIX^cyHLrxhxhOTUBsE2$JhLQ2!QIn0AiR-J9H>aj y)5S5w;&k$#^A2_iNfK9WR#k?4Uh$0aDi4Fw97c5^KZPQoDh5wiKbLh*2~7YTawj1G literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/region-in-body.html b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/region-in-body.html new file mode 100644 index 00000000000..78038fd28ff --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/region-in-body.html @@ -0,0 +1,36 @@ +<!DOCTYPE html> +<html lang="en"><head> + <meta charset="UTF-8"> + <title>One region in body</title> + <style> + html, body { + margin: 0; + padding: 0; + } + #container { + background: red; + } + #content { + flow-into: flow; + font-family: Ahem; + font-size: 20px; + line-height: 1em; + color: green; + } + #region { + flow-from: flow; + } + </style> + <script src="util.js" type="text/javascript"></script> +</head> +<body> + <div id="container"> + <!-- The &#8203; entity is a zerowidth space. It enables me to create nicely reflowing rectangles of Ahem text --> + <div id="content"> + xxxx&#x200B;xxxx&#x200B;xxxx&#x200B;xxxx + </div> + </div> + <div id="region"> + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/region-in-container.html b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/region-in-container.html new file mode 100644 index 00000000000..219fce6503c --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/region-in-container.html @@ -0,0 +1,38 @@ +<!DOCTYPE html> +<html lang="en"><head> + <meta charset="UTF-8"> + <title>One region in body</title> + <style> + html, body { + margin: 0; + padding: 0; + } + #container { + background: red; + } + #content { + flow-into: flow; + font-family: Ahem; + font-size: 20px; + line-height: 1em; + color: green; + } + #region { + flow-from: flow; + } + </style> +</head> +<body> + <div id="container"> + <!-- The &#8203; entity is a zerowidth space. It enables me to create nicely reflowing rectangles of Ahem text --> + <div id="content"> + xxxx&#x200B;xxxx&#x200B;xxxx&#x200B;xxxx + </div> + </div> + <div id="region-parent"> + <div id="region"> + </div> + </div> + <script src="util.js" type="text/javascript"></script> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/ruler-h-50%.png b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/ruler-h-50%.png new file mode 100644 index 0000000000000000000000000000000000000000..cf2eea6b438a11503a89414cbb2f9f1fde55df0c GIT binary patch literal 691 zcmV;k0!;mhP)<h;3K|Lk000e1NJLTq0077U001%w0ssI3;WRTK0007dNkl<Zc-rlq zy{h6s7=~wbiC|&k#KzV}uoP2RSPBY)sHIn;ot@^CYHeD*0k6SU@&o=<wt~SzQP6LT z+1+9bIY?G>_PkGJCLw%0c_-t<Byu8R0TE%rfqnf#2=STCc!0-|BNJiWm+$+t+3XF+ zG01&|R6WZ2a%FMO8DoZFSe6xdSs{%)dLqg~Sttu-y|XONIp^Fk491wQ>y1Vu;JWBp zVzJoqc$A+V$Du&M;PW30)i^&u7Gwd)f-J~_EXabafA}Ss^LRYITrL@7hr_}5ea4uo zs-EXfr_-?8qSw;z_hYfxZnq<%d_G?&6l8n7UMHeNA~7D1DXd_+^X%M^b1Xhu#0egw zA!I?;mp#FUr6!IGxafwE1t1HuAPce}3$g%YK^9~|*6&HOysvn(*(i##-EJ9UsZ`3c zEZerjZtKO@{G-umsZ=7OWHL!ax~|LH&Qw+HcDr($*H`sP-cZ*0d?q4I(}+k2AsaiL zj;3j@>xNm@j~53yo6Tl2nfZLaSS%Dp@jOqqx7+P>I$bK2_WONkdm(-b!)ORuq3(u{ zuZ3eR);?H^UI=h{2M87b0ALRNMpGQFFcbm=3m{kkAXosw0tglW2o^xF0D=Vof&~yP zfM5aey@Mqmboq;Vy>6Q3^?Ef;v)OFQ#$+;S+qUC4@()R>)vA0j20RIU1AN~f3<kMe zPA*0wk^B8lM7P^58jZ@v;czH~5JH%ySu7Suqmd9o*Y(L{67t7~@KDnmXti3a)#`LQ z^?JQ>xhxxNwc21XxLhtDA0P5nd4E{1*Of{|zC6!y9M^SKRYkDydOv{gSOCES0Ko#G Z;3u}YJM}AuyWao+002ovPDHLkV1h`wI+p+d literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/ruler-h-50px.png b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/ruler-h-50px.png new file mode 100644 index 0000000000000000000000000000000000000000..9f46583665ca6471075227f9e2244f1ba1ffece0 GIT binary patch literal 671 zcmV;Q0$}}#P)<h;3K|Lk000e1NJLTq0074T001%w0ssI35I<<G0007JNkl<Zc-rlq zv8v)g6oyYUj*(OvJMF|<*xQPQHX;gQ=Q9YtMk4qIcD_Uk3p+s&EW|>6gP<0o<3OBS z1j1$6y@J=>jmiI2W)i~T^Pfp3CPtA`(u;`E>xkCAIOm38{A6Fs3%^GNnFzqX(&;o2 zDT)%hOaxRt$_h?dilXdxyZwIuAIl18<k1sR7Ro|dDC@73<(+Ub#)4IrH|Pr?i0E>; z;NbHP*$SvFj1Q0nSpc#i3$h>!vLNd#s;X8h6(Y)HGDMWkW{IfR>*e!#BI@`1L^K!- zq999sxJ98*&~=@N=JPpYY_r)A(Q>)W<#PTuuIolY7N$GT%2E_8{&5kbJC1`e1yhkZ z{QWZiAyepm0H$CHreF%DU<$w#Ou-aPy%*}kd9U|DN?9(KiD<D{L{ydh79vWeQmfTU zN_jXOj>n_dsO!3I+fqu~wx`pn*C<1c`p_d0X`044S5?*jCFXoSGsc7vhGD3xigAie z)6_I=x7!g>wOXy$>t1^zkyx+So-)UAqG0No%Wt8-X!kNxI7<M}X6pN1hP7CW{s%Cs z1EdN70HQYojOJV%M?e6ODu7f0qzV9}3LsSgsR9700!S4=ssK_208$0QoT}fxKB3)i zTb3n+uq><7>A-U2c*&C|r_;$a%~Gl4EyiN8`~5DZbX_+dkNXem%w{vr`D8LF7K>iv z?RKlxYUA;^)oKYL{4FJTXMQ?Xb-Uf|cFP#!ocsSC*Jw0`!=VsjG#WLVO@HH$j}Ibp z9OvtMgBWAUWb%5w;_jEw@bB(q!d+8H6#$q60;CFrn@_JUXnGtsT_OMg002ovPDHLk FV1h+lHID!Q literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/ruler-v-100px.png b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/ruler-v-100px.png new file mode 100644 index 0000000000000000000000000000000000000000..a837eca2225082917dc952efd5c689e1b51d7bbd GIT binary patch literal 760 zcmeAS@N?(olHy`uVBq!ia0vp^MnHU=gNcEGaWU)iTMP_L`#oJ8Ln>~)opsRfQGkd; ze)kq>afh25lNKiW9??&5?NHJA%O>=XS@{0}+4zG^EwY_?F_M#iv9}3z1aeiSUzA*K zu(aV(kHK?2k3BK|`KL4QXWugp33W=8Xj?T)Nc8vQ(%9`GT4(2eudkH7c2+NL?u$dR z-nKS2Z~j`Y^K+f^ZT|OzL59~vJ9g=>@?L(q?{UxZ$KUny^7DVzuDt!h?mmN?plfyf zmG|FWk8IKrjGUqMkB_(Yd8N`MAGQ3vyhA@<bgG)GyNbMZyBKBu{M65@X^X#_xz|N( zNI2NE)qRbRnzGW(oG=%g^U{3n2NQ}bDsH?iaanTtWy$WlscV`SSj{;6?RV|zP4C{l zb6FCjH+xxSZLO}-<dZ7%&v$p^-rjt(=cAyQ4#>1ywbzy(%Ux#+<}|T#gG9?_n$GnL zUK#SiePsyOw7;>}x9Vgku7B`~<KEgPU54g^2R_?``Yyk`>Xk*`s(JJ0KQFQj%{7r) zbt}iL)bq?nx5a@6yp{&7nsqXz>CffMm(RcYnakO|rl9#~(#I!HTteT!e?R%;lGnRd zMQMom`TO7h&1I+D{M{YwHHiH{KeA^3UX!~oKff$N`Q3$OHK!M>^?md}Ue5YP`;WJ` zoGPcdSKa}V$916$caR7I{lB!WCtmR1qOjFlqjc|ok6s(LH?H5a&h2Na;zQo04{aAN z%iOnj@5)!NUuP>#?C|XJSbx2`vNCh~ZFhHf$0DPdQ%*l!y?XWL&Bph?D}P^q>`h+m zFXb?;somY&_rL4w>#x3=<rC!6*Wd5@<m1PSg>$|yNsZi=Yj1B~pCFjW&0YS{yFmW8 z{%3D_dwKh-9vNpof7j<_ShMfbl=P&-N7}Xp$UV*Eei}Fr#*lj&2u6iKLAmWf*~0AY cw|+4$pP;3B^U*VLV7g}TboFyt=akR{0G}~+v;Y7A literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/ruler-v-50px.png b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/ruler-v-50px.png new file mode 100644 index 0000000000000000000000000000000000000000..84141028020b7e8cdf2412acbca3c799ba50a534 GIT binary patch literal 757 zcmeAS@N?(olHy`uVBq!ia0vp^MnHU=gNcEGaWU)iTMP_LdpunnLn>~)o#p7Q6)4em z{$d*2BG*@!Lc3jVdA+?Q+2PW(<&`<hUq0SH>~H^wHaWhIaoO!ruE(m{QKE2v_l)kA z-e(KKcYm$vKGDDac}?&6nKO$m!Y2I`xEAGUC@i-6WK{O=zyHpiJNNeO+xv#s?=j!Z zxcM?)V^6`#D~}&Pp5?A$`q-&{Ubpelh>!(auZC((&D%cv^wS>0zQ+>Dv(7%_|5v|q zao)lohkkPybSa7E=I2W%vo$wv-F7j<M5=efqK_3hJ(iZ1hR5E#eOo#2c)7cvt4QFM zmy258?Tg>%?^YeP{?keR*WWj6TXu)LZemGAMMlrg{rmeFE-(LJ<A3S&Y482_`L|4a zV$ruGZ1vX<9}HH``Sp4I^9xs8BD45(?Git7i|IscNI2NU%6%<AQFrUQr?(D+*uNsK z-AeFYem8ITy4x>H79F(9J8|Uk$H$M8Jv&{Tg0!YiDk&_S=(k)oHZIO<*REZcdS={{ zuBxt{yk+-pZOxfJY$vZ@zkcEDg32{MYQY*JDz>(^mVKA=wyUOYzPWhuV$b-4=Px{% z$%e2T?g|j&pZPVd@7osh<~-+>HNJ0@q3xBETkz(j;nVk5#ZE1@IrSJs=KbBV&8b#r zs@K)5tKa`-ZH>~KK0UlH?2I+Pa;AYqh}P8R=H>^<I%3lO$0yypfB*5vA5Q|#-o1Ob zz+%ny*S~-Nb}TZHdiwe2?Afz7Z#KUF-I?$98QU)7&slTl&$qX?-@VRShVSyrk_kFu z-9WGGdw)G^>*dRrJqy()8y@>owKqh|)N|Lm*OhSvei_W#^M7W~=v`a$@8~4GJx?va z-#4{oh}c&&{rS;0ap_x5l~b1MPI0e<Gk|OmIt~)N1C)g`AmVT`zVHuY?mGL;&f7B= Q0uwcZr>mdKI;Vst0OKlsf&c&j literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/runParallelAsyncHarness.js b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/runParallelAsyncHarness.js new file mode 100644 index 00000000000..460f467930e --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/runParallelAsyncHarness.js @@ -0,0 +1,145 @@ +(function(root){ +'use strict'; +// testharness doesn't know about async test queues, +// so this wrapper takes care of that + +/* USAGE: + runParallelAsyncHarness({ + // list of data to test, must be array of objects. + // each object must contain a "name" property to describe the test + // besides name, the object can contain whatever data you need + tests: [ + {name: "name of test 1", custom: "data"}, + {name: "name of test 2", custom: "data"}, + // ... + ], + + // number of tests (tests, not test-cases!) to run concurrently + testsPerSlice: 100, + + // time in milliseconds a test-run takes + duration: 1000, + + // test-cases to run for for the test - there must be at least one + // each case creates its separate async_test() instance + cases: { + // test case named "test1" + test1: { + // run as a async_test.step() this callback contains your primary assertions + start: function(testCaseKey, data, options){}, + // run as a async_test.step() this callback contains assertions to be run + // when the test ended, immediately before teardown + done: function(testCaseKey, data, options){} + }, + // ... + } + + // all callbacks are optional: + + // invoked for individual test before it starts so you can setup the environment + // like DOM, CSS, adding event listeners and such + setup: function(data, options){}, + + // invoked after a test ended, so you can clean up the environment + // like DOM, CSS, removing event listeners and such + teardown: function(data, options){}, + + // invoked before a batch of tests ("slice") are run concurrently + // tests is an array of test data objects + sliceStart: function(options, tests) + + // invoked after a batch of tests ("slice") were run concurrently + // tests is an array of test data objects + sliceDone: function(options, tests) + + // invoked once all tests are done + done: function(options){} + }) +*/ +root.runParallelAsyncHarness = function(options) { + if (!options.cases) { + throw new Error("Options don't contain test cases!"); + } + + var noop = function(){}; + + // add a 100ms buffer to the test timeout, just in case + var duration = Math.ceil(options.duration + 100); + + // names of individual tests + var cases = Object.keys(options.cases); + + // run tests in a batch of slices + // primarily not to overload weak devices (tablets, phones, โ€ฆ) + // with too many tests running simultaneously + var iteration = -1; + var testPerSlice = options.testsPerSlice || 100; + var slices = Math.ceil(options.tests.length / testPerSlice); + + // initialize all async test cases + // Note: satisfying testharness.js needs to know all async tests before load-event + options.tests.forEach(function(data, index) { + data.cases = {}; + cases.forEach(function(name) { + data.cases[name] = async_test(data.name + " / " + name, {timeout: options.timeout || 60000}); + }); + }); + + function runLoop() { + iteration++; + if (iteration >= slices) { + // no more slice, we're done + (options.done || noop)(options); + return; + } + + // grab a slice of testss and initialize them + var offset = iteration * testPerSlice; + var tests = options.tests.slice(offset, offset + testPerSlice); + tests.forEach(function(data) { + (options.setup || noop)(data, options); + + }); + + // kick off the current slice of tests + (options.sliceStart || noop)(options, tests); + + // perform individual "start" test-case + tests.forEach(function(data) { + cases.forEach(function(name) { + data.cases[name].step(function() { + (options.cases[name].start || noop)(data.cases[name], data, options); + }); + }); + }); + + // conclude test (possibly abort) + setTimeout(function() { + tests.forEach(function(data) { + // perform individual "done" test-case + cases.forEach(function(name) { + data.cases[name].step(function() { + (options.cases[name].done || noop)(data.cases[name], data, options); + }); + }); + // clean up after individual test + (options.teardown || noop)(data, options); + // tell harness we're done with individual test-cases + cases.forEach(function(name) { + data.cases[name].done(); + }); + }); + + // finish the test for current slice of tests + (options.sliceDone || noop)(options, tests); + + // next test please, give the browser 50ms to do catch its breath + setTimeout(runLoop, 50); + }, duration); + } + + // allow DOMContentLoaded before actually doing something + setTimeout(runLoop, 100); +}; + +})(window); \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/square-purple.png b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/square-purple.png new file mode 100644 index 0000000000000000000000000000000000000000..0f522d78728417b0f74b694e2e47cd41c00359d1 GIT binary patch literal 92 zcmeAS@N?(olHy`uVBq!ia0vp^f*{Pu3?vyBU)>3$*aCb)TpJh~{xkePDssRFB<<<q n7*cU7`N#kLjg3MaSNIuL+z|fjF-g!1D9PaI>gTe~DWM4f*isp& literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/square-teal.png b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/square-teal.png new file mode 100644 index 0000000000000000000000000000000000000000..e567f51b91bbe40754cb0e0cae066201219cbb4a GIT binary patch literal 92 zcmeAS@N?(olHy`uVBq!ia0vp^f*{Pu3?vyBU)>3$*aCb)Tp1b~82<lv|F?D~NZQlI nF{I*F@{j-f8ykf<uJALgxFP)4W0Ig3P?EvZ)z4*}Q$iB}@>Uv7 literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/square-white.png b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/square-white.png new file mode 100644 index 0000000000000000000000000000000000000000..5853cbb238cb2d4aba3dd49af3f2ba64d6c7a2de GIT binary patch literal 78 zcmeAS@N?(olHy`uVBq!ia0vp^f*{NRBpBq_B-DVEsHcl#NX4yWiv~UkzCZ4)$}udm Z3=C_{1@!OB{@4Xl=;`X`vd$@?2>|f05A6T| literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/swatch-blue.png b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/swatch-blue.png new file mode 100644 index 0000000000000000000000000000000000000000..bf2759634d45dbe3df13868341eddb7e4bf24172 GIT binary patch literal 84 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K83?vyP*g1g|bAV5XD+9y-u8K?HKrWA`i(^Q| dt>gp+Mj%g@f$_JNuojTT;OXk;vd$@?2>>P$4{-nh literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/swatch-gray.png b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/swatch-gray.png new file mode 100644 index 0000000000000000000000000000000000000000..92c73561f3a8b74b279c2859a0b13145ef12f40a GIT binary patch literal 163 zcmeAS@N?(olHy`uVBq!ia0vp^A|TAc1SFYWcSQjy&H|6fVg?3oVGw3ym^DWND9B#o z>FdgVmt9swTFAKFy%s1WS>hT|;+&tGo0?a`;9QiNSdyBeP@Y+mq2TW68xY>eCk|93 z>*?YcVsSb-CnF<4LEOMFfWghQKTGba&8nG2XBpaS8CUo{xWf)q$l&Sf=d#Wzp$Pz< CekfxA literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/swatch-green.png b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/swatch-green.png new file mode 100644 index 0000000000000000000000000000000000000000..0aa79b0c86bd72c2220ecce39b9553e2cd3605b9 GIT binary patch literal 84 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K83?vyP*g1g|bAV5XD?<aroS#c40=Yb%E{-7; dw~`YS7=b)p2FBl7!dgHUgQu&X%Q~loCIBjB50U@? literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/swatch-lime.png b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/swatch-lime.png new file mode 100644 index 0000000000000000000000000000000000000000..55fd7fdaedfc1ed505b111f20fabbca568c68fa5 GIT binary patch literal 84 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K83?vyP*g1g|bAV5XE5m;VlehybfLtC=7srr_ dTgeFuj6j|)1LJQkVJ#qw!PC{xWt~$(6968w4?q9_ literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/swatch-navy.png b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/swatch-navy.png new file mode 100644 index 0000000000000000000000000000000000000000..28dae8a3e12bea03cf41b020bf05540adf9da17f GIT binary patch literal 159 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K11SGd?VUh(>oCO|{#S9GG!XV7ZFl&wkP>{XE z)7O>#E{A}KxioXY?P{QqWQl7;iF1B#Zfaf$gL6@8Vo7R>LV0FMhJw4NZ$Nk>pEyX7 xr;B5V#`)xwgp33QDFed^Om3n5tCsD{VrW{=FfT{-zcNq}gQu&X%Q~loCIIazCb<9r literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/swatch-orange.png b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/swatch-orange.png new file mode 100644 index 0000000000000000000000000000000000000000..d3cd498b52bd88ea6c991f050f1ecb1cfdd136bb GIT binary patch literal 84 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K83?vyP*g1g|bAV5X>;I(;rzSbh26A~kT^vIy dZY3uuFamkH42-|EgtdSy22WQ%mvv4FO#nq@5F-Ep literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/swatch-pink.png b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/swatch-pink.png new file mode 100644 index 0000000000000000000000000000000000000000..95b84499a3d849cfd74eb8711f5d2a1bc45d0c39 GIT binary patch literal 160 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K11SGd?VUh(>oCO|{#S9GG!XV7ZFl&wkP>{XE z)7O>#F1v)dmTbUZVN;-xWQl7;iF1B#Zfaf$gL6@8Vo7R>LV0FMhJw4NZ$Nk>pEyvF zl&6bhh{pNkKlKkxm@hVTHi{UmstPgv8p_P@ua9X3)ACoBfT|cgUHx3vIVCg!0A2AZ AjsO4v literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/swatch-purple.png b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/swatch-purple.png new file mode 100644 index 0000000000000000000000000000000000000000..73bea775175e9bab0dfe664eaea9ceaa566de787 GIT binary patch literal 153 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K11SGd?VUh(>jKx9jP7LeL$-D$|*pj^6T^Rm@ z;DWu&Cj&(|3p^r=85p>QL70(Y)*K0-AbW|YuPgf<CN?H@8SBFiJU}5yPZ!4!jq}Ml p2^k3rQU-<-nA}49S1sF@#c<n>Q7&8X=USj522WQ%mvv4FO#s*6C0hUh literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/swatch-red.png b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/swatch-red.png new file mode 100644 index 0000000000000000000000000000000000000000..1caf25c992aa8e23483cddb3334b5f51ec967f4a GIT binary patch literal 84 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K83?vyP*g1g|bAV5X>wg9Y$w!>#KrWA`i(^Q| dt>gp+Mj%g@f$_JNuojTT;OXk;vd$@?2>=8a4uJpw literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/swatch-teal.png b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/swatch-teal.png new file mode 100644 index 0000000000000000000000000000000000000000..0293ce89dea5c9413e4c829cc83a4e39d8f23300 GIT binary patch literal 156 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K11|+SoP4xm&jKx9jP7LeL$-D$|*pj^6T^Rm@ z;DWu&Cj&(|3p^r=85p>QL70(Y)*K0-AbW|YuPgg4R#65`cCM1`H9#R5PZ!4!jq}MV s85uv$JE$cjEnw)$lDlfNN|Kv_A+(E0c5RvdE}%LFPgg&ebxsLQ0IVw~FaQ7m literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/swatch-white.png b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/swatch-white.png new file mode 100644 index 0000000000000000000000000000000000000000..1a7d4323d77287d8eb03a89c635b09d099d94869 GIT binary patch literal 85 zcmeAS@N?(olHy`uVBq!ia0vp^{2<H-Bp8I(u6Pcln3BBRT^Jbeb_p*5^7uSm978H@ gCI9%}-<ZL|Fh5TA$_Ah94}dZZp00i_>zopr0Qo5vZ~y=R literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/swatch-yellow.png b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/swatch-yellow.png new file mode 100644 index 0000000000000000000000000000000000000000..1591aa0e2e274854ed836cf582235ea0202f9c8e GIT binary patch literal 84 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K83?vyP*g1g|bAV5X>;L}@UB|w-0=Yb%E{-7; dw~`YS7=b)p2FBl7!dgHUgQu&X%Q~loCIDbL5Y7Mq literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/test-bl.png b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/test-bl.png new file mode 100644 index 0000000000000000000000000000000000000000..904e24e996a3e5da93bef89e10c49e24c07d0ed2 GIT binary patch literal 1368 zcmV-e1*iInP)<h;3K|Lk000e1NJLTq003kF003kJ0{{R3g3O3#0000aP)t-s005aY zGnr;)nE(LHGc(L)X3UwH%*@QpW@i7Hng7hp|NsC0s-1y@0000CbW%=J|NsC0|NsC0 z|Ns9065r0w00001VoOIv3m@0SzyJUQ%1J~)RCwC$mrHKsHV}qI#0OA$)CUNV+0PNC z5z>1FDgrZWOHO<59>534BKsDgp7p3B>I7zAF2$Eby&QX;;i_BGr>dV-tSTkfVYNIl zi$7l1mTrsB_C8C-i#4X^3LaLG>jn4e0?941+dy=QV9i9xkG(@4H;@(~ogt^a`43yj z^`**Zh^{Td#Pj%+Qr%fKN-5`g;nYOF+LzqmXhmO+m0gFk>gfe#F-NRAhUdXXT_P3& z5hZ>zhPowUE`a<#=%qb^0(KmTs?O^A;`TX0ocz1q{qO362uJ`J02e5qdmo1g`RwHP z!A7z7fk;yZJFK4j+J<J_!!kFwGv}DTl*m6N!y-fSp;zS$vG4R+^f3f3FkDp6`iZB@ z9Rq0{yOh5|GFgnv$G$b5jmSNW@=3{zpgZ``cV=57#LB;M$gx-;>{j+R-gEgot3{VQ zT_EJMJvHm{U-0*2vCJ(xH5>9<9E?yX{cn>?Cg7{`b(@FBIAj4b8LLlxUA}&DNX9v( z3NQA_a4!BS*5!`~%BqqjA5Y&4uFEHnEyD3&j#zU)o^f5S%cniIzr|OZ3i>ow5`DiR zKV-E(ZYQ3EdZkb6@<UeNeUB?iBFq`D*X2*MI!I#{X}9FZS$$Qmwt_`|Y{-wZnqKV6 z1blp+IyR9XXEjwg7bU<2vXH;?C)8Cq%49XyvL(Ou3A1w<`?`EvZGvCF2-_3drF_v3 zWsvc|O+gEO*$ta$@sA0cmcFE8)2I`NWRx;N{9|`#gBRBOOq5lHKJ|AG{lc-r?c}4) zL-$z5Md6GLEg?qSW3G#N#pKN%xTocLj)Y#BeKpr}_iC1cFHVHGREV^M$HW)&`;U1U zqa(S7SZ8*J-qhDnFUE@G8)EF3n+2Q$s`7)uute1_k<QgF7t5n>rGpW1SV4To*jSQh zlcG$a4=ps-GU>1C2_a&@$I%?>7`aa!VnfzdIeZ#?+sUD|PY~B%U0^7GO|Nu@sDsJ# z@KlWWEXlsO1AjC<{IhGw<M`A>1$M}i5N36xL4oHW;3LYQL{&USeE7rWXggil@q+qy zcqZ;IV<F)o1Yw4G7>JjWW`PLt<%)`T&`L8>V}>Oa<kn^+iI7n5LHubaqvh(*WJr7^ z)T>O$2em@zx|mEC771}cDVqgE!@z!yT>QYv82lFP(%@F<5;wl4TqknAA$72YTMI-# zh4f`KPMMiy>XyGdc~Of)_A<zfoj!JJF(=#0d7SY)+PJ~38KUdBOaRb$*jPKdJK=EV zrkm0Z8xVG(YE0}Yt@-e>+14L1KJ#R!khI&B)WtXi&X5b{lL3*@ZkLC@MvW|+A?7gN zW^9D0T;2*9*?`>~p)-$sKP@gC`DhvB0@0TW$+>vr68OLZ|AFHIA?8UIVp5VL8#iJF zp>x%gNY!OhEyLo1uORl+--}g*Wst2R?yDkOfv7^I8;JRK;rXg-$rj?i69C?WTvb<5 z-Ama!5K|d3=PQC<K{RE8uwP1VM##=LEUkC!&4^ZAZE86{8mYSe$D&=JS`K8398A-< zAkI6YxS&bnwNTEyqw<esfq5o26J~CRQnjl~iN@O75YIKX+q?rYE}CZZF2t>$$WP>d ai~I`(b4pM507-ZN0000<MNUMnLSTZUYM}!F literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/test-br.png b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/test-br.png new file mode 100644 index 0000000000000000000000000000000000000000..f413ff5c1a0f2ad9f9a345d3e07be57a59a82207 GIT binary patch literal 1045 zcmV+w1nT>VP)<h;3K|Lk000e1NJLTq003kF003kJ0{{R3g3O3#0000aP)t-s005aY zGnr;)nE(LHGc(L)X3UwH%*@QpW@i7Hng7hp|NsC0s-1y@0000CbW%=J|NsC0|NsC0 z|Ns9065r0w00001VoOIv3m@0SzyJUPhe<?1RCwC$ms@V5FcgLlnk;}*nH@}b&;=9; z`W^{0$~+gU<h>dx3m9n@P^7faO%<|&!sf>KZm^B!d3qut2z>beeU2{xp@)&j(02`` zTY^Y(yls!8j-g6{#iqXUOZZmq^{tQRnwIpYptOGKE#wg=geU|udB&pePc3cOueFKs zvzd?t6~fN!7xtH~ecHeFR|~mNE=(hU<zcj=XW{%Yp6UJ6N@ftUzmC!P5cbt`?6jy? zkn>j9-;D~v`nZNntt8~9LC7xNOec_RZz1(-9N|5dP=m0v9-_#(n4W^-V2~txiYhzj z!i$YK*$mpxEQDn<+Gk7q?5d2K>8gc&fN~c@-gEJg62@yGi)KdJFKsVL7OffK1s(gk zuDvn5Y{BU<F%-%e((qKG8u5Ul%idy$ct({KxR(KBlCq)lwQ%n=>I*USjd;i%YrdEb z{Sn*_^roe9hCXX0U8@*Tm5}W<;uM1)L8qv|EjeFw?$DQBbYc7Y_+{2Z;0_;OA3x6W z0PY|Sr^RF&+^N9lo^nJde+0T>e|Q%!CAxA~?GMkwJ^q*@L1D^DW{@@e8aZfW&HlL( zh^h58`-7ZbHV<zaS+W1w2>0aSI!6vcWNu~EzD%TLWzD`y<i?s$R_yCU8Y@az$o?{s ztJ8(Yy+rUffV?jfsir=p{xwOCNIQ`VxeF})mt`W=%)g=j#qveyLfcAweUa7TT2Y9% zj|Z80xYL7JBN#v$SuMm7!T-APcUV_RUG7#w6p(kTFo<b#?tbL$mc9)MbD|J81-xCa zu1iy(+!eIf8G_WOYv>wDV7Xr)zJ+r5pkj?+g<rb&*<VHdwnQ#%k*B`?n)b<=Z)r8M z*w%Y?pY@=}iIK&e%yly-p3Gaau$<qAqFp+%WF>S_u|SWDG`g}53&gW~H?kPATZn)^ z{pHpDF0f_Yc)Al>7VPVTai^XiPQR;MAxJ&d2ec|FrET5HXc}tCS~{7gaV(KcTp<oc zQD|B7>QZ^Z1TjZ~gu`3RQzOf}P2=}cU|fp)kR|{zS!z=9ML<>z3CM~dAz5JrL$V?W z4Q^@!)=5xS07+PK!ylVGm5`=3ktPvYvS1MHR5ItZK3>BJtE{TnlF}3mey44O;Kkq6 ztd@0Ivcj%UvClb}M#-r)(X{Qa==a|U(_!d)YlyiY`vK(N;tTmg{#)cPVxOudoeJ1E P00000NkvXXu0mjfoHYWE literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/test-inner-half-size.png b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/test-inner-half-size.png new file mode 100644 index 0000000000000000000000000000000000000000..e473bf80efc66766cb32ec2cc60244ed37dc1157 GIT binary patch literal 180 zcmV;l089UgP)<h;3K|Lk000e1NJLTq0015U001%w1^@s7JXu?L0001cNkl<Zc-rli z!4AM62t%pa|Nk<(E?zL=Fq+2^X)3e<nYr61nsxC@Ld$8rPiTZTB&ja&s6as%ZJL|M z=rOcU${2vp2YUvrojv1iz<}=oKePMm#BU3e)Gz&dnG;ue53v^M#Hf!LH5!*`jH~Z= iHN+4@%ynW{5626)ITymFxuX~W0000<MNUMnLSTZVu1667 literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/test-outer.png b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/test-outer.png new file mode 100644 index 0000000000000000000000000000000000000000..82eeace7fc0c4202f79610978ab423e62abf8939 GIT binary patch literal 2412 zcmZ{mdpOg78^=c{EOMMh4qF~6Bd3rFi9{I*a|(^Nvdq~?QjT*?4xw_Itd@FmT1%@; zkHai-Y6->Aa{4*!H%&eKiag(`-yhHQT+j9WT%Y^CzTeON{@nNL{(P?Mo9&Krl9f@D z0f9iW&L<o^0NV)yNkF9}fteqx$p(R>O`RQ%dM1nrDqQhOXQ7#ug?V#Sa2fmTSTTg# zq5n>b3YP6~G}vwrp{7((H(F%s9=vs(d(vdsw5S`*{!`K=^0e|Hs;%}@ZAe9;YhM#o z_ToaBZbi>ZoPth;c~{8~-g5bm@{$}EyaCQ}|KNtGC?`*cg`T-jp?`3qQTBgZTv?v{ zsdiqg_=L}TaeDHp)WEMH?m}9l;@m~8p=7pF>!36@MZO>-W1E4=+P#fwf=QndMcXv7 z8Z8-fF2Q7mdllSkqq$$v5O4Max@#iK>)>}|J2%opy`et}FlLkY$|k=MPb|h-F&GS# z`yPH&Q53dkQkZ<87kdVuoRE+pLOXW`h4H>u8uuqXC&Rob*li9oo;cl8K)zjxUvIBg z$)w}LH2k-=iDKc?$`Kh8{tr6}PB1uTuEZnV2}8sH8=6vc={^tU1@E=j4k~YXOGQ|X zkJ7bc);}A=x!>Q|ZjgqKn<q^%>txci{z1vOpT5iHp(Eo0q?hU&McH@xcJuaJ!&r=t z?vM4Ew=lmncbCv<w<by^%~!2EMkjjnd54&X#Od#j14r-;{%H*anvq+xT4z&^R~p5` z!xS#*RhyBq#-3+TSq9ZKkNp)WoXPH4H-m1)g6J1}?lL8tMqKR^6?)~97d2-4DhB+5 zUdGN1RJ+xB<5yKLk0NkP^&6b`?>%iQg%g%g!y>UhwjyyUTO+MrE;m#Qlfbq|*dc(4 zZC|6qC(sSHP6V-iNf|!edmH+^^*p7Z*`Fr|qZ;SsTT5vuq{VfH<xT}KU7pO%=gQ-v zpl}EV2Ej;R3K*TfdooFmy;Lk8A$M$3@V7ALWqa%n93N4h!H9%#CFmf!JRkt3OVQHb z4OBETnat*91Ne0G$7cc;8XW%MV(Eh}E-|2Hw!aen*h^t9zNtCIQK#4?o8<B4NzKA= zJ-KtNi74c~C_F{C-09RZX5o7;K}%g#V~>E_u(9E~{{7oy($sRI!r_#kERyw=)upx! zFkJKpcdtUCXezrquiN45{@FUmzL;55Wac?m%0{3=Y46O}udzZQvI2GYkbbEmgW{O# zB*tP_1EQvt8AEX}i1ucwo7Do-=J@@}d(C-#{nOcUixx3CVB}<e`Lw}_xWS0LbrOGg z-0$$Y+G<jqNui?4Zdoxsu$TaOYd=pOXKWEl=;Q$~#Yp}}11wlrY@mF@rT&tjQx2Kc z;EdG(+Qw=(0gQccTmb_LX#GO@-=ToE{*}o1S&Q<qR$oGG$H$7QsF?VyQgL%mGamZB zN8AN0>yfx&o9U9a{k9oC*L+CRvNc6NGmAaSr-%G%isWSVX*Ri;gJFYDY61-RZMJ9s z-`z?*?sVx<BY`>k?ebatm>?cmkvn8n>~gVoVD9PAWg?M?$DhQ9`wq>_JP04nEs0as zGCYyp$>C%Uz4Sbg-8nx$KQdBELKqs3JZpaXR0kdt6C;QpRUl$8ZN2BT1ay8+QeDwI zu62>#lKkWL24UmrHRFc%C7-=lR_WXembP{E_3D{)24gRLd3m`56V=JI3W>Gc@|ghD zM4FnK`Yo)lucxJLsZJ~`ENt|1#h-mVSROoe^Uf(EVVw0btkFTIuq)O|12?%MoRDpA z2yb%N3pEM(Fd#*y6-Dy|)=~4^T7Ra;qxZn6bJQv8eU-G*cUmx99|SwF1S^VO>?Mcy ziKu&}Y5&7fzUR%+PBa2D*ec=Nds+$#Hi85rKsnpQ4u~Tuc0eH#V&@ut(`oSm91zDY za+r0m+14Xz`N-u=du{O&XwC%ls)q~AieIs$nYA?j`i;>+?lE4qb*u__4g0>Wic&zo zR+V36^t{R_-%yv8wr}-_^1lgZWPfdu3O$yvqYW912-Zu#GoWhgovH3+iIzI{A=E)V zcQydV*I><E=u_da(q7DH+)<GXMo3AvA=y+6U6e})iPP3*DUDxWlG~X9WJt}Yx1=aW z9f9!2A{3*A+uM>n-slX6bO6zsU?5t4944(oUP5)GKA$4KLQ4haDC`}{Ps+Ey(|x}` zyBd9~%hyJlk{^d?Lo)0)dE5l)3+)ni{3Zg_i0Xi|wj6^6BU*ew>BPGjg>hpsG84#F zFtJR+%|k#s!XCqF_ng1k)XQe2ZTWsnZZ|ncg`BfZy2~e>2r%0X?)0(asHJc|7s;{V zAyLed^iYKNI1KWOw{~cQNG_eYN!$n`KQ1lw1ky25mK1-sOUN<}du0+Jm-|WOJ}UZk z;MD^*RM{7)%54F<f89d$AT43&eEZMXjD>{-bX|b)&Pma9Hxh~L<9I*zLO^8O^&sR* z+Z4@)s8v757MByxkbSog24S(-^4S*wgp`yZd~#%@yPop)OUea1c4?kMp-^sa!(oST zlOoZRWmaIl?bWsCD++LG;;LvBull2<z%AUo%!0tXV5Zh=aOTXJiC4)n)<ylZJ1#8> zTKN2P=4FEB_A-kIhbh4*)5)gT&@Gq#)33|s%4+1d`N2!(NL$;9utxEAWYvRMlM?)J zUGmy09Ze5xzD#Sp`sH(nNMyos$)$75^*zJVnHX>A58rdx9N!z~iBj0<W}FS}{WTSS zYe(Kh?$^;NgZyZ(TL-Pc;QQJ0!or2b!LYc9i2f%v0)ZgFaP|`7cK3seBhSK1u{4h_ z@XA$Y?)2*bv%CGWDk&;eV+0`iroein?E{ZT1m@$$KVz-tVqdPbjg5@~%n0G(y?uRF z>IU6@K0Y6KJQh(%2_L<F(zQbdtgfyO+|gmbe_i?OiRXdC>Z+=$Xf!%}G|=DQ-_LJ; z{R@v*PI@{ju&;VMdI8E|v)OrCwr%pJojwJ7oSpnX!a|OIC{+5t7cWF27_n5j0g~u3 VAD}`@1i=3k$k`F)P-h>U`X3Goc2EES literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/test-tl.png b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/test-tl.png new file mode 100644 index 0000000000000000000000000000000000000000..f6ac0ef7e8f6e192c9c26239884bf92b13cf67b8 GIT binary patch literal 1025 zcmV+c1pfPpP)<h;3K|Lk000e1NJLTq003kF003kJ0{{R3g3O3#0000aP)t-s005aY zGnr;)nE(LHGc(L)X3UwH%*@QpW@i7Hng7hp|NsC0s-1y@0000CbW%=J|NsC0|NsC0 z|Ns9065r0w00001VoOIv3m@0SzyJUPb4f%&RCwC$mQ8M}Fc5&T!~r@I9HIMngrJ)4 zQ(^kjbwEn?FN@yb9iWkt>{9_J2)W!F@R;Dg)Lp$zS!5CX;rV991JU){SM-DYAV0|e zM%uPHwukYjIUJ7B*Q=ZTu2z>QMR^bD+hKK83n7YJaQrDaUiXl8N2@a^ART^^rwFp> z9#IKgok0Td0KkTyXt?~yXZ<2qM=a7Vzey#Q*6RDnL2!78qHiE=Ex4QTA^lz~J%kTw zstmq|U|5-t@E~V@SRUkpVNEL-i@q);x>HzkHGJJLeJv;~hO4ub=d-q4IFZka!eTMc zu`{buHGh%+at79akO>1WhSi7Zh!q^12-bv5K>WppZFh6@Am?f!<BIe8<ZyJvwWFFq zUcMXE0yolD)G8oeTdi8;=!mNz`J_B*yPwI?M)m~}`KHs5imGL+R7;7ZWotYNJV;A* zWckKOJq2tdq{0$$(*LL3ZKU7Jv@p{|rJmVH#VIZ=UDrmLfQ3*?VqE$rdu3uFswG*f z%lCCbgf){JI*%YWuFdgL!bDU{f?kyVyi~}>KvZ5Be|6^zTf#t8UO;S(JZAKN+3ASN z3j@6)uNUz|&Al}d$_w_F78jlrimN;suUD0qIN$0jWDohucq6MjSV#Rh_J5@Pc!G3f z_wwM3t6xj|WYw9-AC(uqCDDE%<9fTAh~QL5JzvTmP~Jf3VT_w`oktbsK$-$vb-dY+ zEip&>4?ZIC^U;m)Hw&SbOn!F;BHM*_pCjsYrK_unjA?=AlYvYnPPY~!(~?^V6%rmz z<RXVlV(+q3UGZ)qa4U<3RPu9z8&h()Lr7;MvMclhIow%G<k?0tDQT)8vXJ#M5t59J znRmOBS}sb`n8kPXi@9Ww{-vOHwGp3wv!1nUm_EL5ha0)Qi>kimBF|Bjt{e!>7aIY` z$e-!kZF!dZ$<~h?Ekqu$Hyc?mW_>Y3_Tv~aU&L~krJRVP<{Xh@#O3lKU&e81AT)VW z+l8Kn<$pJj%%^`<NBnV^?sG(rO721gjrZ5ir7vt3{7A{<<H{~jA7`ID<MD7X!t_;S zAdaE>s>@+0W|%%6zicXInEvpcG8HpS|5i+Fr$GIwnD~MX)K@9PlerDlpNfeu>p=af vm<;kz{V6gHxvP)gcJytThUyO|QzGyW8di!g0nvTM00000NkvXXu0mjfqXF-V literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/test-tr.png b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/test-tr.png new file mode 100644 index 0000000000000000000000000000000000000000..59843ae54b64f6ce4f7e616d4be491c911ea84cf GIT binary patch literal 1235 zcmV;^1T6cBP)<h;3K|Lk000e1NJLTq003kF003kJ0{{R3g3O3#0000aP)t-s005aY zGnr;)nE(LHGc(L)X3UwH%*@QpW@i7Hng7hp|NsC0s-1y@0000CbW%=J|NsC0|NsC0 z|Ns9065r0w00001VoOIv3m@0SzyJUQMM*?KRCwC$mrYXRI26aFnjFBd+de=qdOt_N zRTBGjNv4=J5|!QqHQb;NfD32Vom9jLqFiod>%)>Qhp^}!Di#F%(|iB->7dhx5Bfwt zkx%50BC1n|tx|6vK%_mLQWqnX6K;;U`FDFEg`lc|)m4wlpBK4@05B8)B_V|J%_Vlw za4<$t6qwQ5?fVe&2b-UQ(B}DF=TLGmWzFWjfTsuoBj{dz2tgQl^A0mb5R|kzAGjHU zzt-QIvk5};13=E&LB-q-)byMklsg#6^|GA>1kTt&3kTTsQcmN$3rJ$UlvDpmfxi-B zs(OsZVotq*l2F1pfdVHvT}FC0ny!_MGKlO{^1lTH|7D!$)SEgOs2&9Y@Lbr2kd{<# zhySTga0aoQC4`TSr6hxqDd{GMq~)Oxf{zHUHg7p3EkeB)qa9pj)F50=N<;4i33kkV z+Zkfqoh0ngavtIa&CE4aHM11QcA(<ZnS*i}9_-kZ;*#IbkX(ZM7}U-VnO=(WZJ}O6 zN?{sklqJk*eYL?f(2HA43tsrLxw#P83GW(do-aa9$Cseyd*a!d^}6HVyqYAe5u#PP zW%Z*kP*_6LlYHvTg7zzOR0H&%9HKkXNYMzhoi|%+O@~02w{IClNzOR!w=8e?lQnb@ z%pq|-dqh2QW;SdM6#?$Yk>1_eQZqwfj_k!6`W4$RXtT;($sb=Vf=Ltr<fHQ=Orru; zUn;qEfp&3@JVRc|I^G&)9Ni4A9mSQOHEM$Fe1C)nz8+lD!g*#oEk#T?Ym^*pUDLa@ zP0fmiPIHK0vlU}q+Y5`}FTpe9;sq1LWPGS!Et$V!6C--}V}{^za7DM=t4WauJA@K$ zMP={GAs~J}TSO4+Obz2!!c-2PJ^BD}6(L7%qhFFWlm_w*{A_jB&gyf79BgCs?>w9n z=2B#u(Pr7sL0tWekex*^{dF&8!>RY)KGWH*ffTXTQc}}ioq82%jI{MEgls^5+h<%O z^>H1Z@tJtBVk*~XX#88aM!5hI=gDs?hBhOj+jXMvWV-~H?(^Z!I&l*r!fNriI&I;K z<Iv6+Vk^Q0%(qeN5a+0NAxn^9#sT%s+L9uce-sc;vjLIT_kg$%QSX=-v{o_lKqih2 zSFAju?}mC>UB`|wTQ4r~E*vl-*0C6Qu@PH2eTrR0Wf{T~%Xbknf3wf*S&<+a`6o9M zz*S7^KKgFY$UnJ0HVgZg8jXfF%*c<rs4-Jtxk{$Dr$zap4viTq<*Snt>L({(KZLbt zzRNL^s?W;zZP~w5L&>g+M15Ai**#&3n|Wb>4eGP<`;PGlMsC0muRbf^cs3p5##&fh zIr(FkMaZ}vrt)1Swj2@$kLqXgyORsRw`3xZBX}-f+RL=$<nPGNDtben%J*+U`~KZM xFqlMZdn&(j3r#(mcWQ87&CEBe=q+_3|9^_Lp+#u>Ntgft002ovPDHLkV1lbeOeO#T literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/two-regions-in-container.html b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/two-regions-in-container.html new file mode 100644 index 00000000000..2fc65261da0 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/two-regions-in-container.html @@ -0,0 +1,38 @@ +<!DOCTYPE html> +<html lang="en"><head> + <meta charset="UTF-8"> + <title>One region in body</title> + <style> + html, body { + margin: 0; + padding: 0; + } + #container { + background: red; + } + #content { + flow-into: flow; + font-family: Ahem; + font-size: 20px; + line-height: 1em; + color: green; + } + #region1, #region2 { + flow-from: flow; + } + </style> +</head> +<body> + <div id="container"> + <!-- The &#8203; entity is a zerowidth space. It enables me to create nicely reflowing rectangles of Ahem text --> + <div id="content"> + xxxx&#x200B;xxxx&#x200B;xxxx&#x200B;xxxx&#x200B;xxxx&#x200B;xxxx&#x200B;xxxx&#x200B;xxxx + </div> + </div> + <div id="region-parent"> + <div id="region1"></div> + <div id="region2"></div> + </div> + <script src="util.js" type="text/javascript"></script> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/two.gif b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/two.gif new file mode 100644 index 0000000000000000000000000000000000000000..01435c80209d533dc2164ac48279574c7ba4615e GIT binary patch literal 184 zcmZ?wbh9u|G-5Dfc+9}?|Nnmm1_pU~d3$^N`Sa)Bzkk2JzCJ!ae*gacKygf<0}=x1 zWnjq_IN`Z^uf^-LyZ<L>^rd9Z%UHE8=k>k<o%1ER_bb-DuX+F9^k9R7fPkLUqK~Q* zc(|CC2%nO1TinphID5}Nt_DZpXpRQPgu)-CGBzifT9*7x<K{V<yu)Ju^Tvk8rskH` Tw)T$BuI`@RzWxaff(+IGsD?$T literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/util.js b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/util.js new file mode 100644 index 00000000000..a7ce4283e45 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/util.js @@ -0,0 +1,29 @@ +function resizeViewportTo(viewportSelector, width, height) { + var iframe = document.querySelector(viewportSelector); + // Commonly used trick to trigger a layout + iframe.contentWindow.document.body.offsetTop; + + iframe.width = width; + iframe.height = height; + + iframe.contentWindow.document.body.offsetTop; +} + +function injectStylesInIFrame(styleSelector, frameSelector) { + var style = document.querySelector(styleSelector), + frame = document.querySelector(frameSelector); + + frame.contentWindow.addNewStyles(style.textContent); +} + + +if (window.parent != window) { + // we're in an iframe, so expose the bits that allow setting styles inside + window.addNewStyles = function (cssText) { + var styleTag = document.createElement("style"), + textNode = document.createTextNode(cssText); + + styleTag.appendChild(textNode); + document.head.appendChild(styleTag); + } +} \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/support/vendorPrefix.js b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/vendorPrefix.js new file mode 100644 index 00000000000..6cf3c5a3783 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/support/vendorPrefix.js @@ -0,0 +1,86 @@ +// +// Vendor-Prefix Helper Functions For Testing CSS +// + +(function(root) { +'use strict'; + +var prefixCache = {}; + +// convert "foo-bar" to "fooBar" +function camelCase(str) { + return str.replace(/\-(\w)/g, function(match, letter){ + return letter.toUpperCase(); + }); +} + +// vendor-prefix a css property +root.addVendorPrefix = function (name) { + var prefix = getVendorPrefix(name); + if (prefix === false) { + // property unknown to browser + return name; + } + + return prefix + name; +}; + +// vendor-prefix a css property value +root.addValueVendorPrefix = function (property, value) { + var prefix = getValueVendorPrefix(property, value); + if (prefix === false) { + // property unknown to browser + return name; + } + + return prefix + value; +}; + +// identify vendor-prefix for css property +root.getVendorPrefix = function(name) { + if (prefixCache[name] !== undefined) { + return prefixCache[name]; + } + + var elem = document.createElement("div"); + name = camelCase(name); + + if (name in elem.style) { + return prefixCache[name] = ""; + } + + var prefixes = ["Webkit", "Moz", "O", "ms"]; + var styles = ["-webkit-", "-moz-", "-o-", "-ms-"]; + var _name = name.substring(0, 1).toUpperCase() + name.substring(1); + + for (var i = 0, length = prefixes.length; i < length; i++) { + if (prefixes[i] + _name in elem.style) { + return prefixCache[name] = styles[i]; + } + } + + return prefixCache[name] = name in elem.style ? "" : false; +}; + +// identify vendor-prefix for css property value +root.getValueVendorPrefix = function(property, value) { + var elem = document.createElement("div"); + // note: webkit needs the element to be attached to the dom + document.body.appendChild(elem); + var styles = ["-webkit-", "-moz-", "-o-", "-ms-", ""]; + var _property = getVendorPrefix(property) + property; + for (var i=0, length = styles.length; i < length; i++) { + var _value = styles[i] + value; + elem.setAttribute('style', _property + ": " + _value); + var _computed = computedStyle(elem, _property); + if (_computed && _computed !== 'none') { + document.body.removeChild(elem); + return styles[i]; + } + } + document.body.removeChild(elem); + return false; +}; + + +})(window); \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reference/vh_not_refreshing_on_chrome-ref.htm b/tests/wpt/css-tests/css-values-3_dev/html/reference/vh_not_refreshing_on_chrome-ref.htm new file mode 100644 index 00000000000..42a1ec8dc4d --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reference/vh_not_refreshing_on_chrome-ref.htm @@ -0,0 +1,49 @@ +<!DOCTYPE html> +<html><!-- Submitted from TestTWF Paris --><head> + + <title>CSS Reference File</title> + <link href="mailto:marc@bourlon.com" rel="author" title="Marc Bourlon"> + + <style type="text/css"> + + * { margin: 0; padding: 0; font-family: Arial, Helvetica, sans-serif; font-size: 13px; } + + #frameTest { width: 600px; height: 200px; border: 1px solid #000; } + + </style> + + <script type="text/javascript"> + var height = 200; + + function resizeReference() { + + var frameTest = document.getElementById('frameTest'); + + // let's resize the iframe vertically only, showing that the vh sizes is not updated. + if (height <= 300) { + + //frameTest.style.width = height++ + "px"; + frameTest.style.height = height++ + "px"; + + setTimeout(resizeReference, 10); + + } else { + + // uncomment the next line to see how a width resize triggers a layout recalculation + //frameTest.style.width = (parseInt(window.getComputedStyle(document.getElementById('frameTest'))['width'], 10) + 1) + "px"; + + } + + } + + setTimeout(resizeReference, 10); + </script> + +</head> +<body> + +<iframe src="vh_not_refreshing_on_chrome_iframe-ref.html" id="frameTest" frameborder="0"></iframe> + + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reftest-toc.htm b/tests/wpt/css-tests/css-values-3_dev/html/reftest-toc.htm new file mode 100644 index 00000000000..219b65b1ad6 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reftest-toc.htm @@ -0,0 +1,486 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>CSS Values and Units Module Level 3 CR Test Suite Reftest Index</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Values and Units Module Level 3 CR Test Suite Reftest Index</h1> + <table width="100%"> + <col id="test-column"> + <col id="ref-column"> + <col id="flags-column"> + <thead> + <tr> + <th>Test</th> + <th>Reference</th> + <th>Flags</th> + </tr> + </thead> + <tbody id="calc-background-image-gradient-1" class=""> + <tr> + <td rowspan="1" title="Test for calc() on background-image gradients"> + <a href="calc-background-image-gradient-1.htm">calc-background-image-gradient-1</a></td> + <td><a href="reference/calc-background-image-gradient-1-ref.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-background-linear-gradient-1" class=""> + <tr> + <td rowspan="1" title="Support calc() on gradient stop positions"> + <a href="calc-background-linear-gradient-1.htm">calc-background-linear-gradient-1</a></td> + <td><a href="reference/calc-background-linear-gradient-1-ref.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-background-position-1" class=""> + <tr> + <td rowspan="1" title="Test for calc() on background-position"> + <a href="calc-background-position-1.htm">calc-background-position-1</a></td> + <td><a href="reference/calc-background-position-1-ref.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-background-size-1" class=""> + <tr> + <td rowspan="1" title="Test for calc() on background-size"> + <a href="calc-background-size-1.htm">calc-background-size-1</a></td> + <td><a href="reference/calc-background-size-1-ref.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-border-radius-1" class=""> + <tr> + <td rowspan="1" title="test for border-radius: calc()"> + <a href="calc-border-radius-1.htm">calc-border-radius-1</a></td> + <td><a href="reference/calc-border-radius-1-ref.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-height-block-1" class=""> + <tr> + <td rowspan="1" title="Test for height:calc() on blocks"> + <a href="calc-height-block-1.htm">calc-height-block-1</a></td> + <td><a href="reference/calc-height-block-1-ref.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-height-table-1" class=""> + <tr> + <td rowspan="1" title="Test that height:calc() with no percentages has an effect on inner table elements"> + <a href="calc-height-table-1.htm">calc-height-table-1</a></td> + <td><a href="reference/calc-height-table-1-ref.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-margin-block-1" class=""> + <tr> + <td rowspan="1" title="Test of margin-*: calc()"> + <a href="calc-margin-block-1.htm">calc-margin-block-1</a></td> + <td><a href="reference/calc-margin-block-1-ref.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-max-height-block-1" class=""> + <tr> + <td rowspan="1" title="Test for max-height:calc() on blocks"> + <a href="calc-max-height-block-1.htm">calc-max-height-block-1</a></td> + <td><a href="reference/calc-max-height-block-1-ref.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-max-width-block-1" class=""> + <tr> + <td rowspan="1" title="max-width: calc() on blocks"> + <a href="calc-max-width-block-1.htm">calc-max-width-block-1</a></td> + <td><a href="reference/calc-width-block-1-ref.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-max-width-block-intrinsic-1" class=""> + <tr> + <td rowspan="1" title="intrinsic width of max-width: calc() on blocks"> + <a href="calc-max-width-block-intrinsic-1.htm">calc-max-width-block-intrinsic-1</a></td> + <td><a href="reference/calc-max-width-block-intrinsic-1-ref.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-min-height-block-1" class=""> + <tr> + <td rowspan="1" title="Test for min-height:calc() on blocks"> + <a href="calc-min-height-block-1.htm">calc-min-height-block-1</a></td> + <td><a href="reference/calc-height-block-1-ref.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-min-width-block-1" class=""> + <tr> + <td rowspan="1" title="min-width: calc() on blocks"> + <a href="calc-min-width-block-1.htm">calc-min-width-block-1</a></td> + <td><a href="reference/calc-width-block-1-ref.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-min-width-block-intrinsic-1" class=""> + <tr> + <td rowspan="1" title="intrinsic width of min-width: calc() on blocks"> + <a href="calc-min-width-block-intrinsic-1.htm">calc-min-width-block-intrinsic-1</a></td> + <td><a href="reference/calc-min-width-block-intrinsic-1-ref.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-offsets-absolute-bottom-1" class=""> + <tr> + <td rowspan="1" title="Test for bottom:calc() on absolutely positioned elements"> + <a href="calc-offsets-absolute-bottom-1.htm">calc-offsets-absolute-bottom-1</a></td> + <td><a href="reference/calc-offsets-absolute-top-1-ref.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-offsets-absolute-left-1" class=""> + <tr> + <td rowspan="1" title="Test for left:calc() on absolutely positioned elements"> + <a href="calc-offsets-absolute-left-1.htm">calc-offsets-absolute-left-1</a></td> + <td><a href="reference/calc-offsets-relative-left-1-ref.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-offsets-absolute-right-1" class=""> + <tr> + <td rowspan="1" title="Test for right:calc() on absolutely positioned elements"> + <a href="calc-offsets-absolute-right-1.htm">calc-offsets-absolute-right-1</a></td> + <td><a href="reference/calc-offsets-relative-left-1-ref.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-offsets-absolute-top-1" class=""> + <tr> + <td rowspan="1" title="Test for top:calc() on absolutely positioned elements"> + <a href="calc-offsets-absolute-top-1.htm">calc-offsets-absolute-top-1</a></td> + <td><a href="reference/calc-offsets-absolute-top-1-ref.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-offsets-relative-bottom-1" class=""> + <tr> + <td rowspan="1" title="Test for bottom:calc() on relatively positioned elements"> + <a href="calc-offsets-relative-bottom-1.htm">calc-offsets-relative-bottom-1</a></td> + <td><a href="reference/calc-offsets-relative-top-1-ref.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-offsets-relative-left-1" class=""> + <tr> + <td rowspan="1" title="Test for left:calc() on relatively positioned elements"> + <a href="calc-offsets-relative-left-1.htm">calc-offsets-relative-left-1</a></td> + <td><a href="reference/calc-offsets-relative-left-1-ref.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-offsets-relative-right-1" class=""> + <tr> + <td rowspan="1" title="Test for right:calc() on relatively positioned elements"> + <a href="calc-offsets-relative-right-1.htm">calc-offsets-relative-right-1</a></td> + <td><a href="reference/calc-offsets-relative-left-1-ref.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-offsets-relative-top-1" class=""> + <tr> + <td rowspan="1" title="Test for top:calc() on relatively positioned elements"> + <a href="calc-offsets-relative-top-1.htm">calc-offsets-relative-top-1</a></td> + <td><a href="reference/calc-offsets-relative-top-1-ref.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-padding-block-1" class=""> + <tr> + <td rowspan="1" title="Test of padding-*: calc()"> + <a href="calc-padding-block-1.htm">calc-padding-block-1</a></td> + <td><a href="reference/calc-padding-block-1-ref.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-text-indent-1" class=""> + <tr> + <td rowspan="1" title="text-indent: calc() on blocks"> + <a href="calc-text-indent-1.htm">calc-text-indent-1</a></td> + <td><a href="reference/calc-text-indent-1-ref.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-text-indent-intrinsic-1" class=""> + <tr> + <td rowspan="1" title="intrinsic width of text-indent: calc() on blocks"> + <a href="calc-text-indent-intrinsic-1.htm">calc-text-indent-intrinsic-1</a></td> + <td><a href="reference/calc-text-indent-intrinsic-1-ref.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-transform-origin-1" class=""> + <tr> + <td rowspan="1" title="Test for calc() on transform-origin"> + <a href="calc-transform-origin-1.htm">calc-transform-origin-1</a></td> + <td><a href="reference/calc-transform-origin-1-ref.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-vertical-align-1" class=""> + <tr> + <td rowspan="1" title="Test for vertical-align:calc()"> + <a href="calc-vertical-align-1.htm">calc-vertical-align-1</a></td> + <td><a href="reference/calc-vertical-align-1-ref.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-width-block-1" class=""> + <tr> + <td rowspan="1" title="width: calc() on blocks"> + <a href="calc-width-block-1.htm">calc-width-block-1</a></td> + <td><a href="reference/calc-width-block-1-ref.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-width-block-intrinsic-1" class=""> + <tr> + <td rowspan="1" title="intrinsic width of width: calc() on blocks"> + <a href="calc-width-block-intrinsic-1.htm">calc-width-block-intrinsic-1</a></td> + <td><a href="reference/calc-width-block-intrinsic-1-ref.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-width-table-auto-1" class=""> + <tr> + <td rowspan="1" title="width: calc() on table-layout: auto tables"> + <a href="calc-width-table-auto-1.htm">calc-width-table-auto-1</a></td> + <td><a href="reference/calc-width-table-auto-1-ref.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-width-table-fixed-1" class=""> + <tr> + <td rowspan="1" title="width: calc() on table-layout: auto tables"> + <a href="calc-width-table-fixed-1.htm">calc-width-table-fixed-1</a></td> + <td><a href="reference/calc-width-table-fixed-1-ref.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="ch-unit-001" class=""> + <tr> + <td rowspan="1" title="support for the ch unit"> + <a href="ch-unit-001.htm">ch-unit-001</a></td> + <td><a href="reference/ch-unit-001-ref.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="min-width-001" class=""> + <tr> + <td rowspan="1" title="min-width length value approximation"> + <a href="min-width-001.htm">min-width-001</a></td> + <td><a href="ref.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="multicol-count-non-integer-001" class="ahem invalid"> + <tr> + <td rowspan="1" title="non-integer 'column-count' value"> + <a href="multicol-count-non-integer-001.htm">multicol-count-non-integer-001</a></td> + <td><a href="reference/multicol-columns-invalid-001-ref.htm">=</a> </td> + <td rowspan="1"><abbr class="ahem" title="Requires Ahem font">Ahem</abbr><abbr class="invalid" title="Tests invalid CSS">Invalid</abbr></td> + </tr> + </tbody> + <tbody id="multicol-count-non-integer-002" class="ahem invalid"> + <tr> + <td rowspan="1" title="non-integer 'column-count' value"> + <a href="multicol-count-non-integer-002.htm">multicol-count-non-integer-002</a></td> + <td><a href="reference/multicol-columns-invalid-001-ref.htm">=</a> </td> + <td rowspan="1"><abbr class="ahem" title="Requires Ahem font">Ahem</abbr><abbr class="invalid" title="Tests invalid CSS">Invalid</abbr></td> + </tr> + </tbody> + <tbody id="multicol-count-non-integer-003" class="ahem invalid"> + <tr> + <td rowspan="1" title="non-integer 'column-count' value"> + <a href="multicol-count-non-integer-003.htm">multicol-count-non-integer-003</a></td> + <td><a href="reference/multicol-columns-invalid-001-ref.htm">=</a> </td> + <td rowspan="1"><abbr class="ahem" title="Requires Ahem font">Ahem</abbr><abbr class="invalid" title="Tests invalid CSS">Invalid</abbr></td> + </tr> + </tbody> + <tbody id="multicol-inherit-002" class="ahem"> + <tr> + <td rowspan="1" title="'column-count' and inherit"> + <a href="multicol-inherit-002.htm">multicol-inherit-002</a></td> + <td><a href="reference/multicol-inherit-002-ref.htm">=</a> </td> + <td rowspan="1"><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + </tr> + </tbody> + <tbody id="multicol-rule-color-inherit-001" class="ahem"> + <tr> + <td rowspan="1" title="column-rule-color: inherit"> + <a href="multicol-rule-color-inherit-001.htm">multicol-rule-color-inherit-001</a></td> + <td><a href="reference/multicol-rule-color-inherit-001-ref.htm">=</a> </td> + <td rowspan="1"><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + </tr> + </tbody> + <tbody id="multicol-rule-color-inherit-002" class="ahem"> + <tr> + <td rowspan="1" title="column-rule-color: inherit (complex)"> + <a href="multicol-rule-color-inherit-002.htm">multicol-rule-color-inherit-002</a></td> + <td><a href="reference/multicol-rule-color-inherit-001-ref.htm">=</a> </td> + <td rowspan="1"><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + </tr> + </tbody> + <tbody id="regions-resizing-003" class="ahem dom http"> + <tr> + <td rowspan="1" title="CSS Regions: resizing region that is sized using viewport units"> + <a href="regions-resizing-003.htm">regions-resizing-003</a></td> + <td><a href="reference/regions-resizing-001-ref.htm">=</a> </td> + <td rowspan="1"><abbr class="ahem" title="Requires Ahem font">Ahem</abbr><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="http" title="Requires HTTP headers">HTTP</abbr></td> + </tr> + </tbody> + <tbody id="regions-resizing-007" class="ahem dom http"> + <tr> + <td rowspan="1" title="CSS Regions: resizing region with percentage size inside a container that has size set in viewport units"> + <a href="regions-resizing-007.htm">regions-resizing-007</a></td> + <td><a href="reference/regions-resizing-001-ref.htm">=</a> </td> + <td rowspan="1"><abbr class="ahem" title="Requires Ahem font">Ahem</abbr><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="http" title="Requires HTTP headers">HTTP</abbr></td> + </tr> + </tbody> + <tbody id="regions-resizing-009" class="ahem dom http"> + <tr> + <td rowspan="1" title="CSS Regions: resizing autosized region when content flowed in it is sized with viewport units"> + <a href="regions-resizing-009.htm">regions-resizing-009</a></td> + <td><a href="reference/regions-resizing-001-ref.htm">=</a> </td> + <td rowspan="1"><abbr class="ahem" title="Requires Ahem font">Ahem</abbr><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="http" title="Requires HTTP headers">HTTP</abbr></td> + </tr> + </tbody> + <tbody id="vh-calc-support" class=""> + <tr> + <td rowspan="1" title="Viewport units are supported inside calc expressions."> + <a href="vh-calc-support.htm">vh-calc-support</a></td> + <td><a href="reference/all-green.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="vh-calc-support-pct" class=""> + <tr> + <td rowspan="1" title="Viewport units are supported inside calc expressions."> + <a href="vh-calc-support-pct.htm">vh-calc-support-pct</a></td> + <td><a href="reference/all-green.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="vh-em-inherit" class=""> + <tr> + <td rowspan="1" title="0vh and 0vw are correctly treated as 0px"> + <a href="vh-em-inherit.htm">vh-em-inherit</a></td> + <td><a href="reference/all-green.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="vh-inherit" class=""> + <tr> + <td rowspan="1" title="Viewport units are inherited properly"> + <a href="vh-inherit.htm">vh-inherit</a></td> + <td><a href="reference/all-green.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="vh-interpolate-pct" class=""> + <tr> + <td rowspan="1" title="Viewport units are interpolated correctly"> + <a href="vh-interpolate-pct.htm">vh-interpolate-pct</a></td> + <td><a href="reference/all-green.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="vh-interpolate-px" class=""> + <tr> + <td rowspan="1" title="Viewport units are interpolated correctly"> + <a href="vh-interpolate-px.htm">vh-interpolate-px</a></td> + <td><a href="reference/all-green.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="vh-interpolate-vh" class=""> + <tr> + <td rowspan="1" title="Viewport units are interpolated correctly"> + <a href="vh-interpolate-vh.htm">vh-interpolate-vh</a></td> + <td><a href="reference/all-green.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="vh-support" class=""> + <tr> + <td rowspan="1" title="Viewports units are supported in sizing properties"> + <a href="vh-support.htm">vh-support</a></td> + <td><a href="reference/all-green.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="vh-support-atviewport" class=""> + <tr> + <td rowspan="1" title="Viewports units are supported in @viewport rules"> + <a href="vh-support-atviewport.htm">vh-support-atviewport</a></td> + <td><a href="reference/all-green.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="vh-support-margin" class=""> + <tr> + <td rowspan="1" title="Viewports units are supported in margin properties"> + <a href="vh-support-margin.htm">vh-support-margin</a></td> + <td><a href="reference/all-green.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="vh-support-transform-origin" class=""> + <tr> + <td rowspan="1" title="Viewports units are supported in transform properties"> + <a href="vh-support-transform-origin.htm">vh-support-transform-origin</a></td> + <td><a href="reference/all-green.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="vh-support-transform-translate" class=""> + <tr> + <td rowspan="1" title="Viewports units are supported in transform properties"> + <a href="vh-support-transform-translate.htm">vh-support-transform-translate</a></td> + <td><a href="reference/all-green.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="vh-zero-support" class=""> + <tr> + <td rowspan="1" title="0vh and 0vw are correctly treated as 0px"> + <a href="vh-zero-support.htm">vh-zero-support</a></td> + <td><a href="reference/all-green.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="vh_not_refreshing_on_chrome" class=""> + <tr> + <td rowspan="1" title="vh-based dimension doesn't change when the element's other dimension doesn't change."> + <a href="vh_not_refreshing_on_chrome.htm">vh_not_refreshing_on_chrome</a></td> + <td><a href="reference/vh_not_refreshing_on_chrome-ref.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="vh_not_refreshing_on_chrome_iframe" class=""> + <tr> + <td rowspan="1" title="vh-based dimension doesn't change when the element other dimension doesn't change."> + <a href="vh_not_refreshing_on_chrome_iframe.htm">vh_not_refreshing_on_chrome_iframe</a></td> + <td><a href="reference/vh_not_refreshing_on_chrome-ref.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + </table> + + </body> +</html> diff --git a/tests/wpt/css-tests/css-values-3_dev/html/reftest.list b/tests/wpt/css-tests/css-values-3_dev/html/reftest.list new file mode 100644 index 00000000000..8714d2b521f --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/reftest.list @@ -0,0 +1,58 @@ + +calc-background-image-gradient-1.htm == reference/calc-background-image-gradient-1-ref.htm +calc-background-linear-gradient-1.htm == reference/calc-background-linear-gradient-1-ref.htm +calc-background-position-1.htm == reference/calc-background-position-1-ref.htm +calc-background-size-1.htm == reference/calc-background-size-1-ref.htm +calc-border-radius-1.htm == reference/calc-border-radius-1-ref.htm +calc-height-block-1.htm == reference/calc-height-block-1-ref.htm +calc-height-table-1.htm == reference/calc-height-table-1-ref.htm +calc-margin-block-1.htm == reference/calc-margin-block-1-ref.htm +calc-max-height-block-1.htm == reference/calc-max-height-block-1-ref.htm +calc-max-width-block-1.htm == reference/calc-width-block-1-ref.htm +calc-max-width-block-intrinsic-1.htm == reference/calc-max-width-block-intrinsic-1-ref.htm +calc-min-height-block-1.htm == reference/calc-height-block-1-ref.htm +calc-min-width-block-1.htm == reference/calc-width-block-1-ref.htm +calc-min-width-block-intrinsic-1.htm == reference/calc-min-width-block-intrinsic-1-ref.htm +calc-offsets-absolute-bottom-1.htm == reference/calc-offsets-absolute-top-1-ref.htm +calc-offsets-absolute-left-1.htm == reference/calc-offsets-relative-left-1-ref.htm +calc-offsets-absolute-right-1.htm == reference/calc-offsets-relative-left-1-ref.htm +calc-offsets-absolute-top-1.htm == reference/calc-offsets-absolute-top-1-ref.htm +calc-offsets-relative-bottom-1.htm == reference/calc-offsets-relative-top-1-ref.htm +calc-offsets-relative-left-1.htm == reference/calc-offsets-relative-left-1-ref.htm +calc-offsets-relative-right-1.htm == reference/calc-offsets-relative-left-1-ref.htm +calc-offsets-relative-top-1.htm == reference/calc-offsets-relative-top-1-ref.htm +calc-padding-block-1.htm == reference/calc-padding-block-1-ref.htm +calc-text-indent-1.htm == reference/calc-text-indent-1-ref.htm +calc-text-indent-intrinsic-1.htm == reference/calc-text-indent-intrinsic-1-ref.htm +calc-transform-origin-1.htm == reference/calc-transform-origin-1-ref.htm +calc-vertical-align-1.htm == reference/calc-vertical-align-1-ref.htm +calc-width-block-1.htm == reference/calc-width-block-1-ref.htm +calc-width-block-intrinsic-1.htm == reference/calc-width-block-intrinsic-1-ref.htm +calc-width-table-auto-1.htm == reference/calc-width-table-auto-1-ref.htm +calc-width-table-fixed-1.htm == reference/calc-width-table-fixed-1-ref.htm +ch-unit-001.htm == reference/ch-unit-001-ref.htm +min-width-001.htm == ref.htm +multicol-count-non-integer-001.htm == reference/multicol-columns-invalid-001-ref.htm +multicol-count-non-integer-002.htm == reference/multicol-columns-invalid-001-ref.htm +multicol-count-non-integer-003.htm == reference/multicol-columns-invalid-001-ref.htm +multicol-inherit-002.htm == reference/multicol-inherit-002-ref.htm +multicol-rule-color-inherit-001.htm == reference/multicol-rule-color-inherit-001-ref.htm +multicol-rule-color-inherit-002.htm == reference/multicol-rule-color-inherit-001-ref.htm +regions-resizing-003.htm == reference/regions-resizing-001-ref.htm +regions-resizing-007.htm == reference/regions-resizing-001-ref.htm +regions-resizing-009.htm == reference/regions-resizing-001-ref.htm +vh-calc-support.htm == reference/all-green.htm +vh-calc-support-pct.htm == reference/all-green.htm +vh-em-inherit.htm == reference/all-green.htm +vh-inherit.htm == reference/all-green.htm +vh-interpolate-pct.htm == reference/all-green.htm +vh-interpolate-px.htm == reference/all-green.htm +vh-interpolate-vh.htm == reference/all-green.htm +vh-support.htm == reference/all-green.htm +vh-support-atviewport.htm == reference/all-green.htm +vh-support-margin.htm == reference/all-green.htm +vh-support-transform-origin.htm == reference/all-green.htm +vh-support-transform-translate.htm == reference/all-green.htm +vh-zero-support.htm == reference/all-green.htm +vh_not_refreshing_on_chrome.htm == reference/vh_not_refreshing_on_chrome-ref.htm +vh_not_refreshing_on_chrome_iframe.htm == reference/vh_not_refreshing_on_chrome-ref.htm diff --git a/tests/wpt/css-tests/css-values-3_dev/html/regions-resizing-003.htm b/tests/wpt/css-tests/css-values-3_dev/html/regions-resizing-003.htm new file mode 100644 index 00000000000..68408a9631f --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/regions-resizing-003.htm @@ -0,0 +1,33 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Regions: resizing region that is sized using viewport units</title> + <link href="mailto:mibalan@adobe.com" rel="author" title="Mihai Balan"> + <link href="http://www.w3.org/TR/css3-regions/#the-flow-into-property" rel="help"> + <link href="http://www.w3.org/TR/css3-regions/#flow-from" rel="help"> + <link href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" rel="help"> + <meta content="dom ahem http" name="flags"> + <meta content="Test checks that resizing the viewport of a page containing a region + sized using viewport units correctly relayouts the region's contents." name="assert"> + <link href="reference/regions-resizing-001-ref.htm" rel="match"> + <!-- The <script type="text/css"> below is just a textual container for styles that will be + injected in the iframe at load time.--> + <script type="text/css" id="test-styles"> + #region { + width: 80vw; + height: 100vh; + } + </script> + <script src="support/util.js" type="text/javascript"></script> + <script type="text/javascript"> + window.addEventListener("load", function() { + injectStylesInIFrame("#test-styles", "iframe"); + resizeViewportTo("iframe", 100, 100); + }) + </script> + </head> + <body> + <p>Test passes if you see a green square below and no red.</p> + <p>The test also fails if the there's a green block that is <strong>not</strong> a square (e.g. rectangle or polygon).</p> + <iframe width="400" height="400" frameborder="0" src="support/region-in-body.html"></iframe> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/regions-resizing-007.htm b/tests/wpt/css-tests/css-values-3_dev/html/regions-resizing-007.htm new file mode 100644 index 00000000000..ac25a372829 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/regions-resizing-007.htm @@ -0,0 +1,41 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Regions: resizing region with percentage size inside a container that has size set in viewport units</title> + <link href="mailto:mibalan@adobe.com" rel="author" title="Mihai Balan"> + <link href="http://www.w3.org/TR/css3-regions/#the-flow-into-property" rel="help"> + <link href="http://www.w3.org/TR/css3-regions/#flow-from" rel="help"> + <link href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" rel="help"> + <meta content="dom ahem http" name="flags"> + <meta content="Test checks that resizing the viewport of a page containing a region + that has a percentage size relative to a parent sized using viewport units correctly + relayouts the region's contents." name="assert"> + <link href="reference/regions-resizing-001-ref.htm" rel="match"> + <!-- The <script type="text/css"> below is just a textual container for styles that will be + injected in the iframe at load time.--> + <script type="text/css" id="test-styles"> + html, body { + height: 100%; + } + #region-parent { + width: 50vw; + height: 80vh; + } + #region { + width: 80%; + height: 70%; + } + </script> + <script src="support/util.js" type="text/javascript"></script> + <script type="text/javascript"> + window.addEventListener("load", function() { + injectStylesInIFrame("#test-styles", "iframe"); + resizeViewportTo("iframe", 200, 200); + }) + </script> + </head> + <body> + <p>Test passes if you see a green square below and no red.</p> + <p>The test also fails if the there's a green block that is <strong>not</strong> a square (e.g. rectangle or polygon).</p> + <iframe width="437" height="143" frameborder="0" src="support/region-in-container.html"></iframe> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/regions-resizing-009.htm b/tests/wpt/css-tests/css-values-3_dev/html/regions-resizing-009.htm new file mode 100644 index 00000000000..19dd5829134 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/regions-resizing-009.htm @@ -0,0 +1,39 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Regions: resizing autosized region when content flowed in it is sized with viewport units</title> + <link href="mailto:mibalan@adobe.com" rel="author" title="Mihai Balan"> + <link href="http://www.w3.org/TR/css3-regions/#the-flow-into-property" rel="help"> + <link href="http://www.w3.org/TR/css3-regions/#flow-from" rel="help"> + <link href="http://www.w3.org/TR/css3-regions/#regions-visual-formatting-details" rel="help"> + <link href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" rel="help"> + <meta content="dom ahem http" name="flags"> + <meta content="Test checks that resizing the viewport of a page containing an + autosized region when the content flowed in it is sized with viewport units correctly + relayouts the region's contents." name="assert"> + <link href="reference/regions-resizing-001-ref.htm" rel="match"> + <!-- The <script type="text/css"> below is just a textual container for styles that will be + injected in the iframe at load time.--> + <script type="text/css" id="test-styles"> + #content { + width: 40vw; + height: 40vh; + } + #region { + width: auto; + height: auto; + } + </script> + <script src="support/util.js" type="text/javascript"></script> + <script type="text/javascript"> + window.addEventListener("load", function() { + injectStylesInIFrame("#test-styles", "iframe"); + resizeViewportTo("iframe", 200, 200); + }) + </script> + </head> + <body> + <p>Test passes if you see a green square below and no red.</p> + <p>The test also fails if the there's a green block that is <strong>not</strong> a square (e.g. rectangle or polygon).</p> + <iframe width="437" height="143" frameborder="0" src="support/region-in-body.html"></iframe> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/shape-outside-circle-002.htm b/tests/wpt/css-tests/css-values-3_dev/html/shape-outside-circle-002.htm new file mode 100644 index 00000000000..48b11189f55 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/shape-outside-circle-002.htm @@ -0,0 +1,30 @@ +<!DOCTYPE html> +<html><head> + <title>Shape Outside Circle Valid Positions</title> + <link href="http://html.adobe.com/" rel="author" title="Adobe"> + <link href="mailto:betravis@adobe.com" rel="author" title="Bear Travis"> + <link href="mailto:rhauck@adobe.com" rel="author" title="Rebecca Hauck"> + <link href="mailto:stearns@adobe.com" rel="reviewer" title="Alan Stearns"> <!-- 2014-03-04 --> + <link href="http://www.w3.org/TR/css-shapes-1/#funcdef-circle" rel="help"> + <link href="http://www.w3.org/TR/css-shapes-1/#shape-outside-property" rel="help"> + <link href="http://www.w3.org/TR/css3-values/#lengths" rel="help"> + <meta content="A circle's position argument may be any of the valid combinations: + [ percentage|length left|center|right ] + or [ percentage|length left|center|right ] [ percentage|length top|center|bottom ] + or [ left|center|right ] + or [ left|center|right top|center|bottom ] + or [ top|center|bottom ]. " name="assert"> + <meta content="dom" name="flags"> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> + <script src="support/parsing-utils.js"></script> + </head> + <body> + <div id="log"></div> + <script type="text/javascript"> + generate_tests(ParsingUtils.testInlineStyle, ParsingUtils.buildPositionTests('circle', true, 'inline', 'px')); + generate_tests(ParsingUtils.testComputedStyle, ParsingUtils.buildPositionTests('circle', true, 'computed', 'px')); + </script> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/shape-outside-circle-004.htm b/tests/wpt/css-tests/css-values-3_dev/html/shape-outside-circle-004.htm new file mode 100644 index 00000000000..11505819210 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/shape-outside-circle-004.htm @@ -0,0 +1,26 @@ +<!DOCTYPE html> +<html><head> + <title>Shape Outside Circle - Position Length Units</title> + <link href="http://html.adobe.com/" rel="author" title="Adobe"> + <link href="mailto:rhauck@adobe.com" rel="author" title="Rebecca Hauck"> + <link href="mailto:stearns@adobe.com" rel="reviewer" title="Alan Stearns"> <!-- 2014-03-04 --> + <link href="http://www.w3.org/TR/css-shapes-1/#funcdef-circle" rel="help"> + <link href="http://www.w3.org/TR/css-shapes-1/#shape-outside-property" rel="help"> + <link href="http://www.w3.org/TR/css3-values/#lengths" rel="help"> + <meta content="A circle's position arguments may in any valid <length> unit allowed by a <position> value." name="assert"> + <meta content="dom" name="flags"> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> + <script src="support/parsing-utils.js"></script> + </head> + <body> + <div id="log"></div> + <script type="text/javascript"> + generate_tests( ParsingUtils.testInlineStyle, + ParsingUtils.buildPositionTests("circle", true, 'lengthUnit + inline', ParsingUtils.validUnits) ); + generate_tests( ParsingUtils.testComputedStyle, + ParsingUtils.buildPositionTests("circle", true, 'lengthUnit + computed', ParsingUtils.validUnits) ); + </script> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/shape-outside-ellipse-002.htm b/tests/wpt/css-tests/css-values-3_dev/html/shape-outside-ellipse-002.htm new file mode 100644 index 00000000000..8a9118abb6e --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/shape-outside-ellipse-002.htm @@ -0,0 +1,30 @@ +<!DOCTYPE html> +<html><head> + <title>Shape Outside Ellipse Valid Positions</title> + <link href="http://html.adobe.com/" rel="author" title="Adobe"> + <link href="mailto:betravis@adobe.com" rel="author" title="Bear Travis"> + <link href="mailto:rhauck@adobe.com" rel="author" title="Rebecca Hauck"> + <link href="mailto:stearns@adobe.com" rel="reviewer" title="Alan Stearns"> <!-- 2014-03-04 --> + <link href="http://www.w3.org/TR/css-shapes-1/#funcdef-ellipse" rel="help"> + <link href="http://www.w3.org/TR/css-shapes-1/#shape-outside-property" rel="help"> + <link href="http://www.w3.org/TR/css3-values/#lengths" rel="help"> + <meta content="An ellipse's position argument may be any of the valid combinations: + [ percentage|length left|center|right ] + or [ percentage|length left|center|right ] [ percentage|length top|center|bottom ] + or [ left|center|right ] + or [ left|center|right top|center|bottom ] + or [ top|center|bottom ]. " name="assert"> + <meta content="dom" name="flags"> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> + <script src="support/parsing-utils.js"></script> + </head> + <body> + <div id="log"></div> + <script type="text/javascript"> + generate_tests(ParsingUtils.testInlineStyle, ParsingUtils.buildPositionTests('ellipse', true, 'inline', 'px')); + generate_tests(ParsingUtils.testComputedStyle, ParsingUtils.buildPositionTests('ellipse', true, 'computed', 'px')); + </script> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/shape-outside-ellipse-004.htm b/tests/wpt/css-tests/css-values-3_dev/html/shape-outside-ellipse-004.htm new file mode 100644 index 00000000000..3e9285192ee --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/shape-outside-ellipse-004.htm @@ -0,0 +1,26 @@ +<!DOCTYPE html> +<html><head> + <title>Shape Outside Ellipse - Position Length Units</title> + <link href="http://html.adobe.com/" rel="author" title="Adobe"> + <link href="mailto:rhauck@adobe.com" rel="author" title="Rebecca Hauck"> + <link href="mailto:stearns@adobe.com" rel="reviewer" title="Alan Stearns"> <!-- 2014-03-04 --> + <link href="http://www.w3.org/TR/css-shapes-1/#funcdef-ellipse" rel="help"> + <link href="http://www.w3.org/TR/css-shapes-1/#shape-outside-property" rel="help"> + <link href="http://www.w3.org/TR/css3-values/#lengths" rel="help"> + <meta content="An ellipse's position arguments may in any valid <length> unit allowed by a <position> value." name="assert"> + <meta content="dom" name="flags"> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> + <script src="support/parsing-utils.js"></script> + </head> + <body> + <div id="log"></div> + <script type="text/javascript"> + generate_tests( ParsingUtils.testInlineStyle, + ParsingUtils.buildPositionTests("ellipse", true, 'lengthUnit + inline', ParsingUtils.validUnits) ); + generate_tests( ParsingUtils.testComputedStyle, + ParsingUtils.buildPositionTests("ellipse", true, 'lengthUnit + computed', ParsingUtils.validUnits) ); + </script> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/shape-outside-inset-003.htm b/tests/wpt/css-tests/css-values-3_dev/html/shape-outside-inset-003.htm new file mode 100644 index 00000000000..e77930da7b2 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/shape-outside-inset-003.htm @@ -0,0 +1,28 @@ +<!DOCTYPE html> +<html><head> + <title>Shape Outside Inset Valid Round Length Units</title> + <link href="http://html.adobe.com/" rel="author" title="Adobe"> + <link href="mailto:rhauck@adobe.com" rel="author" title="Rebecca Hauck"> + <link href="mailto:stearns@adobe.com" rel="reviewer" title="Alan Stearns"> <!-- 2014-03-04 --> + <link href="http://www.w3.org/TR/css-shapes-1/#funcdef-inset" rel="help"> + <link href="http://www.w3.org/TR/css-shapes-1/#shape-outside-property" rel="help"> + <link href="http://www.w3.org/TR/css3-values/#lengths" rel="help"> + <meta content="An inset's radial component's values can be in any length unit" name="assert"> + <meta content="dom" name="flags"> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> + <script src="support/parsing-utils.js"></script> + </head> + <body> + <div id="log"></div> + <script type="text/javascript"> + ParsingUtils.validUnits.forEach(function(unit) { + generate_tests(ParsingUtils.testInlineStyle, ParsingUtils.generateInsetRoundCases(unit, 'inline')); + }); + ParsingUtils.validUnits.forEach(function(unit) { + generate_tests(ParsingUtils.testComputedStyle, ParsingUtils.generateInsetRoundCases(unit, 'computed')); + }); + </script> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/shape-outside-polygon-004.htm b/tests/wpt/css-tests/css-values-3_dev/html/shape-outside-polygon-004.htm new file mode 100644 index 00000000000..777d593d4f0 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/shape-outside-polygon-004.htm @@ -0,0 +1,38 @@ +<!DOCTYPE html> +<html><head> + <title>Shape Outside Polygon - Argument Length Units</title> + <link href="http://html.adobe.com/" rel="author" title="Adobe"> + <link href="mailto:rhauck@adobe.com" rel="author" title="Rebecca Hauck"> + <link href="mailto:stearns@adobe.com" rel="reviewer" title="Alan Stearns"> <!-- 2014-03-04 --> + <link href="http://www.w3.org/TR/css-shapes-1/#funcdef-polygon" rel="help"> + <link href="http://www.w3.org/TR/css-shapes-1/#shape-outside-property" rel="help"> + <link href="http://www.w3.org/TR/css3-values/#lengths" rel="help"> + <meta content="A polygon's veritices may in percentage or any valid <length> units." name="assert"> + <meta content="dom" name="flags"> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> + <script src="support/parsing-utils.js"></script> + </head> + <body> + <div id="log"></div> + <script type="text/javascript"> + var arg_length_units_tests = [ + ['%', 'px', 'px'], + ['px', '%', 'px'], + ['px', 'px', '%'], + ['%', '%', '%'], + ['em', 'em', 'ex'], + ['vw', 'vh', '%'], + ['cm', 'mm', 'pc'], + ['vmin', 'vmin', 'vmax'], + ['rem', 'ch', 'rem'], + ['in', 'pt', '%'] + ]; + generate_tests( ParsingUtils.testInlineStyle, + ParsingUtils.buildPolygonTests(arg_length_units_tests, 'inline') ); + generate_tests( ParsingUtils.testComputedStyle, + ParsingUtils.buildPolygonTests(arg_length_units_tests, 'computed') ); + </script> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/1x1-green.png b/tests/wpt/css-tests/css-values-3_dev/html/support/1x1-green.png new file mode 100644 index 0000000000000000000000000000000000000000..b98ca0ba0a03c580ac339e4a3653539cfa8edc71 GIT binary patch literal 135 zcmeAS@N?(olHy`uVBq!ia0vp^j3CU&3?x-=hn)gaEa{HEjtmUzPnffIy#(@^1AIbU z85$Vo{9HN_$mQ~MaSW-rm7D-%GchneRloNK$dW8^jVKAuPb(=;EJ|f?Ovz75Rq)JB bOiv9;O-!jQJeg_(RK(!v>gTe~DWM4f4{;-! literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/1x1-lime.png b/tests/wpt/css-tests/css-values-3_dev/html/support/1x1-lime.png new file mode 100644 index 0000000000000000000000000000000000000000..cb397fb090e199c51e80e4243d1ede03a79aa8d9 GIT binary patch literal 135 zcmeAS@N?(olHy`uVBq!ia0vp^j3CU&3?x-=hn)gaEa{HEjtmUzPnffIy#(@^1AIbU z8U8bv#2r`x<Z^ksIEGZ*N=^W>nHU(Ks^9wqWJ#8|MwA5Sr<If^7Ns&crsOB3DtP85 brl$s_CZ<#to=mj?Dq`?-^>bP0l+XkK_<AEq literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/1x1-maroon.png b/tests/wpt/css-tests/css-values-3_dev/html/support/1x1-maroon.png new file mode 100644 index 0000000000000000000000000000000000000000..3f86b0721955eb4e0f014102c68c2a9764ef7593 GIT binary patch literal 109 zcmeAS@N?(olHy`uVBq!ia0vp^j3CUx1|;Q0k8}blwj^(N7lsBPi@{?l_gf&vS>O>_ v4B~>Z+sSM@AcNP_#W95AdU8fW!Vi81W){YV4{giyfD#Ozu6{1-oD!M<@rf3U literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/1x1-navy.png b/tests/wpt/css-tests/css-values-3_dev/html/support/1x1-navy.png new file mode 100644 index 0000000000000000000000000000000000000000..9b9a03955baea7abde9e056e8604e18694e49b66 GIT binary patch literal 109 zcmeAS@N?(olHy`uVBq!ia0vp^j3CUx1|;Q0k8}blwj^(N7a+~R&>-^LA|6O{7I;J! w18EO1b~~AE2W0Six;Tb#Tu)9&$oRp}z{JAX(7`d=3n;<h>FVdQ&MBb@0MNe`HUIzs literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/1x1-red.png b/tests/wpt/css-tests/css-values-3_dev/html/support/1x1-red.png new file mode 100644 index 0000000000000000000000000000000000000000..6bd73ac101874f306d007e9cea8fa3a1f62dce16 GIT binary patch literal 135 zcmeAS@N?(olHy`uVBq!ia0vp^j3CU&3?x-=hn)gaEa{HEjtmUzPnffIy#(@^1AIbU z|1&U1KH@Y7a=AQR978H@B_{ycObm=q)$jcQvLs7fBT9nv(@M${i&7aJQ}UBi6+Ckj b(^G>|6H_V+Po~-c6)||a`njxgN@xNA!@(kn literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/1x1-white.png b/tests/wpt/css-tests/css-values-3_dev/html/support/1x1-white.png new file mode 100644 index 0000000000000000000000000000000000000000..dd43faec54ae60a210f1eab6ff4e7c88b8e34c97 GIT binary patch literal 109 zcmeAS@N?(olHy`uVBq!ia0vp^j3CUx1|;Q0k8}blwj^(N7l!{JxM1({$v_d#0*}aI wAngIhZYQ(tfDB$w7sn8e>&ZX<|Nmdl!1<f`@5Sbx4?qb9Pgg&ebxsLQ020p~!2kdN literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/2-80px-block-ref.html b/tests/wpt/css-tests/css-values-3_dev/html/support/2-80px-block-ref.html new file mode 100644 index 00000000000..f616001554c --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/support/2-80px-block-ref.html @@ -0,0 +1,33 @@ +<!DOCTYPE html> +<html lang="en"><head> + <meta charset="UTF-8"> + <title>One region in body</title> + <style> + html, body { + margin: 0; + padding: 0; + } + .content { + margin: 10px; + font-family: Ahem; + font-size: 20px; + line-height: 1em; + color: green; + } + </style> +</head> +<body> + <div class="content"> + xxxx<br> + xxxx<br> + xxxx<br> + xxxx + </div> + <div class="content"> + xxxx<br> + xxxx<br> + xxxx<br> + xxxx + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/60x60-gg-rr.png b/tests/wpt/css-tests/css-values-3_dev/html/support/60x60-gg-rr.png new file mode 100644 index 0000000000000000000000000000000000000000..84f5b2a4f1d1865d763cac875bfa6a8c5c576c91 GIT binary patch literal 224 zcmeAS@N?(olHy`uVBq!ia0vp^HXzKw1SGf4^HT*<jKx9jP7LeL$-D$|I14-?iy0WW zg+Z8+Vb&Z8pdfpRr>`sfEmlzu3&R;K0lq*X$r9Iy66gHf+|;}h2Ir#G#FEq$h4Rdj z3<Y;j-+=H&K5?KTUr!gukc@k8FBtMN81S%c^q)Ar(pb!~&BKo6T4>(2QlSh?@M7jG eOI|GCZ+2WP<2UBa)$Kro89ZJ6T-G@yGywqpiaLV; literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/60x60-green.png b/tests/wpt/css-tests/css-values-3_dev/html/support/60x60-green.png new file mode 100644 index 0000000000000000000000000000000000000000..b3c8cf3eb4c89bd8f2d1ffde051856f375e3a3de GIT binary patch literal 218 zcmeAS@N?(olHy`uVBq!ia0vp^HXzKw1SGf4^HT*<jKx9jP7LeL$-D$|I14-?iy0WW zg+Z8+Vb&Z8pdfpRr>`sfEmlzu3yE9XPACF}BuiW)N}Tg^b5rw57@Uhz6H8K46v{J8 zG8EiBeFMT9`NV;W+&x_!Lo)8YJ?F^Fz`((>;PMkU^HzRy4~NuGe(INq1>ePjdKrGS TIXtNc8p+`4>gTe~DWM4fy9-d) literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/60x60-red.png b/tests/wpt/css-tests/css-values-3_dev/html/support/60x60-red.png new file mode 100644 index 0000000000000000000000000000000000000000..823f125b8e4a60f780f00443c9c9a10b9fa1f447 GIT binary patch literal 217 zcmeAS@N?(olHy`uVBq!ia0vp^HXzKw1SGf4^HT*<jKx9jP7LeL$-D$|I14-?iy0WW zg+Z8+Vb&Z8pdfpRr>`sfEmlzuQ<1cFzubXBk|nMYCC>S|xv6<249-QVi6yBi3gww4 z84B*6z5(HleBwYwZk{fVAsP4Ho@3->VBlchkp2JMEhm9(EUQo2%VrV@UNUpX$1;`+ Ty_~-WXd;8BtDnm{r-UW|v1>m& literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/80px-block-float-ref.html b/tests/wpt/css-tests/css-values-3_dev/html/support/80px-block-float-ref.html new file mode 100644 index 00000000000..6adeeb6fa99 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/support/80px-block-float-ref.html @@ -0,0 +1,27 @@ +<!DOCTYPE html> +<html lang="en"><head> + <meta charset="UTF-8"> + <title>One region in body</title> + <style> + html, body { + margin: 0; + padding: 0; + } + #content { + font-family: Ahem; + font-size: 20px; + line-height: 1em; + color: green; + float: right; + } + </style> +</head> +<body> + <div id="content"> + xxxx<br> + xxxx<br> + xxxx<br> + xxxx + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/80px-block-ref.html b/tests/wpt/css-tests/css-values-3_dev/html/support/80px-block-ref.html new file mode 100644 index 00000000000..2c910e93411 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/support/80px-block-ref.html @@ -0,0 +1,26 @@ +<!DOCTYPE html> +<html lang="en"><head> + <meta charset="UTF-8"> + <title>One region in body</title> + <style> + html, body { + margin: 0; + padding: 0; + } + #content { + font-family: Ahem; + font-size: 20px; + line-height: 1em; + color: green; + } + </style> +</head> +<body> + <div id="content"> + xxxx<br> + xxxx<br> + xxxx<br> + xxxx + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/README b/tests/wpt/css-tests/css-values-3_dev/html/support/README new file mode 100644 index 00000000000..69d1737bead --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/support/README @@ -0,0 +1,29 @@ +CSS Global Support Directory +============================ + +This directory contains common support files (such as images and external +style sheets). These are sync'ed into the support directories of all our +test suites. If you have test-suite-specific support files, please add +them to the appropriate test-suite-specific support/ directory. + +If you add to a support/ directory, please run the tools/supportprop.py +script from the top of the repository to cascade support files into the +lower-level support directories. + +Description of the Common Support File Collection +------------------------------------------------- + +The 1x1-* images are all exactly one pixel. + +The swatch-* images all use 15x15 cells. + +The square-* images all use 15x15 cells with one pixel borders. + +The pattern-* images use cells of various sizes: + + pattern-gg-gr.png 20x20 + pattern-grg-rgr-grg.png 20x20 + pattern-rgr-grg-rgr.png 20x20 + pattern-tr.png 15x15 + pattern-grg-rrg-rgg.png 15x15 + diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/a-green.css b/tests/wpt/css-tests/css-values-3_dev/html/support/a-green.css new file mode 100644 index 00000000000..b0dbb071d5b --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/support/a-green.css @@ -0,0 +1 @@ +.a { color: green; } diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/b-green.css b/tests/wpt/css-tests/css-values-3_dev/html/support/b-green.css new file mode 100644 index 00000000000..a0473f5ca26 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/support/b-green.css @@ -0,0 +1 @@ +.b { color: green; } \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/black20x20.png b/tests/wpt/css-tests/css-values-3_dev/html/support/black20x20.png new file mode 100644 index 0000000000000000000000000000000000000000..ebf7027ee785af8acf0bf6c213c616b4055ee10f GIT binary patch literal 165 zcmeAS@N?(olHy`uVBq!ia0vp^A|TAc1SFYWcSQjy#^NA%Cx&(BWL^R}oCO|{#S9F5 zM?jcysy3fAP>{XE)7O>#4vV<BhIm+`Vi!<Ivcxr_#5q4VH#M(>!MP|ku_QG`p**uB zL&4qCHz2%`PaLR7$kW9!#Nu>vf&}a01d*Pmh1?7*M;I8N6kM?a$})Jm`njxgN@xNA DYH%n_ literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/c-red.css b/tests/wpt/css-tests/css-values-3_dev/html/support/c-red.css new file mode 100644 index 00000000000..d4ba5c64e95 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/support/c-red.css @@ -0,0 +1 @@ +.c { color: red; } \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/cat.png b/tests/wpt/css-tests/css-values-3_dev/html/support/cat.png new file mode 100644 index 0000000000000000000000000000000000000000..85dd7324815b8f8ef1a1d0496224c1a0661db9d8 GIT binary patch literal 1883 zcmV-h2c-CkP)<h;3K|Lk000e1NJLTq003eD003hM0ssI3n4EHI0000LbVXQnLvm$d zbZKvHAXI5>WdH}z3>gRm8%$Aad;kCd2XskIMF-Ff83-yN8ye1400009a7bBm000id z000id0mpBsWB>pL*-1n}RCwC$Tnn<>HVmXZK1a^ho3&SK4-(g{9GN13#R7t8y*I%m zZ)BMw!6g9VLwR{T9*v;e^Z&9e>xbnR^*7(`)-M11{_j7xFNSfJ@$>S&(_i1@5GH@m zhpeXC{afFEKhVJCt^WWpLj3iQEg77_JYJnk79anUvL0gx`(AYZ27s0x;q_WRcJD`A zg+R7jBu}y@4l@kFdQJ7DGoh@H-xD(&>S?#kV5MJwAHN8ovs16uEnknmyyLJw3_Dz} z-2t_1y-WcyWmd+)eVZDoh>C$4rk3Oju)y$mQ#%^)+P>PB74gM`GN6$$a17nlNge7- z3RmB|dPjb|$p?mh6-(D?ThB@WuYf>+sj1twj=G%GFkj5O!mZqLtqotF8cC*N$ri;H z2HQ+$17ses$k7#RTbJz}gD2-`@wiB%W8DFRH7rLV$VR8C-{$0BU^7QA)6xcOPkeLG zIC+y8#pH<ZE4DkLuB$eJu=YD09p6saU_=3B*q=j^t+sjfsKzKVsF6<N*#6N`(<ECy zIXKz+z9s_>H3S(N>pr`5y87*;bv|b^HW*-n7#c-VH5l06wfM%K8tMv%QYu1VMJ&`q zXuT9g-DjG%ok+2IhK&G~#M;r0zu4sf-`3+KmoX<0eCv7>JZuYAQ4+JlXds3Yz$`iq zO!pQ9wr}Yor1)n9bJP~%@)tD+crwU7nJ%PeORd0)1m4F<)qG~XO2nT^iMivEf)z-D zBxjR-YQ3Q3>4*f>(%TkH;D#Ki*aVYot>nkyxLr9zV62-PtQAsVZ<)M&ROZ`q=r-yb zxV0FojhaWJa00$t-zE`xTYXArX#ra%P+dk^apt~h+vO{<A@@#@ZFd70kl?YRKP5&g zb`j&Qn9|8fN_S*$P|_f3a(aM4y>N9i$&>6i;Se`Xu#!Aka_7=8lY{bL`gE8-D*^)! zY7!?ohKiqcXDjd>0jZICXBl_KZ$6sC00LyW54V5*dj5-!>hm-t>Ht(52LoWuR*1xE z2G*{@twTZxdhmIo{825j6wMk`;$*SKGZc>R!t=-#&gkXa<yH8pw79M3dp_ikAFn&8 zlrN9ORLOJsca5=ic6o}b2pc1mIER3bjmUh7pG>kkRkQfHYSKVRo~#WuBph;XemDuD z6qUJ989evMeRwkDj)54kU$UA#IGU-IZHnWTVRA#9kA1APN3ZjwA2_hn2Ug_Nvo#=1 zvdA6|8~BUnoI@62w{|P|2@lwrchE#7bJ6Kq6kBhZllSFE87tja$&a^Vsv9DzjxZA* zQVOrQc2nyJWb8G&wn4GZFkUv;Z=ATnxIprXHN_9;9UHeyvrlY2*kxbFPXGYML&r3) zen%FSp5K}|`|V@N#w>xf>JHCqGnQ($o1mTz0Za^NSrBZ!onF6dnw<3&y(VH1bndXf z391*{FlywkRueb2`q*Y`c5i|#c-`R1y$R0#>_jShsA?F))d087sWd*L&RJQPVgO6z zuKDv)`2I=hc!ut73ss<T4Sc(1p2frAo70eTGSQX~W-TmJr(%YaR!iQ`4Ur=@=?jjU zfTygMe0q~vry0lFm|`8tJ+roq*(WDI6R9%w#!|-Y#%eR(ke!N@^4>>?(GbUMv>AFu zU<y*Z1YJ38rx1Sr_(M)_9Tc=-h}Yr*n2uA=E}I+loFj7auyHJrfHI|Po@I%y`4tj7 zZ|2XgMqBeQS(s^b?xD;O6`XX77pU2u-JQEex9#}uQe_K^?kYOxRi<VJVwG%9W16&C zB}3F3+z%GVHY()dth0|pcjvht>SWGaq^ijA)f<0KH8%k6{9y7l%|MvpgU?6jsh(M$ z5N*sz^783ghS!jcq!BDms81L*G}VLWyHB!u>=8qC&htH>PmP{A<v#~L#&MqpRv4yG zw4r_l@+VBe#^s0kwg9GF@{ms(MG=X;Z*q>HB})c5>>6kFjvP9zMaPHfq~YhEr7DrH zD;~lup<3-juf%_Prr9Z-V4nORxcT&~FF{{2Nk&bqG}pd>$n(1*n4sj(w0;RH6sT{j zbhUJqyjT6iN>h5jrHP`lGXxi;LI(=%bR`2^fsT95-&yGjH)}sb@TGCA(mUti&QX<4 z{U$^U=I18hwKL%pN^cWLwM6MtTI+-Up~5fcjt@Bxe*M77{d?${Py^67eTt4eFFZ)l zh8I~nmB}UQ_u%EtP`CsPA88ZuaO!(Y>9V^z>txmUh$SjH&7r>5XT86X<2m!DSg2-= z-<rS@<i5Y4N=-ro_(K1~{gF<l7M3R7QZPDFa>~W*e9lSUNASn#NOM-@)>-Im^e@d- V<q-+yJ<<RG002ovPDHLkV1mLWjBEe^ literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/generalParallelTest.js b/tests/wpt/css-tests/css-values-3_dev/html/support/generalParallelTest.js new file mode 100644 index 00000000000..1a4bf343df0 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/support/generalParallelTest.js @@ -0,0 +1,231 @@ +(function(root) { +'use strict'; +// +var index = 0; +var suite = root.generalParallelTest = { + // prepare individual test + setup: function(data, options) { + suite._setupDom(data, options); + suite._setupEvents(data, options); + }, + // clone fixture and prepare data containers + _setupDom: function(data, options) { + // clone fixture into off-viewport test-canvas + data.fixture = document.getElementById('fixture').cloneNode(true); + data.fixture.id = 'test-' + (index++); + (document.getElementById('offscreen') || document.body).appendChild(data.fixture); + + // data container for #fixture > .container > .transition + data.transition = { + node: data.fixture.querySelector('.transition'), + values: [], + events: [], + computedStyle: function(property) { + return computedStyle(data.transition.node, property); + } + }; + + // data container for #fixture > .container + data.container = { + node: data.transition.node.parentNode, + values: [], + events: [], + computedStyle: function(property) { + return computedStyle(data.container.node, property); + } + }; + + // data container for #fixture > .container > .transition[:before | :after] + if (data.pseudo) { + data.pseudo = { + name: data.pseudo, + values: [], + computedStyle: function(property) { + return computedStyle(data.transition.node, property, ':' + data.pseudo.name); + } + }; + } + }, + // bind TransitionEnd event listeners + _setupEvents: function(data, options) { + ['transition', 'container'].forEach(function(elem) { + var handler = function(event) { + event.stopPropagation(); + var name = event.propertyName; + var time = Math.round(event.elapsedTime * 1000) / 1000; + var pseudo = event.pseudoElement ? (':' + event.pseudoElement) : ''; + data[elem].events.push(name + pseudo + ":" + time + "s"); + }; + data[elem].node.addEventListener('transitionend', handler, false); + data[elem]._events = {'transitionend': handler}; + }); + }, + // cleanup after individual test + teardown: function(data, options) { + // data.fixture.remove(); + if (data.fixture.parentNode) { + data.fixture.parentNode.removeChild(data.fixture); + } + }, + // invoked prior to running a slice of tests + sliceStart: function(options, tests) { + // inject styles into document + setStyle(options.styles); + // kick off value collection loop + generalParallelTest.startValueCollection(options); + }, + // invoked after running a slice of tests + sliceDone: function(options, tests) { + // stop value collection loop + generalParallelTest.stopValueCollection(options); + // reset styles cache + options.styles = {}; + }, + // called once all tests are done + done: function(options) { + // reset document styles + setStyle(); + reflow(); + }, + // add styles of individual test to slice cache + addStyles: function(data, options, styles) { + if (!options.styles) { + options.styles = {}; + } + + Object.keys(styles).forEach(function(key) { + var selector = '#' + data.fixture.id + // fixture must become #fixture.fixture rather than a child selector + + (key.substring(0, 8) === '.fixture' ? '' : ' ') + + key; + + options.styles[selector] = styles[key]; + }); + }, + // set style and compute values for container and transition + getStyle: function(data) { + reflow(); + // grab current styles: "initial state" + suite._getStyleFor(data, 'from'); + // apply target state + suite._addClass(data, 'to', true); + // grab current styles: "target state" + suite._getStyleFor(data, 'to'); + // remove target state + suite._removeClass(data, 'to', true); + + // clean up the mess created for value collection + data.container._values = []; + data.transition._values = []; + if (data.pseudo) { + data.pseudo._values = []; + } + }, + // grab current styles and store in respective element's data container + _getStyleFor: function(data, key) { + data.container[key] = data.container.computedStyle(data.property); + data.transition[key] = data.transition.computedStyle(data.property); + if (data.pseudo) { + data.pseudo[key] = data.pseudo.computedStyle(data.property); + } + }, + // add class to test's elements and possibly reflow + _addClass: function(data, className, forceReflow) { + data.container.node.classList.add(className); + data.transition.node.classList.add(className); + if (forceReflow) { + reflow(); + } + }, + // remove class from test's elements and possibly reflow + _removeClass: function(data, className, forceReflow) { + data.container.node.classList.remove(className); + data.transition.node.classList.remove(className); + if (forceReflow) { + reflow(); + } + }, + // add transition and to classes to container and transition + startTransition: function(data) { + // add transition-defining class + suite._addClass(data, 'how', true); + // add target state (without reflowing) + suite._addClass(data, 'to', false); + }, + // requestAnimationFrame runLoop to collect computed values + startValueCollection: function(options) { + var raf = window.requestAnimationFrame || function(callback){ + setTimeout(callback, 20); + }; + + // flag denoting if the runLoop should continue (true) or exit (false) + options._collectValues = true; + + function runLoop() { + if (!options._collectValues) { + // test's are done, stop annoying the CPU + return; + } + + // collect current style for test's elements + options.tests.forEach(function(data) { + if (!data.property) { + return; + } + + ['transition', 'container', 'pseudo'].forEach(function(elem) { + var pseudo = null; + if (!data[elem] || (elem === 'pseudo' && !data.pseudo)) { + return; + } + + var current = data[elem].computedStyle(data.property); + var values = data[elem].values; + var length = values.length; + if (!length || values[length - 1] !== current) { + values.push(current); + } + }); + }); + + // rinse and repeat + raf(runLoop); + } + + runLoop(); + }, + // stop requestAnimationFrame runLoop collecting computed values + stopValueCollection: function(options) { + options._collectValues = false; + }, + + // generate test.step function asserting collected events match expected + assertExpectedEventsFunc: function(data, elem, expected) { + return function() { + var _result = data[elem].events.sort().join(" "); + var _expected = typeof expected === 'string' ? expected : expected.sort().join(" "); + assert_equals(_result, _expected, "Expected TransitionEnd events triggered on ." + elem); + }; + }, + // generate test.step function asserting collected values are neither initial nor target + assertIntermediateValuesFunc: function(data, elem) { + return function() { + // the first value (index: 0) is always going to be the initial value + // the last value is always going to be the target value + var values = data[elem].values; + if (data.flags.discrete) { + // a discrete value will just switch from one state to another without having passed intermediate states. + assert_equals(values[0], data[elem].from, "must be initial value while transitioning on ." + elem); + assert_equals(values[1], data[elem].to, "must be target value after transitioning on ." + elem); + assert_equals(values.length, 2, "discrete property only has 2 values ." + elem); + } else { + assert_not_equals(values[1], data[elem].from, "may not be initial value while transitioning on ." + elem); + assert_not_equals(values[1], data[elem].to, "may not be target value while transitioning on ." + elem); + } + + // TODO: first value must be initial, last value must be target + }; + } +}; + +})(window); diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/helper.js b/tests/wpt/css-tests/css-values-3_dev/html/support/helper.js new file mode 100644 index 00000000000..242cd3ca635 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/support/helper.js @@ -0,0 +1,96 @@ +// +// Simple Helper Functions For Testing CSS +// + +(function(root) { +'use strict'; + +// serialize styles object and dump to dom +// appends <style id="dynamic-style"> to <head> +// setStyle("#some-selector", {"some-style" : "value"}) +// setStyle({"#some-selector": {"some-style" : "value"}}) +root.setStyle = function(selector, styles) { + var target = document.getElementById('dynamic-style'); + if (!target) { + target = document.createElement('style'); + target.id = 'dynamic-style'; + target.type = "text/css"; + document.getElementsByTagName('head')[0].appendChild(target); + } + + var data = []; + // single selector/styles + if (typeof selector === 'string' && styles !== undefined) { + data = [selector, '{', serializeStyles(styles), '}']; + target.textContent = data.join("\n"); + return; + } + // map of selector/styles + for (var key in selector) { + if (Object.prototype.hasOwnProperty.call(selector, key)) { + var _data = [key, '{', serializeStyles(selector[key]), '}']; + data.push(_data.join('\n')); + } + } + + target.textContent = data.join("\n"); +}; + +function serializeStyles(styles) { + var data = []; + for (var property in styles) { + if (Object.prototype.hasOwnProperty.call(styles, property)) { + var prefixedProperty = addVendorPrefix(property); + data.push(prefixedProperty + ":" + styles[property] + ";"); + } + } + + return data.join('\n'); +} + + +// shorthand for computed style +root.computedStyle = function(element, property, pseudo) { + var prefixedProperty = addVendorPrefix(property); + return window + .getComputedStyle(element, pseudo || null) + .getPropertyValue(prefixedProperty); +}; + +// flush rendering buffer +root.reflow = function() { + document.body.offsetWidth; +}; + +// merge objects +root.extend = function(target /*, ..rest */) { + Array.prototype.slice.call(arguments, 1).forEach(function(obj) { + Object.keys(obj).forEach(function(key) { + target[key] = obj[key]; + }); + }); + + return target; +}; + +// dom fixture helper ("resetting dom test elements") +var _domFixture; +var _domFixtureSelector; +root.domFixture = function(selector) { + var fixture = document.querySelector(selector || _domFixtureSelector); + if (!fixture) { + throw new Error('fixture ' + (selector || _domFixtureSelector) + ' not found!'); + } + if (!_domFixture && selector) { + // save a copy + _domFixture = fixture.cloneNode(true); + _domFixtureSelector = selector; + } else if (_domFixture) { + // restore the copy + var tmp = _domFixture.cloneNode(true); + fixture.parentNode.replaceChild(tmp, fixture); + } else { + throw new Error('domFixture must be initialized first!'); + } +}; +})(window); diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/import-green.css b/tests/wpt/css-tests/css-values-3_dev/html/support/import-green.css new file mode 100644 index 00000000000..537104e6633 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/support/import-green.css @@ -0,0 +1 @@ +.import { color: green; } diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/import-red.css b/tests/wpt/css-tests/css-values-3_dev/html/support/import-red.css new file mode 100644 index 00000000000..9945ef47114 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/support/import-red.css @@ -0,0 +1 @@ +.import { color: red; } diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/min-width-tables-001-iframe.html b/tests/wpt/css-tests/css-values-3_dev/html/support/min-width-tables-001-iframe.html new file mode 100644 index 00000000000..edc548a6aab --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/support/min-width-tables-001-iframe.html @@ -0,0 +1,59 @@ +<!DOCTYPE html> +<html><head> + <meta charset="utf-8"> + <title>iframe containing the meat of the test</title> + <style> +body { + margin: 0; + overflow: hidden; +} +/* green div that should cover the red divs */ +#green { + position: absolute; + left: 0; + top: 0; + background-color: green; + width: 100%; + height: 600px; +} +.spacer { + height: 98px; + width: 20px; +} +.item { + background-color: red; + display: block;/* property under test */ + /* border to aid understanding of boundaries between items */ + border-style: solid; + border-width: 1px; + border-color: red;/* Note: if you're trying to debug this, use a different color here */ +} +/* 100px = 10*(1 + 8 + 1) */ +@media (min-width: 100px) { + #green { + width: 100px; + height: 100px;/* = 1 + 98 + 1 */ + } + .item { + display: table-cell;/* property and value under test */ + } +} + </style> +</head> +<body> + <div> + <div class="item"><div class="spacer"></div></div> + <div class="item"><div class="spacer"></div></div> + <div class="item"><div class="spacer"></div></div> + <div class="item"><div class="spacer"></div></div> + <div class="item"><div class="spacer"></div></div> + <div class="item"><div class="spacer"></div></div> + <div class="item"><div class="spacer"></div></div> + <div class="item"><div class="spacer"></div></div> + <div class="item"><div class="spacer"></div></div> + <div class="item"><div class="spacer"></div></div> + </div> + <div id="green"></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/one.gif b/tests/wpt/css-tests/css-values-3_dev/html/support/one.gif new file mode 100644 index 0000000000000000000000000000000000000000..74cf7839c9fc0f1572d600ef559972b8e1ae57fc GIT binary patch literal 184 zcmZ?wbh9u|G-5Dfc+3C-|NsBLfB*je{rltN<K^Y$>+9?1&!2B^Zx5D4Cv-ppAiWGM zxdJCVSMRlWeRlW%1dYCw%y}8B*5$n3SD<sgB=>&By7x8j|C=6ca1apCb6WIKbpj6; z^Ah1xGH#0-ni*&B*~iu3C>+hvz?e|@qg2M`BvZ?hziHe&N0WD0?0??a(Ad=6(%RPE R(b?7A)7#fSp+S(r8UVwOMW_G( literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/parsing-utils.js b/tests/wpt/css-tests/css-values-3_dev/html/support/parsing-utils.js new file mode 100644 index 00000000000..beea4958ce8 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/support/parsing-utils.js @@ -0,0 +1,866 @@ +var ParsingUtils = (function() { +function testInlineStyle(value, expected) { + var div = document.createElement('div'); + div.style.setProperty('shape-outside', value); + var actual = div.style.getPropertyValue('shape-outside'); + assert_equals(actual, expected); +} + +function testComputedStyle(value, expected) { + var div = document.createElement('div'); + div.style.setProperty('shape-outside', value); + document.body.appendChild(div); + var style = getComputedStyle(div); + var actual = style.getPropertyValue('shape-outside'); + actual = roundResultStr(actual); + document.body.removeChild(div); + + // Some of the tests in this suite have either/or expected results + // so this check allows for testing that at least one of them passes. + // Description of the 2 expecteds is below near calcTestValues. + if(Object.prototype.toString.call( expected ) === '[object Array]' && expected.length == 2) { + assert_true(expected[0] == actual || expected[1] == actual) + } else { + assert_equals(actual, typeof expected !== 'undefined' ? expected : value); + } +} + +function testShapeMarginInlineStyle(value, expected) { + var div = document.createElement('div'); + div.style.setProperty('shape-outside', "border-box inset(10px)"); + div.style.setProperty('shape-margin', value); + var actual = div.style.getPropertyValue('shape-margin'); + assert_equals(actual, expected); +} + +function testShapeMarginComputedStyle(value, expected) { + + var outerDiv = document.createElement('div'); + outerDiv.style.setProperty('width', '100px'); + + var innerDiv = document.createElement('div'); + innerDiv.style.setProperty('shape-outside', "border-box inset(10px)"); + innerDiv.style.setProperty('shape-margin', value); + + outerDiv.appendChild(innerDiv); + document.body.appendChild(outerDiv); + + var style = getComputedStyle(innerDiv); + var actual = style.getPropertyValue('shape-margin'); + + assert_not_equals(actual, null); + if(actual.indexOf('calc') == -1 ) + actual = roundResultStr(actual); + document.body.removeChild(outerDiv); + + // See comment above about multiple expected results + if(Object.prototype.toString.call( expected ) === '[object Array]' && expected.length == 2) { + assert_true(expected[0] == actual || expected[1] == actual) + } else { + assert_equals(actual, !expected ? '0px' : expected); + } +} + +function testShapeThresholdInlineStyle(value, expected) { + var div = document.createElement('div'); + div.style.setProperty('shape-outside', 'url(someimage.png)'); + div.style.setProperty('shape-image-threshold', value); + var actual = div.style.getPropertyValue('shape-image-threshold'); + assert_equals(actual, expected); +} + +function testShapeThresholdComputedStyle(value, expected) { + + var div = document.createElement('div'); + div.style.setProperty('shape-outside', 'url(someimage.png)'); + div.style.setProperty('shape-image-threshold', value); + document.body.appendChild(div); + + var style = getComputedStyle(div); + var actual = style.getPropertyValue('shape-image-threshold'); + + assert_not_equals(actual, null); + if(actual.indexOf('calc') == -1 ) + actual = roundResultStr(actual); + document.body.removeChild(div); + + // See comment above about multiple expected results + if(Object.prototype.toString.call( expected ) === '[object Array]' && expected.length == 2) { + assert_true(expected[0] == actual || expected[1] == actual) + } else { + assert_equals(actual, !expected ? '0' : expected); + } +} + +// Builds an array of test cases to send to testharness.js where one test case is: [name, actual, expected] +// These test cases will verify results from testInlineStyle() or testComputedStyle() +function buildTestCases(testCases, testType) { + var results = []; + + // If test_type isn't specified, test inline style + var type = typeof testType == 'undefined' ? 'invalid': testType; + + testCases.forEach(function(test) { + oneTestCase = []; + + // name - annotated by type (inline vs. computed) + if ( test.hasOwnProperty('name') ) { + oneTestCase.push(test['name'] +' - '+ type); + } else { + // If test_name isn't specified, use the actual + oneTestCase.push(test['actual'] +' - '+ type); + } + + // actual + oneTestCase.push(test['actual']) + + // expected + if( type.indexOf('invalid') != -1 ){ + oneTestCase.push(null) + } else if( type == 'inline' ) { + oneTestCase.push(test['expected_inline']); + } else if( type == 'computed' ){ + oneTestCase.push( convertToPx(test['expected_computed']) ); + } + results.push(oneTestCase); + }); + return results; +} + + +function buildPositionTests(shape, valid, type, units) { + var results = new Array(); + var convert = type.indexOf('computed') != -1 ? true : false; + + if(Object.prototype.toString.call( units ) === '[object Array]') { + units.forEach(function(unit) { + positionTests = buildPositionTests(shape, valid, type, unit); + results = results.concat(positionTests); + }); + } else { + if (valid) { + validPositions.forEach(function(test) { + var testCase = [], testName, actual, expected; + // skip if this isn't explicitly testing length units + if( !(type.indexOf('lengthUnit') != -1 && test[0].indexOf("u1") == -1)) { + // actual + actual = shape + '(at ' + setUnit(test[0], false, units) +')'; + + // expected + // if(convert && shape == 'circle') + // expected = shape + '(at ' + setUnit(test[1], convert, units) +')'; + // else if(convert && shape == 'ellipse') + // expected = shape + '(at ' + setUnit(test[1], convert, units) +')'; + // else + expected = shape + '(at ' + setUnit(test[1], convert, units) +')'; + + // name + if (type == 'lengthUnit + inline') + testName = 'test unit (inline): ' + units +' - '+ actual; + else if (type == 'lengthUnit + computed') + testName = 'test unit (computed): ' + units +' - '+ actual; + else + testName = (actual + ' serializes as ' + expected +' - '+ type); + + testCase.push(testName) + testCase.push(actual); + testCase.push(expected); + results.push(testCase); + } + }); + } else { + invalidPositions.forEach(function(test) { + var testValue = shape + '(at ' + setUnit(test, false, units) +')'; + testCase = new Array(); + testCase.push(testValue + ' is invalid'); + testCase.push(testValue); + testCase.push(null); + results.push(testCase); + }); + } + } + return unique(results); +} + +function buildRadiiTests(shape, type, units) { + var results = new Array(); + var testUnits = typeof units == 'undefined' ? 'px': units; + var convert = type.indexOf('computed') != -1 ? true : false; + + if(Object.prototype.toString.call( testUnits ) === '[object Array]') { + testUnits.forEach(function(unit) { + radiiTests = buildRadiiTests(shape, type, unit); + results = results.concat(radiiTests); + }); + } else { + var validRadii = shape == 'circle' ? validCircleRadii : validEllipseRadii; + validRadii.forEach(function(test) { + var testCase = [], name, actual, expected; + + // skip if this isn't explicitly testing length units + if( !(type.indexOf('lengthUnit') != -1 && test[0].indexOf("u1") == -1) ) { + actual = shape + '(' + setUnit(test[0], false, testUnits) +')'; + // name + if (type.indexOf('lengthUnit') != -1) { + name = 'test unit: ' + units +' - '+ actual; + if(type.indexOf('computed') != -1) + name = name + ' - computed'; + else + name = name + ' - inline'; + } + else + name = actual +' - '+ type; + + testCase.push(name); + + // actual + testCase.push(actual); + + // expected + if(type.indexOf('computed') != -1 && test.length == 3) { + expected = shape + '(' + setUnit(test[2], convert, testUnits) +')'; + } else { + expected = shape + '(' + setUnit(test[1], convert, testUnits) +')'; + } + testCase.push(expected); + results.push(testCase); + } + }); + } + return unique(results); +} + +function buildInsetTests(unit1, unit2, type) { + var results = new Array(); + var convert = type == 'computed' ? true : false; + + if(Object.prototype.toString.call( unit1 ) === '[object Array]') { + unit1.forEach(function(unit) { + insetTests = buildInsetTests(unit, unit2, type); + results = results.concat(insetTests); + }); + } else { + validInsets.forEach(function(test) { + var testCase = [], name, actual, expected; + + name = setUnit(test[0], false, unit1, unit2) +' - '+ type; + actual = 'inset(' + setUnit(test[1], convert, unit1, unit2) +')'; + expected = actual; + + testCase.push(name); + testCase.push(actual); + testCase.push(expected); + + results.push(testCase); + }); + } + return unique(results); +} + +function buildPolygonTests(unitSet, type) { + var results = new Array(); + var convert = type == 'computed' ? true : false; + + unitSet.forEach(function(set) { + validPolygons.forEach(function(test) { + var testCase = []; + // name + testCase.push(setUnit(test[0], false, set[0], set[1], set[2]) +' - '+ type); + // actual + testCase.push('polygon(' + setUnit(test[1], false, set[0], set[1], set[2]) +')'); + // expected + testCase.push('polygon(' + setUnit(test[1], convert, set[0], set[1], set[2]) +')'); + results.push(testCase); + }); + }); + return unique(results); +} + +function buildCalcTests(testCases, type) { + var results = new Array(); + testCases.forEach(function(test){ + var testCase = []; + if(type == 'computed') { + testCase.push(test[0] + ' - computed style'); + testCase.push(test[0]); + testCase.push(test[2]); + } + else { + testCase.push(test[0] + ' - inline style'); + testCase.push(test[0]); + testCase.push(test[1]); + } + testCase.push(type); + results.push(testCase) + }); + return unique(results); +} + +function unique(tests) { + var list = tests.concat(); + for(var i = 0; i< list.length; ++i) { + for(var j = i+1; j < list.length; ++j) { + if(list[i][0] === list[j][0]) + list.splice(j--, 1); + } + } + return list; +} + +function setUnit(str, convert, unit1, unit2, unit3) { + var retStr = str; + if(typeof unit1 !== 'undefined') { + retStr = retStr.replace(new RegExp('u1', 'g'), unit1); + } + if(typeof unit2 !== 'undefined') { + retStr = retStr.replace(new RegExp("u2", 'g'), unit2); + } + if(typeof unit3 !== 'undefined') { + retStr = retStr.replace(new RegExp("u3", 'g'), unit3); + } + retStr = convert ? convertToPx(retStr) : retStr; + return retStr; +} + +function convertToPx(origValue) { + + var valuesToConvert = origValue.match(/[0-9]+(\.[0-9]+)?([a-z]{2,4}|%)/g); + if(!valuesToConvert) + return origValue; + + var retStr = origValue; + for(var i = 0; i < valuesToConvert.length; i++) { + var unit = valuesToConvert[i].match(/[a-z]{2,4}|%/).toString(); + var numberStr = valuesToConvert[i].match(/[0-9]+(\.[0-9]+)?/)[0]; + + var number = parseFloat(numberStr); + var convertedUnit = 'px'; + if( typeof number !== 'NaN' ) + { + if (unit == 'in') { + number = (96 * number); + } else if (unit == 'cm') { + number = (37.795275591 * number); + } else if (unit == 'mm') { + number = (3.779527559 * number); + } else if (unit == 'pt') { + number = (1.333333333333 * number); + } else if (unit == 'pc') { + number = (16 * number); + } else if (unit == 'em') { + number = (16 * number); + } else if (unit == 'ex') { + number = (7.1796875 * number); + } else if (unit == 'ch') { + number = (8 * number); + } else if (unit == 'rem') { + number = (16 * number); + } else if (unit == 'vw') { + number = ((.01 * window.innerWidth) * number); + } else if (unit == 'vh') { + number = ((.01 * window.innerHeight) * number); + } else if (unit == 'vmin') { + number = Math.min( (.01 * window.innerWidth), (.01 * window.innerHeight) ) * number; + } else if (unit == 'vmax') { + number = Math.max( (.01 * window.innerWidth), (.01 * window.innerHeight) ) * number; + } + else { + convertedUnit = unit; + } + number = Math.round(number * 1000) / 1000; + var find = valuesToConvert[i]; + var replace = number.toString() + convertedUnit; + retStr = retStr.replace(valuesToConvert[i], number.toString() + convertedUnit); + } + } + return retStr.replace(',,', ','); +} + +function roundResultStr(str) { + if(Object.prototype.toString.call( str ) !== '[object String]') + return str; + + var numbersToRound = str.match(/[0-9]+\.[0-9]+/g); + if(!numbersToRound) + return str; + + var retStr = str; + for(var i = 0; i < numbersToRound.length; i++) { + num = parseFloat(numbersToRound[i]); + if( !isNaN(num) ) { + roundedNum = Math.round(num*1000)/1000; + retStr = retStr.replace(numbersToRound[i].toString(), roundedNum.toString()); + } + } + + return retStr; +} + +function generateInsetRoundCases(units, testType) { + var convert = testType.indexOf('computed') != -1 ? true : false; + var testUnit = units; + var sizes = [ + '10' + units, + '20' + units, + '30' + units, + '40' + units + ]; + + function insetRound(value) { + return 'inset(10' +testUnit+ ' round ' + value + ')'; + } + + function serializedInsetRound(lhsValues, rhsValues, convert) { + var retStr = ''; + if(!rhsValues) + retStr = 'inset(10' +testUnit+ ' round ' + lhsValues +')'; + else + retStr = 'inset(10' +testUnit+ ' round ' + lhsValues +' / '+ rhsValues +')'; + + if(convert) + return convertToPx(retStr); + + return retStr; + } + + var results = [], left, lhs, right, rhs; + for (left = 1; left <= 4; left++) { + lhs = sizes.slice(0, left).join(' '); + results.push([insetRound(lhs) +' - '+ testType, insetRound(lhs), serializedInsetRound(lhs, null, convert)]); + for (right = 1; right <= 4; right++) { + rhs = sizes.slice(0, right).join(' '); + if(lhs == rhs) + results.push([insetRound(lhs + ' / ' + rhs) +' - '+ testType, insetRound(lhs + ' / ' + rhs), serializedInsetRound(lhs, null, convert)]); + else + results.push([insetRound(lhs + ' / ' + rhs) +' - '+ testType, insetRound(lhs + ' / ' + rhs), serializedInsetRound(lhs, rhs, convert)]); + } + } + return results; +} + +var validUnits = [ + "cm","mm","in","pt","pc", // Absolute length units (omitting px b/c we default to that in all tests) + "em","ex","ch","rem", // Font relative length units + "vw","vh","vmin","vmax" // Viewport percentage units + ] + +/// [actual, expected] +var validPositions = [ + +/// [ percent ], [ length ], [ percent | percent ], [ percent | length ], [ length | percent ], [ length | length ] + ["50%", "50% 50%"], + ["50u1", "50u1 50%"], + ["50% 50%", "50% 50%"], + ["50% 50u1", "50% 50u1"], + ["50u1 50%", "50u1 50%"], + ["50u1 50u1", "50u1 50u1"], + +///// [ keyword ], [ keyword keyword ] x 5 keywords + ["left", "0% 50%"], + ["top", "50% 0%"], + ["right", "100% 50%"], + ["bottom", "50% 100%"], + ["center", "50% 50%"], + + ["left top", "0% 0%"], + ["left bottom", "0% 100%"], + ["left center", "0% 50%"], + + ["top left", "0% 0%"], + ["top right", "100% 0%"], + ["top center", "50% 0%"], + + ["right top", "100% 0%"], + ["right bottom", "100% 100%"], + ["right center", "100% 50%"], + + ["bottom left", "0% 100%"], + ["bottom right", "100% 100%"], + ["bottom center", "50% 100%"], + + ["center top", "50% 0%"], + ["center left", "0% 50%"], + ["center right", "100% 50%"], + ["center bottom", "50% 100%"], + ["center center", "50% 50%"], + +////// [ keyword | percent ], [ keyword | length ], [ percent | keyword ], [ length | keyword ] x 5 keywords + ["left 50%", "0% 50%"], + ["left 50u1", "0% 50u1"], + + ["50% top", "50% 0%"], + ["50u1 top", "50u1 0%"], + + ["right 80%", "100% 80%"], + ["right 80u1", "100% 80u1"], + + ["70% bottom", "70% 100%"], + ["70u1 bottom", "70u1 100%"], + + ["center 60%", "50% 60%"], + ["center 60u1", "50% 60u1"], + ["60% center", "60% 50%"], + ["60u1 center", "60u1 50%"], + +////// [ keyword | keyword percent ], [ keyword | keyword length ] x 5 keywords + ["center top 50%", "50% 50%"], + ["center top 50u1", "50% 50u1"], + ["center left 50%", "50% 50%"], + ["center left 50u1", "50u1 50%"], + ["center right 70%", "30% 50%"], + ["center right 70u1", "right 70u1 top 50%"], + ["center bottom 70%", "50% 30%"], + ["center bottom 70u1", "left 50% bottom 70u1"], + + ["left top 50%", "0% 50%"], + ["left top 50u1", "0% 50u1"], + ["left bottom 70%", "0% 30%"], + ["left bottom 70u1", "left 0% bottom 70u1"], + + ["top left 50%", "50% 0%"], + ["top left 50u1", "50u1 0%"], + ["top right 70%", "30% 0%"], + ["top right 70u1", "right 70u1 top 0%"], + + ["bottom left 50%", "50% 100%"], + ["bottom left 50u1", "50u1 100%"], + ["bottom right 70%", "30% 100%"], + ["bottom right 70u1", "right 70u1 top 100%"], + + ["right bottom 70%", "100% 30%"], + ["right bottom 70u1", "left 100% bottom 70u1"], + ["right top 50%", "100% 50%"], + ["right top 50u1", "100% 50u1"], + +////// [ keyword percent | keyword], [ keyword length | keyword ] x 5 keywords + ["left 50% center", "50% 50%"], + ["left 50u1 center", "50u1 50%"], + ["left 50% top", "50% 0%"], + ["left 50u1 top", "50u1 0%"], + ["left 50% bottom", "50% 100%"], + ["left 50u1 bottom", "50u1 100%"], + + ["top 50% center", "50% 50%"], + ["top 50u1 center", "50% 50u1"], + ["top 50% left", "0% 50%"], + ["top 50u1 left", "0% 50u1"], + ["top 50% right", "100% 50%"], + ["top 50u1 right", "100% 50u1"], + + ["bottom 70% center", "50% 30%"], + ["bottom 70u1 center", "left 50% bottom 70u1"], + ["bottom 70% left", "0% 30%"], + ["bottom 70u1 left", "left 0% bottom 70u1"], + ["bottom 70% right", "100% 30%"], + ["bottom 70u1 right", "left 100% bottom 70u1"], + + ["right 80% center", "20% 50%"], + ["right 80u1 center", "right 80u1 top 50%"], + ["right 80% bottom", "20% 100%"], + ["right 80u1 bottom", "right 80u1 top 100%"], + ["right 80% top", "20% 0%"], + ["right 80u1 top", "right 80u1 top 0%"], + +////// [ keyword percent | keyword percent], [ keyword percent | keyword length], +////// [ keyword length | keyword length], [ keyword length | keyword percent] x 5 keywords + ["left 50% top 50%", "50% 50%"], + ["left 50% top 50u1", "50% 50u1"], + ["left 50% bottom 70%", "50% 30%"], + ["left 50% bottom 70u1", "left 50% bottom 70u1"], + ["left 50u1 top 50%", "50u1 50%"], + ["left 50u1 top 50u1", "50u1 50u1"], + ["left 50u1 bottom 70%", "50u1 30%"], + ["left 50u1 bottom 70u1", "left 50u1 bottom 70u1"], + + ["top 50% left 50%", "50% 50%"], + ["top 50% left 50u1", "50u1 50%"], + ["top 50% right 80%", "20% 50%"], + ["top 50% right 80u1", "right 80u1 top 50%"], + ["top 50u1 left 50%", "50% 50u1"], + ["top 50u1 left 50u1", "50u1 50u1"], + ["top 50u1 right 80%", "20% 50u1"], + ["top 50u1 right 80u1", "right 80u1 top 50u1"], + + ["bottom 70% left 50%", "50% 30%"], + ["bottom 70% left 50u1", "50u1 30%"], + ["bottom 70% right 80%", "20% 30%"], + ["bottom 70% right 80u1", "right 80u1 top 30%"], + ["bottom 70u1 left 50%", "left 50% bottom 70u1"], + ["bottom 70u1 left 50u1", "left 50u1 bottom 70u1"], + ["bottom 70u1 right 80%", "left 20% bottom 70u1"], + ["bottom 70u1 right 80u1", "right 80u1 bottom 70u1"], + + ["right 80% top 50%", "20% 50%"], + ["right 80% top 50u1", "20% 50u1"], + ["right 80% bottom 70%", "20% 30%"], + ["right 80% bottom 70u1", "left 20% bottom 70u1"], + ["right 80u1 top 50%", "right 80u1 top 50%"], + ["right 80u1 top 50u1", "right 80u1 top 50u1"], + ["right 80u1 bottom 70%", "right 80u1 top 30%"], + ["right 80u1 bottom 70u1", "right 80u1 bottom 70u1"], +]; + +var invalidPositions = [ +////// [ keyword | percent ], [ keyword | length ], [ percent | keyword ], [ length | keyword ] x 5 keywords + "50% left", + "50px left", + "top 50%", + "80% right", + "80px right", + "bottom 70%", + "bottom 70px", + +////// [ keyword | keyword percent ], [ keyword | keyword length ] x 5 keywords + "center center 60%", + "center center 60px", + + "left center 60%", + "left center 60px", + "left right 80%", + "left right 80px", + "left left 50%", + "left left 50px", + + "top center 60%", + "top center 60px", + "top bottom 80%", + "top bottom 80px", + "top top 50%", + "top top 50px", + + "bottom center 60%", + "bottom center 60px", + "bottom top 50%", + "bottom top 50px", + "bottom bottom 50%", + "bottom bottom 50px", + + "right center 60%", + "right center 60px", + "right left 50%", + "right left 50px", + "right right 70%", + "right right 70px", + +////// [ keyword percent | keyword], [ keyword length | keyword ] x 5 keywords + "center 60% top", + "center 60px top", + "center 60% bottom", + "center 60px bottom", + "center 60% left", + "center 60px left", + "center 60% right", + "center 60px right", + "center 60% center", + "center 60px center", + + "left 50% right", + "left 50px right", + "left 50% left", + "left 50px left", + + "top 50% bottom", + "top 50px bottom", + "top 50% top", + "top 50px top", + + "bottom 70% top", + "bottom 70px top", + "bottom 70% bottom", + "bottom 70px bottom", + + "right 80% left", + "right 80px left", + +////// [ keyword percent | keyword percent], [ keyword percent | keyword length], +////// [ keyword length | keyword length], [ keyword length | keyword percent] x 5 keywords + "center 60% top 50%", + "center 60% top 50px", + "center 60% bottom 70%", + "center 60% bottom 70px", + "center 60% left 50%", + "center 60% left 50px", + "center 60% right 70%", + "center 60% right 70px", + "center 60% center 65%", + "center 60% center 65px", + "center 60px top 50%", + "center 60px top 50px", + "center 60px bottom 70%", + "center 60px bottom 70px", + "center 60px left 50%", + "center 60px left 50px", + "center 60px right 70%", + "center 60px right 70px", + "center 60px center 65%", + "center 60px center 65px", + + "left 50% center 60%", + "left 50% center 60px", + "left 50% right 80%", + "left 50% right 80px", + "left 50% left 50%", + "left 50% left 50px", + "left 50px center 60%", + "left 50px center 60px", + "left 50px right 80%", + "left 50px right 80px", + "left 50px left 50%", + "left 50px left 50px", + + "top 50% center 60%", + "top 50% center 60px", + "top 50% bottom 50%", + "top 50% bottom 50px", + "top 50% top 50%", + "top 50% top 50px", + "top 50px center 60%", + "top 50px center 60px", + "top 50px bottom 70%", + "top 50px bottom 70px", + "top 50px top 50%", + "top 50px top 50px", + + "bottom 70% center 60%", + "bottom 70% center 60px", + "bottom 70% top 50%", + "bottom 70% top 50px", + "bottom 70% bottom 50%", + "bottom 70% bottom 50px", + "bottom 70px center 60%", + "bottom 70px center 60px", + "bottom 70px top 50%", + "bottom 70px top 50px", + "bottom 70px bottom 50%", + "bottom 70px bottom 50px", + + "right 80% center 60%", + "right 80% center 60px", + "right 80% left 50%", + "right 80% left 50px", + "right 80% right 85%", + "right 80% right 85px", + "right 80px center 60%", + "right 80px center 60px", + "right 80px left 50%", + "right 80px left 50px", + "right 80px right 85%", + "right 80px right 85px" +]; + +// valid radii values for circle + ellipse +// [value, expected_inline, [expected_computed?]] +var validCircleRadii = [ + ['', 'at 50% 50%', 'at 50% 50%'], + ['50u1', '50u1 at 50% 50%'], + ['50%', '50% at 50% 50%'], + ['closest-side', 'at 50% 50%'], + ['farthest-side', 'farthest-side at 50% 50%'] +] +var validEllipseRadii = [ + ['', 'at 50% 50%', 'at 50% 50%'], + ['50u1', '50u1 at 50% 50%', '50u1 at 50% 50%'], + ['50%', '50% at 50% 50%', '50% at 50% 50%'], + ['closest-side', 'at 50% 50%', 'at 50% 50%'], + ['farthest-side', 'farthest-side at 50% 50%', 'farthest-side at 50% 50%'], + ['50u1 100u1', '50u1 100u1 at 50% 50%'], + ['100u1 100px', '100u1 100px at 50% 50%'], + ['25% 50%', '25% 50% at 50% 50%'], + ['50u1 25%', '50u1 25% at 50% 50%'], + ['25% 50u1', '25% 50u1 at 50% 50%'], + ['25% closest-side', '25% at 50% 50%'], + ['25u1 closest-side', '25u1 at 50% 50%'], + ['closest-side 75%', 'closest-side 75% at 50% 50%'], + ['closest-side 75u1', 'closest-side 75u1 at 50% 50%'], + ['25% farthest-side', '25% farthest-side at 50% 50%'], + ['25u1 farthest-side', '25u1 farthest-side at 50% 50%'], + ['farthest-side 75%', 'farthest-side 75% at 50% 50%'], + ['farthest-side 75u1', 'farthest-side 75u1 at 50% 50%'], + ['closest-side closest-side', 'at 50% 50%'], + ['farthest-side farthest-side', 'farthest-side farthest-side at 50% 50%'], + ['closest-side farthest-side', 'closest-side farthest-side at 50% 50%'], + ['farthest-side closest-side', 'farthest-side at 50% 50%'] +] + +var validInsets = [ + ["One arg - u1", "10u1"], + ["One arg - u2", "10u2"], + ["Two args - u1 u1", "10u1 20u1"], + ["Two args - u1 u2", "10u1 20u2"], + ["Two args - u2 u1", "10u2 20u1"], + ["Two args - u2 u2", "10u2 20u2"], + ["Three args - u1 u1 u1", "10u1 20u1 30u1"], + ["Three args - u1 u1 u2", "10u1 20u1 30u2"], + ["Three args - u1 u2 u1", "10u1 20u2 30u1"], + ["Three args - u1 u2 u2 ", "10u1 20u2 30u2"], + ["Three args - u2 u1 u1", "10u2 20u1 30u1"], + ["Three args - u2 u1 u2 ", "10u2 20u1 30u2"], + ["Three args - u2 u2 u1 ", "10u2 20u2 30u1"], + ["Three args - u2 u2 u2 ","10u2 20u2 30u2"], + ["Four args - u1 u1 u1 u1", "10u1 20u1 30u1 40u1"], + ["Four args - u1 u1 u1 u2", "10u1 20u1 30u1 40u2"], + ["Four args - u1 u1 u2 u1", "10u1 20u1 30u2 40u1"], + ["Four args - u1 u1 u2 u2", "10u1 20u1 30u2 40u2"], + ["Four args - u1 u2 u1 u1", "10u1 20u2 30u1 40u1"], + ["Four args - u1 u2 u1 u2", "10u1 20u2 30u1 40u2"], + ["Four args - u1 u2 u2 u1", "10u1 20u2 30u2 40u1"], + ["Four args - u1 u2 u2 u2", "10u1 20u2 30u2 40u2"], + ["Four args - u2 u1 u1 u1", "10u2 20u1 30u1 40u1"], + ["Four args - u2 u1 u1 u2", "10u2 20u1 30u1 40u2"], + ["Four args - u2 u1 u2 u1", "10u2 20u1 30u2 40u1"], + ["Four args - u2 u1 u2 u2", "10u2 20u1 30u2 40u2"], + ["Four args - u2 u2 u1 u1", "10u2 20u2 30u1 40u1"], + ["Four args - u2 u2 u1 u2", "10u2 20u2 30u1 40u2"], + ["Four args - u2 u2 u2 u1", "10u2 20u2 30u2 40u1"], + ["Four args - u2 u2 u2 u2", "10u2 20u2 30u2 40u2"] +] + +var validPolygons = [ + ["One vertex - u1 u1", "10u1 20u1"], + ["One vertex - u1 u2", "10u1 20u2"], + ["Two vertices - u1 u1, u1 u1", "10u1 20u1, 30u1 40u1"], + ["Two vertices - u1 u1, u2 u2", "10u1 20u1, 30u2 40u2"], + ["Two vertices - u2 u2, u1 u1", "10u2 20u2, 30u1 40u1"], + ["Two vertices - u1 u2, u2 u1", "10u1 20u2, 30u2 40u1"], + ["Three vertices - u1 u1, u1 u1, u1 u1", "10u1 20u1, 30u1 40u1, 50u1 60u1"], + ["Three vertices - u2 u2, u2 u2, u2 u2", "10u2 20u2, 30u2 40u2, 50u2 60u2"], + ["Three vertices - u3 u3, u3 u3, u3 u3", "10u3 20u3, 30u3 40u3, 50u3 60u3"], + ["Three vertices - u1 u1, u2 u2, u3 u3", "10u1 20u1, 30u2 40u2, 50u3 60u3"], + ["Three vertices - u3 u3, u1, u1, u2 u2", "10u3 20u3, 30u1 40u1, 50u2 60u2"], +] + +// [test value, expected property value, expected computed style] +var calcTestValues = [ + ["calc(10in)", "calc(10in)", "960px"], + ["calc(10in + 20px)", "calc(980px)", "980px"], + ["calc(30%)", "calc(30%)", "30%"], + ["calc(100%/4)", "calc(25%)", "25%"], + ["calc(25%*3)", "calc(75%)", "75%"], + // These following two test cases represent an either/or situation in the spec + // computed value is always supposed to be, at most, a tuple of a length and a percentage. + // the computed value of a โ€˜calc()โ€™ expression can be represented as either a number or a tuple + // of a dimension and a percentage. + // http://www.w3.org/TR/css3-values/#calc-notation + ["calc(25%*3 - 10in)", "calc(75% - 10in)", ["calc(75% - 960px)", "calc(-960px + 75%)"]], + ["calc((12.5%*6 + 10in) / 4)", "calc((75% + 10in) / 4)", ["calc((75% + 960px) / 4)", "calc(240px + 18.75%)"]] +] + +return { + testInlineStyle: testInlineStyle, + testComputedStyle: testComputedStyle, + testShapeMarginInlineStyle: testShapeMarginInlineStyle, + testShapeMarginComputedStyle: testShapeMarginComputedStyle, + testShapeThresholdInlineStyle: testShapeThresholdInlineStyle, + testShapeThresholdComputedStyle: testShapeThresholdComputedStyle, + buildTestCases: buildTestCases, + buildRadiiTests: buildRadiiTests, + buildPositionTests: buildPositionTests, + buildInsetTests: buildInsetTests, + buildPolygonTests: buildPolygonTests, + generateInsetRoundCases: generateInsetRoundCases, + buildCalcTests: buildCalcTests, + validUnits: validUnits, + calcTestValues: calcTestValues, + roundResultStr: roundResultStr +} +})(); diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/pattern-gg-gr.png b/tests/wpt/css-tests/css-values-3_dev/html/support/pattern-gg-gr.png new file mode 100644 index 0000000000000000000000000000000000000000..091de70bb72541dda90cafaa4a2eb68d82fb5bdb GIT binary patch literal 203 zcmeAS@N?(olHy`uVBq!ia0vp^8X(NU1SFZ~=vx6P#^NA%Cx&(BWL^R}oCO|{#S9F5 zM?jcysy3fAP>{XE)7O>#4zs*CpV-thX~%&=k|nMYCC>S|xv6<249-QVi6yBi3gww4 z84B*6z5(HleBwYw7M?DSArXh)UO33fpdi3}P(!S4ZZ<c&U5&+WerCy)HkoP(1`<4M m%?I}%c%8QA^i?RYmoGe?DKLBT?xjF87(8A5T-G@yGywqU{5T8% literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/pattern-grg-rgr-grg.png b/tests/wpt/css-tests/css-values-3_dev/html/support/pattern-grg-rgr-grg.png new file mode 100644 index 0000000000000000000000000000000000000000..6fcfeb4883edea810f880fabb861e09df7871695 GIT binary patch literal 222 zcmV<403rX0P)<h;3K|Lk000e1NJLTq001fg001fo0ssI3J*IA&0001`Nkl<Zc-rli z!4iWo2t*%#Ie$(sX|)yGI5;(q%PA9Jmkl8?93ULP9AIK)7R>(GjOxRBMQwxx1mJBk z?aXifhV@+AVlyc!*ZYwgelQCuviAYh+_OT<gcQNg6t-;4S{PYlcfkL&YW~~R`(A2{ zSbtgn)%$nx`tP29_xaQNq4OWFf2l=xr1`(fKl$`TFZx42zT!BA22b>&*N-Q9(T_&| Y0MVE_0ae*F0000007*qoM6N<$f~59g2LJ#7 literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/pattern-grg-rrg-rgg.png b/tests/wpt/css-tests/css-values-3_dev/html/support/pattern-grg-rrg-rgg.png new file mode 100644 index 0000000000000000000000000000000000000000..fcf4f3fd7d95431b8cd1bc5f5129fcb724c5e40f GIT binary patch literal 231 zcmeAS@N?(olHy`uVBq!ia0vp^x**KK#K6FKsNOXi$XVy<;uunK>uuO>p#}vW?s@X} z?5{Vn@(E1fdg>#_p5-zBiX+1VA%+4b26mx2|7={&ovNQ>6SXtcysBl-)c><WmS!Y( zv7BNEzPH=%x{1!KjWd@lmbz(awP;VviDQ{7SW3K#guH|K-#!i8$dVG=UlQ?2Ho)uu z>9DyExiv#HMbsD$XX>p~Q&Z4f6DV?h!MD37E_}{<nz@wk)ekYNY^%>svR6Ky{&{h` fDhG(UQO-Q~pMsNotNvM_%Naaf{an^LB{Ts5h3Hy_ literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/pattern-rgr-grg-rgr.png b/tests/wpt/css-tests/css-values-3_dev/html/support/pattern-rgr-grg-rgr.png new file mode 100644 index 0000000000000000000000000000000000000000..db8ed5cf7bd1837d4810f2885309f8413c6c77d5 GIT binary patch literal 222 zcmV<403rX0P)<h;3K|Lk000e1NJLTq001fg001fo0ssI3J*IA&0001`Nkl<Zc-rli z%Myby2t^NmIe$(!ZH+By>?EUcysXRv&Lsq60f0F`IKaY}8O6F)ckPNrKmh*ySgNcF zsO2B!z+X<jPG+J~4Ii%NgDF80`5mJXpl^B2u+(g0*rz5I>8xiL(f<$Mv|j(s)%z{g zX4K!E|JCbvas7AqzkC1b|Dp4ruYT+<YHHy}$v^q@gcpA3!`InPrp6Oqc)fVS3qKqF Y0cy8C_Kbk@N&o-=07*qoM6N<$g27Q_GXMYp literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/pattern-tr.png b/tests/wpt/css-tests/css-values-3_dev/html/support/pattern-tr.png new file mode 100644 index 0000000000000000000000000000000000000000..8b4b25364e0ffbe09e563e13b567fa57330e48d5 GIT binary patch literal 137 zcmeAS@N?(olHy`uVBq!ia0vp^azM<_!N$PA*s|9jBoW~0;uunKD><d1=|2z8e@O`m zi5U_X7?eM1T?jqI(8f2(=fLXOHJ)xxeNNw5J?)fkN19wc<FT&3eZzeBMQLtcCc<9q mCdFSHSg)@*x>)QnGsEKzd}=q=PizO8&EV<k=d#Wzp$Pzi&n><H literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/properties.js b/tests/wpt/css-tests/css-values-3_dev/html/support/properties.js new file mode 100644 index 00000000000..ddecfb6e336 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/support/properties.js @@ -0,0 +1,449 @@ +(function(root){ + +/* + * General Value Types definition + * they return an object of arrays of type { <name>: [<start-value>, <end-value>], ... } + */ +var values = { + 'length' : function() { + // http://www.w3.org/TR/css3-values/#lengths + return { + // CSS Values and Module Level 3 + // ch: ['1ch', '10ch'], + // rem: ['1rem', '10rem'], + // vw: ['1vw', '10vw'], + // vh: ['1vh', '10vh'], + // vmin: ['1vmin', '10vmin'], + // vmax: ['1vmax', '10vmax'], + // CSS Values and Module Level 2 + pt: ['1pt', '10pt'], + pc: ['1pc', '10pc'], + px: ['1px', '10px'], + // CSS Values and Module Level 1 + em: ['1em', '10em'], + ex: ['1ex', '10ex'], + mm: ['1mm', '10mm'], + cm: ['1cm', '10cm'], + 'in': ['1in', '10in'] + }; + }, + 'length-em': function() { + return { + em: ['1.1em', '1.5em'] + }; + }, + 'percentage': function() { + // http://www.w3.org/TR/css3-values/#percentages + return { + '%': ['33%', '80%'] + }; + }, + 'color': function() { + // http://www.w3.org/TR/css3-values/#colors + // http://www.w3.org/TR/css3-color/ + return { + rgba: ['rgba(100,100,100,1)', 'rgba(10,10,10,0.4)'] + }; + }, + 'rectangle': function() { + // http://www.w3.org/TR/CSS2/visufx.html#value-def-shape + return { + rectangle: ['rect(10px,10px,10px,10px)', 'rect(15px,15px,5px,5px)'] + }; + }, + 'font-weight': function() { + // http://www.w3.org/TR/css3-fonts/#font-weight-prop + return { + keyword: ["normal", "bold"], + numeric: ["100", "900"] + }; + }, + 'number': function() { + // http://www.w3.org/TR/css3-values/#number + return { + integer: ["1", "10"], + decimal: ["1.1", "9.55"] + }; + }, + 'number[0,1]': function() { + // http://www.w3.org/TR/css3-values/#number + // applies to [0,1]-ranged properties like opacity + return { + "zero-to-one": ["0.2", "0.9"] + }; + }, + 'integer': function() { + // http://www.w3.org/TR/css3-values/#integer + return { + integer: ["1", "10"] + }; + }, + 'shadow': function() { + // http://www.w3.org/TR/css-text-decor-3/#text-shadow-property + return { + shadow: ['rgba(0,0,0,0.1) 5px 6px 7px', 'rgba(10,10,10,0.9) 5px 6px 7px'] + }; + }, + 'visibility': function() { + // http://www.w3.org/TR/CSS2/visufx.html#visibility + return { + keyword: ['visible', 'hidden', {discrete: true}] + }; + }, + 'auto': function(property) { + var types = properties[property] || unspecified_properties[property]; + var val = values[types[0]](property); + var key = Object.keys(val).shift(); + return { + to: [val[key][1], 'auto'], + from: ['auto', val[key][1]] + }; + }, + // types reqired for non-specified properties + 'border-radius': function() { + return { + px: ['1px', '10px'], + "px-px": ['1px 3px', '10px 13px'] + }; + }, + 'image' : function() { + var prefix = getValueVendorPrefix('background-image', 'linear-gradient(top, hsl(0, 80%, 70%), #bada55)'); + return { + // Chrome implements this + url: ['url(support/one.gif)', 'url(support/two.gif)'], + data: ['url(data:image/gif;base64,R0lGODlhAQABAAD/ACwAAAAAAQABAAACADs=)', 'url(data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///ywAAAAAAQABAAACAUwAOw==)'], + // A hunch, as from the spec: + // http://www.w3.org/TR/css3-transitions/#animatable-types + // gradient: interpolated via the positions and colors of each stop. They must have the same type (radial or linear) and same number of stops in order to be animated. Note: [CSS3-IMAGES] may extend this definition. + gradient: [prefix + 'linear-gradient(top, hsl(0, 80%, 70%), #bada55)', prefix + 'linear-gradient(top, #bada55, hsl(0, 80%, 70%))'] + }; + }, + 'background-size': function() { + return { + keyword: ['cover', 'contain'] + }; + }, + 'box-shadow': function() { + // http://www.w3.org/TR/css3-background/#ltshadowgt + return { + shadow: ['60px -16px teal', '60px -16px red'] + }; + }, + 'vertical': function() { + return { + keyword: ['top', 'bottom'] + }; + }, + 'horizontal': function() { + return { + keyword: ['left', 'right'] + }; + }, + 'font-stretch': function() { + return { + keyword: ['condensed', 'expanded'] + }; + }, + 'transform': function() { + return { + rotate: ['rotate(10deg)', 'rotate(20deg)'] + }; + }, + 'position': function() { + return { + 'static to absolute': ['static', 'absolute', {discrete: true}], + 'relative to absolute': ['relative', 'absolute', {discrete: true}], + 'absolute to fixed': ['absolute', 'fixed', {discrete: true}] + }; + }, + 'display': function() { + return { + 'static to absolute': ['none', 'block', {discrete: true}], + 'block to inline-block': ['block', 'inline-block', {discrete: true}] + }; + } +}; + +/* + * Property to Type table + * (as stated in specification) + */ +var properties = { + 'background-color': ['color'], + 'background-position': ['length', 'percentage'], + + 'border-top-width': ['length'], + 'border-right-width': ['length'], + 'border-bottom-width': ['length'], + 'border-left-width': ['length'], + + 'border-top-color': ['color'], + 'border-right-color': ['color'], + 'border-bottom-color': ['color'], + 'border-left-color': ['color'], + + 'padding-bottom': ['length'], + 'padding-left': ['length'], + 'padding-right': ['length'], + 'padding-top': ['length'], + + 'margin-bottom': ['length'], + 'margin-left': ['length'], + 'margin-right': ['length'], + 'margin-top': ['length'], + + 'height': ['length', 'percentage'], + 'width': ['length', 'percentage'], + 'min-height': ['length', 'percentage'], + 'min-width': ['length', 'percentage'], + 'max-height': ['length', 'percentage'], + 'max-width': ['length', 'percentage'], + + 'top': ['length', 'percentage'], + 'right': ['length', 'percentage'], + 'bottom': ['length', 'percentage'], + 'left': ['length', 'percentage'], + + 'color': ['color'], + 'font-size': ['length', 'percentage'], + 'font-weight': ['font-weight'], + 'line-height': ['number', 'length', 'percentage'], + 'letter-spacing': ['length'], + // Note: percentage is Level3 and not implemented anywhere yet + // https://drafts.csswg.org/css3-text/#word-spacing + 'word-spacing': ['length', 'percentage'], + 'text-indent': ['length', 'percentage'], + 'text-shadow': ['shadow'], + + 'outline-color': ['color'], + // outline-offset <integer> used to be an error in the spec + 'outline-offset': ['length'], + 'outline-width': ['length'], + + 'clip': ['rectangle'], + // Note: doesn't seem implemented anywhere + 'crop': ['rectangle'], + + 'vertical-align': ['length', 'percentage'], + 'opacity': ['number[0,1]'], + 'visibility': ['visibility'], + 'z-index': ['integer'] +}; + +/* + * Property to auto-value mapping + * (lazily taken from http://www.siliconbaytraining.com/pages/csspv.html) + */ +var properties_auto = [ + 'margin-top', + 'margin-right', + 'margin-bottom', + 'margin-left', + 'height', + 'width', + 'clip', + 'marker-offset', + 'top', + 'right', + 'left', + 'bottom', + 'z-index' +]; + +/* + * Property to Type table + * (missing value-types of specified properties) + */ +var missing_properties = { + 'margin-bottom': ['percentage'], + 'margin-left': ['percentage'], + 'margin-right': ['percentage'], + 'margin-top': ['percentage'], + 'padding-bottom': ['percentage'], + 'padding-left': ['percentage'], + 'padding-right': ['percentage'], + 'padding-top': ['percentage'], + 'vertical-align': ['vertical'] +}; + +/* + * Property to Type table + * (properties that haven't been specified but implemented) + */ +var unspecified_properties = { + // http://oli.jp/2010/css-animatable-properties/ + 'border-top-left-radius': ['border-radius'], + 'border-top-right-radius': ['border-radius'], + 'border-bottom-left-radius': ['border-radius'], + 'border-bottom-right-radius': ['border-radius'], + 'background-image': ['image'], + 'background-size': ['background-size'], + // https://drafts.csswg.org/css3-background/#the-box-shadow + // Animatable: yes, except between inner and outer shadows (Transition to/from an absent shadow is a transition to/from โ€˜0 0 transparentโ€™ or โ€˜0 0 transparent insetโ€™, as appropriate.) + 'box-shadow': ['box-shadow'], + 'font-size-adjust': ['number'], + 'font-stretch': ['font-stretch'], + 'marker-offset': ['length'], + 'text-decoration-color': ['color'], + 'column-count': ['integer'], + 'column-gap': ['length'], + 'column-rule-color': ['color'], + 'column-rule-width': ['length'], + 'column-width': ['length'], + 'transform': ['transform'], + 'transform-origin': ['horizontal'], + 'zoom': ['number'], + 'outline-radius-topleft': ['length', 'percentage'], + 'outline-radius-topright': ['length', 'percentage'], + 'outline-radius-bottomright': ['length', 'percentage'], + 'outline-radius-bottomleft': ['length', 'percentage'], + 'display': ['display'], + 'position': ['position'] +}; + +/* + * additional styles required to actually render + * (different browsers expect different environment) + */ +var additional_styles = { + // all browsers + 'border-top-width': {'border-top-style' : 'solid'}, + 'border-right-width': {'border-right-style' : 'solid'}, + 'border-bottom-width': {'border-bottom-style' : 'solid'}, + 'border-left-width': {'border-left-style' : 'solid'}, + 'top': {'position': 'absolute'}, + 'right': {'position': 'absolute'}, + 'bottom': {'position': 'absolute'}, + 'left': {'position': 'absolute'}, + 'z-index': {'position': 'absolute'}, + 'outline-offset': {'outline-style': 'solid'}, + 'outline-width': {'outline-style': 'solid'}, + 'word-spacing': {'width': '100px', 'height': '100px'}, + // unspecified properties + 'column-rule-width': {'column-rule-style': 'solid'}, + 'position': {'width': '50px', 'height': '50px', top: '10px', left: '50px'} +}; + +/* + * additional styles required *on the parent* to actually render + * (different browsers expect different environment) + */ +var parent_styles = { + 'border-top-width': {'border-top-style' : 'solid'}, + 'border-right-width': {'border-right-style' : 'solid'}, + 'border-bottom-width': {'border-bottom-style' : 'solid'}, + 'border-left-width': {'border-left-style' : 'solid'}, + 'height': {'width': '100px', 'height': '100px'}, + 'min-height': {'width': '100px', 'height': '100px'}, + 'max-height': {'width': '100px', 'height': '100px'}, + 'width': {'width': '100px', 'height': '100px'}, + 'min-width': {'width': '100px', 'height': '100px'}, + 'max-width': {'width': '100px', 'height': '100px'}, + // unspecified properties + 'position': {'position': 'relative', 'width': '100px', 'height': '100px'}, + // inheritance tests + 'top': {'width': '100px', 'height': '100px', 'position': 'relative'}, + 'right': {'width': '100px', 'height': '100px', 'position': 'relative'}, + 'bottom': {'width': '100px', 'height': '100px', 'position': 'relative'}, + 'left': {'width': '100px', 'height': '100px', 'position': 'relative'} +}; + + +function assemble(props) { + var tests = []; + + // assemble tests + for (var property in props) { + props[property].forEach(function(type) { + var _values = values[type](property); + Object.keys(_values).forEach(function(unit) { + var data = { + name: property + ' ' + type + '(' + unit + ')', + property: property, + valueType : type, + unit : unit, + parentStyle: extend({}, parent_styles[property] || {}), + from: extend({}, additional_styles[property] || {}), + to: {} + }; + + data.from[property] = _values[unit][0]; + data.to[property] = _values[unit][1]; + data.flags = _values[unit][2] || {}; + + tests.push(data); + }); + }); + } + + return tests; +} + +root.getPropertyTests = function() { + return assemble(properties); +}; + +root.getMissingPropertyTests = function() { + return assemble(missing_properties); +}; + +root.getUnspecifiedPropertyTests = function() { + return assemble(unspecified_properties); +}; + +root.getFontSizeRelativePropertyTests = function() { + var accepted = {}; + + for (var key in properties) { + if (!Object.prototype.hasOwnProperty.call(properties, key) || key === "font-size") { + continue; + } + + if (properties[key].indexOf('length') > -1) { + accepted[key] = ['length-em']; + } + } + + return assemble(accepted); +}; + +root.getAutoPropertyTests = function() { + var accepted = {}; + + for (var i = 0, key; key = properties_auto[i]; i++) { + accepted[key] = ['auto']; + } + + return assemble(accepted); +}; + +root.filterPropertyTests = function(tests, names) { + var allowed = {}; + var accepted = []; + + if (typeof names === "string") { + names = [names]; + } + + if (!(names instanceof RegExp)) { + names.forEach(function(name) { + allowed[name] = true; + }); + } + + tests.forEach(function(test) { + if (names instanceof RegExp) { + if (!test.name.match(names)) { + return; + } + } else if (!allowed[test.name]) { + return; + } + + accepted.push(test); + }); + + return accepted; +}; + +})(window); \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/red20x20.png b/tests/wpt/css-tests/css-values-3_dev/html/support/red20x20.png new file mode 100644 index 0000000000000000000000000000000000000000..5d44ef210e1132a7de6c5442ee47d3a220dfc2ab GIT binary patch literal 160 zcmeAS@N?(olHy`uVBq!ia0vp^A|TAc1SFYWcSQjy&H|6fVg?3oVGw3ym^DWND9B#o z>FdgV7pRU^Vw#v22T(||#5JPCIX^cyHLrxhxhOTUBsE2$JhLQ2!QIn0AiR-J9H>aj y)5S5w;&k$#^A2_iNfK9WR#k?4Uh$0aDi4Fw97c5^KZPQoDh5wiKbLh*2~7YTawj1G literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/region-in-body.html b/tests/wpt/css-tests/css-values-3_dev/html/support/region-in-body.html new file mode 100644 index 00000000000..78038fd28ff --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/support/region-in-body.html @@ -0,0 +1,36 @@ +<!DOCTYPE html> +<html lang="en"><head> + <meta charset="UTF-8"> + <title>One region in body</title> + <style> + html, body { + margin: 0; + padding: 0; + } + #container { + background: red; + } + #content { + flow-into: flow; + font-family: Ahem; + font-size: 20px; + line-height: 1em; + color: green; + } + #region { + flow-from: flow; + } + </style> + <script src="util.js" type="text/javascript"></script> +</head> +<body> + <div id="container"> + <!-- The &#8203; entity is a zerowidth space. It enables me to create nicely reflowing rectangles of Ahem text --> + <div id="content"> + xxxx&#x200B;xxxx&#x200B;xxxx&#x200B;xxxx + </div> + </div> + <div id="region"> + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/region-in-container.html b/tests/wpt/css-tests/css-values-3_dev/html/support/region-in-container.html new file mode 100644 index 00000000000..219fce6503c --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/support/region-in-container.html @@ -0,0 +1,38 @@ +<!DOCTYPE html> +<html lang="en"><head> + <meta charset="UTF-8"> + <title>One region in body</title> + <style> + html, body { + margin: 0; + padding: 0; + } + #container { + background: red; + } + #content { + flow-into: flow; + font-family: Ahem; + font-size: 20px; + line-height: 1em; + color: green; + } + #region { + flow-from: flow; + } + </style> +</head> +<body> + <div id="container"> + <!-- The &#8203; entity is a zerowidth space. It enables me to create nicely reflowing rectangles of Ahem text --> + <div id="content"> + xxxx&#x200B;xxxx&#x200B;xxxx&#x200B;xxxx + </div> + </div> + <div id="region-parent"> + <div id="region"> + </div> + </div> + <script src="util.js" type="text/javascript"></script> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/ruler-h-50%.png b/tests/wpt/css-tests/css-values-3_dev/html/support/ruler-h-50%.png new file mode 100644 index 0000000000000000000000000000000000000000..cf2eea6b438a11503a89414cbb2f9f1fde55df0c GIT binary patch literal 691 zcmV;k0!;mhP)<h;3K|Lk000e1NJLTq0077U001%w0ssI3;WRTK0007dNkl<Zc-rlq zy{h6s7=~wbiC|&k#KzV}uoP2RSPBY)sHIn;ot@^CYHeD*0k6SU@&o=<wt~SzQP6LT z+1+9bIY?G>_PkGJCLw%0c_-t<Byu8R0TE%rfqnf#2=STCc!0-|BNJiWm+$+t+3XF+ zG01&|R6WZ2a%FMO8DoZFSe6xdSs{%)dLqg~Sttu-y|XONIp^Fk491wQ>y1Vu;JWBp zVzJoqc$A+V$Du&M;PW30)i^&u7Gwd)f-J~_EXabafA}Ss^LRYITrL@7hr_}5ea4uo zs-EXfr_-?8qSw;z_hYfxZnq<%d_G?&6l8n7UMHeNA~7D1DXd_+^X%M^b1Xhu#0egw zA!I?;mp#FUr6!IGxafwE1t1HuAPce}3$g%YK^9~|*6&HOysvn(*(i##-EJ9UsZ`3c zEZerjZtKO@{G-umsZ=7OWHL!ax~|LH&Qw+HcDr($*H`sP-cZ*0d?q4I(}+k2AsaiL zj;3j@>xNm@j~53yo6Tl2nfZLaSS%Dp@jOqqx7+P>I$bK2_WONkdm(-b!)ORuq3(u{ zuZ3eR);?H^UI=h{2M87b0ALRNMpGQFFcbm=3m{kkAXosw0tglW2o^xF0D=Vof&~yP zfM5aey@Mqmboq;Vy>6Q3^?Ef;v)OFQ#$+;S+qUC4@()R>)vA0j20RIU1AN~f3<kMe zPA*0wk^B8lM7P^58jZ@v;czH~5JH%ySu7Suqmd9o*Y(L{67t7~@KDnmXti3a)#`LQ z^?JQ>xhxxNwc21XxLhtDA0P5nd4E{1*Of{|zC6!y9M^SKRYkDydOv{gSOCES0Ko#G Z;3u}YJM}AuyWao+002ovPDHLkV1h`wI+p+d literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/ruler-h-50px.png b/tests/wpt/css-tests/css-values-3_dev/html/support/ruler-h-50px.png new file mode 100644 index 0000000000000000000000000000000000000000..9f46583665ca6471075227f9e2244f1ba1ffece0 GIT binary patch literal 671 zcmV;Q0$}}#P)<h;3K|Lk000e1NJLTq0074T001%w0ssI35I<<G0007JNkl<Zc-rlq zv8v)g6oyYUj*(OvJMF|<*xQPQHX;gQ=Q9YtMk4qIcD_Uk3p+s&EW|>6gP<0o<3OBS z1j1$6y@J=>jmiI2W)i~T^Pfp3CPtA`(u;`E>xkCAIOm38{A6Fs3%^GNnFzqX(&;o2 zDT)%hOaxRt$_h?dilXdxyZwIuAIl18<k1sR7Ro|dDC@73<(+Ub#)4IrH|Pr?i0E>; z;NbHP*$SvFj1Q0nSpc#i3$h>!vLNd#s;X8h6(Y)HGDMWkW{IfR>*e!#BI@`1L^K!- zq999sxJ98*&~=@N=JPpYY_r)A(Q>)W<#PTuuIolY7N$GT%2E_8{&5kbJC1`e1yhkZ z{QWZiAyepm0H$CHreF%DU<$w#Ou-aPy%*}kd9U|DN?9(KiD<D{L{ydh79vWeQmfTU zN_jXOj>n_dsO!3I+fqu~wx`pn*C<1c`p_d0X`044S5?*jCFXoSGsc7vhGD3xigAie z)6_I=x7!g>wOXy$>t1^zkyx+So-)UAqG0No%Wt8-X!kNxI7<M}X6pN1hP7CW{s%Cs z1EdN70HQYojOJV%M?e6ODu7f0qzV9}3LsSgsR9700!S4=ssK_208$0QoT}fxKB3)i zTb3n+uq><7>A-U2c*&C|r_;$a%~Gl4EyiN8`~5DZbX_+dkNXem%w{vr`D8LF7K>iv z?RKlxYUA;^)oKYL{4FJTXMQ?Xb-Uf|cFP#!ocsSC*Jw0`!=VsjG#WLVO@HH$j}Ibp z9OvtMgBWAUWb%5w;_jEw@bB(q!d+8H6#$q60;CFrn@_JUXnGtsT_OMg002ovPDHLk FV1h+lHID!Q literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/ruler-v-100px.png b/tests/wpt/css-tests/css-values-3_dev/html/support/ruler-v-100px.png new file mode 100644 index 0000000000000000000000000000000000000000..a837eca2225082917dc952efd5c689e1b51d7bbd GIT binary patch literal 760 zcmeAS@N?(olHy`uVBq!ia0vp^MnHU=gNcEGaWU)iTMP_L`#oJ8Ln>~)opsRfQGkd; ze)kq>afh25lNKiW9??&5?NHJA%O>=XS@{0}+4zG^EwY_?F_M#iv9}3z1aeiSUzA*K zu(aV(kHK?2k3BK|`KL4QXWugp33W=8Xj?T)Nc8vQ(%9`GT4(2eudkH7c2+NL?u$dR z-nKS2Z~j`Y^K+f^ZT|OzL59~vJ9g=>@?L(q?{UxZ$KUny^7DVzuDt!h?mmN?plfyf zmG|FWk8IKrjGUqMkB_(Yd8N`MAGQ3vyhA@<bgG)GyNbMZyBKBu{M65@X^X#_xz|N( zNI2NE)qRbRnzGW(oG=%g^U{3n2NQ}bDsH?iaanTtWy$WlscV`SSj{;6?RV|zP4C{l zb6FCjH+xxSZLO}-<dZ7%&v$p^-rjt(=cAyQ4#>1ywbzy(%Ux#+<}|T#gG9?_n$GnL zUK#SiePsyOw7;>}x9Vgku7B`~<KEgPU54g^2R_?``Yyk`>Xk*`s(JJ0KQFQj%{7r) zbt}iL)bq?nx5a@6yp{&7nsqXz>CffMm(RcYnakO|rl9#~(#I!HTteT!e?R%;lGnRd zMQMom`TO7h&1I+D{M{YwHHiH{KeA^3UX!~oKff$N`Q3$OHK!M>^?md}Ue5YP`;WJ` zoGPcdSKa}V$916$caR7I{lB!WCtmR1qOjFlqjc|ok6s(LH?H5a&h2Na;zQo04{aAN z%iOnj@5)!NUuP>#?C|XJSbx2`vNCh~ZFhHf$0DPdQ%*l!y?XWL&Bph?D}P^q>`h+m zFXb?;somY&_rL4w>#x3=<rC!6*Wd5@<m1PSg>$|yNsZi=Yj1B~pCFjW&0YS{yFmW8 z{%3D_dwKh-9vNpof7j<_ShMfbl=P&-N7}Xp$UV*Eei}Fr#*lj&2u6iKLAmWf*~0AY cw|+4$pP;3B^U*VLV7g}TboFyt=akR{0G}~+v;Y7A literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/ruler-v-50px.png b/tests/wpt/css-tests/css-values-3_dev/html/support/ruler-v-50px.png new file mode 100644 index 0000000000000000000000000000000000000000..84141028020b7e8cdf2412acbca3c799ba50a534 GIT binary patch literal 757 zcmeAS@N?(olHy`uVBq!ia0vp^MnHU=gNcEGaWU)iTMP_LdpunnLn>~)o#p7Q6)4em z{$d*2BG*@!Lc3jVdA+?Q+2PW(<&`<hUq0SH>~H^wHaWhIaoO!ruE(m{QKE2v_l)kA z-e(KKcYm$vKGDDac}?&6nKO$m!Y2I`xEAGUC@i-6WK{O=zyHpiJNNeO+xv#s?=j!Z zxcM?)V^6`#D~}&Pp5?A$`q-&{Ubpelh>!(auZC((&D%cv^wS>0zQ+>Dv(7%_|5v|q zao)lohkkPybSa7E=I2W%vo$wv-F7j<M5=efqK_3hJ(iZ1hR5E#eOo#2c)7cvt4QFM zmy258?Tg>%?^YeP{?keR*WWj6TXu)LZemGAMMlrg{rmeFE-(LJ<A3S&Y482_`L|4a zV$ruGZ1vX<9}HH``Sp4I^9xs8BD45(?Git7i|IscNI2NU%6%<AQFrUQr?(D+*uNsK z-AeFYem8ITy4x>H79F(9J8|Uk$H$M8Jv&{Tg0!YiDk&_S=(k)oHZIO<*REZcdS={{ zuBxt{yk+-pZOxfJY$vZ@zkcEDg32{MYQY*JDz>(^mVKA=wyUOYzPWhuV$b-4=Px{% z$%e2T?g|j&pZPVd@7osh<~-+>HNJ0@q3xBETkz(j;nVk5#ZE1@IrSJs=KbBV&8b#r zs@K)5tKa`-ZH>~KK0UlH?2I+Pa;AYqh}P8R=H>^<I%3lO$0yypfB*5vA5Q|#-o1Ob zz+%ny*S~-Nb}TZHdiwe2?Afz7Z#KUF-I?$98QU)7&slTl&$qX?-@VRShVSyrk_kFu z-9WGGdw)G^>*dRrJqy()8y@>owKqh|)N|Lm*OhSvei_W#^M7W~=v`a$@8~4GJx?va z-#4{oh}c&&{rS;0ap_x5l~b1MPI0e<Gk|OmIt~)N1C)g`AmVT`zVHuY?mGL;&f7B= Q0uwcZr>mdKI;Vst0OKlsf&c&j literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/runParallelAsyncHarness.js b/tests/wpt/css-tests/css-values-3_dev/html/support/runParallelAsyncHarness.js new file mode 100644 index 00000000000..460f467930e --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/support/runParallelAsyncHarness.js @@ -0,0 +1,145 @@ +(function(root){ +'use strict'; +// testharness doesn't know about async test queues, +// so this wrapper takes care of that + +/* USAGE: + runParallelAsyncHarness({ + // list of data to test, must be array of objects. + // each object must contain a "name" property to describe the test + // besides name, the object can contain whatever data you need + tests: [ + {name: "name of test 1", custom: "data"}, + {name: "name of test 2", custom: "data"}, + // ... + ], + + // number of tests (tests, not test-cases!) to run concurrently + testsPerSlice: 100, + + // time in milliseconds a test-run takes + duration: 1000, + + // test-cases to run for for the test - there must be at least one + // each case creates its separate async_test() instance + cases: { + // test case named "test1" + test1: { + // run as a async_test.step() this callback contains your primary assertions + start: function(testCaseKey, data, options){}, + // run as a async_test.step() this callback contains assertions to be run + // when the test ended, immediately before teardown + done: function(testCaseKey, data, options){} + }, + // ... + } + + // all callbacks are optional: + + // invoked for individual test before it starts so you can setup the environment + // like DOM, CSS, adding event listeners and such + setup: function(data, options){}, + + // invoked after a test ended, so you can clean up the environment + // like DOM, CSS, removing event listeners and such + teardown: function(data, options){}, + + // invoked before a batch of tests ("slice") are run concurrently + // tests is an array of test data objects + sliceStart: function(options, tests) + + // invoked after a batch of tests ("slice") were run concurrently + // tests is an array of test data objects + sliceDone: function(options, tests) + + // invoked once all tests are done + done: function(options){} + }) +*/ +root.runParallelAsyncHarness = function(options) { + if (!options.cases) { + throw new Error("Options don't contain test cases!"); + } + + var noop = function(){}; + + // add a 100ms buffer to the test timeout, just in case + var duration = Math.ceil(options.duration + 100); + + // names of individual tests + var cases = Object.keys(options.cases); + + // run tests in a batch of slices + // primarily not to overload weak devices (tablets, phones, โ€ฆ) + // with too many tests running simultaneously + var iteration = -1; + var testPerSlice = options.testsPerSlice || 100; + var slices = Math.ceil(options.tests.length / testPerSlice); + + // initialize all async test cases + // Note: satisfying testharness.js needs to know all async tests before load-event + options.tests.forEach(function(data, index) { + data.cases = {}; + cases.forEach(function(name) { + data.cases[name] = async_test(data.name + " / " + name, {timeout: options.timeout || 60000}); + }); + }); + + function runLoop() { + iteration++; + if (iteration >= slices) { + // no more slice, we're done + (options.done || noop)(options); + return; + } + + // grab a slice of testss and initialize them + var offset = iteration * testPerSlice; + var tests = options.tests.slice(offset, offset + testPerSlice); + tests.forEach(function(data) { + (options.setup || noop)(data, options); + + }); + + // kick off the current slice of tests + (options.sliceStart || noop)(options, tests); + + // perform individual "start" test-case + tests.forEach(function(data) { + cases.forEach(function(name) { + data.cases[name].step(function() { + (options.cases[name].start || noop)(data.cases[name], data, options); + }); + }); + }); + + // conclude test (possibly abort) + setTimeout(function() { + tests.forEach(function(data) { + // perform individual "done" test-case + cases.forEach(function(name) { + data.cases[name].step(function() { + (options.cases[name].done || noop)(data.cases[name], data, options); + }); + }); + // clean up after individual test + (options.teardown || noop)(data, options); + // tell harness we're done with individual test-cases + cases.forEach(function(name) { + data.cases[name].done(); + }); + }); + + // finish the test for current slice of tests + (options.sliceDone || noop)(options, tests); + + // next test please, give the browser 50ms to do catch its breath + setTimeout(runLoop, 50); + }, duration); + } + + // allow DOMContentLoaded before actually doing something + setTimeout(runLoop, 100); +}; + +})(window); \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/square-purple.png b/tests/wpt/css-tests/css-values-3_dev/html/support/square-purple.png new file mode 100644 index 0000000000000000000000000000000000000000..0f522d78728417b0f74b694e2e47cd41c00359d1 GIT binary patch literal 92 zcmeAS@N?(olHy`uVBq!ia0vp^f*{Pu3?vyBU)>3$*aCb)TpJh~{xkePDssRFB<<<q n7*cU7`N#kLjg3MaSNIuL+z|fjF-g!1D9PaI>gTe~DWM4f*isp& literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/square-teal.png b/tests/wpt/css-tests/css-values-3_dev/html/support/square-teal.png new file mode 100644 index 0000000000000000000000000000000000000000..e567f51b91bbe40754cb0e0cae066201219cbb4a GIT binary patch literal 92 zcmeAS@N?(olHy`uVBq!ia0vp^f*{Pu3?vyBU)>3$*aCb)Tp1b~82<lv|F?D~NZQlI nF{I*F@{j-f8ykf<uJALgxFP)4W0Ig3P?EvZ)z4*}Q$iB}@>Uv7 literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/square-white.png b/tests/wpt/css-tests/css-values-3_dev/html/support/square-white.png new file mode 100644 index 0000000000000000000000000000000000000000..5853cbb238cb2d4aba3dd49af3f2ba64d6c7a2de GIT binary patch literal 78 zcmeAS@N?(olHy`uVBq!ia0vp^f*{NRBpBq_B-DVEsHcl#NX4yWiv~UkzCZ4)$}udm Z3=C_{1@!OB{@4Xl=;`X`vd$@?2>|f05A6T| literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/swatch-blue.png b/tests/wpt/css-tests/css-values-3_dev/html/support/swatch-blue.png new file mode 100644 index 0000000000000000000000000000000000000000..bf2759634d45dbe3df13868341eddb7e4bf24172 GIT binary patch literal 84 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K83?vyP*g1g|bAV5XD+9y-u8K?HKrWA`i(^Q| dt>gp+Mj%g@f$_JNuojTT;OXk;vd$@?2>>P$4{-nh literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/swatch-gray.png b/tests/wpt/css-tests/css-values-3_dev/html/support/swatch-gray.png new file mode 100644 index 0000000000000000000000000000000000000000..92c73561f3a8b74b279c2859a0b13145ef12f40a GIT binary patch literal 163 zcmeAS@N?(olHy`uVBq!ia0vp^A|TAc1SFYWcSQjy&H|6fVg?3oVGw3ym^DWND9B#o z>FdgVmt9swTFAKFy%s1WS>hT|;+&tGo0?a`;9QiNSdyBeP@Y+mq2TW68xY>eCk|93 z>*?YcVsSb-CnF<4LEOMFfWghQKTGba&8nG2XBpaS8CUo{xWf)q$l&Sf=d#Wzp$Pz< CekfxA literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/swatch-green.png b/tests/wpt/css-tests/css-values-3_dev/html/support/swatch-green.png new file mode 100644 index 0000000000000000000000000000000000000000..0aa79b0c86bd72c2220ecce39b9553e2cd3605b9 GIT binary patch literal 84 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K83?vyP*g1g|bAV5XD?<aroS#c40=Yb%E{-7; dw~`YS7=b)p2FBl7!dgHUgQu&X%Q~loCIBjB50U@? literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/swatch-lime.png b/tests/wpt/css-tests/css-values-3_dev/html/support/swatch-lime.png new file mode 100644 index 0000000000000000000000000000000000000000..55fd7fdaedfc1ed505b111f20fabbca568c68fa5 GIT binary patch literal 84 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K83?vyP*g1g|bAV5XE5m;VlehybfLtC=7srr_ dTgeFuj6j|)1LJQkVJ#qw!PC{xWt~$(6968w4?q9_ literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/swatch-navy.png b/tests/wpt/css-tests/css-values-3_dev/html/support/swatch-navy.png new file mode 100644 index 0000000000000000000000000000000000000000..28dae8a3e12bea03cf41b020bf05540adf9da17f GIT binary patch literal 159 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K11SGd?VUh(>oCO|{#S9GG!XV7ZFl&wkP>{XE z)7O>#E{A}KxioXY?P{QqWQl7;iF1B#Zfaf$gL6@8Vo7R>LV0FMhJw4NZ$Nk>pEyX7 xr;B5V#`)xwgp33QDFed^Om3n5tCsD{VrW{=FfT{-zcNq}gQu&X%Q~loCIIazCb<9r literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/swatch-orange.png b/tests/wpt/css-tests/css-values-3_dev/html/support/swatch-orange.png new file mode 100644 index 0000000000000000000000000000000000000000..d3cd498b52bd88ea6c991f050f1ecb1cfdd136bb GIT binary patch literal 84 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K83?vyP*g1g|bAV5X>;I(;rzSbh26A~kT^vIy dZY3uuFamkH42-|EgtdSy22WQ%mvv4FO#nq@5F-Ep literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/swatch-pink.png b/tests/wpt/css-tests/css-values-3_dev/html/support/swatch-pink.png new file mode 100644 index 0000000000000000000000000000000000000000..95b84499a3d849cfd74eb8711f5d2a1bc45d0c39 GIT binary patch literal 160 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K11SGd?VUh(>oCO|{#S9GG!XV7ZFl&wkP>{XE z)7O>#F1v)dmTbUZVN;-xWQl7;iF1B#Zfaf$gL6@8Vo7R>LV0FMhJw4NZ$Nk>pEyvF zl&6bhh{pNkKlKkxm@hVTHi{UmstPgv8p_P@ua9X3)ACoBfT|cgUHx3vIVCg!0A2AZ AjsO4v literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/swatch-purple.png b/tests/wpt/css-tests/css-values-3_dev/html/support/swatch-purple.png new file mode 100644 index 0000000000000000000000000000000000000000..73bea775175e9bab0dfe664eaea9ceaa566de787 GIT binary patch literal 153 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K11SGd?VUh(>jKx9jP7LeL$-D$|*pj^6T^Rm@ z;DWu&Cj&(|3p^r=85p>QL70(Y)*K0-AbW|YuPgf<CN?H@8SBFiJU}5yPZ!4!jq}Ml p2^k3rQU-<-nA}49S1sF@#c<n>Q7&8X=USj522WQ%mvv4FO#s*6C0hUh literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/swatch-red.png b/tests/wpt/css-tests/css-values-3_dev/html/support/swatch-red.png new file mode 100644 index 0000000000000000000000000000000000000000..1caf25c992aa8e23483cddb3334b5f51ec967f4a GIT binary patch literal 84 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K83?vyP*g1g|bAV5X>wg9Y$w!>#KrWA`i(^Q| dt>gp+Mj%g@f$_JNuojTT;OXk;vd$@?2>=8a4uJpw literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/swatch-teal.png b/tests/wpt/css-tests/css-values-3_dev/html/support/swatch-teal.png new file mode 100644 index 0000000000000000000000000000000000000000..0293ce89dea5c9413e4c829cc83a4e39d8f23300 GIT binary patch literal 156 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K11|+SoP4xm&jKx9jP7LeL$-D$|*pj^6T^Rm@ z;DWu&Cj&(|3p^r=85p>QL70(Y)*K0-AbW|YuPgg4R#65`cCM1`H9#R5PZ!4!jq}MV s85uv$JE$cjEnw)$lDlfNN|Kv_A+(E0c5RvdE}%LFPgg&ebxsLQ0IVw~FaQ7m literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/swatch-white.png b/tests/wpt/css-tests/css-values-3_dev/html/support/swatch-white.png new file mode 100644 index 0000000000000000000000000000000000000000..1a7d4323d77287d8eb03a89c635b09d099d94869 GIT binary patch literal 85 zcmeAS@N?(olHy`uVBq!ia0vp^{2<H-Bp8I(u6Pcln3BBRT^Jbeb_p*5^7uSm978H@ gCI9%}-<ZL|Fh5TA$_Ah94}dZZp00i_>zopr0Qo5vZ~y=R literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/swatch-yellow.png b/tests/wpt/css-tests/css-values-3_dev/html/support/swatch-yellow.png new file mode 100644 index 0000000000000000000000000000000000000000..1591aa0e2e274854ed836cf582235ea0202f9c8e GIT binary patch literal 84 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K83?vyP*g1g|bAV5X>;L}@UB|w-0=Yb%E{-7; dw~`YS7=b)p2FBl7!dgHUgQu&X%Q~loCIDbL5Y7Mq literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/test-bl.png b/tests/wpt/css-tests/css-values-3_dev/html/support/test-bl.png new file mode 100644 index 0000000000000000000000000000000000000000..904e24e996a3e5da93bef89e10c49e24c07d0ed2 GIT binary patch literal 1368 zcmV-e1*iInP)<h;3K|Lk000e1NJLTq003kF003kJ0{{R3g3O3#0000aP)t-s005aY zGnr;)nE(LHGc(L)X3UwH%*@QpW@i7Hng7hp|NsC0s-1y@0000CbW%=J|NsC0|NsC0 z|Ns9065r0w00001VoOIv3m@0SzyJUQ%1J~)RCwC$mrHKsHV}qI#0OA$)CUNV+0PNC z5z>1FDgrZWOHO<59>534BKsDgp7p3B>I7zAF2$Eby&QX;;i_BGr>dV-tSTkfVYNIl zi$7l1mTrsB_C8C-i#4X^3LaLG>jn4e0?941+dy=QV9i9xkG(@4H;@(~ogt^a`43yj z^`**Zh^{Td#Pj%+Qr%fKN-5`g;nYOF+LzqmXhmO+m0gFk>gfe#F-NRAhUdXXT_P3& z5hZ>zhPowUE`a<#=%qb^0(KmTs?O^A;`TX0ocz1q{qO362uJ`J02e5qdmo1g`RwHP z!A7z7fk;yZJFK4j+J<J_!!kFwGv}DTl*m6N!y-fSp;zS$vG4R+^f3f3FkDp6`iZB@ z9Rq0{yOh5|GFgnv$G$b5jmSNW@=3{zpgZ``cV=57#LB;M$gx-;>{j+R-gEgot3{VQ zT_EJMJvHm{U-0*2vCJ(xH5>9<9E?yX{cn>?Cg7{`b(@FBIAj4b8LLlxUA}&DNX9v( z3NQA_a4!BS*5!`~%BqqjA5Y&4uFEHnEyD3&j#zU)o^f5S%cniIzr|OZ3i>ow5`DiR zKV-E(ZYQ3EdZkb6@<UeNeUB?iBFq`D*X2*MI!I#{X}9FZS$$Qmwt_`|Y{-wZnqKV6 z1blp+IyR9XXEjwg7bU<2vXH;?C)8Cq%49XyvL(Ou3A1w<`?`EvZGvCF2-_3drF_v3 zWsvc|O+gEO*$ta$@sA0cmcFE8)2I`NWRx;N{9|`#gBRBOOq5lHKJ|AG{lc-r?c}4) zL-$z5Md6GLEg?qSW3G#N#pKN%xTocLj)Y#BeKpr}_iC1cFHVHGREV^M$HW)&`;U1U zqa(S7SZ8*J-qhDnFUE@G8)EF3n+2Q$s`7)uute1_k<QgF7t5n>rGpW1SV4To*jSQh zlcG$a4=ps-GU>1C2_a&@$I%?>7`aa!VnfzdIeZ#?+sUD|PY~B%U0^7GO|Nu@sDsJ# z@KlWWEXlsO1AjC<{IhGw<M`A>1$M}i5N36xL4oHW;3LYQL{&USeE7rWXggil@q+qy zcqZ;IV<F)o1Yw4G7>JjWW`PLt<%)`T&`L8>V}>Oa<kn^+iI7n5LHubaqvh(*WJr7^ z)T>O$2em@zx|mEC771}cDVqgE!@z!yT>QYv82lFP(%@F<5;wl4TqknAA$72YTMI-# zh4f`KPMMiy>XyGdc~Of)_A<zfoj!JJF(=#0d7SY)+PJ~38KUdBOaRb$*jPKdJK=EV zrkm0Z8xVG(YE0}Yt@-e>+14L1KJ#R!khI&B)WtXi&X5b{lL3*@ZkLC@MvW|+A?7gN zW^9D0T;2*9*?`>~p)-$sKP@gC`DhvB0@0TW$+>vr68OLZ|AFHIA?8UIVp5VL8#iJF zp>x%gNY!OhEyLo1uORl+--}g*Wst2R?yDkOfv7^I8;JRK;rXg-$rj?i69C?WTvb<5 z-Ama!5K|d3=PQC<K{RE8uwP1VM##=LEUkC!&4^ZAZE86{8mYSe$D&=JS`K8398A-< zAkI6YxS&bnwNTEyqw<esfq5o26J~CRQnjl~iN@O75YIKX+q?rYE}CZZF2t>$$WP>d ai~I`(b4pM507-ZN0000<MNUMnLSTZUYM}!F literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/test-br.png b/tests/wpt/css-tests/css-values-3_dev/html/support/test-br.png new file mode 100644 index 0000000000000000000000000000000000000000..f413ff5c1a0f2ad9f9a345d3e07be57a59a82207 GIT binary patch literal 1045 zcmV+w1nT>VP)<h;3K|Lk000e1NJLTq003kF003kJ0{{R3g3O3#0000aP)t-s005aY zGnr;)nE(LHGc(L)X3UwH%*@QpW@i7Hng7hp|NsC0s-1y@0000CbW%=J|NsC0|NsC0 z|Ns9065r0w00001VoOIv3m@0SzyJUPhe<?1RCwC$ms@V5FcgLlnk;}*nH@}b&;=9; z`W^{0$~+gU<h>dx3m9n@P^7faO%<|&!sf>KZm^B!d3qut2z>beeU2{xp@)&j(02`` zTY^Y(yls!8j-g6{#iqXUOZZmq^{tQRnwIpYptOGKE#wg=geU|udB&pePc3cOueFKs zvzd?t6~fN!7xtH~ecHeFR|~mNE=(hU<zcj=XW{%Yp6UJ6N@ftUzmC!P5cbt`?6jy? zkn>j9-;D~v`nZNntt8~9LC7xNOec_RZz1(-9N|5dP=m0v9-_#(n4W^-V2~txiYhzj z!i$YK*$mpxEQDn<+Gk7q?5d2K>8gc&fN~c@-gEJg62@yGi)KdJFKsVL7OffK1s(gk zuDvn5Y{BU<F%-%e((qKG8u5Ul%idy$ct({KxR(KBlCq)lwQ%n=>I*USjd;i%YrdEb z{Sn*_^roe9hCXX0U8@*Tm5}W<;uM1)L8qv|EjeFw?$DQBbYc7Y_+{2Z;0_;OA3x6W z0PY|Sr^RF&+^N9lo^nJde+0T>e|Q%!CAxA~?GMkwJ^q*@L1D^DW{@@e8aZfW&HlL( zh^h58`-7ZbHV<zaS+W1w2>0aSI!6vcWNu~EzD%TLWzD`y<i?s$R_yCU8Y@az$o?{s ztJ8(Yy+rUffV?jfsir=p{xwOCNIQ`VxeF})mt`W=%)g=j#qveyLfcAweUa7TT2Y9% zj|Z80xYL7JBN#v$SuMm7!T-APcUV_RUG7#w6p(kTFo<b#?tbL$mc9)MbD|J81-xCa zu1iy(+!eIf8G_WOYv>wDV7Xr)zJ+r5pkj?+g<rb&*<VHdwnQ#%k*B`?n)b<=Z)r8M z*w%Y?pY@=}iIK&e%yly-p3Gaau$<qAqFp+%WF>S_u|SWDG`g}53&gW~H?kPATZn)^ z{pHpDF0f_Yc)Al>7VPVTai^XiPQR;MAxJ&d2ec|FrET5HXc}tCS~{7gaV(KcTp<oc zQD|B7>QZ^Z1TjZ~gu`3RQzOf}P2=}cU|fp)kR|{zS!z=9ML<>z3CM~dAz5JrL$V?W z4Q^@!)=5xS07+PK!ylVGm5`=3ktPvYvS1MHR5ItZK3>BJtE{TnlF}3mey44O;Kkq6 ztd@0Ivcj%UvClb}M#-r)(X{Qa==a|U(_!d)YlyiY`vK(N;tTmg{#)cPVxOudoeJ1E P00000NkvXXu0mjfoHYWE literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/test-inner-half-size.png b/tests/wpt/css-tests/css-values-3_dev/html/support/test-inner-half-size.png new file mode 100644 index 0000000000000000000000000000000000000000..e473bf80efc66766cb32ec2cc60244ed37dc1157 GIT binary patch literal 180 zcmV;l089UgP)<h;3K|Lk000e1NJLTq0015U001%w1^@s7JXu?L0001cNkl<Zc-rli z!4AM62t%pa|Nk<(E?zL=Fq+2^X)3e<nYr61nsxC@Ld$8rPiTZTB&ja&s6as%ZJL|M z=rOcU${2vp2YUvrojv1iz<}=oKePMm#BU3e)Gz&dnG;ue53v^M#Hf!LH5!*`jH~Z= iHN+4@%ynW{5626)ITymFxuX~W0000<MNUMnLSTZVu1667 literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/test-outer.png b/tests/wpt/css-tests/css-values-3_dev/html/support/test-outer.png new file mode 100644 index 0000000000000000000000000000000000000000..82eeace7fc0c4202f79610978ab423e62abf8939 GIT binary patch literal 2412 zcmZ{mdpOg78^=c{EOMMh4qF~6Bd3rFi9{I*a|(^Nvdq~?QjT*?4xw_Itd@FmT1%@; zkHai-Y6->Aa{4*!H%&eKiag(`-yhHQT+j9WT%Y^CzTeON{@nNL{(P?Mo9&Krl9f@D z0f9iW&L<o^0NV)yNkF9}fteqx$p(R>O`RQ%dM1nrDqQhOXQ7#ug?V#Sa2fmTSTTg# zq5n>b3YP6~G}vwrp{7((H(F%s9=vs(d(vdsw5S`*{!`K=^0e|Hs;%}@ZAe9;YhM#o z_ToaBZbi>ZoPth;c~{8~-g5bm@{$}EyaCQ}|KNtGC?`*cg`T-jp?`3qQTBgZTv?v{ zsdiqg_=L}TaeDHp)WEMH?m}9l;@m~8p=7pF>!36@MZO>-W1E4=+P#fwf=QndMcXv7 z8Z8-fF2Q7mdllSkqq$$v5O4Max@#iK>)>}|J2%opy`et}FlLkY$|k=MPb|h-F&GS# z`yPH&Q53dkQkZ<87kdVuoRE+pLOXW`h4H>u8uuqXC&Rob*li9oo;cl8K)zjxUvIBg z$)w}LH2k-=iDKc?$`Kh8{tr6}PB1uTuEZnV2}8sH8=6vc={^tU1@E=j4k~YXOGQ|X zkJ7bc);}A=x!>Q|ZjgqKn<q^%>txci{z1vOpT5iHp(Eo0q?hU&McH@xcJuaJ!&r=t z?vM4Ew=lmncbCv<w<by^%~!2EMkjjnd54&X#Od#j14r-;{%H*anvq+xT4z&^R~p5` z!xS#*RhyBq#-3+TSq9ZKkNp)WoXPH4H-m1)g6J1}?lL8tMqKR^6?)~97d2-4DhB+5 zUdGN1RJ+xB<5yKLk0NkP^&6b`?>%iQg%g%g!y>UhwjyyUTO+MrE;m#Qlfbq|*dc(4 zZC|6qC(sSHP6V-iNf|!edmH+^^*p7Z*`Fr|qZ;SsTT5vuq{VfH<xT}KU7pO%=gQ-v zpl}EV2Ej;R3K*TfdooFmy;Lk8A$M$3@V7ALWqa%n93N4h!H9%#CFmf!JRkt3OVQHb z4OBETnat*91Ne0G$7cc;8XW%MV(Eh}E-|2Hw!aen*h^t9zNtCIQK#4?o8<B4NzKA= zJ-KtNi74c~C_F{C-09RZX5o7;K}%g#V~>E_u(9E~{{7oy($sRI!r_#kERyw=)upx! zFkJKpcdtUCXezrquiN45{@FUmzL;55Wac?m%0{3=Y46O}udzZQvI2GYkbbEmgW{O# zB*tP_1EQvt8AEX}i1ucwo7Do-=J@@}d(C-#{nOcUixx3CVB}<e`Lw}_xWS0LbrOGg z-0$$Y+G<jqNui?4Zdoxsu$TaOYd=pOXKWEl=;Q$~#Yp}}11wlrY@mF@rT&tjQx2Kc z;EdG(+Qw=(0gQccTmb_LX#GO@-=ToE{*}o1S&Q<qR$oGG$H$7QsF?VyQgL%mGamZB zN8AN0>yfx&o9U9a{k9oC*L+CRvNc6NGmAaSr-%G%isWSVX*Ri;gJFYDY61-RZMJ9s z-`z?*?sVx<BY`>k?ebatm>?cmkvn8n>~gVoVD9PAWg?M?$DhQ9`wq>_JP04nEs0as zGCYyp$>C%Uz4Sbg-8nx$KQdBELKqs3JZpaXR0kdt6C;QpRUl$8ZN2BT1ay8+QeDwI zu62>#lKkWL24UmrHRFc%C7-=lR_WXembP{E_3D{)24gRLd3m`56V=JI3W>Gc@|ghD zM4FnK`Yo)lucxJLsZJ~`ENt|1#h-mVSROoe^Uf(EVVw0btkFTIuq)O|12?%MoRDpA z2yb%N3pEM(Fd#*y6-Dy|)=~4^T7Ra;qxZn6bJQv8eU-G*cUmx99|SwF1S^VO>?Mcy ziKu&}Y5&7fzUR%+PBa2D*ec=Nds+$#Hi85rKsnpQ4u~Tuc0eH#V&@ut(`oSm91zDY za+r0m+14Xz`N-u=du{O&XwC%ls)q~AieIs$nYA?j`i;>+?lE4qb*u__4g0>Wic&zo zR+V36^t{R_-%yv8wr}-_^1lgZWPfdu3O$yvqYW912-Zu#GoWhgovH3+iIzI{A=E)V zcQydV*I><E=u_da(q7DH+)<GXMo3AvA=y+6U6e})iPP3*DUDxWlG~X9WJt}Yx1=aW z9f9!2A{3*A+uM>n-slX6bO6zsU?5t4944(oUP5)GKA$4KLQ4haDC`}{Ps+Ey(|x}` zyBd9~%hyJlk{^d?Lo)0)dE5l)3+)ni{3Zg_i0Xi|wj6^6BU*ew>BPGjg>hpsG84#F zFtJR+%|k#s!XCqF_ng1k)XQe2ZTWsnZZ|ncg`BfZy2~e>2r%0X?)0(asHJc|7s;{V zAyLed^iYKNI1KWOw{~cQNG_eYN!$n`KQ1lw1ky25mK1-sOUN<}du0+Jm-|WOJ}UZk z;MD^*RM{7)%54F<f89d$AT43&eEZMXjD>{-bX|b)&Pma9Hxh~L<9I*zLO^8O^&sR* z+Z4@)s8v757MByxkbSog24S(-^4S*wgp`yZd~#%@yPop)OUea1c4?kMp-^sa!(oST zlOoZRWmaIl?bWsCD++LG;;LvBull2<z%AUo%!0tXV5Zh=aOTXJiC4)n)<ylZJ1#8> zTKN2P=4FEB_A-kIhbh4*)5)gT&@Gq#)33|s%4+1d`N2!(NL$;9utxEAWYvRMlM?)J zUGmy09Ze5xzD#Sp`sH(nNMyos$)$75^*zJVnHX>A58rdx9N!z~iBj0<W}FS}{WTSS zYe(Kh?$^;NgZyZ(TL-Pc;QQJ0!or2b!LYc9i2f%v0)ZgFaP|`7cK3seBhSK1u{4h_ z@XA$Y?)2*bv%CGWDk&;eV+0`iroein?E{ZT1m@$$KVz-tVqdPbjg5@~%n0G(y?uRF z>IU6@K0Y6KJQh(%2_L<F(zQbdtgfyO+|gmbe_i?OiRXdC>Z+=$Xf!%}G|=DQ-_LJ; z{R@v*PI@{ju&;VMdI8E|v)OrCwr%pJojwJ7oSpnX!a|OIC{+5t7cWF27_n5j0g~u3 VAD}`@1i=3k$k`F)P-h>U`X3Goc2EES literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/test-tl.png b/tests/wpt/css-tests/css-values-3_dev/html/support/test-tl.png new file mode 100644 index 0000000000000000000000000000000000000000..f6ac0ef7e8f6e192c9c26239884bf92b13cf67b8 GIT binary patch literal 1025 zcmV+c1pfPpP)<h;3K|Lk000e1NJLTq003kF003kJ0{{R3g3O3#0000aP)t-s005aY zGnr;)nE(LHGc(L)X3UwH%*@QpW@i7Hng7hp|NsC0s-1y@0000CbW%=J|NsC0|NsC0 z|Ns9065r0w00001VoOIv3m@0SzyJUPb4f%&RCwC$mQ8M}Fc5&T!~r@I9HIMngrJ)4 zQ(^kjbwEn?FN@yb9iWkt>{9_J2)W!F@R;Dg)Lp$zS!5CX;rV991JU){SM-DYAV0|e zM%uPHwukYjIUJ7B*Q=ZTu2z>QMR^bD+hKK83n7YJaQrDaUiXl8N2@a^ART^^rwFp> z9#IKgok0Td0KkTyXt?~yXZ<2qM=a7Vzey#Q*6RDnL2!78qHiE=Ex4QTA^lz~J%kTw zstmq|U|5-t@E~V@SRUkpVNEL-i@q);x>HzkHGJJLeJv;~hO4ub=d-q4IFZka!eTMc zu`{buHGh%+at79akO>1WhSi7Zh!q^12-bv5K>WppZFh6@Am?f!<BIe8<ZyJvwWFFq zUcMXE0yolD)G8oeTdi8;=!mNz`J_B*yPwI?M)m~}`KHs5imGL+R7;7ZWotYNJV;A* zWckKOJq2tdq{0$$(*LL3ZKU7Jv@p{|rJmVH#VIZ=UDrmLfQ3*?VqE$rdu3uFswG*f z%lCCbgf){JI*%YWuFdgL!bDU{f?kyVyi~}>KvZ5Be|6^zTf#t8UO;S(JZAKN+3ASN z3j@6)uNUz|&Al}d$_w_F78jlrimN;suUD0qIN$0jWDohucq6MjSV#Rh_J5@Pc!G3f z_wwM3t6xj|WYw9-AC(uqCDDE%<9fTAh~QL5JzvTmP~Jf3VT_w`oktbsK$-$vb-dY+ zEip&>4?ZIC^U;m)Hw&SbOn!F;BHM*_pCjsYrK_unjA?=AlYvYnPPY~!(~?^V6%rmz z<RXVlV(+q3UGZ)qa4U<3RPu9z8&h()Lr7;MvMclhIow%G<k?0tDQT)8vXJ#M5t59J znRmOBS}sb`n8kPXi@9Ww{-vOHwGp3wv!1nUm_EL5ha0)Qi>kimBF|Bjt{e!>7aIY` z$e-!kZF!dZ$<~h?Ekqu$Hyc?mW_>Y3_Tv~aU&L~krJRVP<{Xh@#O3lKU&e81AT)VW z+l8Kn<$pJj%%^`<NBnV^?sG(rO721gjrZ5ir7vt3{7A{<<H{~jA7`ID<MD7X!t_;S zAdaE>s>@+0W|%%6zicXInEvpcG8HpS|5i+Fr$GIwnD~MX)K@9PlerDlpNfeu>p=af vm<;kz{V6gHxvP)gcJytThUyO|QzGyW8di!g0nvTM00000NkvXXu0mjfqXF-V literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/test-tr.png b/tests/wpt/css-tests/css-values-3_dev/html/support/test-tr.png new file mode 100644 index 0000000000000000000000000000000000000000..59843ae54b64f6ce4f7e616d4be491c911ea84cf GIT binary patch literal 1235 zcmV;^1T6cBP)<h;3K|Lk000e1NJLTq003kF003kJ0{{R3g3O3#0000aP)t-s005aY zGnr;)nE(LHGc(L)X3UwH%*@QpW@i7Hng7hp|NsC0s-1y@0000CbW%=J|NsC0|NsC0 z|Ns9065r0w00001VoOIv3m@0SzyJUQMM*?KRCwC$mrYXRI26aFnjFBd+de=qdOt_N zRTBGjNv4=J5|!QqHQb;NfD32Vom9jLqFiod>%)>Qhp^}!Di#F%(|iB->7dhx5Bfwt zkx%50BC1n|tx|6vK%_mLQWqnX6K;;U`FDFEg`lc|)m4wlpBK4@05B8)B_V|J%_Vlw za4<$t6qwQ5?fVe&2b-UQ(B}DF=TLGmWzFWjfTsuoBj{dz2tgQl^A0mb5R|kzAGjHU zzt-QIvk5};13=E&LB-q-)byMklsg#6^|GA>1kTt&3kTTsQcmN$3rJ$UlvDpmfxi-B zs(OsZVotq*l2F1pfdVHvT}FC0ny!_MGKlO{^1lTH|7D!$)SEgOs2&9Y@Lbr2kd{<# zhySTga0aoQC4`TSr6hxqDd{GMq~)Oxf{zHUHg7p3EkeB)qa9pj)F50=N<;4i33kkV z+Zkfqoh0ngavtIa&CE4aHM11QcA(<ZnS*i}9_-kZ;*#IbkX(ZM7}U-VnO=(WZJ}O6 zN?{sklqJk*eYL?f(2HA43tsrLxw#P83GW(do-aa9$Cseyd*a!d^}6HVyqYAe5u#PP zW%Z*kP*_6LlYHvTg7zzOR0H&%9HKkXNYMzhoi|%+O@~02w{IClNzOR!w=8e?lQnb@ z%pq|-dqh2QW;SdM6#?$Yk>1_eQZqwfj_k!6`W4$RXtT;($sb=Vf=Ltr<fHQ=Orru; zUn;qEfp&3@JVRc|I^G&)9Ni4A9mSQOHEM$Fe1C)nz8+lD!g*#oEk#T?Ym^*pUDLa@ zP0fmiPIHK0vlU}q+Y5`}FTpe9;sq1LWPGS!Et$V!6C--}V}{^za7DM=t4WauJA@K$ zMP={GAs~J}TSO4+Obz2!!c-2PJ^BD}6(L7%qhFFWlm_w*{A_jB&gyf79BgCs?>w9n z=2B#u(Pr7sL0tWekex*^{dF&8!>RY)KGWH*ffTXTQc}}ioq82%jI{MEgls^5+h<%O z^>H1Z@tJtBVk*~XX#88aM!5hI=gDs?hBhOj+jXMvWV-~H?(^Z!I&l*r!fNriI&I;K z<Iv6+Vk^Q0%(qeN5a+0NAxn^9#sT%s+L9uce-sc;vjLIT_kg$%QSX=-v{o_lKqih2 zSFAju?}mC>UB`|wTQ4r~E*vl-*0C6Qu@PH2eTrR0Wf{T~%Xbknf3wf*S&<+a`6o9M zz*S7^KKgFY$UnJ0HVgZg8jXfF%*c<rs4-Jtxk{$Dr$zap4viTq<*Snt>L({(KZLbt zzRNL^s?W;zZP~w5L&>g+M15Ai**#&3n|Wb>4eGP<`;PGlMsC0muRbf^cs3p5##&fh zIr(FkMaZ}vrt)1Swj2@$kLqXgyORsRw`3xZBX}-f+RL=$<nPGNDtben%J*+U`~KZM xFqlMZdn&(j3r#(mcWQ87&CEBe=q+_3|9^_Lp+#u>Ntgft002ovPDHLkV1lbeOeO#T literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/two-regions-in-container.html b/tests/wpt/css-tests/css-values-3_dev/html/support/two-regions-in-container.html new file mode 100644 index 00000000000..2fc65261da0 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/support/two-regions-in-container.html @@ -0,0 +1,38 @@ +<!DOCTYPE html> +<html lang="en"><head> + <meta charset="UTF-8"> + <title>One region in body</title> + <style> + html, body { + margin: 0; + padding: 0; + } + #container { + background: red; + } + #content { + flow-into: flow; + font-family: Ahem; + font-size: 20px; + line-height: 1em; + color: green; + } + #region1, #region2 { + flow-from: flow; + } + </style> +</head> +<body> + <div id="container"> + <!-- The &#8203; entity is a zerowidth space. It enables me to create nicely reflowing rectangles of Ahem text --> + <div id="content"> + xxxx&#x200B;xxxx&#x200B;xxxx&#x200B;xxxx&#x200B;xxxx&#x200B;xxxx&#x200B;xxxx&#x200B;xxxx + </div> + </div> + <div id="region-parent"> + <div id="region1"></div> + <div id="region2"></div> + </div> + <script src="util.js" type="text/javascript"></script> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/two.gif b/tests/wpt/css-tests/css-values-3_dev/html/support/two.gif new file mode 100644 index 0000000000000000000000000000000000000000..01435c80209d533dc2164ac48279574c7ba4615e GIT binary patch literal 184 zcmZ?wbh9u|G-5Dfc+9}?|Nnmm1_pU~d3$^N`Sa)Bzkk2JzCJ!ae*gacKygf<0}=x1 zWnjq_IN`Z^uf^-LyZ<L>^rd9Z%UHE8=k>k<o%1ER_bb-DuX+F9^k9R7fPkLUqK~Q* zc(|CC2%nO1TinphID5}Nt_DZpXpRQPgu)-CGBzifT9*7x<K{V<yu)Ju^Tvk8rskH` Tw)T$BuI`@RzWxaff(+IGsD?$T literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/util.js b/tests/wpt/css-tests/css-values-3_dev/html/support/util.js new file mode 100644 index 00000000000..a7ce4283e45 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/support/util.js @@ -0,0 +1,29 @@ +function resizeViewportTo(viewportSelector, width, height) { + var iframe = document.querySelector(viewportSelector); + // Commonly used trick to trigger a layout + iframe.contentWindow.document.body.offsetTop; + + iframe.width = width; + iframe.height = height; + + iframe.contentWindow.document.body.offsetTop; +} + +function injectStylesInIFrame(styleSelector, frameSelector) { + var style = document.querySelector(styleSelector), + frame = document.querySelector(frameSelector); + + frame.contentWindow.addNewStyles(style.textContent); +} + + +if (window.parent != window) { + // we're in an iframe, so expose the bits that allow setting styles inside + window.addNewStyles = function (cssText) { + var styleTag = document.createElement("style"), + textNode = document.createTextNode(cssText); + + styleTag.appendChild(textNode); + document.head.appendChild(styleTag); + } +} \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/support/vendorPrefix.js b/tests/wpt/css-tests/css-values-3_dev/html/support/vendorPrefix.js new file mode 100644 index 00000000000..6cf3c5a3783 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/support/vendorPrefix.js @@ -0,0 +1,86 @@ +// +// Vendor-Prefix Helper Functions For Testing CSS +// + +(function(root) { +'use strict'; + +var prefixCache = {}; + +// convert "foo-bar" to "fooBar" +function camelCase(str) { + return str.replace(/\-(\w)/g, function(match, letter){ + return letter.toUpperCase(); + }); +} + +// vendor-prefix a css property +root.addVendorPrefix = function (name) { + var prefix = getVendorPrefix(name); + if (prefix === false) { + // property unknown to browser + return name; + } + + return prefix + name; +}; + +// vendor-prefix a css property value +root.addValueVendorPrefix = function (property, value) { + var prefix = getValueVendorPrefix(property, value); + if (prefix === false) { + // property unknown to browser + return name; + } + + return prefix + value; +}; + +// identify vendor-prefix for css property +root.getVendorPrefix = function(name) { + if (prefixCache[name] !== undefined) { + return prefixCache[name]; + } + + var elem = document.createElement("div"); + name = camelCase(name); + + if (name in elem.style) { + return prefixCache[name] = ""; + } + + var prefixes = ["Webkit", "Moz", "O", "ms"]; + var styles = ["-webkit-", "-moz-", "-o-", "-ms-"]; + var _name = name.substring(0, 1).toUpperCase() + name.substring(1); + + for (var i = 0, length = prefixes.length; i < length; i++) { + if (prefixes[i] + _name in elem.style) { + return prefixCache[name] = styles[i]; + } + } + + return prefixCache[name] = name in elem.style ? "" : false; +}; + +// identify vendor-prefix for css property value +root.getValueVendorPrefix = function(property, value) { + var elem = document.createElement("div"); + // note: webkit needs the element to be attached to the dom + document.body.appendChild(elem); + var styles = ["-webkit-", "-moz-", "-o-", "-ms-", ""]; + var _property = getVendorPrefix(property) + property; + for (var i=0, length = styles.length; i < length; i++) { + var _value = styles[i] + value; + elem.setAttribute('style', _property + ": " + _value); + var _computed = computedStyle(elem, _property); + if (_computed && _computed !== 'none') { + document.body.removeChild(elem); + return styles[i]; + } + } + document.body.removeChild(elem); + return false; +}; + + +})(window); \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/toc.htm b/tests/wpt/css-tests/css-values-3_dev/html/toc.htm new file mode 100644 index 00000000000..b39ba9aaaf5 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/toc.htm @@ -0,0 +1,69 @@ + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>CSS Values and Units Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> +<body> + <h1>CSS Values and Units Module Level 3 CR Test Suite By Chapter</h1> + + <p>This index contains both + <a href="http://wiki.csswg.org/test/selftest">self-describing tests</a> + and reftests. + A separate <a href="reftest-toc.htm">alphabetical reftest index</a> + is provided for tests in <a href="http://wiki.csswg.org/test/reftest">reftest + format</a> along with the <a href="reftest.list">reftest manifest</a>.</p> + + <table> + <tbody id="s1"> + <tr><th><a href="chapter-1.htm">Chapter 1 - + Introduction</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s2"> + <tr><th><a href="chapter-2.htm">Chapter 2 - + Value Definition Syntax</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s3"> + <tr><th><a href="chapter-3.htm">Chapter 3 - + Textual Data Types</a></th> + <td>(3 Tests)</td></tr> + </tbody> + <tbody id="s4"> + <tr><th><a href="chapter-4.htm">Chapter 4 - + Numeric Data Types</a></th> + <td>(3 Tests)</td></tr> + </tbody> + <tbody id="s5"> + <tr><th><a href="chapter-5.htm">Chapter 5 - + Distance Units: the <length> type</a></th> + <td>(30 Tests)</td></tr> + </tbody> + <tbody id="s6"> + <tr><th><a href="chapter-6.htm">Chapter 6 - + Other Quantities</a></th> + <td>(2 Tests)</td></tr> + </tbody> + <tbody id="s7"> + <tr><th><a href="chapter-7.htm">Chapter 7 - + Data Types Defined Elsewhere</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s8"> + <tr><th><a href="chapter-8.htm">Chapter 8 - + Functional Notations</a></th> + <td>(32 Tests)</td></tr> + </tbody> + <tbody id="s9"> + <tr><th><a href="chapter-9.htm">Chapter 9 - + Appendix A: IANA Considerations</a></th> + <td>(0 Tests)</td></tr> + </tbody> + </table> +</body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/transition-delay-001.htm b/tests/wpt/css-tests/css-values-3_dev/html/transition-delay-001.htm new file mode 100644 index 00000000000..97f97f76c0f --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/transition-delay-001.htm @@ -0,0 +1,106 @@ +<!DOCTYPE html> +<html><head> + <meta charset="utf-8"> + <title>CSS Transitions Test: Parsing transition-delay</title> + <meta content="Test checks that transition-delay values are parsed properly" name="assert"> + <link href="http://www.w3.org/TR/css3-transitions/#transition-delay-property" rel="help" title="2.4. The 'transition-delay' Property"> + <link href="http://www.w3.org/TR/css3-values/#time" rel="help" title="CSS Values and Units Module Level 3 - 6.2. Times: the โ€˜<time>โ€™ type and โ€˜sโ€™, โ€˜msโ€™ units"> + <link href="http://rodneyrehm.de/en/" rel="author" title="Rodney Rehm"> + <meta content="dom" name="flags"> + + <script src="/resources/testharness.js" type="text/javascript"></script> + <script src="/resources/testharnessreport.js" type="text/javascript"></script> + + <script src="./support/vendorPrefix.js" type="text/javascript"></script> + <script src="./support/helper.js" type="text/javascript"></script> + + <script id="metadata_cache">/* + { + "parse '10.2s'": {}, + "parse '1s'": {}, + "parse '0.1s'": {}, + "parse '0.01s'": {}, + "parse '0.001s'": {}, + "parse '0.009s'": {}, + "parse '0s'": {}, + "parse '.0s'": {}, + "parse '0.0s'": {}, + "parse '.3s'": {}, + "parse '-5s'": {}, + "parse '10200ms'": {}, + "parse '1000ms'": {}, + "parse '100ms'": {}, + "parse '10ms'": {}, + "parse '9ms'": {}, + "parse '1ms'": {}, + "parse '0ms'": {}, + "parse '-500ms'": {}, + "parse '1s, 0.1s, 10ms'": {}, + "parse 'foobar'": { "flags": "invalid" } + } + */</script> + </head> + <body> + <!-- required by testharnessreport.js --> + <div id="log"></div> + <!-- elements used for testing --> + <div id="container"> + <div id="transition"></div> + </div> + + <script> + var transition = document.getElementById('transition'); + // <time> [, <time>]* + var values = { + // seconds + '10.2s': '10.2s', + '1s': '1s', + '0.1s': '0.1s', + '0.01s': '0.01s', + '0.001s': '0.001s', + '0.009s': '0.009s', + '0s': '0s', + '0s': '0s', + '.0s': '0s', + '0.0s': '0s', + '.3s': '0.3s', + '-5s' : '-5s', + // milliseconds + '10200ms': '10.2s', + '1000ms': '1s', + '100ms': '0.1s', + '10ms': '0.01s', + '9ms': '0.009s', + '1ms': '0.001s', + '0ms': '0s', + '-500ms' : '-0.5s', + // combination + '1s, 0.1s, 10ms': '1s, 0.1s, 0.01s', + // invalid + 'foobar': '0s' + }; + + // these tests are supposed to fail and + // possibly make the engine issue a parser warning + var invalidTests = { + 'foobar': true + }; + + for (var key in values) { + if (Object.prototype.hasOwnProperty.call(values, key)) { + test(function() { + setStyle('#transition', { + 'transition-delay': key + }); + var result = computedStyle(transition, 'transition-delay'); + assert_equals(result, values[key], "Expected computed value"); + }, "parse '" + key + "'", + { + // mark tests that fail as such + flags: invalidTests[key] ? "invalid" : "" + }); + } + } + </script> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/transition-duration-001.htm b/tests/wpt/css-tests/css-values-3_dev/html/transition-duration-001.htm new file mode 100644 index 00000000000..0769fc2aad3 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/transition-duration-001.htm @@ -0,0 +1,107 @@ +<!DOCTYPE html> +<html><head> + <meta charset="utf-8"> + <title>CSS Transitions Test: Parsing transition-duration</title> + <meta content="Test checks that transition-duration values are parsed properly" name="assert"> + <link href="http://www.w3.org/TR/css3-transitions/#transition-duration-property" rel="help" title="2.2. The 'transition-duration' Property"> + <link href="http://www.w3.org/TR/css3-values/#time" rel="help" title="CSS Values and Units Module Level 3 - 6.2. Times: the โ€˜<time>โ€™ type and โ€˜sโ€™, โ€˜msโ€™ units"> + <link href="http://rodneyrehm.de/en/" rel="author" title="Rodney Rehm"> + <meta content="dom" name="flags"> + + <script src="/resources/testharness.js" type="text/javascript"></script> + <script src="/resources/testharnessreport.js" type="text/javascript"></script> + + <script src="./support/vendorPrefix.js" type="text/javascript"></script> + <script src="./support/helper.js" type="text/javascript"></script> + + <script id="metadata_cache">/* + { + "parse '10.2s'": {}, + "parse '1s'": {}, + "parse '0.1s'": {}, + "parse '0.01s'": {}, + "parse '0.001s'": {}, + "parse '0.009s'": {}, + "parse '0s'": {}, + "parse '.0s'": {}, + "parse '0.0s'": {}, + "parse '.3s'": {}, + "parse '-5s'": { "flags": "invalid" }, + "parse '10200ms'": {}, + "parse '1000ms'": {}, + "parse '100ms'": {}, + "parse '10ms'": {}, + "parse '9ms'": {}, + "parse '1ms'": {}, + "parse '0ms'": {}, + "parse '-500ms'": { "flags": "invalid" }, + "parse '1s, 0.1s, 10ms'": {}, + "parse 'foobar'": { "flags": "invalid" } + } + */</script> + </head> + <body> + <!-- required by testharnessreport.js --> + <div id="log"></div> + <!-- elements used for testing --> + <div id="container"> + <div id="transition"></div> + </div> + + <script> + var transition = document.getElementById('transition'); + // <time> [, <time>]* + var values = { + // seconds + '10.2s': '10.2s', + '1s': '1s', + '0.1s': '0.1s', + '0.01s': '0.01s', + '0.001s': '0.001s', + '0.009s': '0.009s', + '0s': '0s', + '.0s': '0s', + '0.0s': '0s', + '.3s': '0.3s', + '-5s' : '0s', + // milliseconds + '10200ms': '10.2s', + '1000ms': '1s', + '100ms': '0.1s', + '10ms': '0.01s', + '9ms': '0.009s', + '1ms': '0.001s', + '0ms': '0s', + '-500ms' : '0s', + // combination + '1s, 0.1s, 10ms': '1s, 0.1s, 0.01s', + // invalid + 'foobar': '0s' + }; + + // these tests are supposed to fail and + // possibly make the engine issue a parser warning + var invalidTests = { + '-5s': true, + '-500ms': true, + 'foobar': true + }; + + for (var key in values) { + if (Object.prototype.hasOwnProperty.call(values, key)) { + test(function() { + setStyle('#transition', { + 'transition-duration': key + }); + var result = computedStyle(transition, 'transition-duration'); + assert_equals(result, values[key], "Expected computed value"); + }, "parse '" + key + "'", + { + // mark tests that fail as such + flags: invalidTests[key] ? "invalid" : "" + }); + } + } + </script> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/vh-calc-support-pct.htm b/tests/wpt/css-tests/css-values-3_dev/html/vh-calc-support-pct.htm new file mode 100644 index 00000000000..9674ccee7d4 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/vh-calc-support-pct.htm @@ -0,0 +1,36 @@ +<!DOCTYPE html> +<html><head> + + <title> + CSS Values and Units Test: + Viewport units are supported inside calc expressions. + </title> + <meta content=" + Check that viewport units add correctly to percentages in calc() expressions + " name="assert"> + + + <link href="mailto:fremycompany.developer@yahoo.fr" rel="author" title="Fran็ois REMY"> + + <link href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" rel="help"> + <link href="http://www.w3.org/TR/css3-values/#calc" rel="help"> + + <link href="reference/all-green.htm" rel="match"> + + <style type="text/css"> + + html, body { margin: 0px; padding: 0px; } + + html { background: red; } + #target { position: absolute; background: green; width: calc(100vw + 50%); height: calc(100vh + 50%); top: -50%; left: -50%; } + + </style> + +</head> +<body> + + <div id="target"></div> + + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/vh-calc-support.htm b/tests/wpt/css-tests/css-values-3_dev/html/vh-calc-support.htm new file mode 100644 index 00000000000..8f81ff0be5e --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/vh-calc-support.htm @@ -0,0 +1,36 @@ +<!DOCTYPE html> +<html><head> + + <title> + CSS Values and Units Test: + Viewport units are supported inside calc expressions. + </title> + <meta content=" + Check that viewport units add correctly to pixels in calc() expressions + " name="assert"> + + + <link href="mailto:fremycompany.developer@yahoo.fr" rel="author" title="Fran็ois REMY"> + + <link href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" rel="help"> + <link href="http://www.w3.org/TR/css3-values/#calc" rel="help"> + + <link href="reference/all-green.htm" rel="match"> + + <style type="text/css"> + + html, body { margin: 0px; padding: 0px; } + + html { background: red; } + #target { position: absolute; background: green; width: calc(100vw + 50px); height: calc(100vh + 50px); top: -50px; left: -50px; } + + </style> + +</head> +<body> + + <div id="target"></div> + + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/vh-em-inherit.htm b/tests/wpt/css-tests/css-values-3_dev/html/vh-em-inherit.htm new file mode 100644 index 00000000000..d8fba8f3818 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/vh-em-inherit.htm @@ -0,0 +1,34 @@ +<!DOCTYPE html> +<html><head> + + <title> + CSS Values and Units Test: + 0vh and 0vw are correctly treated as 0px + </title> + <meta content=" + 0vh and 0vw are correctly treated as 0px + " name="assert"> + + <link href="mailto:fremycompany.developer@yahoo.fr" rel="author" title="Franรงois REMY"> + + <link href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" rel="help"> + + <link href="reference/all-green.htm" rel="match"> + + <style type="text/css"> + + html, body { margin: 0px; padding: 0px; } + + html { background: red; font-size: 100vw; } + #target { background: green; width: 1rem; height: 1em; font-size: 100vh; } + + </style> + +</head> +<body> + + <div id="target"></div> + + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/vh-inherit.htm b/tests/wpt/css-tests/css-values-3_dev/html/vh-inherit.htm new file mode 100644 index 00000000000..f3013e2045d --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/vh-inherit.htm @@ -0,0 +1,35 @@ +<!DOCTYPE html> +<html><head> + + <title> + CSS Values and Units Test: + Viewport units are inherited properly + </title> + <meta content=" + Viewport units are inherited properly + " name="assert"> + + <link href="mailto:fremycompany.developer@yahoo.fr" rel="author" title="Franรงois REMY"> + + <link href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" rel="help"> + + <link href="reference/all-green.htm" rel="match"> + + <style type="text/css"> + + html, body { margin: 0px; padding: 0px; } + + html { background: red; } + #outer { position: relative; background: green; width: 50vw; height: 100vh; } + #inner { position: absolute; background: green; left: 100%; width: inherit; height: inherit; } + + </style> + +</head> +<body> + + <div id="outer"><div id="inner"></div></div> + + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/vh-interpolate-pct.htm b/tests/wpt/css-tests/css-values-3_dev/html/vh-interpolate-pct.htm new file mode 100644 index 00000000000..ffa688992f5 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/vh-interpolate-pct.htm @@ -0,0 +1,41 @@ +<!DOCTYPE html> +<html><head> + + <title> + CSS Values and Units Test: + Viewport units are interpolated correctly + </title> + <meta content=" + The interpolated size mid-way between 0px and 200vh is 100vh (respectively for vw) + " name="assert"> + + <link href="mailto:fremycompany.developer@yahoo.fr" rel="author" title="Franรงois REMY"> + + <link href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" rel="help"> + <link href="http://www.w3.org/TR/css3-animations/#animations" rel="help"> + + <link href="reference/all-green.htm" rel="match"> + + <style type="text/css"> + + @keyframes anim { + from { width: 0%; height: 0%; } + to { width: 200vw; height: 200vh; } + } + + html, body { margin: 0px; padding: 0px; } + + html { background: red; overflow: hidden; } + #outer { position: relative; background: green; } + #outer { animation: anim 2000000s; animation-delay: -1000000s; } + + </style> + +</head> +<body> + + <div id="outer"></div> + + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/vh-interpolate-px.htm b/tests/wpt/css-tests/css-values-3_dev/html/vh-interpolate-px.htm new file mode 100644 index 00000000000..c59a9f1a143 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/vh-interpolate-px.htm @@ -0,0 +1,41 @@ +<!DOCTYPE html> +<html><head> + + <title> + CSS Values and Units Test: + Viewport units are interpolated correctly + </title> + <meta content=" + The interpolated size mid-way between 0px and 200vh is 100vh (respectively for vw) + " name="assert"> + + <link href="mailto:fremycompany.developer@yahoo.fr" rel="author" title="Franรงois REMY"> + + <link href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" rel="help"> + <link href="http://www.w3.org/TR/css3-animations/#animations" rel="help"> + + <link href="reference/all-green.htm" rel="match"> + + <style type="text/css"> + + @keyframes anim { + from { width: 0px; height: 0px; } + to { width: 200vw; height: 200vh; } + } + + html, body { margin: 0px; padding: 0px; } + + html { background: red; overflow: hidden; } + #outer { position: relative; background: green; } + #outer { animation: anim 2000000s; animation-delay: -1000000s; } + + </style> + +</head> +<body> + + <div id="outer"></div> + + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/vh-interpolate-vh.htm b/tests/wpt/css-tests/css-values-3_dev/html/vh-interpolate-vh.htm new file mode 100644 index 00000000000..f1c00034826 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/vh-interpolate-vh.htm @@ -0,0 +1,41 @@ +<!DOCTYPE html> +<html><head> + + <title> + CSS Values and Units Test: + Viewport units are interpolated correctly + </title> + <meta content=" + The interpolated size mid-way between 75vh and 125vh is 100vh (respectively for vw) + " name="assert"> + + <link href="mailto:fremycompany.developer@yahoo.fr" rel="author" title="Franรงois REMY"> + + <link href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" rel="help"> + <link href="http://www.w3.org/TR/css3-animations/#animations" rel="help"> + + <link href="reference/all-green.htm" rel="match"> + + <style type="text/css"> + + @keyframes anim { + from { width: 75vw; height: 75vh; } + to { width: 125vw; height: 125vh; } + } + + html, body { margin: 0px; padding: 0px; } + + html { background: red; overflow: hidden; } + #outer { position: relative; background: green; } + #outer { animation: anim 2000000s; animation-delay: -1000000s; } + + </style> + +</head> +<body> + + <div id="outer"></div> + + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/vh-support-atviewport.htm b/tests/wpt/css-tests/css-values-3_dev/html/vh-support-atviewport.htm new file mode 100644 index 00000000000..6b02c566294 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/vh-support-atviewport.htm @@ -0,0 +1,37 @@ +<!DOCTYPE html> +<html><head> + + <title> + CSS Values and Units Test: + Viewports units are supported in @viewport rules + </title> + <meta content=" + Viewports units are supported in @viewport rules + " name="assert"> + + <link href="mailto:fremycompany.developer@yahoo.fr" rel="author" title="Fran็ois REMY"> + + <link href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" rel="help"> + <link href="https://drafts.csswg.org/css-device-adapt-1/" rel="help"> + + <link href="reference/all-green.htm" rel="match"> + + <style type="text/css"> + + html, body { margin: 0px; padding: 0px; overflow: hidden; } + + @viewport { width: 1vw; } + + html { background: red; } + #target { background: green; width: 100vw; height: 100vh; } + + </style> + +</head> +<body> + + <div id="target"></div> + + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/vh-support-margin.htm b/tests/wpt/css-tests/css-values-3_dev/html/vh-support-margin.htm new file mode 100644 index 00000000000..01fd05f9e68 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/vh-support-margin.htm @@ -0,0 +1,34 @@ +<!DOCTYPE html> +<html><head> + + <title> + CSS Values and Units Test: + Viewports units are supported in margin properties + </title> + <meta content=" + Viewports units are supported in margin properties + " name="assert"> + + <link href="mailto:fremycompany.developer@yahoo.fr" rel="author" title="Franรงois REMY"> + + <link href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" rel="help"> + + <link href="reference/all-green.htm" rel="match"> + + <style type="text/css"> + + html, body { margin: 0px; padding: 0px; } + + html { background: green; } + #target { background: red; width: 100%; height: 100%; margin-left: -100vw; margin-top: -100vh; } + + </style> + +</head> +<body> + + <div id="target"></div> + + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/vh-support-transform-origin.htm b/tests/wpt/css-tests/css-values-3_dev/html/vh-support-transform-origin.htm new file mode 100644 index 00000000000..d8854e23cbf --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/vh-support-transform-origin.htm @@ -0,0 +1,35 @@ +<!DOCTYPE html> +<html><head> + + <title> + CSS Values and Units Test: + Viewports units are supported in transform properties + </title> + <meta content=" + Viewports units are supported in transform properties + " name="assert"> + + <link href="mailto:fremycompany.developer@yahoo.fr" rel="author" title="Fran็ois REMY"> + + <link href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" rel="help"> + <link href="http://www.w3.org/TR/css3-2d-transforms/#css-values" rel="help"> + + <link href="reference/all-green.htm" rel="match"> + + <style type="text/css"> + + html, body { margin: 0px; padding: 0px; overflow: hidden; } + + html { background: green; } + iframe { width: 400px; height: 400px; margin: 0px; padding: 0px; border: 0px none transparent; } + + </style> + +</head> +<body> + + <iframe src="iframe/vh-support-transform-origin.html"></iframe> + + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/vh-support-transform-translate.htm b/tests/wpt/css-tests/css-values-3_dev/html/vh-support-transform-translate.htm new file mode 100644 index 00000000000..dc6389363af --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/vh-support-transform-translate.htm @@ -0,0 +1,35 @@ +<!DOCTYPE html> +<html><head> + + <title> + CSS Values and Units Test: + Viewports units are supported in transform properties + </title> + <meta content=" + Viewports units are supported in transform properties (translate) + " name="assert"> + + <link href="mailto:fremycompany.developer@yahoo.fr" rel="author" title="Fran็ois REMY"> + + <link href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" rel="help"> + <link href="http://www.w3.org/TR/css3-2d-transforms/#css-values" rel="help"> + + <link href="reference/all-green.htm" rel="match"> + + <style type="text/css"> + + html, body { margin: 0px; padding: 0px; overflow: hidden; } + + html { background: green; } + iframe { width: 400px; height: 400px; margin: 0px; padding: 0px; border: 0px none transparent; } + + </style> + +</head> +<body> + + <iframe src="iframe/vh-support-transform-translate.html"></iframe> + + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/vh-support.htm b/tests/wpt/css-tests/css-values-3_dev/html/vh-support.htm new file mode 100644 index 00000000000..e22a73775c6 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/vh-support.htm @@ -0,0 +1,32 @@ +<!DOCTYPE html> +<html><head> + + <title> + CSS Values and Units Test: + Viewports units are supported in sizing properties + </title> + <meta content=" + Viewports units are supported in sizing properties + " name="assert"> + + <link href="mailto:fremycompany.developer@yahoo.fr" rel="author" title="Franรงois REMY"> + + <link href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" rel="help"> + + <link href="reference/all-green.htm" rel="match"> + + <style type="text/css"> + + html, body { margin: 0px; padding: 0px; } + + #target { background: green; width: 100vw; height: 100vh; } + </style> + +</head> +<body> + + <div id="target"></div> + + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/vh-zero-support.htm b/tests/wpt/css-tests/css-values-3_dev/html/vh-zero-support.htm new file mode 100644 index 00000000000..6fe99d92e8e --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/vh-zero-support.htm @@ -0,0 +1,34 @@ +<!DOCTYPE html> +<html><head> + + <title> + CSS Values and Units Test: + 0vh and 0vw are correctly treated as 0px + </title> + <meta content=" + 0vh and 0vw are correctly treated as 0px + " name="assert"> + + <link href="mailto:fremycompany.developer@yahoo.fr" rel="author" title="Franรงois REMY"> + + <link href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" rel="help"> + + <link href="reference/all-green.htm" rel="match"> + + <style type="text/css"> + + html, body { margin: 0px; padding: 0px; } + + html { background: green; } + #target { background: red; width: 0vw; height: 0vh; } + + </style> + +</head> +<body> + + <div id="target"></div> + + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/vh_not_refreshing_on_chrome.htm b/tests/wpt/css-tests/css-values-3_dev/html/vh_not_refreshing_on_chrome.htm new file mode 100644 index 00000000000..74062a7e744 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/vh_not_refreshing_on_chrome.htm @@ -0,0 +1,52 @@ +<!DOCTYPE html> +<!-- Submitted from TestTWF Paris --><html><head> + <title>CSS Values and Units Test: vh-based dimension doesn't change when the element's other dimension doesn't change.</title> + <link href="mailto:marc@bourlon.com" rel="author" title="Marc Bourlon"> + <link href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" rel="help"> + <link href="reference/vh_not_refreshing_on_chrome-ref.htm" rel="match"> + <meta content="vh-based dimension doesn't change when the element's other dimension doesn't change." name="assert"> + <!-- This test exhibits a bug for Chrome 19.0.1084.56 / Mac OS X 10.6.8 --> + + <style type="text/css"> + + * { margin: 0; padding: 0; font-family: Arial, Helvetica, sans-serif; font-size: 13px; } + + #frameTest { width: 600px; height: 200px; border: 1px solid #000; } + + </style> + + <script type="text/javascript"> + var height = 200; + + function resizeReference() { + + var frameTest = document.getElementById('frameTest'); + + // let's resize the iframe vertically only, showing that the vh sizes is not updated. + if (height <= 300) { + + //frameTest.style.width = height++ + "px"; + frameTest.style.height = height++ + "px"; + + setTimeout(resizeReference, 10); + + } else { + + // uncomment the next line to see how a width resize triggers a layout recalculation + //frameTest.style.width = (parseInt(window.getComputedStyle(document.getElementById('frameTest'))['width'], 10) + 1) + "px"; + + } + + } + + setTimeout(resizeReference, 10); + </script> + +</head> +<body> + +<iframe src="vh_not_refreshing_on_chrome_iframe.html" id="frameTest" frameborder="0"></iframe> + + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/vh_not_refreshing_on_chrome_iframe.htm b/tests/wpt/css-tests/css-values-3_dev/html/vh_not_refreshing_on_chrome_iframe.htm new file mode 100644 index 00000000000..5582282af2f --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/vh_not_refreshing_on_chrome_iframe.htm @@ -0,0 +1,84 @@ +<!DOCTYPE html> +<html><!-- Submitted from TestTWF Paris --><head> + + <title>CSS Values and Units Test: vh-based dimension doesn't change when the element other dimension doesn't change.</title> + <meta content="vh-based dimension doesn't change when the element other dimension doesn't change. Bug for Chrome 19.0.1084.56 / Mac OS X 10.6.8" name="assert"> + <link href="mailto:marc@bourlon.com" rel="author" title="Marc Bourlon"> + <link href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" rel="help" title="5.1.2. Viewport-percentage lengths: the 'vw', 'vh', 'vmin', 'vmax' units"> + <link href="reference/vh_not_refreshing_on_chrome-ref.htm" rel="match"> + + <style type="text/css"> + + * { margin: 0; padding: 0; font-family: Arial, Helvetica, sans-serif; font-size: 13px; } + + /* the first test box has its vertical dimension is set to some vh units */ + #testBoxWithVhOnly { background: #F00; width: 60px; height: 20vh; float: left; } + + /* the second test box, with fixed height */ + #testBoxNotGrownHorizontallyByJS { background: #F0F; width: 20vh; height: 60px; float: left; } + + /* third box, changed by using CSS transition */ + #testBoxWithTransition { background: #FF0; width: 20vh; height: 40px; float: left; + transition-property: width, height; + transition-duration: 1.5s; + transition-delay: 0; + } + + /* the reference box, growing in both directions (height by js, width by vh unit */ + #referenceBoxGrownHorizontallyByJS { background: #0F0; width: 20vh; height: 40px; float: left; } + + p { clear: both; margin: 10px 0; } + + </style> + +</head> +<body> + +<p> + All boxes should end up the same size. The green box is the reference one. +</p> + +<div id="testBoxWithVhOnly"></div> +<div id="testBoxNotGrownHorizontallyByJS"></div> +<div id="testBoxWithTransition"></div> +<div id="referenceBoxGrownHorizontallyByJS"></div> + +<script type="text/javascript"> + + // In case this file was opened by mistake, redirects to proper test + if (window.top.location.href === document.location.href) { + + window.top.location.href = "vh_not_refreshing_on_chrome.html"; + + } + + function setDimension(id, dimension, value) { + + var element = document.getElementById(id); + + element.style[dimension] = value + "px"; + + } + + function animate() { + + var viewportHeight = document.documentElement.clientHeight; + + var sizeH = 20; + + var referenceDimension = Math.round(sizeH * viewportHeight / 100); + + setDimension('referenceBoxGrownHorizontallyByJS', 'height', referenceDimension); + + setTimeout(animate, 20); + } + + setTimeout(animate, 20); + + var transitionedTestBoxStyle = document.getElementById('testBoxWithTransition').style; + transitionedTestBoxStyle.height = "60px"; +</script> + + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/viewport-relative-lengths-scaled-viewport.htm b/tests/wpt/css-tests/css-values-3_dev/html/viewport-relative-lengths-scaled-viewport.htm new file mode 100644 index 00000000000..f4d5a38c7be --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/viewport-relative-lengths-scaled-viewport.htm @@ -0,0 +1,48 @@ +<!DOCTYPE html> +<html><!-- Submitted from TestTWF Paris --><head> + <title>CSS Values and Units Test: Viewport units in scaled viewport</title> + <meta content="viewport relative units scale with viewport." name="assert"> + <link href="mailto:eae@chromium.org" rel="author" title="Emil A Eklund"> + <link href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" rel="help"> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> + <style> + iframe { border: 0; } + </style> + </head> + <body> + <div id="log"></div> + <iframe src="javascript:void(0)" id="testFrame"></iframe> + <script> + test(function() { + var frameElement = document.getElementById('testFrame'); + var frameDocument = frameElement.contentDocument; + + var testElement = frameDocument.createElement('div'); + testElement.style.width = '50vw'; + testElement.style.height = '50vh'; + testElement.style.position = 'absolute'; + testElement.style.left = '0'; + testElement.style.top = '0'; + testElement.style.backgroundColor = 'black'; + frameDocument.body.appendChild(testElement); + + var frameWidth = frameElement.getBoundingClientRect().width; + var frameHeight = frameElement.getBoundingClientRect().height; + for (var i = 1; i <= 200; i++) { + var scale = i / 100; + frameDocument.body.style.transform = 'scale(' + scale + ')'; + var rect = testElement.getBoundingClientRect(); + var actualWidth = rect.width; + var actualHeight = rect.height; + var expectedWidth = frameWidth * scale / 2; + var expectedHeight = frameHeight * scale / 2; + + assert_approx_equals(actualWidth, expectedWidth, 0.1, '50vw at ' + scale + ' scale'); + assert_approx_equals(actualHeight, expectedHeight, 0.1, '50vh at ' + scale + ' scale'); + } + }, 'viewport relative units in scaled viewport'); + </script> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/html/viewport-units-css2-001.htm b/tests/wpt/css-tests/css-values-3_dev/html/viewport-units-css2-001.htm new file mode 100644 index 00000000000..77d862b0685 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/html/viewport-units-css2-001.htm @@ -0,0 +1,255 @@ +<!DOCTYPE html> +<html><head> + + <title> + CSS Values and Units Test: + Checks viewport units against CSS 2.1 properties and the CSSOM + </title> + <meta content="Testing what happens when one applies and rereads viewport unit lengths to CSS 2.1 properties that accept length values" name="assert"> + + <link href="mailto:schaepp@gmx.de" rel="author" title="Christian Schaefer"> + + <!-- You must have at least one spec link, but may have as many as are covered in the test. --> + <!-- Be sure to make the main testing area first in the order --> + <link href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" rel="help"> + + <!-- testharness inclusion for later submission --> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> + + <!-- testharness fallback for local testing --> + <script> + window.test || document.write('\ + <script src="http://www.w3c-test.org/resources/testharness.js"><\/script>\ + <script src="http://www.w3c-test.org/resources/testharnessreport.js"><\/script>\ + '); + </script> + + <style> + + #div { + position: relative; + width: 50vw; + height: 10vw; + background: green; + border: 0 green solid; + font-size: 4vw; + } + + #table td { + border: 1px solid green; + } + + </style> + +</head> +<body> + <div id="log"></div> + + <p> + Checks viewport units. Also re-check with zoom in/out. + </p> + + <div id="div"> + Test the Web Forward! + </div> + + <table id="table"> + <tbody> + <tr> + <td id="td">Test</td> + <td>T</td> + <td>W</td> + <td>F</td> + </tr> + </tbody> + </table> + + <script> + + /* Boilerplate code */ + + var camelize = function (str) { + return str.replace(/\-(\w)/g, function(str, letter){ + return letter.toUpperCase(); + }); + }; + + var retrieveComputedStyle = function(element,property){ + var result = + document + .defaultView + .getComputedStyle(element,null) + .getPropertyValue(property); + + // If there are multiple values, cut down to the first + result = result.split(' ')[0]; + + if(window.console) console.log('Retrieving ' + property + ' property. Result: ' + result); + + return result; + } + + var testit = function(element,vunit,property,expectedResult){ + + element.style[camelize(property)] = '0px'; + element.style[camelize(property)] = lengthAmount + vunit; + + if(window.console) console.log(element.nodeName.toLowerCase() + '.style.' + camelize(property) + ' = ' + lengthAmount + vunit); + + var result = retrieveComputedStyle(element,property); + + // Test against WebKit's getComputedStyle bug, where it does not return absolute values + // As required here: http://www.w3.org/TR/1998/REC-CSS2-19980512/cascade.html#computed-value + // If it returns a pixel value, but this value is 0px then it is considered a fail, too. + var px_result = result.search(/^[-\d\.]+px$/) !== -1 && result !== '0px' ? 'non-zero px-based value' : result; + + // If browser returns pixel value, we compare against our expected pixel value + if(px_result === 'non-zero px-based value'){ + test(function(){ + assert_equals(Math.round(parseFloat(result.replace(/[^-\d\.]+/g,''))),expectedResult); + },vunit + ' length applied to ' + property); + } + // If not, we compare against the value we set initially + else { + test(function(){ + assert_equals(result,lengthAmount + vunit); + },vunit + ' length applied to ' + property); + } + + // Does the browser have a bug in getComputedStyle or not? + test(function(){ + assert_equals(px_result,'non-zero px-based value'); + },vunit + ' length applied to ' + property + ': getComputedStyle returns a non-zero px-based value'); + + element.style[camelize(property)] = ''; + } + + var lengthAmount = 10; + var layoutViewportWidth = document.documentElement.clientWidth; + var layoutViewportHeight = document.documentElement.clientHeight; + + var viewportUnits = [ + { + ident: 'vw', + expectedResult: Math.round(layoutViewportWidth * (lengthAmount / 100)) + } + ,{ + ident: 'vh', + expectedResult: Math.round(layoutViewportHeight * (lengthAmount / 100)) + } + ,{ + ident: 'vmin', + expectedResult: layoutViewportWidth < layoutViewportHeight ? Math.round(layoutViewportWidth * (lengthAmount / 100)) : Math.round(layoutViewportHeight * (lengthAmount / 100)) + } + ,{ + ident: 'vmax', + expectedResult: layoutViewportWidth > layoutViewportHeight ? Math.round(layoutViewportWidth * (lengthAmount / 100)) : Math.round(layoutViewportHeight * (lengthAmount / 100)) + } + ] + + // List of length accepting properties and which element they map to + // http://www.w3.org/TR/CSS21/propidx.html + var lengthAcceptingProperties = [ + { + name: 'width', + element: 'div' + } + ,{ + name: 'height', + element: 'div' + } + ,{ + name: 'min-width', + element: 'div' + } + ,{ + name: 'min-height', + element: 'div' + } + ,{ + name: 'max-width', + element: 'div' + } + ,{ + name: 'max-height', + element: 'div' + } + ,{ + name: 'margin-top', + element: 'div' + } + ,{ + name: 'padding-top', + element: 'div' + } + ,{ + name: 'border-top-width', + element: 'div' + } + ,{ + name: 'font-size', + element: 'div' + } + ,{ + name: 'line-height', + element: 'div' + } + ,{ + name: 'border-spacing', + element: 'table' + } + ,{ + name: 'top', + element: 'div' + } + ,{ + name: 'right', + element: 'div' + } + ,{ + name: 'bottom', + element: 'div' + } + ,{ + name: 'left', + element: 'div' + } + ,{ + name: 'letter-spacing', + element: 'div' + } + ,{ + name: 'text-indent', + element: 'div' + } + ,{ + name: 'vertical-align', + element: 'td' + } + ,{ + name: 'word-spacing', + element: 'div' + } + ]; + + var div = document.getElementById('div'); + var table = document.getElementById('table'); + var td = document.getElementById('td'); + + for(unitEntry in viewportUnits){ + for(propertyEntry in lengthAcceptingProperties){ + + var vunit = viewportUnits[unitEntry].ident; + var expectedResult = viewportUnits[unitEntry].expectedResult; + var property = lengthAcceptingProperties[propertyEntry].name; + var element = window[lengthAcceptingProperties[propertyEntry].element]; + + testit(element,vunit,property,expectedResult); + } + } + + </script> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/implementation-report-TEMPLATE.data b/tests/wpt/css-tests/css-values-3_dev/implementation-report-TEMPLATE.data new file mode 100644 index 00000000000..c9d0da374db --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/implementation-report-TEMPLATE.data @@ -0,0 +1,143 @@ +# UA version OS version +# UA string (if applicable) +# http://test.csswg.org/suites/css-values-3_dev/DATESTAMP/ +# See http://wiki.csswg.org/test/implementation-report for instructions +testname revision result comment +html/absolute_length_units.htm 1e0e4f150942320da5e8bab9f573add223fe72f7 ? +xhtml1/absolute_length_units.xht 1e0e4f150942320da5e8bab9f573add223fe72f7 ? +html/calc-background-image-gradient-1.htm 4908626b6c3bd6da5d47ec5ee366e0c06d8cae50 ? +xhtml1/calc-background-image-gradient-1.xht 4908626b6c3bd6da5d47ec5ee366e0c06d8cae50 ? +html/calc-background-linear-gradient-1.htm 89f5dc390231b59bc044bde93bb4cc3133002df6 ? +xhtml1/calc-background-linear-gradient-1.xht 89f5dc390231b59bc044bde93bb4cc3133002df6 ? +html/calc-background-position-1.htm d5a0d6858f4cc7d245898f066606204e559e4b50 ? +xhtml1/calc-background-position-1.xht d5a0d6858f4cc7d245898f066606204e559e4b50 ? +html/calc-background-size-1.htm 72065683ace08d6b2a82f035a634c801d1321761 ? +xhtml1/calc-background-size-1.xht 72065683ace08d6b2a82f035a634c801d1321761 ? +html/calc-border-radius-1.htm 9d9eeb4f1aeff36e108f038dffcd9cbe19044b9f ? +xhtml1/calc-border-radius-1.xht 9d9eeb4f1aeff36e108f038dffcd9cbe19044b9f ? +html/calc-height-block-1.htm 952526a2250e62df4cd71c656df40c8e1583d802 ? +xhtml1/calc-height-block-1.xht 952526a2250e62df4cd71c656df40c8e1583d802 ? +html/calc-height-table-1.htm aaa87fc375b1f80271853d2c80fa30e6e7953c05 ? +xhtml1/calc-height-table-1.xht aaa87fc375b1f80271853d2c80fa30e6e7953c05 ? +html/calc-margin-block-1.htm 1d7889b64fd00e87e2b2961c5e42e6af8577ae5a ? +xhtml1/calc-margin-block-1.xht 1d7889b64fd00e87e2b2961c5e42e6af8577ae5a ? +html/calc-max-height-block-1.htm f59e64c55e4610b5e23a0cf99f646f657d0ae58f ? +xhtml1/calc-max-height-block-1.xht f59e64c55e4610b5e23a0cf99f646f657d0ae58f ? +html/calc-max-width-block-1.htm 0c2e3de995e9b8644479cb9b6154c268268df2bf ? +xhtml1/calc-max-width-block-1.xht 0c2e3de995e9b8644479cb9b6154c268268df2bf ? +html/calc-max-width-block-intrinsic-1.htm 1ac22229d3c2872e7079e6c9dadf5da282e427d7 ? +xhtml1/calc-max-width-block-intrinsic-1.xht 1ac22229d3c2872e7079e6c9dadf5da282e427d7 ? +html/calc-min-height-block-1.htm 0cddf80f07465e7d498399857bfea48d665aaaf9 ? +xhtml1/calc-min-height-block-1.xht 0cddf80f07465e7d498399857bfea48d665aaaf9 ? +html/calc-min-width-block-1.htm a08959fa9123b0ce0f6a0062fff8fc48b9d64f3d ? +xhtml1/calc-min-width-block-1.xht a08959fa9123b0ce0f6a0062fff8fc48b9d64f3d ? +html/calc-min-width-block-intrinsic-1.htm 087f81b5bb656bd7a99e965460e61b51b6c66cfa ? +xhtml1/calc-min-width-block-intrinsic-1.xht 087f81b5bb656bd7a99e965460e61b51b6c66cfa ? +html/calc-offsets-absolute-bottom-1.htm c8f2101c65c8efcb87041d69c39598e77db38bd7 ? +xhtml1/calc-offsets-absolute-bottom-1.xht c8f2101c65c8efcb87041d69c39598e77db38bd7 ? +html/calc-offsets-absolute-left-1.htm 76226a8db09005107647baa10a26243e78a6db40 ? +xhtml1/calc-offsets-absolute-left-1.xht 76226a8db09005107647baa10a26243e78a6db40 ? +html/calc-offsets-absolute-right-1.htm 1837995bd1aba09200a1a25620041e3a7333b737 ? +xhtml1/calc-offsets-absolute-right-1.xht 1837995bd1aba09200a1a25620041e3a7333b737 ? +html/calc-offsets-absolute-top-1.htm 11e4d218e2e4de8cb88a6890bb4151bec7fc9836 ? +xhtml1/calc-offsets-absolute-top-1.xht 11e4d218e2e4de8cb88a6890bb4151bec7fc9836 ? +html/calc-offsets-relative-bottom-1.htm d36f93e3013eb49e98cb89805d1ec16daee6d298 ? +xhtml1/calc-offsets-relative-bottom-1.xht d36f93e3013eb49e98cb89805d1ec16daee6d298 ? +html/calc-offsets-relative-left-1.htm 0b6c6289836923bc87523367eda6d58c79048a8c ? +xhtml1/calc-offsets-relative-left-1.xht 0b6c6289836923bc87523367eda6d58c79048a8c ? +html/calc-offsets-relative-right-1.htm e7e22c4c64b97f993430cfae81fa9a40b007df5b ? +xhtml1/calc-offsets-relative-right-1.xht e7e22c4c64b97f993430cfae81fa9a40b007df5b ? +html/calc-offsets-relative-top-1.htm 138f42115aa281eabba1eb4ea3b327d917c05e83 ? +xhtml1/calc-offsets-relative-top-1.xht 138f42115aa281eabba1eb4ea3b327d917c05e83 ? +html/calc-padding-block-1.htm 0a6fcb06af632bc921b8fdcf6e84dc9632747d0d ? +xhtml1/calc-padding-block-1.xht 0a6fcb06af632bc921b8fdcf6e84dc9632747d0d ? +html/calc-text-indent-1.htm 4791e504f1036b2c117a842014409132ffc0f8e0 ? +xhtml1/calc-text-indent-1.xht 4791e504f1036b2c117a842014409132ffc0f8e0 ? +html/calc-text-indent-intrinsic-1.htm 212d0b36c668eb0ce4b8fbffb7ddc91faac7ef10 ? +xhtml1/calc-text-indent-intrinsic-1.xht 212d0b36c668eb0ce4b8fbffb7ddc91faac7ef10 ? +html/calc-transform-origin-1.htm 37759c591badf6155fa5f3721d6feeabe9e4b606 ? +xhtml1/calc-transform-origin-1.xht 37759c591badf6155fa5f3721d6feeabe9e4b606 ? +html/calc-unit-analysis.htm 6a5b9ea86f959202db5065d15b347b024a552480 ? +xhtml1/calc-unit-analysis.xht 6a5b9ea86f959202db5065d15b347b024a552480 ? +html/calc-vertical-align-1.htm 7b2b5dac7448097556b6233f426eea822c27c4fd ? +xhtml1/calc-vertical-align-1.xht 7b2b5dac7448097556b6233f426eea822c27c4fd ? +html/calc-width-block-1.htm a204cfddfb32046b292b2c79abd546adb526570f ? +xhtml1/calc-width-block-1.xht a204cfddfb32046b292b2c79abd546adb526570f ? +html/calc-width-block-intrinsic-1.htm f85e6251038f10b07736dc3d3ff547da3401b43d ? +xhtml1/calc-width-block-intrinsic-1.xht f85e6251038f10b07736dc3d3ff547da3401b43d ? +html/calc-width-table-auto-1.htm b75533977bfccbdb094aefcc277e95f28710f507 ? +xhtml1/calc-width-table-auto-1.xht b75533977bfccbdb094aefcc277e95f28710f507 ? +html/calc-width-table-fixed-1.htm b16a53e8a8072b68c6bd91790cc982cccbcf2bc6 ? +xhtml1/calc-width-table-fixed-1.xht b16a53e8a8072b68c6bd91790cc982cccbcf2bc6 ? +html/ch-unit-001.htm 4c390e4f1e8b24beaa0520c61466cd43e87a62c8 ? +xhtml1/ch-unit-001.xht 4c390e4f1e8b24beaa0520c61466cd43e87a62c8 ? +html/min-width-001.htm edff68d05ca48525e5456d924b43578c8dfdbf57 ? +xhtml1/min-width-001.xht edff68d05ca48525e5456d924b43578c8dfdbf57 ? +html/multicol-count-non-integer-001.htm 6ebfd7a8bb7081898fed146d154ff0c1119f05e1 ? +xhtml1/multicol-count-non-integer-001.xht 6ebfd7a8bb7081898fed146d154ff0c1119f05e1 ? +html/multicol-count-non-integer-002.htm ed064290bd392497aad5107e30a9e336532a4d31 ? +xhtml1/multicol-count-non-integer-002.xht ed064290bd392497aad5107e30a9e336532a4d31 ? +html/multicol-count-non-integer-003.htm d6173aac65acc056fcc61b00944e06e7f30f70e9 ? +xhtml1/multicol-count-non-integer-003.xht d6173aac65acc056fcc61b00944e06e7f30f70e9 ? +html/multicol-inherit-002.htm 2d1165aded078402115fc317a47ae6856bed77a6 ? +xhtml1/multicol-inherit-002.xht 2d1165aded078402115fc317a47ae6856bed77a6 ? +html/multicol-rule-color-inherit-001.htm ccebd3df8a5aa4b32dad211082f45f677c8a61c5 ? +xhtml1/multicol-rule-color-inherit-001.xht ccebd3df8a5aa4b32dad211082f45f677c8a61c5 ? +html/multicol-rule-color-inherit-002.htm 5df59c878149324b852064274b30ee0782181442 ? +xhtml1/multicol-rule-color-inherit-002.xht 5df59c878149324b852064274b30ee0782181442 ? +html/regions-resizing-003.htm e27649199c4544ad34ad206d2ea195c184cebeb2 ? +xhtml1/regions-resizing-003.xht e27649199c4544ad34ad206d2ea195c184cebeb2 ? +html/regions-resizing-007.htm 4eabcff5cdeb95b084b8f6fe2fa1bf4bbbc0f889 ? +xhtml1/regions-resizing-007.xht 4eabcff5cdeb95b084b8f6fe2fa1bf4bbbc0f889 ? +html/regions-resizing-009.htm 4a1d7ae83ef004c6c097fecd07b21c7c7c368f8e ? +xhtml1/regions-resizing-009.xht 4a1d7ae83ef004c6c097fecd07b21c7c7c368f8e ? +html/shape-outside-circle-002.htm 8a1c43c953fe3b82edd77025bbf55b77475c59f0 ? +xhtml1/shape-outside-circle-002.xht 8a1c43c953fe3b82edd77025bbf55b77475c59f0 ? +html/shape-outside-circle-004.htm 44092ed692b65149dd5593c1aecce3f4d3352600 ? +xhtml1/shape-outside-circle-004.xht 44092ed692b65149dd5593c1aecce3f4d3352600 ? +html/shape-outside-ellipse-002.htm e069870229afea5bc6dbf4b6768c847230aafc09 ? +xhtml1/shape-outside-ellipse-002.xht e069870229afea5bc6dbf4b6768c847230aafc09 ? +html/shape-outside-ellipse-004.htm cf7a179b06597950e51c08580c0bcc5d7476e1c1 ? +xhtml1/shape-outside-ellipse-004.xht cf7a179b06597950e51c08580c0bcc5d7476e1c1 ? +html/shape-outside-inset-003.htm a28821639a481807aba32477b3ad98a7bec40b41 ? +xhtml1/shape-outside-inset-003.xht a28821639a481807aba32477b3ad98a7bec40b41 ? +html/shape-outside-polygon-004.htm e4bb8c0597a4b08fe5d5e94f83f94e7adf0dfb90 ? +xhtml1/shape-outside-polygon-004.xht e4bb8c0597a4b08fe5d5e94f83f94e7adf0dfb90 ? +html/transition-delay-001.htm 936ec60d74c61f54ba71930eafbd8db9c5e84e82 ? +xhtml1/transition-delay-001.xht 936ec60d74c61f54ba71930eafbd8db9c5e84e82 ? +html/transition-duration-001.htm 663439e329a5e15084fda9eb5be1ac7d2e0dc5f7 ? +xhtml1/transition-duration-001.xht 663439e329a5e15084fda9eb5be1ac7d2e0dc5f7 ? +html/vh-calc-support-pct.htm 094f5381d9f411a374844075893597b78fb15b46 ? +xhtml1/vh-calc-support-pct.xht 094f5381d9f411a374844075893597b78fb15b46 ? +html/vh-calc-support.htm 92ae3e98da13a95fdcd08517692d0ee79a39810b ? +xhtml1/vh-calc-support.xht 92ae3e98da13a95fdcd08517692d0ee79a39810b ? +html/vh-em-inherit.htm bd54e3e097d1f4b5799a696bfffeebf5561c072f ? +xhtml1/vh-em-inherit.xht bd54e3e097d1f4b5799a696bfffeebf5561c072f ? +html/vh-inherit.htm e006cf0e4f727a753c115bb062ed9aa3854375b0 ? +xhtml1/vh-inherit.xht e006cf0e4f727a753c115bb062ed9aa3854375b0 ? +html/vh-interpolate-pct.htm e263245c653c76da4ebf1afd5463deb31d27e365 ? +xhtml1/vh-interpolate-pct.xht e263245c653c76da4ebf1afd5463deb31d27e365 ? +html/vh-interpolate-px.htm fa83d5d77411f3c93cf7e465552f47494bfe9d7a ? +xhtml1/vh-interpolate-px.xht fa83d5d77411f3c93cf7e465552f47494bfe9d7a ? +html/vh-interpolate-vh.htm 0e224532385323bb9061d9b18c1def8c330ad6ae ? +xhtml1/vh-interpolate-vh.xht 0e224532385323bb9061d9b18c1def8c330ad6ae ? +html/vh-support-atviewport.htm 7cc8bb8f1cde2aecece15e72882e45b67bfc4bdd ? +xhtml1/vh-support-atviewport.xht 7cc8bb8f1cde2aecece15e72882e45b67bfc4bdd ? +html/vh-support-margin.htm f951f1c99e3a6be4134265b4da05aabbd71eb103 ? +xhtml1/vh-support-margin.xht f951f1c99e3a6be4134265b4da05aabbd71eb103 ? +html/vh-support-transform-origin.htm 8dee0773fb5519b06d225ea643bb562db431f97c ? +xhtml1/vh-support-transform-origin.xht 8dee0773fb5519b06d225ea643bb562db431f97c ? +html/vh-support-transform-translate.htm 8ce0374dbb32ab1c6b2a3590856748be6b92fb91 ? +xhtml1/vh-support-transform-translate.xht 8ce0374dbb32ab1c6b2a3590856748be6b92fb91 ? +html/vh-support.htm 13609543ab6880c4f4fa00168fe8c6d48abf0270 ? +xhtml1/vh-support.xht 13609543ab6880c4f4fa00168fe8c6d48abf0270 ? +html/vh-zero-support.htm 8cb13e6d29fba8a619119a85d745dd3e87156c22 ? +xhtml1/vh-zero-support.xht 8cb13e6d29fba8a619119a85d745dd3e87156c22 ? +html/vh_not_refreshing_on_chrome.htm a27560454ad4d3e11996f4a3a9ed7d66f4b639b8 ? +xhtml1/vh_not_refreshing_on_chrome.xht a27560454ad4d3e11996f4a3a9ed7d66f4b639b8 ? +html/vh_not_refreshing_on_chrome_iframe.htm 8d080a2350a0e8e006e0141407e6a2c804027986 ? +xhtml1/vh_not_refreshing_on_chrome_iframe.xht 8d080a2350a0e8e006e0141407e6a2c804027986 ? +html/viewport-relative-lengths-scaled-viewport.htm 34183e6c538e9e431ef5cd0cb5d6834a911f3b8f ? +xhtml1/viewport-relative-lengths-scaled-viewport.xht 34183e6c538e9e431ef5cd0cb5d6834a911f3b8f ? +html/viewport-units-css2-001.htm 0765a1e0ba205be0f26ff35a8683c6e91f2c43a7 ? +xhtml1/viewport-units-css2-001.xht 0765a1e0ba205be0f26ff35a8683c6e91f2c43a7 ? diff --git a/tests/wpt/css-tests/css-values-3_dev/index.htm b/tests/wpt/css-tests/css-values-3_dev/index.htm new file mode 100644 index 00000000000..e845ed34d9e --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/index.htm @@ -0,0 +1,147 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html lang="en"> + <head> + <title>CSS Values and Units Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "indices.css"; + </style> + </head> + <body> + + + <h1>CSS Values and Units Module Level 3 CR Test Suite</h1> + <dt>Test Coordinator:</dt> + <dd>None Yet</dd> + + <p>This is a <strong>Development</strong> + version of the CSS Values and Units Module Level 3 CR Test Suite.</p> + + <p>You can provide test data or review the testing results for this test suite:</p> + <dt><a href="http://test.csswg.org/harness/suite/css-values-3_dev">Enter Data</a></dt> + <dt><a href="http://test.csswg.org/harness/review/css-values-3_dev">Review Results</a></dt> + + + <p>Some tests in the test suite may contain errors. + Please check the latest version of the + <a href="http://www.w3.org/TR/css3-values/">CSS Values 3 specification</a> + <strong>and its errata</strong> + before assuming a failure is due to an implementation bug and + not a test suite bug.</p> + + + <p> + In time we hope to correct all errors and extend this test suite to + cover all of CSS Values 3. Your help is welcome in this effort. + The appropriate mailing list for submitting tests and bug reports is + <a href="http://lists.w3.org/Archives/Public/public-css-testsuite/">public-css-testsuite@w3.org</a>. + More information on the contribution process and test guidelines is + available on the <a href="http://wiki.csswg.org/test">wiki + page</a>.</p> + + <p>Tests are currently available in these formats:</p> + + <dl> + <dt><a href="html/toc.htm">HTML 5</a></dt> + <dd>HTML 5 tests sent as <code>text/html</code></dd> + <dt><a href="xhtml1/toc.xht">XHTML 1.1</a></dt> + <dd>XHTML 1.1 tests sent as <code>application/xhtml+xml</code></dd> + + + <p>Unless the test instructions explicitly indicate otherwise, + any occurrence of red in a test indicates test failure.</p> + +<h2 id="implement">Implementation Reports</h2> + <p>An <a href="implementation-report-TEMPLATE.data">implementation report template</a> + is available to help with creating implementation reports. See also the + <a href="http://lists.w3.org/Archives/Public/public-css-testsuite/2010Aug/0020.html">explanation</a> + of its format.</p> + +<h2 id="common">Common Assumptions</h2> + + <p>Most of the test suite makes the following assumptions:</p> + <ul> + <li>The X/HTML <code>div</code> element is assigned <code>display: block;</code> + and no other property declaration.</li> + <li>The X/HTML <code>span</code> element is assigned <code>display: inline;</code> + and no other property declaration.</li> + <li>The X/HTML <code>p</code> element is assigned <code>display: block;</code></li> + <li>The X/HTML <code>li</code> element is assigned <code>display: list-item;</code></li> + <li>The X/HTML table elements <code>table</code>, <code>tbody</code>, + <code>tr</code>, and <code>td</code> are assigned the <code>display</code> + values <code>table</code>, <code>table-row-group</code>, + <code>table-row</code>, and <code>table-cell</code>, respectively.</li> + <li>The device can display the sixteen color values associated with the color + keywords <code>black</code>, <code>white</code>, <code>gray</code>, + <code>silver</code>, <code>red</code>, <code>green</code>, <code>blue</code>, + <code>purple</code>, <code>yellow</code>, <code>orange</code>, <code>teal</code>, + <code>fuchsia</code>, <code>maroon</code>, <code>navy</code>, <code>aqua</code>, + and <code>lime</code> as distinct colors.</li> + <li>The UA is set to print background colors and, if it supports graphics, + background images.</li> + <li>The UA implements reasonable page-breaking behavior; e.g., it is assumed + that UAs will not break at every opportunity, but only near the end of + a page unless a page break is forced.</li> + <li>The UA implements reasonable line-breaking behavior; e.g., it is assumed + that spaces between alphanumeric characters provide line breaking + opportunities and that UAs will not break at every opportunity, but only + near the end of a line unless a line break is forced.</li> + </ul> + +<h2 id="uncommon">Uncommon Assumptions</h2> + + <p>In addition, some of the tests make one or more of the following + assumptions:</p> + + <ul> + <li>The device is a full-color device.</li> + <li>The device has a viewport width of at least 640px (approx).</li> + <li>The resolution of the device is 96 CSS pixels per inch.</li> + <li>The UA imposes no minimum font size.</li> + <li>The 'medium' font-size computes to 16px.</li> + <li>The initial value of 'color' is black.</li> + <li>The canvas background is white.</li> + <li>The user stylesheet is empty (except where indicated by the tests).</li> + <li>The device is interactive and uses scroll bars.</li> + </ul> + + <p>The tests that need these assumptions to be true have not yet been + marked, but it is likely that we will add a way to identify these + tests in due course. Tests should avoid relying on these assumptions + unless necessary.</p> + +<h2>License</h2> + + <p>This test suite is licensed under both the + <a href="http://www.w3.org/Consortium/Legal/2008/04-testsuite-license">W3C + Test Suite License</a> and the <a href="http://www.w3.org/Consortium/Legal/2008/03-bsd-license">W3C + 3-clause BSD License</a>. See W3C Legal's <a href="http://www.w3.org/Consortium/Legal/2008/04-testsuite-copyright">explanation + of the licenses</a>.</p> + +<h2>Acknowledgements</h2> + + <p>Many thanks to the following for their contributions:</p> + <ul> + <li>Adobe</li> + <li>Bear Travis</li> + <li>Chris Rebert</li> + <li>Christian Schaefer</li> + <li>Emil A Eklund</li> + <li>Florian Rivoal</li> + <li>Fran&Atilde;&sect;ois REMY</li> + <li>Fran&ccedil;ois REMY</li> + <li>G&eacute;rard Talbot</li> + <li>L. David Baron</li> + <li>Marc Bourlon</li> + <li>Mihai Balan</li> + <li>Mozilla Corporation</li> + <li>Opera Software ASA</li> + <li>Rebecca Hauck</li> + <li>Rodney Rehm</li> + <li>Yu-Sian (Thomasy) Liu</li> + </ul> + +</body> +</html> diff --git a/tests/wpt/css-tests/css-values-3_dev/index.xht b/tests/wpt/css-tests/css-values-3_dev/index.xht new file mode 100644 index 00000000000..e410c2c4d4b --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/index.xht @@ -0,0 +1,147 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> + <head> + <title>CSS Values and Units Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "indices.css"; + </style> + </head> + <body> + + + <h1>CSS Values and Units Module Level 3 CR Test Suite</h1> + <dt>Test Coordinator:</dt> + <dd>None Yet</dd> + + <p>This is a <strong>Development</strong> + version of the CSS Values and Units Module Level 3 CR Test Suite.</p> + + <p>You can provide test data or review the testing results for this test suite:</p> + <dt><a href="http://test.csswg.org/harness/suite/css-values-3_dev">Enter Data</a></dt> + <dt><a href="http://test.csswg.org/harness/review/css-values-3_dev">Review Results</a></dt> + + + <p>Some tests in the test suite may contain errors. + Please check the latest version of the + <a href="http://www.w3.org/TR/css3-values/">CSS Values 3 specification</a> + <strong>and its errata</strong> + before assuming a failure is due to an implementation bug and + not a test suite bug.</p> + + + <p> + In time we hope to correct all errors and extend this test suite to + cover all of CSS Values 3. Your help is welcome in this effort. + The appropriate mailing list for submitting tests and bug reports is + <a href="http://lists.w3.org/Archives/Public/public-css-testsuite/">public-css-testsuite@w3.org</a>. + More information on the contribution process and test guidelines is + available on the <a href="http://wiki.csswg.org/test">wiki + page</a>.</p> + + <p>Tests are currently available in these formats:</p> + + <dl> + <dt><a href="html/toc.htm">HTML 5</a></dt> + <dd>HTML 5 tests sent as <code>text/html</code></dd> + <dt><a href="xhtml1/toc.xht">XHTML 1.1</a></dt> + <dd>XHTML 1.1 tests sent as <code>application/xhtml+xml</code></dd> + + + <p>Unless the test instructions explicitly indicate otherwise, + any occurrence of red in a test indicates test failure.</p> + +<h2 id="implement">Implementation Reports</h2> + <p>An <a href="implementation-report-TEMPLATE.data">implementation report template</a> + is available to help with creating implementation reports. See also the + <a href="http://lists.w3.org/Archives/Public/public-css-testsuite/2010Aug/0020.html">explanation</a> + of its format.</p> + +<h2 id="common">Common Assumptions</h2> + + <p>Most of the test suite makes the following assumptions:</p> + <ul> + <li>The X/HTML <code>div</code> element is assigned <code>display: block;</code> + and no other property declaration.</li> + <li>The X/HTML <code>span</code> element is assigned <code>display: inline;</code> + and no other property declaration.</li> + <li>The X/HTML <code>p</code> element is assigned <code>display: block;</code></li> + <li>The X/HTML <code>li</code> element is assigned <code>display: list-item;</code></li> + <li>The X/HTML table elements <code>table</code>, <code>tbody</code>, + <code>tr</code>, and <code>td</code> are assigned the <code>display</code> + values <code>table</code>, <code>table-row-group</code>, + <code>table-row</code>, and <code>table-cell</code>, respectively.</li> + <li>The device can display the sixteen color values associated with the color + keywords <code>black</code>, <code>white</code>, <code>gray</code>, + <code>silver</code>, <code>red</code>, <code>green</code>, <code>blue</code>, + <code>purple</code>, <code>yellow</code>, <code>orange</code>, <code>teal</code>, + <code>fuchsia</code>, <code>maroon</code>, <code>navy</code>, <code>aqua</code>, + and <code>lime</code> as distinct colors.</li> + <li>The UA is set to print background colors and, if it supports graphics, + background images.</li> + <li>The UA implements reasonable page-breaking behavior; e.g., it is assumed + that UAs will not break at every opportunity, but only near the end of + a page unless a page break is forced.</li> + <li>The UA implements reasonable line-breaking behavior; e.g., it is assumed + that spaces between alphanumeric characters provide line breaking + opportunities and that UAs will not break at every opportunity, but only + near the end of a line unless a line break is forced.</li> + </ul> + +<h2 id="uncommon">Uncommon Assumptions</h2> + + <p>In addition, some of the tests make one or more of the following + assumptions:</p> + + <ul> + <li>The device is a full-color device.</li> + <li>The device has a viewport width of at least 640px (approx).</li> + <li>The resolution of the device is 96 CSS pixels per inch.</li> + <li>The UA imposes no minimum font size.</li> + <li>The 'medium' font-size computes to 16px.</li> + <li>The initial value of 'color' is black.</li> + <li>The canvas background is white.</li> + <li>The user stylesheet is empty (except where indicated by the tests).</li> + <li>The device is interactive and uses scroll bars.</li> + </ul> + + <p>The tests that need these assumptions to be true have not yet been + marked, but it is likely that we will add a way to identify these + tests in due course. Tests should avoid relying on these assumptions + unless necessary.</p> + +<h2>License</h2> + + <p>This test suite is licensed under both the + <a href="http://www.w3.org/Consortium/Legal/2008/04-testsuite-license">W3C + Test Suite License</a> and the <a href="http://www.w3.org/Consortium/Legal/2008/03-bsd-license">W3C + 3-clause BSD License</a>. See W3C Legal's <a href="http://www.w3.org/Consortium/Legal/2008/04-testsuite-copyright">explanation + of the licenses</a>.</p> + +<h2>Acknowledgements</h2> + + <p>Many thanks to the following for their contributions:</p> + <ul> + <li>Adobe</li> + <li>Bear Travis</li> + <li>Chris Rebert</li> + <li>Christian Schaefer</li> + <li>Emil A Eklund</li> + <li>Florian Rivoal</li> + <li>Fran&Atilde;&sect;ois REMY</li> + <li>Fran&ccedil;ois REMY</li> + <li>G&eacute;rard Talbot</li> + <li>L. David Baron</li> + <li>Marc Bourlon</li> + <li>Mihai Balan</li> + <li>Mozilla Corporation</li> + <li>Opera Software ASA</li> + <li>Rebecca Hauck</li> + <li>Rodney Rehm</li> + <li>Yu-Sian (Thomasy) Liu</li> + </ul> + +</body> +</html> diff --git a/tests/wpt/css-tests/css-values-3_dev/indices.css b/tests/wpt/css-tests/css-values-3_dev/indices.css new file mode 100644 index 00000000000..7bc70eeef94 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/indices.css @@ -0,0 +1,96 @@ +/* CSS for CSS Conformance Test Indices */ +/* Written by fantasai */ + +/* Test Tables */ + + table { + border-collapse: collapse; + } + + thead { + border-bottom: 0.2em solid; + } + + tbody { + border: thin solid; + border-style: solid none; + } + + tbody.ch { + border-top: 0.2em solid; + } + tbody.ch th { + font-weight: bold; + } + + tbody th { + border-bottom: silver dotted thin; + background: #EEE; + color: black; + font-weight: normal; + font-style: italic; + } + tbody th :link { + color: gray; + background: transparent; + } + tbody th :visited { + color: #333; + background: transparent; + } + + th, td { + padding: 0.2em; + text-align: left; + vertical-align: baseline; + } + + td { + font-size: 0.9em; + } + + /* flags */ + td abbr { + border: solid thin gray; + padding: 0 0.1em; + cursor: help; + } + td abbr:hover { + background: #ffa; + color: black; + } + + + tr:hover { + background: #F9F9F9; + color: navy; + } + + th a, + td a { + text-decoration: none; + } + th a:hover, + td a:hover, + th a:focus, + td a:focus { + text-decoration: underline; + } + + td a { + display: block; + padding-left: 2em; + text-indent: -1em; + } + .refs { + font-weight: bold; + font-size: larger; + } + .assert, .assert > li { + list-style-type: none; + font-style: italic; + color: gray; + margin: 0; + padding: 0; + text-indent: 0; + } diff --git a/tests/wpt/css-tests/css-values-3_dev/testinfo.data b/tests/wpt/css-tests/css-values-3_dev/testinfo.data new file mode 100644 index 00000000000..2c3c552e689 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/testinfo.data @@ -0,0 +1,70 @@ +id references title flags links revision credits assertion +absolute_length_units elements should be the real world size given in mm, cm, inches... http://www.w3.org/TR/css3-values/#viewport-relative-lengths 1e0e4f150942320da5e8bab9f573add223fe72f7 `Marc Bourlon`<mailto:marc@bourlon.com> elements are not displayed with the real world size units they should be, when specified in millimeters, centimeters, inches, ... +calc-background-image-gradient-1 reference/calc-background-image-gradient-1-ref Test for calc() on background-image gradients http://www.w3.org/TR/css3-values/#calc-notation 4908626b6c3bd6da5d47ec5ee366e0c06d8cae50 `L. David Baron`<http://dbaron.org/> +calc-background-linear-gradient-1 reference/calc-background-linear-gradient-1-ref Support calc() on gradient stop positions http://www.w3.org/TR/css3-values/#calc-notation 89f5dc390231b59bc044bde93bb4cc3133002df6 `Yu-Sian (Thomasy) Liu`<https://bugzilla.mozilla.org/show_bug.cgi?id=594935> +calc-background-position-1 reference/calc-background-position-1-ref Test for calc() on background-position http://www.w3.org/TR/css3-values/#calc-notation d5a0d6858f4cc7d245898f066606204e559e4b50 `L. David Baron`<https://bugzilla.mozilla.org/show_bug.cgi?id=594934> +calc-background-size-1 reference/calc-background-size-1-ref Test for calc() on background-size http://www.w3.org/TR/css3-values/#calc-notation 72065683ace08d6b2a82f035a634c801d1321761 `L. David Baron`<https://bugzilla.mozilla.org/show_bug.cgi?id=594934> +calc-border-radius-1 reference/calc-border-radius-1-ref test for border-radius: calc() http://www.w3.org/TR/css3-values/#calc-notation 9d9eeb4f1aeff36e108f038dffcd9cbe19044b9f `L. David Baron`<http://dbaron.org/> +calc-height-block-1 reference/calc-height-block-1-ref Test for height:calc() on blocks http://www.w3.org/TR/css3-values/#calc-notation 952526a2250e62df4cd71c656df40c8e1583d802 `L. David Baron`<http://dbaron.org/> +calc-height-table-1 reference/calc-height-table-1-ref Test that height:calc() with no percentages has an effect on inner table elements http://www.w3.org/TR/css3-values/#calc-notation aaa87fc375b1f80271853d2c80fa30e6e7953c05 `L. David Baron`<http://dbaron.org/> +calc-margin-block-1 reference/calc-margin-block-1-ref Test of margin-*: calc() http://www.w3.org/TR/css3-values/#calc-notation 1d7889b64fd00e87e2b2961c5e42e6af8577ae5a `L. David Baron`<http://dbaron.org/> +calc-max-height-block-1 reference/calc-max-height-block-1-ref Test for max-height:calc() on blocks http://www.w3.org/TR/css3-values/#calc-notation f59e64c55e4610b5e23a0cf99f646f657d0ae58f `L. David Baron`<http://dbaron.org/> +calc-max-width-block-1 reference/calc-width-block-1-ref max-width: calc() on blocks http://www.w3.org/TR/css3-values/#calc-notation 0c2e3de995e9b8644479cb9b6154c268268df2bf `L. David Baron`<http://dbaron.org/> +calc-max-width-block-intrinsic-1 reference/calc-max-width-block-intrinsic-1-ref intrinsic width of max-width: calc() on blocks http://www.w3.org/TR/css3-values/#calc-notation 1ac22229d3c2872e7079e6c9dadf5da282e427d7 `L. David Baron`<http://dbaron.org/> +calc-min-height-block-1 reference/calc-height-block-1-ref Test for min-height:calc() on blocks http://www.w3.org/TR/css3-values/#calc-notation 0cddf80f07465e7d498399857bfea48d665aaaf9 `L. David Baron`<http://dbaron.org/> +calc-min-width-block-1 reference/calc-width-block-1-ref min-width: calc() on blocks http://www.w3.org/TR/css3-values/#calc-notation a08959fa9123b0ce0f6a0062fff8fc48b9d64f3d `L. David Baron`<http://dbaron.org/> +calc-min-width-block-intrinsic-1 reference/calc-min-width-block-intrinsic-1-ref intrinsic width of min-width: calc() on blocks http://www.w3.org/TR/css3-values/#calc-notation 087f81b5bb656bd7a99e965460e61b51b6c66cfa `L. David Baron`<http://dbaron.org/> +calc-offsets-absolute-bottom-1 reference/calc-offsets-absolute-top-1-ref Test for bottom:calc() on absolutely positioned elements http://www.w3.org/TR/css3-values/#calc-notation c8f2101c65c8efcb87041d69c39598e77db38bd7 `L. David Baron`<http://dbaron.org/> +calc-offsets-absolute-left-1 reference/calc-offsets-relative-left-1-ref Test for left:calc() on absolutely positioned elements http://www.w3.org/TR/css3-values/#calc-notation 76226a8db09005107647baa10a26243e78a6db40 `L. David Baron`<http://dbaron.org/> +calc-offsets-absolute-right-1 reference/calc-offsets-relative-left-1-ref Test for right:calc() on absolutely positioned elements http://www.w3.org/TR/css3-values/#calc-notation 1837995bd1aba09200a1a25620041e3a7333b737 `L. David Baron`<http://dbaron.org/> +calc-offsets-absolute-top-1 reference/calc-offsets-absolute-top-1-ref Test for top:calc() on absolutely positioned elements http://www.w3.org/TR/css3-values/#calc-notation 11e4d218e2e4de8cb88a6890bb4151bec7fc9836 `L. David Baron`<http://dbaron.org/> +calc-offsets-relative-bottom-1 reference/calc-offsets-relative-top-1-ref Test for bottom:calc() on relatively positioned elements http://www.w3.org/TR/css3-values/#calc-notation d36f93e3013eb49e98cb89805d1ec16daee6d298 `L. David Baron`<http://dbaron.org/> +calc-offsets-relative-left-1 reference/calc-offsets-relative-left-1-ref Test for left:calc() on relatively positioned elements http://www.w3.org/TR/css3-values/#calc-notation 0b6c6289836923bc87523367eda6d58c79048a8c `L. David Baron`<http://dbaron.org/> +calc-offsets-relative-right-1 reference/calc-offsets-relative-left-1-ref Test for right:calc() on relatively positioned elements http://www.w3.org/TR/css3-values/#calc-notation e7e22c4c64b97f993430cfae81fa9a40b007df5b `L. David Baron`<http://dbaron.org/> +calc-offsets-relative-top-1 reference/calc-offsets-relative-top-1-ref Test for top:calc() on relatively positioned elements http://www.w3.org/TR/css3-values/#calc-notation 138f42115aa281eabba1eb4ea3b327d917c05e83 `L. David Baron`<http://dbaron.org/> +calc-padding-block-1 reference/calc-padding-block-1-ref Test of padding-*: calc() http://www.w3.org/TR/css3-values/#calc-notation 0a6fcb06af632bc921b8fdcf6e84dc9632747d0d `L. David Baron`<http://dbaron.org/> +calc-text-indent-1 reference/calc-text-indent-1-ref text-indent: calc() on blocks http://www.w3.org/TR/css3-values/#calc-notation 4791e504f1036b2c117a842014409132ffc0f8e0 `L. David Baron`<http://dbaron.org/> +calc-text-indent-intrinsic-1 reference/calc-text-indent-intrinsic-1-ref intrinsic width of text-indent: calc() on blocks http://www.w3.org/TR/css3-values/#calc-notation 212d0b36c668eb0ce4b8fbffb7ddc91faac7ef10 `L. David Baron`<http://dbaron.org/> +calc-transform-origin-1 reference/calc-transform-origin-1-ref Test for calc() on transform-origin http://www.w3.org/TR/css3-values/#calc-notation 37759c591badf6155fa5f3721d6feeabe9e4b606 `L. David Baron`<https://bugzilla.mozilla.org/show_bug.cgi?id=594934> +calc-unit-analysis CSS Variables Allowed Syntax script http://www.w3.org/TR/css3-values/#lengths,http://www.w3.org/TR/css3-values/#calc-type-checking 6a5b9ea86f959202db5065d15b347b024a552480 `L. David Baron`<http://dbaron.org/>,`Mozilla Corporation`<http://mozilla.com/> +calc-vertical-align-1 reference/calc-vertical-align-1-ref Test for vertical-align:calc() http://www.w3.org/TR/css3-values/#calc-notation 7b2b5dac7448097556b6233f426eea822c27c4fd `L. David Baron`<http://dbaron.org/> +calc-width-block-1 reference/calc-width-block-1-ref width: calc() on blocks http://www.w3.org/TR/css3-values/#calc-notation a204cfddfb32046b292b2c79abd546adb526570f `L. David Baron`<http://dbaron.org/> +calc-width-block-intrinsic-1 reference/calc-width-block-intrinsic-1-ref intrinsic width of width: calc() on blocks http://www.w3.org/TR/css3-values/#calc-notation f85e6251038f10b07736dc3d3ff547da3401b43d `L. David Baron`<http://dbaron.org/> +calc-width-table-auto-1 reference/calc-width-table-auto-1-ref width: calc() on table-layout: auto tables http://www.w3.org/TR/css3-values/#calc-notation b75533977bfccbdb094aefcc277e95f28710f507 `L. David Baron`<http://dbaron.org/> +calc-width-table-fixed-1 reference/calc-width-table-fixed-1-ref width: calc() on table-layout: auto tables http://www.w3.org/TR/css3-values/#calc-notation b16a53e8a8072b68c6bd91790cc982cccbcf2bc6 `L. David Baron`<http://dbaron.org/> +ch-unit-001 reference/ch-unit-001-ref support for the ch unit https://drafts.csswg.org/css-values-3/#font-relative-lengths 4c390e4f1e8b24beaa0520c61466cd43e87a62c8 `Florian Rivoal`<http://florian.rivoal.net/> The ch unit is equal to the used advance measure of the 0 (ZERO, U+0030) glyph found in the font used to render it. +min-width-001 ref min-width length value approximation http://www.w3.org/TR/css3-mediaqueries/#width,http://www.w3.org/TR/mediaqueries-4/#width,http://www.w3.org/TR/css3-values/#length-value edff68d05ca48525e5456d924b43578c8dfdbf57 `Chris Rebert`<http://chrisrebert.com> min-width length values that are too large to be supported must be clamped, rounded to infinity, or approximated, but not overflowed to a small or negative value. +multicol-count-non-integer-001 reference/multicol-columns-invalid-001-ref non-integer 'column-count' value ahem,invalid http://www.w3.org/TR/css3-multicol/#the-number-and-width-of-columns,http://www.w3.org/TR/css3-values/#integers 6ebfd7a8bb7081898fed146d154ff0c1119f05e1 `G&eacute;rard Talbot`<http://www.gtalbot.org/BrowserBugsSection/css21testsuite/> This test checks that a specified real 'column-count' value is invalid and ignored. +multicol-count-non-integer-002 reference/multicol-columns-invalid-001-ref non-integer 'column-count' value ahem,invalid http://www.w3.org/TR/css3-multicol/#the-number-and-width-of-columns,http://www.w3.org/TR/css3-values/#integers ed064290bd392497aad5107e30a9e336532a4d31 `G&eacute;rard Talbot`<http://www.gtalbot.org/BrowserBugsSection/css21testsuite/> This test checks that a specified real 'column-count' value is invalid and ignored. +multicol-count-non-integer-003 reference/multicol-columns-invalid-001-ref non-integer 'column-count' value ahem,invalid http://www.w3.org/TR/css3-multicol/#the-number-and-width-of-columns,http://www.w3.org/TR/css3-values/#integers d6173aac65acc056fcc61b00944e06e7f30f70e9 `G&eacute;rard Talbot`<http://www.gtalbot.org/BrowserBugsSection/css21testsuite/> This test checks that a specified real 'column-count' value is invalid and ignored. +multicol-inherit-002 reference/multicol-inherit-002-ref 'column-count' and inherit ahem http://www.w3.org/TR/css3-multicol/#cc,http://www.w3.org/TR/css3-values/#common-keywords 2d1165aded078402115fc317a47ae6856bed77a6 `Opera Software ASA`<http://www.opera.com/> This test checks that 'column-count' can be inherited by setting it with the CSS-wide keyword 'inherit'. +multicol-rule-color-inherit-001 reference/multicol-rule-color-inherit-001-ref column-rule-color: inherit ahem http://www.w3.org/TR/css3-multicol/#crc,http://www.w3.org/TR/css3-values/#common-keywords ccebd3df8a5aa4b32dad211082f45f677c8a61c5 `Opera Software ASA`<http://www.opera.com/> This test checks that, by default, column-rule-color is the current color applying to the element unless reserved keyword 'inherit' is used in which case column-rule-color will be inherited from the parent's column-rule-color value. +multicol-rule-color-inherit-002 reference/multicol-rule-color-inherit-001-ref column-rule-color: inherit (complex) ahem http://www.w3.org/TR/css3-multicol/#crc,http://www.w3.org/TR/css3-values/#common-keywords 5df59c878149324b852064274b30ee0782181442 `G&eacute;rard Talbot`<http://www.gtalbot.org/BrowserBugsSection/css21testsuite/> This test checks that, by default, column-rule-color is the current color applying to the element. +regions-resizing-003 reference/regions-resizing-001-ref CSS Regions: resizing region that is sized using viewport units ahem,dom,http http://www.w3.org/TR/css3-regions/#the-flow-into-property,http://www.w3.org/TR/css3-regions/#flow-from,http://www.w3.org/TR/css3-values/#viewport-relative-lengths e27649199c4544ad34ad206d2ea195c184cebeb2 `Mihai Balan`<mailto:mibalan@adobe.com> Test checks that resizing the viewport of a page containing a region sized using viewport units correctly relayouts the region's contents. +regions-resizing-007 reference/regions-resizing-001-ref CSS Regions: resizing region with percentage size inside a container that has size set in viewport units ahem,dom,http http://www.w3.org/TR/css3-regions/#the-flow-into-property,http://www.w3.org/TR/css3-regions/#flow-from,http://www.w3.org/TR/css3-values/#viewport-relative-lengths 4eabcff5cdeb95b084b8f6fe2fa1bf4bbbc0f889 `Mihai Balan`<mailto:mibalan@adobe.com> Test checks that resizing the viewport of a page containing a region that has a percentage size relative to a parent sized using viewport units correctly relayouts the region's contents. +regions-resizing-009 reference/regions-resizing-001-ref CSS Regions: resizing autosized region when content flowed in it is sized with viewport units ahem,dom,http http://www.w3.org/TR/css3-regions/#the-flow-into-property,http://www.w3.org/TR/css3-regions/#flow-from,http://www.w3.org/TR/css3-regions/#regions-visual-formatting-details,http://www.w3.org/TR/css3-values/#viewport-relative-lengths 4a1d7ae83ef004c6c097fecd07b21c7c7c368f8e `Mihai Balan`<mailto:mibalan@adobe.com> Test checks that resizing the viewport of a page containing an autosized region when the content flowed in it is sized with viewport units correctly relayouts the region's contents. +shape-outside-circle-002 Shape Outside Circle Valid Positions dom,script http://www.w3.org/TR/css-shapes-1/#funcdef-circle,http://www.w3.org/TR/css-shapes-1/#shape-outside-property,http://www.w3.org/TR/css3-values/#lengths 8a1c43c953fe3b82edd77025bbf55b77475c59f0 `Adobe`<http://html.adobe.com/>,`Bear Travis`<mailto:betravis@adobe.com>,`Rebecca Hauck`<mailto:rhauck@adobe.com> A circle's position argument may be any of the valid combinations: [ percentage|length left|center|right ] or [ percentage|length left|center|right ] [ percentage|length top|center|bottom ] or [ left|center|right ] or [ left|center|right top|center|bottom ] or [ top|center|bottom ]. +shape-outside-circle-004 Shape Outside Circle - Position Length Units dom,script http://www.w3.org/TR/css-shapes-1/#funcdef-circle,http://www.w3.org/TR/css-shapes-1/#shape-outside-property,http://www.w3.org/TR/css3-values/#lengths 44092ed692b65149dd5593c1aecce3f4d3352600 `Adobe`<http://html.adobe.com/>,`Rebecca Hauck`<mailto:rhauck@adobe.com> A circle's position arguments may in any valid <length> unit allowed by a <position> value. +shape-outside-ellipse-002 Shape Outside Ellipse Valid Positions dom,script http://www.w3.org/TR/css-shapes-1/#funcdef-ellipse,http://www.w3.org/TR/css-shapes-1/#shape-outside-property,http://www.w3.org/TR/css3-values/#lengths e069870229afea5bc6dbf4b6768c847230aafc09 `Adobe`<http://html.adobe.com/>,`Bear Travis`<mailto:betravis@adobe.com>,`Rebecca Hauck`<mailto:rhauck@adobe.com> An ellipse's position argument may be any of the valid combinations: [ percentage|length left|center|right ] or [ percentage|length left|center|right ] [ percentage|length top|center|bottom ] or [ left|center|right ] or [ left|center|right top|center|bottom ] or [ top|center|bottom ]. +shape-outside-ellipse-004 Shape Outside Ellipse - Position Length Units dom,script http://www.w3.org/TR/css-shapes-1/#funcdef-ellipse,http://www.w3.org/TR/css-shapes-1/#shape-outside-property,http://www.w3.org/TR/css3-values/#lengths cf7a179b06597950e51c08580c0bcc5d7476e1c1 `Adobe`<http://html.adobe.com/>,`Rebecca Hauck`<mailto:rhauck@adobe.com> An ellipse's position arguments may in any valid <length> unit allowed by a <position> value. +shape-outside-inset-003 Shape Outside Inset Valid Round Length Units dom,script http://www.w3.org/TR/css-shapes-1/#funcdef-inset,http://www.w3.org/TR/css-shapes-1/#shape-outside-property,http://www.w3.org/TR/css3-values/#lengths a28821639a481807aba32477b3ad98a7bec40b41 `Adobe`<http://html.adobe.com/>,`Rebecca Hauck`<mailto:rhauck@adobe.com> An inset's radial component's values can be in any length unit +shape-outside-polygon-004 Shape Outside Polygon - Argument Length Units dom,script http://www.w3.org/TR/css-shapes-1/#funcdef-polygon,http://www.w3.org/TR/css-shapes-1/#shape-outside-property,http://www.w3.org/TR/css3-values/#lengths e4bb8c0597a4b08fe5d5e94f83f94e7adf0dfb90 `Adobe`<http://html.adobe.com/>,`Rebecca Hauck`<mailto:rhauck@adobe.com> A polygon's veritices may in percentage or any valid <length> units. +transition-delay-001 Parsing transition-delay dom,script http://www.w3.org/TR/css3-transitions/#transition-delay-property,http://www.w3.org/TR/css3-values/#time 936ec60d74c61f54ba71930eafbd8db9c5e84e82 `Rodney Rehm`<http://rodneyrehm.de/en/> Test checks that transition-delay values are parsed properly +transition-duration-001 Parsing transition-duration dom,script http://www.w3.org/TR/css3-transitions/#transition-duration-property,http://www.w3.org/TR/css3-values/#time 663439e329a5e15084fda9eb5be1ac7d2e0dc5f7 `Rodney Rehm`<http://rodneyrehm.de/en/> Test checks that transition-duration values are parsed properly +vh-calc-support reference/all-green Viewport units are supported inside calc expressions. http://www.w3.org/TR/css3-values/#viewport-relative-lengths,http://www.w3.org/TR/css3-values/#calc 92ae3e98da13a95fdcd08517692d0ee79a39810b `Fran&ccedil;ois REMY`<mailto:fremycompany.developer@yahoo.fr> Check that viewport units add correctly to pixels in calc() expressions +vh-calc-support-pct reference/all-green Viewport units are supported inside calc expressions. http://www.w3.org/TR/css3-values/#viewport-relative-lengths,http://www.w3.org/TR/css3-values/#calc 094f5381d9f411a374844075893597b78fb15b46 `Fran&ccedil;ois REMY`<mailto:fremycompany.developer@yahoo.fr> Check that viewport units add correctly to percentages in calc() expressions +vh-em-inherit reference/all-green 0vh and 0vw are correctly treated as 0px http://www.w3.org/TR/css3-values/#viewport-relative-lengths bd54e3e097d1f4b5799a696bfffeebf5561c072f `Fran&Atilde;&sect;ois REMY`<mailto:fremycompany.developer@yahoo.fr> 0vh and 0vw are correctly treated as 0px +vh-inherit reference/all-green Viewport units are inherited properly http://www.w3.org/TR/css3-values/#viewport-relative-lengths e006cf0e4f727a753c115bb062ed9aa3854375b0 `Fran&Atilde;&sect;ois REMY`<mailto:fremycompany.developer@yahoo.fr> Viewport units are inherited properly +vh-interpolate-pct reference/all-green Viewport units are interpolated correctly http://www.w3.org/TR/css3-values/#viewport-relative-lengths,http://www.w3.org/TR/css3-animations/#animations e263245c653c76da4ebf1afd5463deb31d27e365 `Fran&Atilde;&sect;ois REMY`<mailto:fremycompany.developer@yahoo.fr> The interpolated size mid-way between 0px and 200vh is 100vh (respectively for vw) +vh-interpolate-px reference/all-green Viewport units are interpolated correctly http://www.w3.org/TR/css3-values/#viewport-relative-lengths,http://www.w3.org/TR/css3-animations/#animations fa83d5d77411f3c93cf7e465552f47494bfe9d7a `Fran&Atilde;&sect;ois REMY`<mailto:fremycompany.developer@yahoo.fr> The interpolated size mid-way between 0px and 200vh is 100vh (respectively for vw) +vh-interpolate-vh reference/all-green Viewport units are interpolated correctly http://www.w3.org/TR/css3-values/#viewport-relative-lengths,http://www.w3.org/TR/css3-animations/#animations 0e224532385323bb9061d9b18c1def8c330ad6ae `Fran&Atilde;&sect;ois REMY`<mailto:fremycompany.developer@yahoo.fr> The interpolated size mid-way between 75vh and 125vh is 100vh (respectively for vw) +vh-support reference/all-green Viewports units are supported in sizing properties http://www.w3.org/TR/css3-values/#viewport-relative-lengths 13609543ab6880c4f4fa00168fe8c6d48abf0270 `Fran&Atilde;&sect;ois REMY`<mailto:fremycompany.developer@yahoo.fr> Viewports units are supported in sizing properties +vh-support-atviewport reference/all-green Viewports units are supported in @viewport rules http://www.w3.org/TR/css3-values/#viewport-relative-lengths,https://drafts.csswg.org/css-device-adapt-1/ 7cc8bb8f1cde2aecece15e72882e45b67bfc4bdd `Fran&ccedil;ois REMY`<mailto:fremycompany.developer@yahoo.fr> Viewports units are supported in @viewport rules +vh-support-margin reference/all-green Viewports units are supported in margin properties http://www.w3.org/TR/css3-values/#viewport-relative-lengths f951f1c99e3a6be4134265b4da05aabbd71eb103 `Fran&Atilde;&sect;ois REMY`<mailto:fremycompany.developer@yahoo.fr> Viewports units are supported in margin properties +vh-support-transform-origin reference/all-green Viewports units are supported in transform properties http://www.w3.org/TR/css3-values/#viewport-relative-lengths,http://www.w3.org/TR/css3-2d-transforms/#css-values 8dee0773fb5519b06d225ea643bb562db431f97c `Fran&ccedil;ois REMY`<mailto:fremycompany.developer@yahoo.fr> Viewports units are supported in transform properties +vh-support-transform-translate reference/all-green Viewports units are supported in transform properties http://www.w3.org/TR/css3-values/#viewport-relative-lengths,http://www.w3.org/TR/css3-2d-transforms/#css-values 8ce0374dbb32ab1c6b2a3590856748be6b92fb91 `Fran&ccedil;ois REMY`<mailto:fremycompany.developer@yahoo.fr> Viewports units are supported in transform properties (translate) +vh-zero-support reference/all-green 0vh and 0vw are correctly treated as 0px http://www.w3.org/TR/css3-values/#viewport-relative-lengths 8cb13e6d29fba8a619119a85d745dd3e87156c22 `Fran&Atilde;&sect;ois REMY`<mailto:fremycompany.developer@yahoo.fr> 0vh and 0vw are correctly treated as 0px +vh_not_refreshing_on_chrome reference/vh_not_refreshing_on_chrome-ref vh-based dimension doesn't change when the element's other dimension doesn't change. http://www.w3.org/TR/css3-values/#viewport-relative-lengths a27560454ad4d3e11996f4a3a9ed7d66f4b639b8 `Marc Bourlon`<mailto:marc@bourlon.com> vh-based dimension doesn't change when the element's other dimension doesn't change. +vh_not_refreshing_on_chrome_iframe reference/vh_not_refreshing_on_chrome-ref vh-based dimension doesn't change when the element other dimension doesn't change. http://www.w3.org/TR/css3-values/#viewport-relative-lengths 8d080a2350a0e8e006e0141407e6a2c804027986 `Marc Bourlon`<mailto:marc@bourlon.com> vh-based dimension doesn't change when the element other dimension doesn't change. Bug for Chrome 19.0.1084.56 / Mac OS X 10.6.8 +viewport-relative-lengths-scaled-viewport Viewport units in scaled viewport script http://www.w3.org/TR/css3-values/#viewport-relative-lengths 34183e6c538e9e431ef5cd0cb5d6834a911f3b8f `Emil A Eklund`<mailto:eae@chromium.org> viewport relative units scale with viewport. +viewport-units-css2-001 Checks viewport units against CSS 2.1 properties and the CSSOM script http://www.w3.org/TR/css3-values/#viewport-relative-lengths 0765a1e0ba205be0f26ff35a8683c6e91f2c43a7 `Christian Schaefer`<mailto:schaepp@gmx.de> Testing what happens when one applies and rereads viewport unit lengths to CSS 2.1 properties that accept length values diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/absolute_length_units.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/absolute_length_units.xht new file mode 100644 index 00000000000..57e9b1b2a8c --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/absolute_length_units.xht @@ -0,0 +1,77 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><!-- Submitted from TestTWF Paris --><head> + + <title>CSS Values and Units Test: elements should be the real world size given in mm, cm, inches...</title> + <meta content="elements are not displayed with the real world size units they should be, when specified in millimeters, centimeters, inches, ..." name="assert" /> + <link href="mailto:marc@bourlon.com" rel="author" title="Marc Bourlon" /> + <link href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" rel="help" title="5.1.2. Viewport-percentage lengths: the 'vw', 'vh', 'vmin', 'vmax' units" /> + + <style type="text/css"> + + * { margin: 0; padding: 0; font-family: Arial, Helvetica, sans-serif; font-size: 13px; } + + .s1mm { background: #F00; width: 1mm; height: 1mm; } + .s10mm { background: #66F; width: 10mm; height: 10mm; } + .s1cm { background: #E90; width: 1cm; height: 1cm; } + .s254cm { background: #D0D; width: 2.54cm; height: 2.54cm; } + .s1in { background: #00F; width: 1in; height: 1in; } + + .inline { float: left; } + + .newline { clear: left; } + + p { clear: both; margin: 10px 0; } + + </style> + +</head> +<body> + +<p> + This should be 1mm (width) by 1mm (height) size +</p> + +<div class="s1mm"></div> + +<p> + This is 10 1mm x 1mm divs, so it should be 10mm (width) by 1mm (height) size +</p> + +<div class="s1mm newline inline"></div> +<div class="s1mm inline"></div> +<div class="s1mm inline"></div> +<div class="s1mm inline"></div> +<div class="s1mm inline"></div> +<div class="s1mm inline"></div> +<div class="s1mm inline"></div> +<div class="s1mm inline"></div> +<div class="s1mm inline"></div> +<div class="s1mm inline"></div> + +<p> + This should be 10mm (width) by 10mm (height) size. +</p> + +<div class="s10mm newline "></div> + +<p> + This should be 1cm (width) by 1cm (height) size. So, same width as the line above. +</p> + +<div class="s1cm newline "></div> + +<p> + This should be 2.54cm (width) by 2.54cm (height) size. +</p> + +<div class="s254cm newline "></div> + +<p> + This should be 1in (width) by 1in (height) size. So, same size as above. +</p> + +<div class="s1in"></div> + + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-background-image-gradient-1.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-background-image-gradient-1.xht new file mode 100644 index 00000000000..afd51669911 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-background-image-gradient-1.xht @@ -0,0 +1,23 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Test: Test for calc() on background-image gradients</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help" /> + <link href="reference/calc-background-image-gradient-1-ref.xht" rel="match" /> + <meta content="" name="flags" /> +<style type="text/css"> + +p { + height: 50px; width: 200px; + border: thin solid; +} + +#one { background-image: radial-gradient(circle farthest-side at calc(50px + 50%) calc(100% - 30px), red, green); } + +</style> +</head> +<body> +<p id="one"></p> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-background-linear-gradient-1.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-background-linear-gradient-1.xht new file mode 100644 index 00000000000..419e5adc96d --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-background-linear-gradient-1.xht @@ -0,0 +1,42 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Test: Support calc() on gradient stop positions</title> + <link href="https://bugzilla.mozilla.org/show_bug.cgi?id=594935" rel="author" title="Yu-Sian (Thomasy) Liu" /> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help" /> + <link href="reference/calc-background-linear-gradient-1-ref.xht" rel="match" /> + <meta content="" name="flags" /> +<style type="text/css"> +div { + width:100px; + height:100px; + background:red; + margin:5px 0 0 5px; + float:left; +} +div#one { + background: linear-gradient(lime 0px, lime calc(100% - 10px), blue calc(100% - 10px), blue 100%); +} +div#two { + background: linear-gradient(blue calc(100% - 100px) ,green calc(10% + 20px) ,red 40px ,white calc(100% - 40px) , lime 80px); +} +div#three { + background: linear-gradient(blue calc(0px) ,purple calc(20%) ,red calc(10px + 10px + 20px) ,blue calc(30% + 30px) , lime calc(180% - 100px)); +} +div#four { + background: linear-gradient(blue calc(0% + 0px) ,green calc(10% + 20px) ,red 40px ,blue calc(200% / 2 - 40px) , yellow 80px); +} +div#five { + background: linear-gradient(red calc(100% - 100px) ,green calc(10% + 20px)); +} + +</style> +</head> +<body> +<div id="one">1</div> +<div id="two">2</div> +<div id="three">3</div> +<div id="four">4</div> +<div id="five">5</div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-background-position-1.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-background-position-1.xht new file mode 100644 index 00000000000..dffe2b28f75 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-background-position-1.xht @@ -0,0 +1,27 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Test: Test for calc() on background-position</title> + <link href="https://bugzilla.mozilla.org/show_bug.cgi?id=594934" rel="author" title="L. David Baron" /> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help" /> + <link href="reference/calc-background-position-1-ref.xht" rel="match" /> + <meta content="" name="flags" /> +<style type="text/css"> + +p { + height: 50px; width: 200px; + border: thin solid; + background-image: url(../backgrounds/blue-32x32.png); + background-repeat: no-repeat; +} + +#one { background-position: calc(50px + 50%) calc(100% - 30px) } +#two { background-position: calc(-12.5% + 3px) calc(-10px - 50%) } + +</style> +</head> +<body> +<p id="one"></p> +<p id="two"></p> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-background-size-1.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-background-size-1.xht new file mode 100644 index 00000000000..92d1fe7e476 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-background-size-1.xht @@ -0,0 +1,27 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Test: Test for calc() on background-size</title> + <link href="https://bugzilla.mozilla.org/show_bug.cgi?id=594934" rel="author" title="L. David Baron" /> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help" /> + <link href="reference/calc-background-size-1-ref.xht" rel="match" /> + <meta content="" name="flags" /> +<style type="text/css"> + +p { + height: 50px; width: 200px; + border: thin solid; + background-image: url(../backgrounds/blue-32x32.png); + background-repeat: no-repeat; +} + +#one { background-size: calc(50px + 50%) calc(100% - 30px) } +#two { background-size: calc(50px + 50%) calc(10px - 50%) } + +</style> +</head> +<body> +<p id="one"></p> +<p id="two"></p> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-border-radius-1.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-border-radius-1.xht new file mode 100644 index 00000000000..fb89bc2d89c --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-border-radius-1.xht @@ -0,0 +1,33 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Test: test for border-radius: calc()</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help" /> + <link href="reference/calc-border-radius-1-ref.xht" rel="match" /> + <meta content="" name="flags" /> +<style type="text/css"> + +p { + /* We use powers of two here to avoid floating-point issues. + See bug 590181. */ + + height: 256px; + width: 512px; + background: blue; + border-radius: calc((1/32 * 100%) + 5px) + calc((1/64 * 100%) - 2px) + calc(10px + (1/256 * 100%)) + calc((1/16 * 100%) - 3px) / + calc((1/32 * 100%) - (1px + (1/128 * 100%))) + calc(1/16 * 100%) + calc(10px) + 3px; +} + +</style> +</head> +<body> +<p></p> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-height-block-1.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-height-block-1.xht new file mode 100644 index 00000000000..c32aa04bdd8 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-height-block-1.xht @@ -0,0 +1,36 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Test: Test for height:calc() on blocks</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help" /> + <link href="reference/calc-height-block-1-ref.xht" rel="match" /> + <meta content="" name="flags" /> +<style type="text/css"> +body { margin: 0 } +body &gt; div { float: left; height: 100px; width: 1px; } +body &gt; div &gt; div { background: blue } + +/* for auto-height tests */ +body &gt; div &gt; div &gt; div &gt; div { height: 10px } +</style> +</head> +<body> + +<!-- tests with a fixed-height container --> +<div><div style="height: calc(50px)"></div></div> +<div><div style="height: calc(50%)"></div></div> +<div><div style="height: calc(25px + 50%)"></div></div> +<div><div style="height: calc(150% / 2 - 30px)"></div></div> +<div><div style="height: calc(40px + 10% - 20% / 2)"></div></div> +<div><div style="height: calc(40px - 10%)"></div></div> + +<!-- tests with an auto-height container --> +<div><div><div style="height: calc(50px)"><div></div></div></div></div> +<div><div><div style="height: calc(50%)"><div></div></div></div></div> +<div><div><div style="height: calc(25px + 50%)"><div></div></div></div></div> +<div><div><div style="height: calc(150% / 2 - 30px)"><div></div></div></div></div> +<div><div><div style="height: calc(40px + 10% - 20% / 2)"><div></div></div></div></div> +<div><div><div style="height: calc(40px - 10%)"><div></div></div></div></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-height-table-1.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-height-table-1.xht new file mode 100644 index 00000000000..bd8cd4126f0 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-height-table-1.xht @@ -0,0 +1,31 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Test: Test that height:calc() with no percentages has an effect on inner table elements</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help" /> + <link href="reference/calc-height-table-1-ref.xht" rel="match" /> + <meta content="" name="flags" /> +<style type="text/css"> +tbody, tr, td { + height: calc(500px); + min-height: calc(700px); + max-height: calc(2px); +} +</style> +</head> +<body> +<table border=""> + <tbody> + <tr> + <td>cell</td> + <td>cell</td> + </tr> + <tr> + <td>cell</td> + <td>cell</td> + </tr> + </tbody> +</table> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-margin-block-1.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-margin-block-1.xht new file mode 100644 index 00000000000..8121e41e301 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-margin-block-1.xht @@ -0,0 +1,24 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Test: Test of margin-*: calc()</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help" /> + <link href="reference/calc-margin-block-1-ref.xht" rel="match" /> + <meta content="" name="flags" /> +<style type="text/css"> + +div { border: medium solid green; width: 500px } +p { background: yellow } + +</style> +</head> +<body> + +<div><p style="margin: calc(10px + 1%) 0 0 0">paragraph with margin</p></div> +<div><p style="margin: 0 calc(10px + 1%) 0 0">paragraph with margin</p></div> +<div><p style="margin: 0 0 calc(10px + 1%) 0">paragraph with margin</p></div> +<div><p style="margin: 0 0 0 calc(10px + 1%)">paragraph with margin</p></div> +<div><p style="margin: calc(30px - 1%)">paragraph with margin</p></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-max-height-block-1.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-max-height-block-1.xht new file mode 100644 index 00000000000..a274c9664fa --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-max-height-block-1.xht @@ -0,0 +1,36 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Test: Test for max-height:calc() on blocks</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help" /> + <link href="reference/calc-max-height-block-1-ref.xht" rel="match" /> + <meta content="" name="flags" /> +<style type="text/css"> +body { margin: 0 } +body &gt; div { float: left; height: 100px; width: 1px; } +body &gt; div &gt; div { background: blue } + +/* to give the max-height something to restrict */ +span { display: block; height: 300px } +</style> +</head> +<body> + +<!-- tests with a fixed-height container --> +<div><div style="max-height: calc(50px)"><span></span></div></div> +<div><div style="max-height: calc(50%)"><span></span></div></div> +<div><div style="max-height: calc(25px + 50%)"><span></span></div></div> +<div><div style="max-height: calc(150% / 2 - 30px)"><span></span></div></div> +<div><div style="max-height: calc(40px + 10% - 20% / 2)"><span></span></div></div> +<div><div style="max-height: calc(40px - 10%)"><span></span></div></div> + +<!-- tests with an auto-height container --> +<div><div><div style="max-height: calc(50px)"><span></span></div></div></div> +<div><div><div style="max-height: calc(50%)"><span></span></div></div></div> +<div><div><div style="max-height: calc(25px + 50%)"><span></span></div></div></div> +<div><div><div style="max-height: calc(150% / 2 - 30px)"><span></span></div></div></div> +<div><div><div style="max-height: calc(40px + 10% - 20% / 2)"><span></span></div></div></div> +<div><div><div style="max-height: calc(40px - 10%)"><span></span></div></div></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-max-width-block-1.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-max-width-block-1.xht new file mode 100644 index 00000000000..be3d0d4c020 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-max-width-block-1.xht @@ -0,0 +1,26 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Test: max-width: calc() on blocks</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help" /> + <link href="reference/calc-width-block-1-ref.xht" rel="match" /> + <meta content="" name="flags" /> +<style type="text/css"> + +body { width: 500px } +p { background: green; color: white; margin: 1px 0; font-size: 10px; width: 1000px; } + +</style> +</head> +<body> + +<p style="max-width: calc(50% - 3px)">50% - 3px</p> +<p style="max-width: calc(25% - 3px + 25%)">25% - 3px + 25%</p> +<p style="max-width: calc(25% - 3px + 12.5% * 2)">25% - 3px + 12.5% * 2</p> +<p style="max-width: calc(25% - 3px + 12.5%*2)">25% - 3px + 12.5%*2</p> +<p style="max-width: calc(25% - 3px + 2*12.5%)">25% - 3px + 2*12.5%</p> +<p style="max-width: calc(25% - 3px + 2 * 12.5%)">25% - 3px + 2 * 12.5%</p> +<p style="max-width: calc(30% + 20%)">30% + 20%</p> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-max-width-block-intrinsic-1.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-max-width-block-intrinsic-1.xht new file mode 100644 index 00000000000..aa78f36f3b1 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-max-width-block-intrinsic-1.xht @@ -0,0 +1,28 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Test: intrinsic width of max-width: calc() on blocks</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help" /> + <link href="reference/calc-max-width-block-intrinsic-1-ref.xht" rel="match" /> + <meta content="" name="flags" /> +<style type="text/css"> + +body { font-size: 10px } +body &gt; div { float: left; clear: left; + margin: 0 0 1px 0; background: blue; color: white; height: 5px } +body &gt; div &gt; div { width: 400px } +body &gt; div &gt; div &gt; div { width: 200px } + +</style> +</head> +<body> + +<div><div style="max-width: calc(50% - 3px)"><div></div></div></div> +<div><div style="max-width: calc(5em - 3px)"><div></div></div></div> +<div><div style="max-width: calc(5em - 0%)"><div></div></div></div> +<div><div style="max-width: calc(50%)"><div></div></div></div> +<div><div style="max-width: calc(50px)"><div></div></div></div> +<div><div style="max-width: calc(25% + 25%)"><div></div></div></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-min-height-block-1.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-min-height-block-1.xht new file mode 100644 index 00000000000..889d5086c84 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-min-height-block-1.xht @@ -0,0 +1,36 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Test: Test for min-height:calc() on blocks</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help" /> + <link href="reference/calc-height-block-1-ref.xht" rel="match" /> + <meta content="" name="flags" /> +<style type="text/css"> +body { margin: 0 } +body &gt; div { float: left; height: 100px; width: 1px; } +body &gt; div &gt; div { background: blue } + +/* for auto-height tests */ +body &gt; div &gt; div &gt; div &gt; div { height: 10px } +</style> +</head> +<body> + +<!-- tests with a fixed-height container --> +<div><div style="min-height: calc(50px)"></div></div> +<div><div style="min-height: calc(50%)"></div></div> +<div><div style="min-height: calc(25px + 50%)"></div></div> +<div><div style="min-height: calc(150% / 2 - 30px)"></div></div> +<div><div style="min-height: calc(40px + 10% - 20% / 2)"></div></div> +<div><div style="min-height: calc(40px - 10%)"></div></div> + +<!-- tests with an auto-height container --> +<div><div><div style="min-height: calc(50px)"><div></div></div></div></div> +<div><div><div style="min-height: calc(50%)"><div></div></div></div></div> +<div><div><div style="min-height: calc(25px + 50%)"><div></div></div></div></div> +<div><div><div style="min-height: calc(150% / 2 - 30px)"><div></div></div></div></div> +<div><div><div style="min-height: calc(40px + 10% - 20% / 2)"><div></div></div></div></div> +<div><div><div style="min-height: calc(40px - 10%)"><div></div></div></div></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-min-width-block-1.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-min-width-block-1.xht new file mode 100644 index 00000000000..5def56adab8 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-min-width-block-1.xht @@ -0,0 +1,26 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Test: min-width: calc() on blocks</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help" /> + <link href="reference/calc-width-block-1-ref.xht" rel="match" /> + <meta content="" name="flags" /> +<style type="text/css"> + +body { width: 500px } +p { background: green; color: white; margin: 1px 0; font-size: 10px; width: 0 } + +</style> +</head> +<body> + +<p style="min-width: calc(50% - 3px)">50% - 3px</p> +<p style="min-width: calc(25% - 3px + 25%)">25% - 3px + 25%</p> +<p style="min-width: calc(25% - 3px + 12.5% * 2)">25% - 3px + 12.5% * 2</p> +<p style="min-width: calc(25% - 3px + 12.5%*2)">25% - 3px + 12.5%*2</p> +<p style="min-width: calc(25% - 3px + 2*12.5%)">25% - 3px + 2*12.5%</p> +<p style="min-width: calc(25% - 3px + 2 * 12.5%)">25% - 3px + 2 * 12.5%</p> +<p style="min-width: calc(30% + 20%)">30% + 20%</p> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-min-width-block-intrinsic-1.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-min-width-block-intrinsic-1.xht new file mode 100644 index 00000000000..d06982a5c06 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-min-width-block-intrinsic-1.xht @@ -0,0 +1,28 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Test: intrinsic width of min-width: calc() on blocks</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help" /> + <link href="reference/calc-min-width-block-intrinsic-1-ref.xht" rel="match" /> + <meta content="" name="flags" /> +<style type="text/css"> + +body { font-size: 10px } +body &gt; div { float: left; clear: left; + margin: 0 0 1px 0; background: blue; color: white; height: 5px } +body &gt; div &gt; div { width: 1px } +body &gt; div &gt; div &gt; div { width: 200px } + +</style> +</head> +<body> + +<div><div style="min-width: calc(50% - 3px)"><div></div></div></div> +<div><div style="min-width: calc(5em - 3px)"><div></div></div></div> +<div><div style="min-width: calc(5em - 0%)"><div></div></div></div> +<div><div style="min-width: calc(50%)"><div></div></div></div> +<div><div style="min-width: calc(50px)"><div></div></div></div> +<div><div style="min-width: calc(25% + 25%)"><div></div></div></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-offsets-absolute-bottom-1.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-offsets-absolute-bottom-1.xht new file mode 100644 index 00000000000..1db15817bee --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-offsets-absolute-bottom-1.xht @@ -0,0 +1,34 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Test: Test for bottom:calc() on absolutely positioned elements</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help" /> + <link href="reference/calc-offsets-absolute-top-1-ref.xht" rel="match" /> + <meta content="" name="flags" /> +<style type="text/css"> +body { margin: 0 } +body &gt; div { float: left; margin-top: -90px; height: 100px; margin-bottom: 90px; width: 3px; position: relative } +div[style] { background: blue; position: absolute; height: 10px; width: 3px } +div.space { height: 100px } +</style> +</head> +<body> + +<!-- tests with a fixed-height container --> +<div><div style="bottom: calc(-50px)"></div></div> +<div><div style="bottom: calc(-50%)"></div></div> +<div><div style="bottom: calc(-25px - 50%)"></div></div> +<div><div style="bottom: calc(-150% / 2 + 30px)"></div></div> +<div><div style="bottom: calc(-40px - 10% + 20% / 2)"></div></div> +<div><div style="bottom: calc(-40px + 10%)"></div></div> + +<!-- tests with an auto-bottom container --> +<div><div><div style="bottom: calc(-50px)"></div><div class="space"></div></div></div> +<div><div><div style="bottom: calc(-50%)"></div><div class="space"></div></div></div> +<div><div><div style="bottom: calc(-25px - 50%)"></div><div class="space"></div></div></div> +<div><div><div style="bottom: calc(-150% / 2 + 30px)"></div><div class="space"></div></div></div> +<div><div><div style="bottom: calc(-40px - 10% + 20% / 2)"></div><div class="space"></div></div></div> +<div><div><div style="bottom: calc(-40px + 10%)"></div><div class="space"></div></div></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-offsets-absolute-left-1.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-offsets-absolute-left-1.xht new file mode 100644 index 00000000000..c431be2c3d3 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-offsets-absolute-left-1.xht @@ -0,0 +1,24 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Test: Test for left:calc() on absolutely positioned elements</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help" /> + <link href="reference/calc-offsets-relative-left-1-ref.xht" rel="match" /> + <meta content="" name="flags" /> +<style type="text/css"> +body { margin: 0 100px; width: 200px } +body &gt; div { height: 3px; position: relative } +div[style] { background: blue; position: absolute; height: 3px; width: 100px } +</style> +</head> +<body> + +<div><div style="left: calc(50px)"></div></div> +<div><div style="left: calc(-25%)"></div></div> +<div><div style="left: calc(25px + 25%)"></div></div> +<div><div style="left: calc(-75% / 2 + 30px)"></div></div> +<div><div style="left: calc(40px + 5% - 10% / 2)"></div></div> +<div><div style="left: calc(5% - 40px)"></div></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-offsets-absolute-right-1.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-offsets-absolute-right-1.xht new file mode 100644 index 00000000000..8f38f636075 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-offsets-absolute-right-1.xht @@ -0,0 +1,24 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Test: Test for right:calc() on absolutely positioned elements</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help" /> + <link href="reference/calc-offsets-relative-left-1-ref.xht" rel="match" /> + <meta content="" name="flags" /> +<style type="text/css"> +body { margin: 0; width: 200px } +body &gt; div { height: 3px; position: relative } +div[style] { background: blue; position: absolute; height: 3px; width: 100px } +</style> +</head> +<body> + +<div><div style="right: calc(-50px)"></div></div> +<div><div style="right: calc(25%)"></div></div> +<div><div style="right: calc(-25px - 25%)"></div></div> +<div><div style="right: calc(75% / 2 - 30px)"></div></div> +<div><div style="right: calc(-40px - 5% + 10% / 2)"></div></div> +<div><div style="right: calc(-5% + 40px)"></div></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-offsets-absolute-top-1.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-offsets-absolute-top-1.xht new file mode 100644 index 00000000000..932d465adfd --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-offsets-absolute-top-1.xht @@ -0,0 +1,34 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Test: Test for top:calc() on absolutely positioned elements</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help" /> + <link href="reference/calc-offsets-absolute-top-1-ref.xht" rel="match" /> + <meta content="" name="flags" /> +<style type="text/css"> +body { margin: 0 } +body &gt; div { float: left; height: 100px; width: 3px; position: relative } +div[style] { background: blue; position: absolute; height: 10px; width: 3px } +div.space { height: 100px } +</style> +</head> +<body> + +<!-- tests with a fixed-height container --> +<div><div style="top: calc(50px)"></div></div> +<div><div style="top: calc(50%)"></div></div> +<div><div style="top: calc(25px + 50%)"></div></div> +<div><div style="top: calc(150% / 2 - 30px)"></div></div> +<div><div style="top: calc(40px + 10% - 20% / 2)"></div></div> +<div><div style="top: calc(40px - 10%)"></div></div> + +<!-- tests with an auto-top container --> +<div><div><div style="top: calc(50px)"></div><div class="space"></div></div></div> +<div><div><div style="top: calc(50%)"></div><div class="space"></div></div></div> +<div><div><div style="top: calc(25px + 50%)"></div><div class="space"></div></div></div> +<div><div><div style="top: calc(150% / 2 - 30px)"></div><div class="space"></div></div></div> +<div><div><div style="top: calc(40px + 10% - 20% / 2)"></div><div class="space"></div></div></div> +<div><div><div style="top: calc(40px - 10%)"></div><div class="space"></div></div></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-offsets-relative-bottom-1.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-offsets-relative-bottom-1.xht new file mode 100644 index 00000000000..16dfba4c53d --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-offsets-relative-bottom-1.xht @@ -0,0 +1,33 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Test: Test for bottom:calc() on relatively positioned elements</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help" /> + <link href="reference/calc-offsets-relative-top-1-ref.xht" rel="match" /> + <meta content="" name="flags" /> +<style type="text/css"> +body { margin: 0 } +body &gt; div { float: left; height: 100px; width: 3px; } +div[style] { background: blue; position: relative; height: 10px; } +</style> +</head> +<body> + +<!-- tests with a fixed-height container --> +<div><div style="bottom: calc(-50px)"></div></div> +<div><div style="bottom: calc(-50%)"></div></div> +<div><div style="bottom: calc(-25px - 50%)"></div></div> +<div><div style="bottom: calc(-150% / 2 + 30px)"></div></div> +<div><div style="bottom: calc(-40px - 10% + 20% / 2)"></div></div> +<div><div style="bottom: calc(-40px + 10%)"></div></div> + +<!-- tests with an auto-top container --> +<div><div><div style="bottom: calc(-50px)"></div></div></div> +<div><div><div style="bottom: calc(-50%)"></div></div></div> +<div><div><div style="bottom: calc(-25px - 50%)"></div></div></div> +<div><div><div style="bottom: calc(-150% / 2 + 30px)"></div></div></div> +<div><div><div style="bottom: calc(-40px - 10% + 20% / 2)"></div></div></div> +<div><div><div style="bottom: calc(-40px + 10%)"></div></div></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-offsets-relative-left-1.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-offsets-relative-left-1.xht new file mode 100644 index 00000000000..d4715a498fb --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-offsets-relative-left-1.xht @@ -0,0 +1,23 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Test: Test for left:calc() on relatively positioned elements</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help" /> + <link href="reference/calc-offsets-relative-left-1-ref.xht" rel="match" /> + <meta content="" name="flags" /> +<style type="text/css"> +body { margin: 0 100px; width: 100px } +div[style] { background: blue; position: relative; height: 3px; } +</style> +</head> +<body> + +<div style="left: calc(50px)"></div> +<div style="left: calc(-50%)"></div> +<div style="left: calc(25px + 50%)"></div> +<div style="left: calc(-150% / 2 + 30px)"></div> +<div style="left: calc(40px + 10% - 20% / 2)"></div> +<div style="left: calc(10% - 40px)"></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-offsets-relative-right-1.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-offsets-relative-right-1.xht new file mode 100644 index 00000000000..187b0d624fd --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-offsets-relative-right-1.xht @@ -0,0 +1,23 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Test: Test for right:calc() on relatively positioned elements</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help" /> + <link href="reference/calc-offsets-relative-left-1-ref.xht" rel="match" /> + <meta content="" name="flags" /> +<style type="text/css"> +body { margin: 0 100px; width: 100px } +div[style] { background: blue; position: relative; height: 3px; } +</style> +</head> +<body> + +<div style="right: calc(-50px)"></div> +<div style="right: calc(50%)"></div> +<div style="right: calc(-25px - 50%)"></div> +<div style="right: calc(150% / 2 - 30px)"></div> +<div style="right: calc(-40px - 10% + 20% / 2)"></div> +<div style="right: calc(-10% + 40px)"></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-offsets-relative-top-1.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-offsets-relative-top-1.xht new file mode 100644 index 00000000000..e5f6ef85fa5 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-offsets-relative-top-1.xht @@ -0,0 +1,33 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Test: Test for top:calc() on relatively positioned elements</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help" /> + <link href="reference/calc-offsets-relative-top-1-ref.xht" rel="match" /> + <meta content="" name="flags" /> +<style type="text/css"> +body { margin: 0 } +body &gt; div { float: left; height: 100px; width: 3px; } +div[style] { background: blue; position: relative; height: 10px; } +</style> +</head> +<body> + +<!-- tests with a fixed-height container --> +<div><div style="top: calc(50px)"></div></div> +<div><div style="top: calc(50%)"></div></div> +<div><div style="top: calc(25px + 50%)"></div></div> +<div><div style="top: calc(150% / 2 - 30px)"></div></div> +<div><div style="top: calc(40px + 10% - 20% / 2)"></div></div> +<div><div style="top: calc(40px - 10%)"></div></div> + +<!-- tests with an auto-top container --> +<div><div><div style="top: calc(50px)"></div></div></div> +<div><div><div style="top: calc(50%)"></div></div></div> +<div><div><div style="top: calc(25px + 50%)"></div></div></div> +<div><div><div style="top: calc(150% / 2 - 30px)"></div></div></div> +<div><div><div style="top: calc(40px + 10% - 20% / 2)"></div></div></div> +<div><div><div style="top: calc(40px - 10%)"></div></div></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-padding-block-1.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-padding-block-1.xht new file mode 100644 index 00000000000..bef20f627ee --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-padding-block-1.xht @@ -0,0 +1,25 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Test: Test of padding-*: calc()</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help" /> + <link href="reference/calc-padding-block-1-ref.xht" rel="match" /> + <meta content="" name="flags" /> +<style type="text/css"> + +body { width: 500px } +div { border: medium solid green } +p { background: yellow; margin: 0 } + +</style> +</head> +<body> + +<div style="padding: calc(10px + 1%) 0 0 0"><p>paragraph with padding</p></div> +<div style="padding: 0 calc(10px + 1%) 0 0"><p>paragraph with padding</p></div> +<div style="padding: 0 0 calc(10px + 1%) 0"><p>paragraph with padding</p></div> +<div style="padding: 0 0 0 calc(10px + 1%)"><p>paragraph with padding</p></div> +<div style="padding: calc(30px - 1%)"><p>paragraph with padding</p></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-text-indent-1.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-text-indent-1.xht new file mode 100644 index 00000000000..4f7881db6d1 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-text-indent-1.xht @@ -0,0 +1,26 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Test: text-indent: calc() on blocks</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help" /> + <link href="reference/calc-text-indent-1-ref.xht" rel="match" /> + <meta content="" name="flags" /> +<style type="text/css"> + +body { width: 500px } +p { font-size: 10px } + +</style> +</head> +<body> + +<p style="text-indent: calc(50% - 3px)">50% - 3px</p> +<p style="text-indent: calc(25% - 3px + 25%)">25% - 3px + 25%</p> +<p style="text-indent: calc(25% - 3px + 12.5% * 2)">25% - 3px + 12.5% * 2</p> +<p style="text-indent: calc(25% - 3px + 12.5%*2)">25% - 3px + 12.5%*2</p> +<p style="text-indent: calc(25% - 3px + 2*12.5%)">25% - 3px + 2*12.5%</p> +<p style="text-indent: calc(25% - 3px + 2 * 12.5%)">25% - 3px + 2 * 12.5%</p> +<p style="text-indent: calc(30% + 20%)">30% + 20%</p> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-text-indent-intrinsic-1.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-text-indent-intrinsic-1.xht new file mode 100644 index 00000000000..800f6cbb23b --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-text-indent-intrinsic-1.xht @@ -0,0 +1,27 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Test: intrinsic width of text-indent: calc() on blocks</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help" /> + <link href="reference/calc-text-indent-intrinsic-1-ref.xht" rel="match" /> + <meta content="" name="flags" /> +<style type="text/css"> + +body { font-size: 10px } +div { float: left; clear: left; + margin: 0 0 1px 0; background: blue; color: white; height: 5px } +span { display: inline-block; width: 10px } + +</style> +</head> +<body> + +<div style="text-indent: calc(50% - 3px)"><span></span></div> +<div style="text-indent: calc(5em - 3px)"><span></span></div> +<div style="text-indent: calc(5em - 0%)"><span></span></div> +<div style="text-indent: calc(50%)"><span></span></div> +<div style="text-indent: calc(50px)"><span></span></div> +<div style="text-indent: calc(25% + 25%)"><span></span></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-transform-origin-1.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-transform-origin-1.xht new file mode 100644 index 00000000000..933ac83d73a --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-transform-origin-1.xht @@ -0,0 +1,28 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Test: Test for calc() on transform-origin</title> + <link href="https://bugzilla.mozilla.org/show_bug.cgi?id=594934" rel="author" title="L. David Baron" /> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help" /> + <link href="reference/calc-transform-origin-1-ref.xht" rel="match" /> + <meta content="" name="flags" /> +<style type="text/css"> + +body { margin: 100px } + +p { + height: 50px; width: 200px; + background: yellow; + transform: rotate(15deg); +} + +#one { transform-origin: calc(50px + 50%) calc(100% - 30px); } +#two { transform-origin: calc(-12.5% + 3px) calc(-10px - 50%); } + +</style> +</head> +<body> +<p id="one">hello</p> +<p id="two">hello</p> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-unit-analysis.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-unit-analysis.xht new file mode 100644 index 00000000000..e64082cbe50 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-unit-analysis.xht @@ -0,0 +1,91 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Variables Allowed Syntax</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <link href="http://mozilla.com/" rel="author" title="Mozilla Corporation" /> + <link href="http://www.w3.org/TR/css3-values/#lengths" rel="help" /> + <link href="http://www.w3.org/TR/css3-values/#calc-type-checking" rel="help" /> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> +<style id="style"></style> +<script id="metadata_cache">/* +{ + "unitless_zero_in_calc_is_a_numeric_type_not_length": { "assert": "invalid calc expression: unitless zero in calc() is a numeric type, not length" }, + "0px_in_calc": { "assert": "invalid calc expression: 0px in calc()" }, + "addition_of_length_and_number": { "assert": "invalid calc expression: addition of length and number" }, + "addition_of_number_and_length": { "assert": "invalid calc expression: addition of number and length" }, + "subtraction_of_length_and_number": { "assert": "invalid calc expression: subtraction of length and number" }, + "subtraction_of_number_and_length": { "assert": "invalid calc expression: subtraction of number and length" }, + "multiplication_of_length_and_number": { "assert": "invalid calc expression: multiplication of length and number" }, + "multiplication_of_number_and_length": { "assert": "invalid calc expression: multiplication of number and length" }, + "multiplication_of_length_and_length": { "assert": "invalid calc expression: multiplication of length and length" } +} +*/</script> +</head> +<body onload="run()"> +<div id="log"></div> +<div id="test"></div> +<script> + +function run() { + var test_elt = document.getElementById("test"); + var test_cs = window.getComputedStyle(test_elt, ""); + + function description_to_name(description) { + return description.replace(/\W+/g, "_").replace(/^_/, "").replace(/_$/, ""); + } + + function assert_invalid_value(property, value, description) { + test(function() { + test_elt.style.setProperty(property, "inherit"); + test_elt.style.setProperty(property, value); + assert_equals(test_elt.style.getPropertyValue(property), + "inherit"); + test_elt.style.setProperty(property, value); + test_elt.style.removeProperty(property); + }, + description_to_name(description), + { assert: "invalid calc expression: " + description }); + } + + function assert_valid_value(property, value, computes_to, description) { + test(function() { + test_elt.style.setProperty(property, "inherit"); + test_elt.style.setProperty(property, value); + assert_not_equals(test_elt.style.getPropertyValue(property), + "inherit"); + assert_equals(test_cs.getPropertyValue(property), + computes_to); + test_elt.style.removeProperty(property); + }, + description_to_name(description), + { assert: "valid calc expression: " + description }); + } + + assert_invalid_value("margin-left", "calc(0)", + "unitless zero in calc() is a numeric type, not length"); + assert_valid_value("margin-left", "calc(0px)", "0px", + "0px in calc()"); + assert_invalid_value("margin-left", "calc(1px + 2)", + "addition of length and number"); + assert_invalid_value("margin-left", "calc(2 + 1px)", + "addition of number and length"); + assert_invalid_value("margin-left", "calc(1px - 2)", + "subtraction of length and number"); + assert_invalid_value("margin-left", "calc(2 - 1px)", + "subtraction of number and length"); + assert_valid_value("margin-left", "calc(2px * 2)", "4px", + "multiplication of length and number"); + assert_valid_value("margin-left", "calc(2 * 2px)", "4px", + "multiplication of number and length"); + assert_invalid_value("margin-left", "calc(2px * 1px)", + "multiplication of length and length"); + +} + +run(); + +</script> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-vertical-align-1.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-vertical-align-1.xht new file mode 100644 index 00000000000..2a1a2925ef4 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-vertical-align-1.xht @@ -0,0 +1,20 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Test: Test for vertical-align:calc()</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help" /> + <link href="reference/calc-vertical-align-1-ref.xht" rel="match" /> + <meta content="" name="flags" /> + +</head><body><div style="line-height: 100px; margin-top: 100px"> + <span>x</span> + <span style="vertical-align: calc(50px)">x</span> + <span style="vertical-align: calc(50%)">x</span> + <span style="vertical-align: calc(25px + 50%)">x</span> + <span style="vertical-align: calc(150% / 2 - 30px)">x</span> + <span style="vertical-align: calc(40px + 10% - 20% / 2)">x</span> + <span style="vertical-align: calc(40px - 10%)">x</span> +</div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-width-block-1.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-width-block-1.xht new file mode 100644 index 00000000000..0f5d4d217a6 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-width-block-1.xht @@ -0,0 +1,26 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Test: width: calc() on blocks</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help" /> + <link href="reference/calc-width-block-1-ref.xht" rel="match" /> + <meta content="" name="flags" /> +<style type="text/css"> + +body { width: 500px } +p { background: green; color: white; margin: 1px 0; font-size: 10px } + +</style> +</head> +<body> + +<p style="width: calc(50% - 3px)">50% - 3px</p> +<p style="width: calc(25% - 3px + 25%)">25% - 3px + 25%</p> +<p style="width: calc(25% - 3px + 12.5% * 2)">25% - 3px + 12.5% * 2</p> +<p style="width: calc(25% - 3px + 12.5%*2)">25% - 3px + 12.5%*2</p> +<p style="width: calc(25% - 3px + 2*12.5%)">25% - 3px + 2*12.5%</p> +<p style="width: calc(25% - 3px + 2 * 12.5%)">25% - 3px + 2 * 12.5%</p> +<p style="width: calc(30% + 20%)">30% + 20%</p> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-width-block-intrinsic-1.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-width-block-intrinsic-1.xht new file mode 100644 index 00000000000..1edcd7cad3c --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-width-block-intrinsic-1.xht @@ -0,0 +1,27 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Test: intrinsic width of width: calc() on blocks</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help" /> + <link href="reference/calc-width-block-intrinsic-1-ref.xht" rel="match" /> + <meta content="" name="flags" /> +<style type="text/css"> + +body { font-size: 10px } +body &gt; div { float: left; clear: left; + margin: 0 0 1px 0; background: blue; color: white; height: 5px } +body &gt; div &gt; div &gt; div { width: 200px } + +</style> +</head> +<body> + +<div><div style="width: calc(50% - 3px)"><div></div></div></div> +<div><div style="width: calc(5em - 3px)"><div></div></div></div> +<div><div style="width: calc(5em - 0%)"><div></div></div></div> +<div><div style="width: calc(50%)"><div></div></div></div> +<div><div style="width: calc(50px)"><div></div></div></div> +<div><div style="width: calc(25% + 25%)"><div></div></div></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-width-table-auto-1.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-width-table-auto-1.xht new file mode 100644 index 00000000000..775779cf031 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-width-table-auto-1.xht @@ -0,0 +1,25 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Test: width: calc() on table-layout: auto tables</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help" /> + <link href="reference/calc-width-table-auto-1-ref.xht" rel="match" /> + <meta content="" name="flags" /> +</head><body><table border=""> + <tbody><tr> + <td style="width: calc(500px)">x</td> + <td style="width: 100px">y</td> +</tr></tbody></table> +<table border=""> + <tbody><tr> + <td style="width: calc(50%)">x</td> + <td style="width: 100px">y</td> +</tr></tbody></table> +<table border=""> + <tbody><tr> + <td style="width: calc(2 * 10% + 0.5 * 500px)">x</td> + <td style="width: 100px">y</td> +</tr></tbody></table> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-width-table-fixed-1.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-width-table-fixed-1.xht new file mode 100644 index 00000000000..2de64e478ed --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/calc-width-table-fixed-1.xht @@ -0,0 +1,30 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Test: width: calc() on table-layout: auto tables</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <link href="http://www.w3.org/TR/css3-values/#calc-notation" rel="help" /> + <link href="reference/calc-width-table-fixed-1-ref.xht" rel="match" /> + <meta content="" name="flags" /> +<style type="text/css"> +table { table-layout: fixed; width: 500px; border-spacing: 0 } +</style> +</head> +<body> +<table border=""> + <tbody><tr> + <td style="width: calc(500px)">x</td> + <td style="width: 100px">y</td> +</tr></tbody></table> +<table border=""> + <tbody><tr> + <td style="width: calc(50%)">x</td> + <td style="width: 100px">y</td> +</tr></tbody></table> +<table border=""> + <tbody><tr> + <td style="width: calc(2 * 10% + 0.5 * 500px)">x</td> + <td style="width: 100px">y</td> +</tr></tbody></table> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/ch-unit-001.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/ch-unit-001.xht new file mode 100644 index 00000000000..b4044d2b39a --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/ch-unit-001.xht @@ -0,0 +1,38 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head><meta charset="utf-8" /> +<title>CSS Values and Units Test: support for the ch unit</title> +<link href="http://florian.rivoal.net/" rel="author" title="Florian Rivoal" /> +<link href="https://drafts.csswg.org/css-values-3/#font-relative-lengths" rel="help" /> +<meta content="" name="flags" /> +<link href="reference/ch-unit-001-ref.xht" rel="match" /> +<meta content="The ch unit is equal to the used advance measure of the 0 (ZERO, U+0030) glyph found in the font used to render it." name="assert" /> +<style> +span { + background: green; + color: green; + top: 0; bottom: 0; + position: absolute; +} +div { + background: red; + color: red; + position: relative; + height: 10ch; + width: 5ch; + float: left; +} + +div + div { + width: auto; +} + +div + div span { + width: 5ch; +} +</style> +</head><body> + <p>Test passes if there is a <strong>filled green square</strong> and <strong>no red</strong>.</p> + <div><span>00000</span></div> + <div><span></span>00000</div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/chapter-1.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/chapter-1.xht new file mode 100644 index 00000000000..f63a499be97 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/chapter-1.xht @@ -0,0 +1,45 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Introduction - CSS Values and Units Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Values and Units Module Level 3 CR Test Suite</h1> + <h2>Introduction (0 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s1">+</a> + <a href="http://www.w3.org/TR/css3-values/#intro">1 Introduction</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s1.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s1.1">+</a> + <a href="http://www.w3.org/TR/css3-values/#placement">1.1 Module Interactions</a></th></tr> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/chapter-2.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/chapter-2.xht new file mode 100644 index 00000000000..499700c0993 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/chapter-2.xht @@ -0,0 +1,117 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Value Definition Syntax - CSS Values and Units Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Values and Units Module Level 3 CR Test Suite</h1> + <h2>Value Definition Syntax (0 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2">+</a> + <a href="http://www.w3.org/TR/css3-values/#value-defs">2 Value Definition Syntax</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s2.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.1">+</a> + <a href="http://www.w3.org/TR/css3-values/#component-types">2.1 Component value types</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s2.1.#comb-comma"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.1.#example-1c610a4c"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.2">+</a> + <a href="http://www.w3.org/TR/css3-values/#component-combinators">2.2 Component value combinators</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s2.2.#comb-all"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.2.#comb-any"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.2.#comb-one"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.3">+</a> + <a href="http://www.w3.org/TR/css3-values/#component-multipliers">2.3 Component value multipliers</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s2.3.#mult-comma"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.3.#mult-num"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.3.#mult-num-range"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.3.#mult-one-plus"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.3.#mult-opt"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.3.#mult-req"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.3.#mult-zero-plus"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.4"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.4">+</a> + <a href="http://www.w3.org/TR/css3-values/#combinator-multiplier-patterns">2.4 Combinator and Multiplier Patterns</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s2.5"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.5">+</a> + <a href="http://www.w3.org/TR/css3-values/#component-whitespace">2.5 Component values and white space</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s2.6"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.6">+</a> + <a href="http://www.w3.org/TR/css3-values/#value-examples">2.6 Property value examples</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s2.6.#example-ceb46dd6"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.6.#propvalues"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/chapter-3.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/chapter-3.xht new file mode 100644 index 00000000000..dd1785450ad --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/chapter-3.xht @@ -0,0 +1,156 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Textual Data Types - CSS Values and Units Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Values and Units Module Level 3 CR Test Suite</h1> + <h2>Textual Data Types (3 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3">+</a> + <a href="http://www.w3.org/TR/css3-values/#textual-values">3 Textual Data Types</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#identifier"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.1">+</a> + <a href="http://www.w3.org/TR/css3-values/#keywords">3.1 Pre-defined Keywords</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.#example-fefeae88"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.1.1">+</a> + <a href="http://www.w3.org/TR/css3-values/#common-keywords">3.1.1 CSS-wide keywords: initial, inherit and unset</a></th></tr> + <!-- 3 tests --> + <tr id="multicol-inherit-002-3.1.1" class="ahem"> + <td> + <a href="multicol-inherit-002.xht">multicol-inherit-002</a></td> + <td><a href="reference/multicol-inherit-002-ref.xht">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + <td>'column-count' and inherit + <ul class="assert"> + <li>This test checks that 'column-count' can be inherited by setting it with the CSS-wide keyword 'inherit'.</li> + </ul> + </td> + </tr> + <tr id="multicol-rule-color-inherit-001-3.1.1" class="ahem"> + <td> + <a href="multicol-rule-color-inherit-001.xht">multicol-rule-color-inherit-001</a></td> + <td><a href="reference/multicol-rule-color-inherit-001-ref.xht">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + <td>column-rule-color: inherit + <ul class="assert"> + <li>This test checks that, by default, column-rule-color is the current color applying to the element unless reserved keyword 'inherit' is used in which case column-rule-color will be inherited from the parent's column-rule-color value.</li> + </ul> + </td> + </tr> + <tr id="multicol-rule-color-inherit-002-3.1.1" class="ahem"> + <td> + <a href="multicol-rule-color-inherit-002.xht">multicol-rule-color-inherit-002</a></td> + <td><a href="reference/multicol-rule-color-inherit-001-ref.xht">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + <td>column-rule-color: inherit (complex) + <ul class="assert"> + <li>This test checks that, by default, column-rule-color is the current color applying to the element.</li> + </ul> + </td> + </tr> + </tbody> + <tbody id="s3.1.1.#css_wide-keywords"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.2">+</a> + <a href="http://www.w3.org/TR/css3-values/#custom-idents">3.2 Author-defined Identifiers: the <custom-ident> type</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.2.#example-4adf48cf"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.2.#identifier-value"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.3">+</a> + <a href="http://www.w3.org/TR/css3-values/#strings">3.3 Quoted Strings: the <string> type</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.3.#example-a6100cec"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.3.#example-aecae029"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.3.#string"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.3.#string-value"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.4"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.4">+</a> + <a href="http://www.w3.org/TR/css3-values/#urls">3.4 Resource Locators: the <url> type</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.4.#example-f4b87e68"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.4.#url"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.4.#url-value"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.4.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.4.1">+</a> + <a href="http://www.w3.org/TR/css3-values/#relative-urls">3.4.1 Relative URLs</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.4.1.#example-b20bc0e0"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.4.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.4.2">+</a> + <a href="http://www.w3.org/TR/css3-values/#url-modifiers">3.4.2 URL Modifiers</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.4.2.#typedef-url-modifier"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/chapter-4.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/chapter-4.xht new file mode 100644 index 00000000000..e89cfa4d64f --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/chapter-4.xht @@ -0,0 +1,117 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Numeric Data Types - CSS Values and Units Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Values and Units Module Level 3 CR Test Suite</h1> + <h2>Numeric Data Types (3 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s4"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4">+</a> + <a href="http://www.w3.org/TR/css3-values/#numeric-types">4 Numeric Data Types</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s4.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4.1">+</a> + <a href="http://www.w3.org/TR/css3-values/#integers">4.1 Integers: the <integer> type</a></th></tr> + <!-- 3 tests --> + <tr id="multicol-count-non-integer-001-4.1" class="ahem invalid"> + <td> + <a href="multicol-count-non-integer-001.xht">multicol-count-non-integer-001</a></td> + <td><a href="reference/multicol-columns-invalid-001-ref.xht">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr><abbr class="invalid" title="Tests invalid CSS">Invalid</abbr></td> + <td>non-integer 'column-count' value + <ul class="assert"> + <li>This test checks that a specified real 'column-count' value is invalid and ignored.</li> + </ul> + </td> + </tr> + <tr id="multicol-count-non-integer-002-4.1" class="ahem invalid"> + <td> + <a href="multicol-count-non-integer-002.xht">multicol-count-non-integer-002</a></td> + <td><a href="reference/multicol-columns-invalid-001-ref.xht">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr><abbr class="invalid" title="Tests invalid CSS">Invalid</abbr></td> + <td>non-integer 'column-count' value + <ul class="assert"> + <li>This test checks that a specified real 'column-count' value is invalid and ignored.</li> + </ul> + </td> + </tr> + <tr id="multicol-count-non-integer-003-4.1" class="ahem invalid"> + <td> + <a href="multicol-count-non-integer-003.xht">multicol-count-non-integer-003</a></td> + <td><a href="reference/multicol-columns-invalid-001-ref.xht">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr><abbr class="invalid" title="Tests invalid CSS">Invalid</abbr></td> + <td>non-integer 'column-count' value + <ul class="assert"> + <li>This test checks that a specified real 'column-count' value is invalid and ignored.</li> + </ul> + </td> + </tr> + </tbody> + <tbody id="s4.1.#integer"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.1.#integer-value"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4.2">+</a> + <a href="http://www.w3.org/TR/css3-values/#numbers">4.2 Real Numbers: the <number> type</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s4.2.#number"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.2.#number-value"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4.3">+</a> + <a href="http://www.w3.org/TR/css3-values/#percentages">4.3 Percentages: the <percentage> type</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s4.3.#percentage"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.3.#percentage-value"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.4"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4.4">+</a> + <a href="http://www.w3.org/TR/css3-values/#dimensions">4.4 Numbers with Units: dimensions</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s4.4.#dimension"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/chapter-5.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/chapter-5.xht new file mode 100644 index 00000000000..5f676187ee0 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/chapter-5.xht @@ -0,0 +1,468 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Distance Units: the <length> type - CSS Values and Units Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Values and Units Module Level 3 CR Test Suite</h1> + <h2>Distance Units: the <length> type (30 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s5"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s5">+</a> + <a href="http://www.w3.org/TR/css3-values/#lengths">5 Distance Units: the <length> type</a></th></tr> + <!-- 7 tests --> + <tr id="calc-unit-analysis-5" class="primary script"> + <td><strong> + <a href="calc-unit-analysis.xht">calc-unit-analysis</a></strong></td> + <td></td> + <td><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>CSS Variables Allowed Syntax + </td> + </tr> + <tr id="shape-outside-circle-002-5" class="dom script"> + <td> + <a href="shape-outside-circle-002.xht">shape-outside-circle-002</a></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>Shape Outside Circle Valid Positions + <ul class="assert"> + <li>A circle's position argument may be any of the valid combinations: [ percentage|length left|center|right ] or [ percentage|length left|center|right ] [ percentage|length top|center|bottom ] or [ left|center|right ] or [ left|center|right top|center|bottom ] or [ top|center|bottom ].</li> + </ul> + </td> + </tr> + <tr id="shape-outside-circle-004-5" class="dom script"> + <td> + <a href="shape-outside-circle-004.xht">shape-outside-circle-004</a></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>Shape Outside Circle - Position Length Units + <ul class="assert"> + <li>A circle's position arguments may in any valid &lt;length&gt; unit allowed by a &lt;position&gt; value.</li> + </ul> + </td> + </tr> + <tr id="shape-outside-ellipse-002-5" class="dom script"> + <td> + <a href="shape-outside-ellipse-002.xht">shape-outside-ellipse-002</a></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>Shape Outside Ellipse Valid Positions + <ul class="assert"> + <li>An ellipse's position argument may be any of the valid combinations: [ percentage|length left|center|right ] or [ percentage|length left|center|right ] [ percentage|length top|center|bottom ] or [ left|center|right ] or [ left|center|right top|center|bottom ] or [ top|center|bottom ].</li> + </ul> + </td> + </tr> + <tr id="shape-outside-ellipse-004-5" class="dom script"> + <td> + <a href="shape-outside-ellipse-004.xht">shape-outside-ellipse-004</a></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>Shape Outside Ellipse - Position Length Units + <ul class="assert"> + <li>An ellipse's position arguments may in any valid &lt;length&gt; unit allowed by a &lt;position&gt; value.</li> + </ul> + </td> + </tr> + <tr id="shape-outside-inset-003-5" class="dom script"> + <td> + <a href="shape-outside-inset-003.xht">shape-outside-inset-003</a></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>Shape Outside Inset Valid Round Length Units + <ul class="assert"> + <li>An inset's radial component's values can be in any length unit</li> + </ul> + </td> + </tr> + <tr id="shape-outside-polygon-004-5" class="dom script"> + <td> + <a href="shape-outside-polygon-004.xht">shape-outside-polygon-004</a></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>Shape Outside Polygon - Argument Length Units + <ul class="assert"> + <li>A polygon's veritices may in percentage or any valid &lt;length&gt; units.</li> + </ul> + </td> + </tr> + </tbody> + <tbody id="s5.#length-value"> + <!-- 1 tests --> + <tr id="min-width-001-5.#length-value" class=""> + <td> + <a href="min-width-001.xht">min-width-001</a></td> + <td><a href="ref.xht">=</a> </td> + <td></td> + <td>min-width length value approximation + <ul class="assert"> + <li>min-width length values that are too large to be supported must be clamped, rounded to infinity, or approximated, but not overflowed to a small or negative value.</li> + </ul> + </td> + </tr> + </tbody> + <tbody id="s5.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s5.1">+</a> + <a href="http://www.w3.org/TR/css3-values/#relative-lengths">5.1 Relative lengths</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s5.1.#relative-length"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.1.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s5.1.1">+</a> + <a href="http://www.w3.org/TR/css3-values/#font-relative-lengths">5.1.1 Font-relative lengths: the em, ex, ch, rem units</a></th></tr> + <!-- 1 tests --> + <tr id="ch-unit-001-5.1.1" class="primary"> + <td><strong> + <a href="ch-unit-001.xht">ch-unit-001</a></strong></td> + <td><a href="reference/ch-unit-001-ref.xht">=</a> </td> + <td></td> + <td>support for the ch unit + <ul class="assert"> + <li>The ch unit is equal to the used advance measure of the 0 (ZERO, U+0030) glyph found in the font used to render it.</li> + </ul> + </td> + </tr> + </tbody> + <tbody id="s5.1.1.#ch"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.1.1.#em"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.1.1.#ex"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.1.1.#example-14cae19d"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.1.1.#font-relative-length"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.1.1.#rem"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.1.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s5.1.2">+</a> + <a href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths">5.1.2 Viewport-percentage lengths: the vw, vh, vmin, vmax units</a></th></tr> + <!-- 21 tests --> + <tr id="absolute_length_units-5.1.2" class="primary"> + <td><strong> + <a href="absolute_length_units.xht">absolute_length_units</a></strong></td> + <td></td> + <td></td> + <td>elements should be the real world size given in mm, cm, inches... + <ul class="assert"> + <li>elements are not displayed with the real world size units they should be, when specified in millimeters, centimeters, inches, ...</li> + </ul> + </td> + </tr> + <tr id="regions-resizing-003-5.1.2" class="ahem dom http"> + <td> + <a href="regions-resizing-003.xht">regions-resizing-003</a></td> + <td><a href="reference/regions-resizing-001-ref.xht">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="http" title="Requires HTTP headers">HTTP</abbr></td> + <td>CSS Regions: resizing region that is sized using viewport units + <ul class="assert"> + <li>Test checks that resizing the viewport of a page containing a region sized using viewport units correctly relayouts the region's contents.</li> + </ul> + </td> + </tr> + <tr id="regions-resizing-007-5.1.2" class="ahem dom http"> + <td> + <a href="regions-resizing-007.xht">regions-resizing-007</a></td> + <td><a href="reference/regions-resizing-001-ref.xht">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="http" title="Requires HTTP headers">HTTP</abbr></td> + <td>CSS Regions: resizing region with percentage size inside a container that has size set in viewport units + <ul class="assert"> + <li>Test checks that resizing the viewport of a page containing a region that has a percentage size relative to a parent sized using viewport units correctly relayouts the region's contents.</li> + </ul> + </td> + </tr> + <tr id="regions-resizing-009-5.1.2" class="ahem dom http"> + <td> + <a href="regions-resizing-009.xht">regions-resizing-009</a></td> + <td><a href="reference/regions-resizing-001-ref.xht">=</a> </td> + <td><abbr class="ahem" title="Requires Ahem font">Ahem</abbr><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="http" title="Requires HTTP headers">HTTP</abbr></td> + <td>CSS Regions: resizing autosized region when content flowed in it is sized with viewport units + <ul class="assert"> + <li>Test checks that resizing the viewport of a page containing an autosized region when the content flowed in it is sized with viewport units correctly relayouts the region's contents.</li> + </ul> + </td> + </tr> + <tr id="vh-calc-support-5.1.2" class="primary"> + <td><strong> + <a href="vh-calc-support.xht">vh-calc-support</a></strong></td> + <td><a href="reference/all-green.xht">=</a> </td> + <td></td> + <td>Viewport units are supported inside calc expressions. + <ul class="assert"> + <li>Check that viewport units add correctly to pixels in calc() expressions</li> + </ul> + </td> + </tr> + <tr id="vh-calc-support-pct-5.1.2" class="primary"> + <td><strong> + <a href="vh-calc-support-pct.xht">vh-calc-support-pct</a></strong></td> + <td><a href="reference/all-green.xht">=</a> </td> + <td></td> + <td>Viewport units are supported inside calc expressions. + <ul class="assert"> + <li>Check that viewport units add correctly to percentages in calc() expressions</li> + </ul> + </td> + </tr> + <tr id="vh-em-inherit-5.1.2" class="primary"> + <td><strong> + <a href="vh-em-inherit.xht">vh-em-inherit</a></strong></td> + <td><a href="reference/all-green.xht">=</a> </td> + <td></td> + <td>0vh and 0vw are correctly treated as 0px + <ul class="assert"> + <li>0vh and 0vw are correctly treated as 0px</li> + </ul> + </td> + </tr> + <tr id="vh-inherit-5.1.2" class="primary"> + <td><strong> + <a href="vh-inherit.xht">vh-inherit</a></strong></td> + <td><a href="reference/all-green.xht">=</a> </td> + <td></td> + <td>Viewport units are inherited properly + <ul class="assert"> + <li>Viewport units are inherited properly</li> + </ul> + </td> + </tr> + <tr id="vh-interpolate-pct-5.1.2" class="primary"> + <td><strong> + <a href="vh-interpolate-pct.xht">vh-interpolate-pct</a></strong></td> + <td><a href="reference/all-green.xht">=</a> </td> + <td></td> + <td>Viewport units are interpolated correctly + <ul class="assert"> + <li>The interpolated size mid-way between 0px and 200vh is 100vh (respectively for vw)</li> + </ul> + </td> + </tr> + <tr id="vh-interpolate-px-5.1.2" class="primary"> + <td><strong> + <a href="vh-interpolate-px.xht">vh-interpolate-px</a></strong></td> + <td><a href="reference/all-green.xht">=</a> </td> + <td></td> + <td>Viewport units are interpolated correctly + <ul class="assert"> + <li>The interpolated size mid-way between 0px and 200vh is 100vh (respectively for vw)</li> + </ul> + </td> + </tr> + <tr id="vh-interpolate-vh-5.1.2" class="primary"> + <td><strong> + <a href="vh-interpolate-vh.xht">vh-interpolate-vh</a></strong></td> + <td><a href="reference/all-green.xht">=</a> </td> + <td></td> + <td>Viewport units are interpolated correctly + <ul class="assert"> + <li>The interpolated size mid-way between 75vh and 125vh is 100vh (respectively for vw)</li> + </ul> + </td> + </tr> + <tr id="vh-support-5.1.2" class="primary"> + <td><strong> + <a href="vh-support.xht">vh-support</a></strong></td> + <td><a href="reference/all-green.xht">=</a> </td> + <td></td> + <td>Viewports units are supported in sizing properties + <ul class="assert"> + <li>Viewports units are supported in sizing properties</li> + </ul> + </td> + </tr> + <tr id="vh-support-atviewport-5.1.2" class="primary"> + <td><strong> + <a href="vh-support-atviewport.xht">vh-support-atviewport</a></strong></td> + <td><a href="reference/all-green.xht">=</a> </td> + <td></td> + <td>Viewports units are supported in @viewport rules + <ul class="assert"> + <li>Viewports units are supported in @viewport rules</li> + </ul> + </td> + </tr> + <tr id="vh-support-margin-5.1.2" class="primary"> + <td><strong> + <a href="vh-support-margin.xht">vh-support-margin</a></strong></td> + <td><a href="reference/all-green.xht">=</a> </td> + <td></td> + <td>Viewports units are supported in margin properties + <ul class="assert"> + <li>Viewports units are supported in margin properties</li> + </ul> + </td> + </tr> + <tr id="vh-support-transform-origin-5.1.2" class="primary"> + <td><strong> + <a href="vh-support-transform-origin.xht">vh-support-transform-origin</a></strong></td> + <td><a href="reference/all-green.xht">=</a> </td> + <td></td> + <td>Viewports units are supported in transform properties + <ul class="assert"> + <li>Viewports units are supported in transform properties</li> + </ul> + </td> + </tr> + <tr id="vh-support-transform-translate-5.1.2" class="primary"> + <td><strong> + <a href="vh-support-transform-translate.xht">vh-support-transform-translate</a></strong></td> + <td><a href="reference/all-green.xht">=</a> </td> + <td></td> + <td>Viewports units are supported in transform properties + <ul class="assert"> + <li>Viewports units are supported in transform properties (translate)</li> + </ul> + </td> + </tr> + <tr id="vh-zero-support-5.1.2" class="primary"> + <td><strong> + <a href="vh-zero-support.xht">vh-zero-support</a></strong></td> + <td><a href="reference/all-green.xht">=</a> </td> + <td></td> + <td>0vh and 0vw are correctly treated as 0px + <ul class="assert"> + <li>0vh and 0vw are correctly treated as 0px</li> + </ul> + </td> + </tr> + <tr id="vh_not_refreshing_on_chrome-5.1.2" class="primary"> + <td><strong> + <a href="vh_not_refreshing_on_chrome.xht">vh_not_refreshing_on_chrome</a></strong></td> + <td><a href="reference/vh_not_refreshing_on_chrome-ref.xht">=</a> </td> + <td></td> + <td>vh-based dimension doesn't change when the element's other dimension doesn't change. + <ul class="assert"> + <li>vh-based dimension doesn't change when the element's other dimension doesn't change.</li> + </ul> + </td> + </tr> + <tr id="vh_not_refreshing_on_chrome_iframe-5.1.2" class="primary"> + <td><strong> + <a href="vh_not_refreshing_on_chrome_iframe.xht">vh_not_refreshing_on_chrome_iframe</a></strong></td> + <td><a href="reference/vh_not_refreshing_on_chrome-ref.xht">=</a> </td> + <td></td> + <td>vh-based dimension doesn't change when the element other dimension doesn't change. + <ul class="assert"> + <li>vh-based dimension doesn't change when the element other dimension doesn't change. Bug for Chrome 19.0.1084.56 / Mac OS X 10.6.8</li> + </ul> + </td> + </tr> + <tr id="viewport-relative-lengths-scaled-viewport-5.1.2" class="primary script"> + <td><strong> + <a href="viewport-relative-lengths-scaled-viewport.xht">viewport-relative-lengths-scaled-viewport</a></strong></td> + <td></td> + <td><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>Viewport units in scaled viewport + <ul class="assert"> + <li>viewport relative units scale with viewport.</li> + </ul> + </td> + </tr> + <tr id="viewport-units-css2-001-5.1.2" class="primary script"> + <td><strong> + <a href="viewport-units-css2-001.xht">viewport-units-css2-001</a></strong></td> + <td></td> + <td><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>Checks viewport units against CSS 2.1 properties and the CSSOM + <ul class="assert"> + <li>Testing what happens when one applies and rereads viewport unit lengths to CSS 2.1 properties that accept length values</li> + </ul> + </td> + </tr> + </tbody> + <tbody id="s5.1.2.#example-74b4de35"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.1.2.#vh"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.1.2.#viewport_percentage-lengths"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.1.2.#vmax"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.1.2.#vmin"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.1.2.#vw"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s5.2">+</a> + <a href="http://www.w3.org/TR/css3-values/#absolute-lengths">5.2 Absolute lengths: the cm, mm, q, in, pt, pc, px units</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2.#absolute-length"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2.#cm"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2.#example-42a5d4eb"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2.#in"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2.#mm"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2.#pc"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2.#physical-units"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2.#pt"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2.#px"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2.#q"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2.#reference-pixel"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2.#visual-angle-unit"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/chapter-6.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/chapter-6.xht new file mode 100644 index 00000000000..aadf89cb06b --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/chapter-6.xht @@ -0,0 +1,136 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Other Quantities - CSS Values and Units Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Values and Units Module Level 3 CR Test Suite</h1> + <h2>Other Quantities (2 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s6"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6">+</a> + <a href="http://www.w3.org/TR/css3-values/#other-units">6 Other Quantities</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6.1">+</a> + <a href="http://www.w3.org/TR/css3-values/#angles">6.1 Angle Units: the <angle> type and deg, grad, rad, turn units</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#angle-value"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#bearing-angle"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#deg"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#grad"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#rad"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#turn"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6.2">+</a> + <a href="http://www.w3.org/TR/css3-values/#time">6.2 Duration Units: the <time> type and s, ms units</a></th></tr> + <!-- 2 tests --> + <tr id="transition-delay-001-6.2" class="dom script"> + <td> + <a href="transition-delay-001.xht">transition-delay-001</a></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>Parsing transition-delay + <ul class="assert"> + <li>Test checks that transition-delay values are parsed properly</li> + </ul> + </td> + </tr> + <tr id="transition-duration-001-6.2" class="dom script"> + <td> + <a href="transition-duration-001.xht">transition-duration-001</a></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>Parsing transition-duration + <ul class="assert"> + <li>Test checks that transition-duration values are parsed properly</li> + </ul> + </td> + </tr> + </tbody> + <tbody id="s6.2.#ms"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2.#s"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.2.#time-value"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6.3">+</a> + <a href="http://www.w3.org/TR/css3-values/#frequency">6.3 Frequency Units: the <frequency> type and Hz, kHz units</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s6.3.#frequency-value"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.3.#hz"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.3.#khz"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.4"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6.4">+</a> + <a href="http://www.w3.org/TR/css3-values/#resolution">6.4 Resolution Units: the <resolution> type and dpi, dpcm, dppx units</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s6.4.#dpcm"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.4.#dpi"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.4.#dppx"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.4.#example-0c0bf820"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.4.#resolution-value"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/chapter-7.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/chapter-7.xht new file mode 100644 index 00000000000..711aebbe2ff --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/chapter-7.xht @@ -0,0 +1,57 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Data Types Defined Elsewhere - CSS Values and Units Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Values and Units Module Level 3 CR Test Suite</h1> + <h2>Data Types Defined Elsewhere (0 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s7"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s7">+</a> + <a href="http://www.w3.org/TR/css3-values/#defined-elsewhere">7 Data Types Defined Elsewhere</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s7.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s7.1">+</a> + <a href="http://www.w3.org/TR/css3-values/#colors">7.1 Colors: the <color> type</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s7.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s7.2">+</a> + <a href="http://www.w3.org/TR/css3-values/#images">7.2 Images: the <image> type</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s7.3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s7.3">+</a> + <a href="http://www.w3.org/TR/css3-values/#position">7.3 2D Positioning: the <position> type</a></th></tr> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/chapter-8.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/chapter-8.xht new file mode 100644 index 00000000000..9a6aab51354 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/chapter-8.xht @@ -0,0 +1,418 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Functional Notations - CSS Values and Units Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Values and Units Module Level 3 CR Test Suite</h1> + <h2>Functional Notations (32 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s8"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s8">+</a> + <a href="http://www.w3.org/TR/css3-values/#functional-notations">8 Functional Notations</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s8.#example-9de05e52"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.#functional-notation"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s8.1">+</a> + <a href="http://www.w3.org/TR/css3-values/#calc-notation">8.1 Mathematical Expressions: calc()</a></th></tr> + <!-- 31 tests --> + <tr id="calc-background-image-gradient-1-8.1" class="primary"> + <td><strong> + <a href="calc-background-image-gradient-1.xht">calc-background-image-gradient-1</a></strong></td> + <td><a href="reference/calc-background-image-gradient-1-ref.xht">=</a> </td> + <td></td> + <td>Test for calc() on background-image gradients + </td> + </tr> + <tr id="calc-background-linear-gradient-1-8.1" class="primary"> + <td><strong> + <a href="calc-background-linear-gradient-1.xht">calc-background-linear-gradient-1</a></strong></td> + <td><a href="reference/calc-background-linear-gradient-1-ref.xht">=</a> </td> + <td></td> + <td>Support calc() on gradient stop positions + </td> + </tr> + <tr id="calc-background-position-1-8.1" class="primary"> + <td><strong> + <a href="calc-background-position-1.xht">calc-background-position-1</a></strong></td> + <td><a href="reference/calc-background-position-1-ref.xht">=</a> </td> + <td></td> + <td>Test for calc() on background-position + </td> + </tr> + <tr id="calc-background-size-1-8.1" class="primary"> + <td><strong> + <a href="calc-background-size-1.xht">calc-background-size-1</a></strong></td> + <td><a href="reference/calc-background-size-1-ref.xht">=</a> </td> + <td></td> + <td>Test for calc() on background-size + </td> + </tr> + <tr id="calc-border-radius-1-8.1" class="primary"> + <td><strong> + <a href="calc-border-radius-1.xht">calc-border-radius-1</a></strong></td> + <td><a href="reference/calc-border-radius-1-ref.xht">=</a> </td> + <td></td> + <td>test for border-radius: calc() + </td> + </tr> + <tr id="calc-height-block-1-8.1" class="primary"> + <td><strong> + <a href="calc-height-block-1.xht">calc-height-block-1</a></strong></td> + <td><a href="reference/calc-height-block-1-ref.xht">=</a> </td> + <td></td> + <td>Test for height:calc() on blocks + </td> + </tr> + <tr id="calc-height-table-1-8.1" class="primary"> + <td><strong> + <a href="calc-height-table-1.xht">calc-height-table-1</a></strong></td> + <td><a href="reference/calc-height-table-1-ref.xht">=</a> </td> + <td></td> + <td>Test that height:calc() with no percentages has an effect on inner table elements + </td> + </tr> + <tr id="calc-margin-block-1-8.1" class="primary"> + <td><strong> + <a href="calc-margin-block-1.xht">calc-margin-block-1</a></strong></td> + <td><a href="reference/calc-margin-block-1-ref.xht">=</a> </td> + <td></td> + <td>Test of margin-*: calc() + </td> + </tr> + <tr id="calc-max-height-block-1-8.1" class="primary"> + <td><strong> + <a href="calc-max-height-block-1.xht">calc-max-height-block-1</a></strong></td> + <td><a href="reference/calc-max-height-block-1-ref.xht">=</a> </td> + <td></td> + <td>Test for max-height:calc() on blocks + </td> + </tr> + <tr id="calc-max-width-block-1-8.1" class="primary"> + <td><strong> + <a href="calc-max-width-block-1.xht">calc-max-width-block-1</a></strong></td> + <td><a href="reference/calc-width-block-1-ref.xht">=</a> </td> + <td></td> + <td>max-width: calc() on blocks + </td> + </tr> + <tr id="calc-max-width-block-intrinsic-1-8.1" class="primary"> + <td><strong> + <a href="calc-max-width-block-intrinsic-1.xht">calc-max-width-block-intrinsic-1</a></strong></td> + <td><a href="reference/calc-max-width-block-intrinsic-1-ref.xht">=</a> </td> + <td></td> + <td>intrinsic width of max-width: calc() on blocks + </td> + </tr> + <tr id="calc-min-height-block-1-8.1" class="primary"> + <td><strong> + <a href="calc-min-height-block-1.xht">calc-min-height-block-1</a></strong></td> + <td><a href="reference/calc-height-block-1-ref.xht">=</a> </td> + <td></td> + <td>Test for min-height:calc() on blocks + </td> + </tr> + <tr id="calc-min-width-block-1-8.1" class="primary"> + <td><strong> + <a href="calc-min-width-block-1.xht">calc-min-width-block-1</a></strong></td> + <td><a href="reference/calc-width-block-1-ref.xht">=</a> </td> + <td></td> + <td>min-width: calc() on blocks + </td> + </tr> + <tr id="calc-min-width-block-intrinsic-1-8.1" class="primary"> + <td><strong> + <a href="calc-min-width-block-intrinsic-1.xht">calc-min-width-block-intrinsic-1</a></strong></td> + <td><a href="reference/calc-min-width-block-intrinsic-1-ref.xht">=</a> </td> + <td></td> + <td>intrinsic width of min-width: calc() on blocks + </td> + </tr> + <tr id="calc-offsets-absolute-bottom-1-8.1" class="primary"> + <td><strong> + <a href="calc-offsets-absolute-bottom-1.xht">calc-offsets-absolute-bottom-1</a></strong></td> + <td><a href="reference/calc-offsets-absolute-top-1-ref.xht">=</a> </td> + <td></td> + <td>Test for bottom:calc() on absolutely positioned elements + </td> + </tr> + <tr id="calc-offsets-absolute-left-1-8.1" class="primary"> + <td><strong> + <a href="calc-offsets-absolute-left-1.xht">calc-offsets-absolute-left-1</a></strong></td> + <td><a href="reference/calc-offsets-relative-left-1-ref.xht">=</a> </td> + <td></td> + <td>Test for left:calc() on absolutely positioned elements + </td> + </tr> + <tr id="calc-offsets-absolute-right-1-8.1" class="primary"> + <td><strong> + <a href="calc-offsets-absolute-right-1.xht">calc-offsets-absolute-right-1</a></strong></td> + <td><a href="reference/calc-offsets-relative-left-1-ref.xht">=</a> </td> + <td></td> + <td>Test for right:calc() on absolutely positioned elements + </td> + </tr> + <tr id="calc-offsets-absolute-top-1-8.1" class="primary"> + <td><strong> + <a href="calc-offsets-absolute-top-1.xht">calc-offsets-absolute-top-1</a></strong></td> + <td><a href="reference/calc-offsets-absolute-top-1-ref.xht">=</a> </td> + <td></td> + <td>Test for top:calc() on absolutely positioned elements + </td> + </tr> + <tr id="calc-offsets-relative-bottom-1-8.1" class="primary"> + <td><strong> + <a href="calc-offsets-relative-bottom-1.xht">calc-offsets-relative-bottom-1</a></strong></td> + <td><a href="reference/calc-offsets-relative-top-1-ref.xht">=</a> </td> + <td></td> + <td>Test for bottom:calc() on relatively positioned elements + </td> + </tr> + <tr id="calc-offsets-relative-left-1-8.1" class="primary"> + <td><strong> + <a href="calc-offsets-relative-left-1.xht">calc-offsets-relative-left-1</a></strong></td> + <td><a href="reference/calc-offsets-relative-left-1-ref.xht">=</a> </td> + <td></td> + <td>Test for left:calc() on relatively positioned elements + </td> + </tr> + <tr id="calc-offsets-relative-right-1-8.1" class="primary"> + <td><strong> + <a href="calc-offsets-relative-right-1.xht">calc-offsets-relative-right-1</a></strong></td> + <td><a href="reference/calc-offsets-relative-left-1-ref.xht">=</a> </td> + <td></td> + <td>Test for right:calc() on relatively positioned elements + </td> + </tr> + <tr id="calc-offsets-relative-top-1-8.1" class="primary"> + <td><strong> + <a href="calc-offsets-relative-top-1.xht">calc-offsets-relative-top-1</a></strong></td> + <td><a href="reference/calc-offsets-relative-top-1-ref.xht">=</a> </td> + <td></td> + <td>Test for top:calc() on relatively positioned elements + </td> + </tr> + <tr id="calc-padding-block-1-8.1" class="primary"> + <td><strong> + <a href="calc-padding-block-1.xht">calc-padding-block-1</a></strong></td> + <td><a href="reference/calc-padding-block-1-ref.xht">=</a> </td> + <td></td> + <td>Test of padding-*: calc() + </td> + </tr> + <tr id="calc-text-indent-1-8.1" class="primary"> + <td><strong> + <a href="calc-text-indent-1.xht">calc-text-indent-1</a></strong></td> + <td><a href="reference/calc-text-indent-1-ref.xht">=</a> </td> + <td></td> + <td>text-indent: calc() on blocks + </td> + </tr> + <tr id="calc-text-indent-intrinsic-1-8.1" class="primary"> + <td><strong> + <a href="calc-text-indent-intrinsic-1.xht">calc-text-indent-intrinsic-1</a></strong></td> + <td><a href="reference/calc-text-indent-intrinsic-1-ref.xht">=</a> </td> + <td></td> + <td>intrinsic width of text-indent: calc() on blocks + </td> + </tr> + <tr id="calc-transform-origin-1-8.1" class="primary"> + <td><strong> + <a href="calc-transform-origin-1.xht">calc-transform-origin-1</a></strong></td> + <td><a href="reference/calc-transform-origin-1-ref.xht">=</a> </td> + <td></td> + <td>Test for calc() on transform-origin + </td> + </tr> + <tr id="calc-vertical-align-1-8.1" class="primary"> + <td><strong> + <a href="calc-vertical-align-1.xht">calc-vertical-align-1</a></strong></td> + <td><a href="reference/calc-vertical-align-1-ref.xht">=</a> </td> + <td></td> + <td>Test for vertical-align:calc() + </td> + </tr> + <tr id="calc-width-block-1-8.1" class="primary"> + <td><strong> + <a href="calc-width-block-1.xht">calc-width-block-1</a></strong></td> + <td><a href="reference/calc-width-block-1-ref.xht">=</a> </td> + <td></td> + <td>width: calc() on blocks + </td> + </tr> + <tr id="calc-width-block-intrinsic-1-8.1" class="primary"> + <td><strong> + <a href="calc-width-block-intrinsic-1.xht">calc-width-block-intrinsic-1</a></strong></td> + <td><a href="reference/calc-width-block-intrinsic-1-ref.xht">=</a> </td> + <td></td> + <td>intrinsic width of width: calc() on blocks + </td> + </tr> + <tr id="calc-width-table-auto-1-8.1" class="primary"> + <td><strong> + <a href="calc-width-table-auto-1.xht">calc-width-table-auto-1</a></strong></td> + <td><a href="reference/calc-width-table-auto-1-ref.xht">=</a> </td> + <td></td> + <td>width: calc() on table-layout: auto tables + </td> + </tr> + <tr id="calc-width-table-fixed-1-8.1" class="primary"> + <td><strong> + <a href="calc-width-table-fixed-1.xht">calc-width-table-fixed-1</a></strong></td> + <td><a href="reference/calc-width-table-fixed-1-ref.xht">=</a> </td> + <td></td> + <td>width: calc() on table-layout: auto tables + </td> + </tr> + </tbody> + <tbody id="s8.1.#example-0bd12a8e"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.1.#example-2b4e561f"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.1.#example-6e868f9c"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.1.#example-776de6b9"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.1.#example-f570e599"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.1.#funcdef-calc"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.1.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s8.1.1">+</a> + <a href="http://www.w3.org/TR/css3-values/#calc-syntax">8.1.1 Syntax</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s8.1.1.#typedef-calc-product"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.1.1.#typedef-calc-sum"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.1.1.#typedef-calc-value"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.1.1.#typedef-dimension"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.1.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s8.1.2">+</a> + <a href="http://www.w3.org/TR/css3-values/#calc-type-checking">8.1.2 Type Checking</a></th></tr> + <!-- 1 tests --> + <tr id="calc-unit-analysis-8.1.2" class="script"> + <td> + <a href="calc-unit-analysis.xht">calc-unit-analysis</a></td> + <td></td> + <td><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>CSS Variables Allowed Syntax + </td> + </tr> + </tbody> + <tbody id="s8.1.2.#resolved-type"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.1.3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s8.1.3">+</a> + <a href="http://www.w3.org/TR/css3-values/#calc-computed-value">8.1.3 Computed Value</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s8.1.3.#example-240b0ace"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.1.4"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s8.1.4">+</a> + <a href="http://www.w3.org/TR/css3-values/#calc-range">8.1.4 Range Checking</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s8.1.4.#example-02a3b71f"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s8.2">+</a> + <a href="http://www.w3.org/TR/css3-values/#toggle-notation">8.2 Toggling Between Values: toggle()</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s8.2.#example-17046e65"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.2.#example-349c53dd"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.2.#example-851607de"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.2.#example-9492bba0"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.2.#funcdef-toggle"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.2.#typedef-toggle-value"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s8.3">+</a> + <a href="http://www.w3.org/TR/css3-values/#attr-notation">8.3 Attribute References: attr()</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s8.3.#example-0366e27a"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.3.#example-4771a1ff"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.3.#funcdef-attr"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.3.#typedef-attr-fallback"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.3.#typedef-attr-name"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.3.#typedef-type-or-unit"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/chapter-9.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/chapter-9.xht new file mode 100644 index 00000000000..38777ae4e2f --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/chapter-9.xht @@ -0,0 +1,207 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Appendix A: IANA Considerations - CSS Values and Units Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Values and Units Module Level 3 CR Test Suite</h1> + <h2>Appendix A: IANA Considerations (0 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s9"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s9">+</a> + <a href="http://www.w3.org/TR/css3-values/#iana">9 Appendix A: IANA Considerations</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s9.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s9.1">+</a> + <a href="http://www.w3.org/TR/css3-values/#about-invalid">9.1 Registration for the about:invalid URL scheme</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s.#abstract"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#acknowledgments"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-compositing-1"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css-animations-1"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css-backgrounds-3"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css-break-3"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css-cascade-4"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css-color-3"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css-color-4"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css-counter-styles-3"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css-fonts-3"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css-images-3"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css-overflow-3"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css-syntax-3"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css-text-3"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css-text-decor-3"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css-transitions-1"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css-ui-3"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css21"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css3-fonts"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css3-images"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css3bg"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css3cascade"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css3color"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css3namespace"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css3page"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-css3syn"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-dom-ls"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-filters-1"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-mediaq"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-mediaqueries-4"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-rfc2119"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-rfc6694"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-selectors-4"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#biblio-url"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#changes"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#conformance"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#conformance-classes"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#contents"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#conventions"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#example-f839f6c8"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#experimental"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#index"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#index-defined-elsewhere"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#index-defined-here"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#informative"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#normative"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#partial"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#references"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#status"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#subtitle"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#testing"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#title"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#w3c_process_revision"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/min-width-001.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/min-width-001.xht new file mode 100644 index 00000000000..115a48398a3 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/min-width-001.xht @@ -0,0 +1,30 @@ +<!DOCTYPE html SYSTEM "about:legacy-compat"> +<html xmlns="http://www.w3.org/1999/xhtml"> +<head> + <meta charset="utf-8"/> + <title>CSS Media Queries Test: min-width length value approximation</title> + <link rel="author" title="Chris Rebert" href="http://chrisrebert.com"/> + <link rel="help" href="http://www.w3.org/TR/css3-mediaqueries/#width"/> + <link rel="help" href="http://www.w3.org/TR/mediaqueries-4/#width"/> + <link rel="help" href="http://www.w3.org/TR/css3-values/#length-value"/> + <link rel="match" href="ref.xht"/> + <meta name="flags" content=""/> + <meta name="assert" content="min-width length values that are too large to be supported must be clamped, rounded to infinity, or approximated, but not overflowed to a small or negative value."/> + <style> +div { + width: 100px; + height: 100px; + background-color: green; +} +@media (min-width: 9999999999px) { + div { + background-color: red; + } +} + </style> +</head> +<body> + <p>Test passes if there is a <strong>filled green square</strong> and <strong>no red</strong>.</p> + <div/> +</body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/multicol-count-non-integer-001.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/multicol-count-non-integer-001.xht new file mode 100644 index 00000000000..0f829bc715d --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/multicol-count-non-integer-001.xht @@ -0,0 +1,45 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> + <title>CSS Multi-column Layout Test: non-integer 'column-count' value</title> + <link rel="author" title="Gรฉrard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> + <link rel="help" href="http://www.w3.org/TR/css3-multicol/#the-number-and-width-of-columns" title="3. The number and width of columns" /> + <link rel="help" href="http://www.w3.org/TR/css3-values/#integers" title="4.1. Integers: the '&lt;integer&gt;' type" /> + <link rel="match" href="reference/multicol-columns-invalid-001-ref.xht" /> + <meta name="flags" content="ahem invalid" /> + <meta name="assert" content="This test checks that a specified real 'column-count' value is invalid and ignored." /> + <style type="text/css"><![CDATA[ + div + { + background: yellow; + border: gray solid 1em; + color: black; + font: 1.25em/1 Ahem; + orphans: 1; + widows: 1; + width: 12em; + + column-count: 4; + column-count: 2.1; /* invalid; must be an integer */ + column-gap: 0; + } + + span {color: blue;} + ]]></style> + </head> + + <body> + + <div> + bl ac + <span> + bl ue + </span> + <span> + bl ue + </span> + bl ac + </div> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/multicol-count-non-integer-002.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/multicol-count-non-integer-002.xht new file mode 100644 index 00000000000..4f89303ffc5 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/multicol-count-non-integer-002.xht @@ -0,0 +1,45 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> + <title>CSS Multi-column Layout Test: non-integer 'column-count' value</title> + <link rel="author" title="Gรฉrard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> + <link rel="help" href="http://www.w3.org/TR/css3-multicol/#the-number-and-width-of-columns" title="3. The number and width of columns" /> + <link rel="help" href="http://www.w3.org/TR/css3-values/#integers" title="4.1. Integers: the '&lt;integer&gt;' type" /> + <link rel="match" href="reference/multicol-columns-invalid-001-ref.xht" /> + <meta name="flags" content="ahem invalid" /> + <meta name="assert" content="This test checks that a specified real 'column-count' value is invalid and ignored." /> + <style type="text/css"><![CDATA[ + div + { + background: yellow; + border: gray solid 1em; + color: black; + font: 1.25em/1 Ahem; + orphans: 1; + widows: 1; + width: 12em; + + column-count: 4; + column-count: 1.9; /* invalid; must be an integer */ + column-gap: 0; + } + + span {color: blue;} + ]]></style> + </head> + + <body> + + <div> + bl ac + <span> + bl ue + </span> + <span> + bl ue + </span> + bl ac + </div> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/multicol-count-non-integer-003.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/multicol-count-non-integer-003.xht new file mode 100644 index 00000000000..2857395be42 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/multicol-count-non-integer-003.xht @@ -0,0 +1,45 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> + <title>CSS Multi-column Layout Test: non-integer 'column-count' value</title> + <link rel="author" title="Gรฉrard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> + <link rel="help" href="http://www.w3.org/TR/css3-multicol/#the-number-and-width-of-columns" title="3. The number and width of columns" /> + <link rel="help" href="http://www.w3.org/TR/css3-values/#integers" title="4.1. Integers: the '&lt;integer&gt;' type" /> + <link rel="match" href="reference/multicol-columns-invalid-001-ref.xht" /> + <meta name="flags" content="ahem invalid" /> + <meta name="assert" content="This test checks that a specified real 'column-count' value is invalid and ignored." /> + <style type="text/css"><![CDATA[ + div + { + background: yellow; + border: gray solid 1em; + color: black; + font: 1.25em/1 Ahem; + orphans: 1; + widows: 1; + width: 12em; + + column-count: 4; + column-count: 2.0; /* invalid; must be an integer */ + column-gap: 0; + } + + span {color: blue;} + ]]></style> + </head> + + <body> + + <div> + bl ac + <span> + bl ue + </span> + <span> + bl ue + </span> + bl ac + </div> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/multicol-inherit-002.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/multicol-inherit-002.xht new file mode 100644 index 00000000000..3c4f450d75b --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/multicol-inherit-002.xht @@ -0,0 +1,82 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> + <title>CSS Multi-column Layout Test: 'column-count' and inherit</title> + <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" /> + <link rel="reviewer" title="Gรฉrard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-08 --> + <link rel="help" href="http://www.w3.org/TR/css3-multicol/#cc" title="3.2 'column-count'" /> + <link rel="help" href="http://www.w3.org/TR/css3-values/#common-keywords" title="3.1.1. CSS-wide keywords: 'initial' and 'inherit'" /> + <link rel="match" href="reference/multicol-inherit-002-ref.xht" /> + <meta name="flags" content="ahem" /> + <meta name="assert" content="This test checks that 'column-count' can be inherited by setting it with the CSS-wide keyword 'inherit'." /> + <style type="text/css"><![CDATA[ + body > div + { + background-color: blue; + column-count: 3; + column-gap: 1em; + font: 1.25em/1 Ahem; + width: 32em; + + /* + N == 3; + + 32em + - 2em : 2 column gaps + ========== + 30em : available width of the 3 inner multi-column elements + + So, W == 10em; + + 30em + - 6em : 3 mult by 2em: horizontal margin of 3 inner multi-column elements + - 6em : 3 mult by 2em: horizontal column-gaps of all 3 inner multi-column elements + ========== + 18em : 6em for each of the 3 column boxes without their own horizontal margins + So, each column boxes of inner multi-column elements is 2em wide. + */ + } + + div + { + color: black; + margin: 1em; + orphans: 1; + widows: 1; + } + + div > div + { + background-color: yellow; + column-count: inherit; + column-gap: 1em; + } + + div > div:first-child {margin-top: 0;} + ]]></style> + </head> + <body> + + <div> + <div> + aa aa + aa aa + aa aa + aa aa + </div> + <div> + mm mm + mm mm + mm mm + mm mm + </div> + <div> + xx xx + xx xx + xx xx + xx xx + </div> + </div> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/multicol-rule-color-inherit-001.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/multicol-rule-color-inherit-001.xht new file mode 100644 index 00000000000..83eb5968098 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/multicol-rule-color-inherit-001.xht @@ -0,0 +1,137 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> + <title>CSS Multi-column Layout Test: column-rule-color: inherit</title> + <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" /> + <link rel="reviewer" title="Gรฉrard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-09-02 --> + <link rel="help" href="http://www.w3.org/TR/css3-multicol/#crc" title="4.2. 'column-rule-color'" /> + <link rel="help" href="http://www.w3.org/TR/css3-values/#common-keywords" title="3.1.1. CSS-wide keywords: 'initial' and 'inherit'" /> + <link rel="match" href="reference/multicol-rule-color-inherit-001-ref.xht" /> + <meta name="flags" content="ahem" /> + <meta name="assert" content="This test checks that, by default, column-rule-color is the current color applying to the element unless reserved keyword 'inherit' is used in which case column-rule-color will be inherited from the parent's column-rule-color value." /> + <style type="text/css"><![CDATA[ + div#parent + { + column-rule-color: green; + column-rule-style: none; + font: 1.25em/1 Ahem; + width: 17em; + } + + /* + + N == 3; + + W == max(0, (available-width - ((N - 1) * column-gap)) / N); + W == max(0, (17em - ((3 - 1) * 1em)) / 3); + W == max(0, (17em - (2 * 1em)) / 3); + W == max(0, (17em - 2em) / 3); + W == max(0, 15em / 3); + W == max(0, 5em); + W == 5em; + + The height of column rule depends on number of line boxes in + each outer column box which depends on number of line boxes + in each inner column box. + + N == 3; + + W == max(0, (available-width - ((N - 1) * column-gap)) / N); + W == max(0, (5em - ((3 - 1) * 1em)) / 3); + W == max(0, (5em - (2 * 1em)) / 3); + W == max(0, (5em - 2em) / 3); + W == max(0, 3em / 3); + W == max(0, 1em); + W == 1em; + + */ + + div + { + color: red; /* both div#parent and div.child have and use 'color: red' */ + orphans: 1; + widows: 1; + + column-count: 3; + column-gap: 1em; + column-rule-width: 1em; + } + + div.child + { + column-rule-color: inherit; + column-rule-style: solid; + font-size: 1em; + } + ]]></style> + </head> + + <body> + + <p>Test passes if there are 6 vertical green stripes and <strong>no red</strong>.</p> + + <div id="parent"> + <div class="child"> + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + </div> + <div class="child"> + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + </div> + <div class="child"> + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + </div> + </div> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/multicol-rule-color-inherit-002.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/multicol-rule-color-inherit-002.xht new file mode 100644 index 00000000000..96a210d39d2 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/multicol-rule-color-inherit-002.xht @@ -0,0 +1,120 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> + <title>CSS Multi-column Layout Test: column-rule-color: inherit (complex)</title> + <link rel="author" title="Gรฉrard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-09-03 --> + <link rel="help" href="http://www.w3.org/TR/css3-multicol/#crc" title="4.2. 'column-rule-color'" /> + <link rel="help" href="http://www.w3.org/TR/css3-values/#common-keywords" title="3.1.1. CSS-wide keywords: 'initial' and 'inherit'" /> + <link rel="match" href="reference/multicol-rule-color-inherit-001-ref.xht" /> + <meta name="flags" content="ahem" /> + <meta name="assert" content="This test checks that, by default, column-rule-color is the current color applying to the element." /> + <style type="text/css"><![CDATA[ + div#parent + { + color: green; + font: 1.25em/1 Ahem; + } + + div.child + { + color: red; + display: inline-block; + font-size: 1em; + width: 5em; + + column-count: 3; + column-gap: 1em; + column-rule-color: inherit; + column-rule-style: solid; + column-rule-width: 1em; + } + + /* + + N == 3; + + W == max(0, (available-width - ((N - 1) * column-gap)) / N); + W == max(0, (5em - ((3 - 1) * 1em)) / 3); + W == max(0, (5em - (2 * 1em)) / 3); + W == max(0, (5em - 2em) / 3); + W == max(0, 3em / 3); + W == max(0, 1em); + W == 1em; + + */ + + ]]></style> + </head> + + <body> + + <p>Test passes if there are 6 vertical green stripes and <strong>no red</strong>.</p> + + <div id="parent"> + <div class="child"> + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + </div> + + <div class="child"> + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + </div> + + <div class="child"> + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + &nbsp; + </div> + + </div> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/ref.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/ref.xht new file mode 100644 index 00000000000..c0148889a62 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/ref.xht @@ -0,0 +1,18 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reftest Reference</title> + <link href="http://florian.rivoal.net/" rel="author" title="Florian Rivoal" /> + <style> + div { + background-color:green; + height:100px; + width:100px; + } + </style> + </head> + <body> + <p>Test passes if there is a <strong>filled green square</strong> and <strong>no red</strong>.</p> + <div></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/all-green.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/all-green.xht new file mode 100644 index 00000000000..76df4226c11 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/all-green.xht @@ -0,0 +1,2 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html style="background: green" xmlns="http://www.w3.org/1999/xhtml"><head></head><body></body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-background-image-gradient-1-ref.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-background-image-gradient-1-ref.xht new file mode 100644 index 00000000000..bdd6d0bbaf7 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-background-image-gradient-1-ref.xht @@ -0,0 +1,21 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reference: Test for calc() on background-image gradients</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <meta content="" name="flags" /> +<style type="text/css"> + +p { + height: 50px; width: 200px; + border: thin solid; +} + +#one { background-image: radial-gradient(circle farthest-side at 150px 20px, red, green); } + +</style> +</head> +<body> +<p id="one"></p> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-background-linear-gradient-1-ref.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-background-linear-gradient-1-ref.xht new file mode 100644 index 00000000000..00821726e83 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-background-linear-gradient-1-ref.xht @@ -0,0 +1,39 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reference: Support calc() on gradient stop positions</title> + <link href="https://bugzilla.mozilla.org/show_bug.cgi?id=594935" rel="author" title="Yu-Sian (Thomasy) Liu" /> + <meta content="" name="flags" /> +<style type="text/css"> +div { + width:100px; + height:100px; + background:red; + margin:5px 0 0 5px; + float:left; +} +div#one { + background: linear-gradient(lime 0px, lime 90px, blue 90px, blue 100%); +} +div#two { + background: linear-gradient(blue 0px ,green 30px ,red 40px ,white 60px , lime 80px); +} +div#three { + background: linear-gradient(blue 0px ,purple 20px ,red 40px ,blue 60px , lime 80px); +} +div#four { + background: linear-gradient(blue 0px ,green 30px ,red 40px ,blue 60px , yellow 80px); +} +div#five { + background: linear-gradient(red 0px ,green 30px); +} +</style> +</head> +<body> +<div id="one">1</div> +<div id="two">2</div> +<div id="three">3</div> +<div id="four">4</div> +<div id="five">5</div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-background-position-1-ref.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-background-position-1-ref.xht new file mode 100644 index 00000000000..55d8613c6aa --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-background-position-1-ref.xht @@ -0,0 +1,25 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reference: Test for calc() on background-position</title> + <link href="https://bugzilla.mozilla.org/show_bug.cgi?id=594934" rel="author" title="L. David Baron" /> + <meta content="" name="flags" /> +<style type="text/css"> + +p { + height: 50px; width: 200px; + border: thin solid; + background-image: url(../backgrounds/blue-32x32.png); + background-repeat: no-repeat; +} + +#one { background-position: 134px -12px } +#two { background-position: -18px -19px } + +</style> +</head> +<body> +<p id="one"></p> +<p id="two"></p> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-background-size-1-ref.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-background-size-1-ref.xht new file mode 100644 index 00000000000..413caf4c30f --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-background-size-1-ref.xht @@ -0,0 +1,25 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reference: Test for calc() on background-size</title> + <link href="https://bugzilla.mozilla.org/show_bug.cgi?id=594934" rel="author" title="L. David Baron" /> + <meta content="" name="flags" /> +<style type="text/css"> + +p { + height: 50px; width: 200px; + border: thin solid; + background-image: url(../backgrounds/blue-32x32.png); + background-repeat: no-repeat; +} + +#one { background-size: 150px 20px; } +#two { background-image: none } + +</style> +</head> +<body> +<p id="one"></p> +<p id="two"></p> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-border-radius-1-ref.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-border-radius-1-ref.xht new file mode 100644 index 00000000000..45ee7ccfffe --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-border-radius-1-ref.xht @@ -0,0 +1,21 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reference: test for border-radius: calc()</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <meta content="" name="flags" /> +<style type="text/css"> + +p { + height: 256px; + width: 512px; + background: blue; + border-radius: 21px 6px 12px 29px / 5px 16px 10px 3px; +} + +</style> +</head> +<body> +<p></p> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-height-block-1-ref.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-height-block-1-ref.xht new file mode 100644 index 00000000000..dc9655c456d --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-height-block-1-ref.xht @@ -0,0 +1,30 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reference: Test for height:calc() or min-height:calc() on blocks</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <meta content="" name="flags" /> +<style type="text/css"> +body { margin: 0 } +body &gt; div { float: left; width: 1px; background: blue; } +</style> +</head> +<body> + +<!-- tests with a fixed-height container --> +<div style="height: 50px"></div> +<div style="height: 50px"></div> +<div style="height: 75px"></div> +<div style="height: 45px"></div> +<div style="height: 40px"></div> +<div style="height: 30px"></div> + +<!-- tests with an auto-height container --> +<div style="height: 50px"></div> +<div style="height: 10px"></div> +<div style="height: 10px"></div> +<div style="height: 10px"></div> +<div style="height: 10px"></div> +<div style="height: 10px"></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-height-table-1-ref.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-height-table-1-ref.xht new file mode 100644 index 00000000000..256f3f933a0 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-height-table-1-ref.xht @@ -0,0 +1,29 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reference: Test that height:calc() with no percentages has an effect on inner table elements</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <meta content="" name="flags" /> +<style type="text/css"> +tbody, tr, td { + height: 500px; + min-height: 700px; + max-height: 2px; +} +</style> +</head> +<body> +<table border=""> + <tbody> + <tr> + <td>cell</td> + <td>cell</td> + </tr> + <tr> + <td>cell</td> + <td>cell</td> + </tr> + </tbody> +</table> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-margin-block-1-ref.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-margin-block-1-ref.xht new file mode 100644 index 00000000000..efc4922093d --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-margin-block-1-ref.xht @@ -0,0 +1,22 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reference: Test of margin-*: calc()</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <meta content="" name="flags" /> +<style type="text/css"> + +div { border: medium solid green; width: 500px } +p { background: yellow } + +</style> +</head> +<body> + +<div><p style="margin: 15px 0 0 0">paragraph with margin</p></div> +<div><p style="margin: 0 15px 0 0">paragraph with margin</p></div> +<div><p style="margin: 0 0 15px 0">paragraph with margin</p></div> +<div><p style="margin: 0 0 0 15px">paragraph with margin</p></div> +<div><p style="margin: 25px 25px 25px 25px">paragraph with margin</p></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-max-height-block-1-ref.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-max-height-block-1-ref.xht new file mode 100644 index 00000000000..f15566ccaba --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-max-height-block-1-ref.xht @@ -0,0 +1,30 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reference: Test for max-height:calc() on blocks</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <meta content="" name="flags" /> +<style type="text/css"> +body { margin: 0 } +body &gt; div { float: left; width: 1px; background: blue; } +</style> +</head> +<body> + +<!-- tests with a fixed-height container --> +<div style="height: 50px"></div> +<div style="height: 50px"></div> +<div style="height: 75px"></div> +<div style="height: 45px"></div> +<div style="height: 40px"></div> +<div style="height: 30px"></div> + +<!-- tests with an auto-height container --> +<div style="height: 50px"></div> +<div style="height: 300px"></div> +<div style="height: 300px"></div> +<div style="height: 300px"></div> +<div style="height: 300px"></div> +<div style="height: 300px"></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-max-width-block-intrinsic-1-ref.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-max-width-block-intrinsic-1-ref.xht new file mode 100644 index 00000000000..aab6648ac0a --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-max-width-block-intrinsic-1-ref.xht @@ -0,0 +1,22 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reference: intrinsic width of max-width: calc() on blocks</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <meta content="" name="flags" /> +<style type="text/css"> + +body &gt; div { margin: 0 0 1px 0; background: blue; color: white; height: 5px } + +</style> +</head> +<body> + +<div style="width: 400px"></div> +<div style="width: 47px"></div> +<div style="width: 400px"></div> +<div style="width: 400px"></div> +<div style="width: 50px"></div> +<div style="width: 400px"></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-min-width-block-intrinsic-1-ref.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-min-width-block-intrinsic-1-ref.xht new file mode 100644 index 00000000000..f643af4df23 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-min-width-block-intrinsic-1-ref.xht @@ -0,0 +1,22 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reference: intrinsic width of min-width: calc() on blocks</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <meta content="" name="flags" /> +<style type="text/css"> + +body &gt; div { margin: 0 0 1px 0; background: blue; color: white; height: 5px } + +</style> +</head> +<body> + +<div style="width: 1px"></div> +<div style="width: 47px"></div> +<div style="width: 1px"></div> +<div style="width: 1px"></div> +<div style="width: 50px"></div> +<div style="width: 1px"></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-offsets-absolute-top-1-ref.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-offsets-absolute-top-1-ref.xht new file mode 100644 index 00000000000..eada32a5904 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-offsets-absolute-top-1-ref.xht @@ -0,0 +1,31 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reference: Test for top:calc() on absolutely positioned elements</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <meta content="" name="flags" /> +<style type="text/css"> +body { margin: 0 } +body &gt; div { float: left; height: 100px; width: 3px; } +div[style] { background: blue; position: relative; height: 10px; } +</style> +</head> +<body> + +<!-- tests with a fixed-height container --> +<div><div style="top: 50px"></div></div> +<div><div style="top: 50px"></div></div> +<div><div style="top: 75px"></div></div> +<div><div style="top: 45px"></div></div> +<div><div style="top: 40px"></div></div> +<div><div style="top: 30px"></div></div> + +<!-- tests with an auto-top container --> +<div><div style="top: 50px"></div></div> +<div><div style="top: 50px"></div></div> +<div><div style="top: 75px"></div></div> +<div><div style="top: 45px"></div></div> +<div><div style="top: 40px"></div></div> +<div><div style="top: 30px"></div></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-offsets-relative-left-1-ref.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-offsets-relative-left-1-ref.xht new file mode 100644 index 00000000000..f5e5fa2cfd8 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-offsets-relative-left-1-ref.xht @@ -0,0 +1,21 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reference: Test for left:calc() on relatively positioned elements</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <meta content="" name="flags" /> +<style type="text/css"> +body { margin: 0 100px; width: 100px } +div[style] { background: blue; position: relative; height: 3px; } +</style> +</head> +<body> + +<div style="left: 50px"></div> +<div style="left: -50px"></div> +<div style="left: 75px"></div> +<div style="left: -45px"></div> +<div style="left: 40px"></div> +<div style="left: -30px"></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-offsets-relative-top-1-ref.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-offsets-relative-top-1-ref.xht new file mode 100644 index 00000000000..c7aecf7d642 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-offsets-relative-top-1-ref.xht @@ -0,0 +1,31 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reference: Test for top:calc() on relatively positioned elements</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <meta content="" name="flags" /> +<style type="text/css"> +body { margin: 0 } +body &gt; div { float: left; height: 100px; width: 3px; } +div[style] { background: blue; position: relative; height: 10px; } +</style> +</head> +<body> + +<!-- tests with a fixed-height container --> +<div><div style="top: 50px"></div></div> +<div><div style="top: 50px"></div></div> +<div><div style="top: 75px"></div></div> +<div><div style="top: 45px"></div></div> +<div><div style="top: 40px"></div></div> +<div><div style="top: 30px"></div></div> + +<!-- tests with an auto-top container --> +<div><div style="top: 50px"></div></div> +<div><div style="top: 0px"></div></div> +<div><div style="top: 0px"></div></div> +<div><div style="top: 0px"></div></div> +<div><div style="top: 0px"></div></div> +<div><div style="top: 0px"></div></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-padding-block-1-ref.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-padding-block-1-ref.xht new file mode 100644 index 00000000000..4e3bfb014fc --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-padding-block-1-ref.xht @@ -0,0 +1,23 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reference: Test of padding-*: calc()</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <meta content="" name="flags" /> +<style type="text/css"> + +body { width: 500px } +div { border: medium solid green } +p { background: yellow; margin: 0 } + +</style> +</head> +<body> + +<div style="padding: 15px 0 0 0"><p>paragraph with padding</p></div> +<div style="padding: 0 15px 0 0"><p>paragraph with padding</p></div> +<div style="padding: 0 0 15px 0"><p>paragraph with padding</p></div> +<div style="padding: 0 0 0 15px"><p>paragraph with padding</p></div> +<div style="padding: 25px 25px 25px 25px"><p>paragraph with padding</p></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-text-indent-1-ref.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-text-indent-1-ref.xht new file mode 100644 index 00000000000..d7e13079ddd --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-text-indent-1-ref.xht @@ -0,0 +1,24 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reference: text-indent: calc()</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <meta content="" name="flags" /> +<style type="text/css"> + +body { width: 500px } +p { font-size: 10px } + +</style> +</head> +<body> + +<p style="text-indent: 247px">50% - 3px</p> +<p style="text-indent: 247px">25% - 3px + 25%</p> +<p style="text-indent: 247px">25% - 3px + 12.5% * 2</p> +<p style="text-indent: 247px">25% - 3px + 12.5%*2</p> +<p style="text-indent: 247px">25% - 3px + 2*12.5%</p> +<p style="text-indent: 247px">25% - 3px + 2 * 12.5%</p> +<p style="text-indent: 250px">30% + 20%</p> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-text-indent-intrinsic-1-ref.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-text-indent-intrinsic-1-ref.xht new file mode 100644 index 00000000000..6f191480bdc --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-text-indent-intrinsic-1-ref.xht @@ -0,0 +1,22 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reference: intrinsic width of text-indent: calc() on blocks</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <meta content="" name="flags" /> +<style type="text/css"> + +body &gt; div { margin: 0 0 1px 0; background: blue; color: white; height: 5px } + +</style> +</head> +<body> + +<div style="width: 10px"></div> +<div style="width: 57px"></div> +<div style="width: 10px"></div> +<div style="width: 10px"></div> +<div style="width: 60px"></div> +<div style="width: 10px"></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-transform-origin-1-ref.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-transform-origin-1-ref.xht new file mode 100644 index 00000000000..17e23014afd --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-transform-origin-1-ref.xht @@ -0,0 +1,26 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reference: Test for calc() on transform-origin</title> + <link href="https://bugzilla.mozilla.org/show_bug.cgi?id=594934" rel="author" title="L. David Baron" /> + <meta content="" name="flags" /> +<style type="text/css"> + +body { margin: 100px } + +p { + height: 50px; width: 200px; + background: yellow; + transform: rotate(15deg); +} + +#one { transform-origin: 150px 20px; } +#two { transform-origin: -22px -35px; } + +</style> +</head> +<body> +<p id="one">hello</p> +<p id="two">hello</p> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-vertical-align-1-ref.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-vertical-align-1-ref.xht new file mode 100644 index 00000000000..baedf2121cc --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-vertical-align-1-ref.xht @@ -0,0 +1,18 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reference: Test for vertical-align:calc()</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <meta content="" name="flags" /> + +</head><body><div style="line-height: 100px; margin-top: 100px"> + <span>x</span> + <span style="vertical-align: 50px">x</span> + <span style="vertical-align: 50px">x</span> + <span style="vertical-align: 75px">x</span> + <span style="vertical-align: 45px">x</span> + <span style="vertical-align: 40px">x</span> + <span style="vertical-align: 30px">x</span> +</div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-width-block-1-ref.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-width-block-1-ref.xht new file mode 100644 index 00000000000..eb0b500426c --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-width-block-1-ref.xht @@ -0,0 +1,24 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reference: width: calc() and min-width: calc() on blocks</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <meta content="" name="flags" /> +<style type="text/css"> + +body { width: 500px } +p { background: green; color: white; margin: 1px 0; font-size: 10px } + +</style> +</head> +<body> + +<p style="width: 247px">50% - 3px</p> +<p style="width: 247px">25% - 3px + 25%</p> +<p style="width: 247px">25% - 3px + 12.5% * 2</p> +<p style="width: 247px">25% - 3px + 12.5%*2</p> +<p style="width: 247px">25% - 3px + 2*12.5%</p> +<p style="width: 247px">25% - 3px + 2 * 12.5%</p> +<p style="width: 250px">30% + 20%</p> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-width-block-intrinsic-1-ref.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-width-block-intrinsic-1-ref.xht new file mode 100644 index 00000000000..5cd8d8aa6e5 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-width-block-intrinsic-1-ref.xht @@ -0,0 +1,22 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reference: intrinsic width of width: calc() on blocks</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <meta content="" name="flags" /> +<style type="text/css"> + +body &gt; div { margin: 0 0 1px 0; background: blue; color: white; height: 5px } + +</style> +</head> +<body> + +<div style="width: 200px"></div> +<div style="width: 47px"></div> +<div style="width: 200px"></div> +<div style="width: 200px"></div> +<div style="width: 50px"></div> +<div style="width: 200px"></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-width-table-auto-1-ref.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-width-table-auto-1-ref.xht new file mode 100644 index 00000000000..d4df3cf860d --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-width-table-auto-1-ref.xht @@ -0,0 +1,23 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reference: width: calc() on table-layout: auto tables</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <meta content="" name="flags" /> +</head><body><table border=""> + <tbody><tr> + <td style="width: 500px">x</td> + <td style="width: 100px">y</td> +</tr></tbody></table> +<table border=""> + <tbody><tr> + <td>x</td> + <td style="width: 100px">y</td> +</tr></tbody></table> +<table border=""> + <tbody><tr> + <td>x</td> + <td style="width: 100px">y</td> +</tr></tbody></table> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-width-table-fixed-1-ref.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-width-table-fixed-1-ref.xht new file mode 100644 index 00000000000..f7b4e838a8f --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/calc-width-table-fixed-1-ref.xht @@ -0,0 +1,28 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reference: width: calc() on table-layout: auto tables</title> + <link href="http://dbaron.org/" rel="author" title="L. David Baron" /> + <meta content="" name="flags" /> +<style type="text/css"> +table { table-layout: fixed; width: 500px; border-spacing: 0 } +</style> +</head> +<body> +<table border=""> + <tbody><tr> + <td style="width: 500px">x</td> + <td style="width: 100px">y</td> +</tr></tbody></table> +<table border=""> + <tbody><tr> + <td>x</td> + <td style="width: 100px">y</td> +</tr></tbody></table> +<table border=""> + <tbody><tr> + <td>x</td> + <td style="width: 100px">y</td> +</tr></tbody></table> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/ch-unit-001-ref.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/ch-unit-001-ref.xht new file mode 100644 index 00000000000..729dda4f2e2 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/ch-unit-001-ref.xht @@ -0,0 +1,19 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head><meta charset="utf-8" /> +<title>CSS Values and Units Test Reference File</title> +<link href="http://florian.rivoal.net/" rel="author" title="Florian Rivoal" /> +<meta content="" name="flags" /> +<style> +div { + background: green; + height: 10ch; + width: 10ch; + float: left; +} + +</style> +</head><body> + <p>Test passes if there is a <strong>filled green square</strong> and <strong>no red</strong>.</p> + <div></div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/multicol-columns-invalid-001-ref.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/multicol-columns-invalid-001-ref.xht new file mode 100644 index 00000000000..1340efb2620 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/multicol-columns-invalid-001-ref.xht @@ -0,0 +1,32 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> + <title>CSS Reftest Reference</title> + <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" /> + <link rel="reviewer" title="Gรฉrard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-07-26 --> + <meta name="flags" content="image" /> + <style type="text/css"><![CDATA[ + table + { + background-color: yellow; + border-spacing: 0px; + border: gray solid 1em; + font: 1.25em/1 serif; + } + + td {padding: 0 1em 0 0;} + + img, td {vertical-align: top;} + ]]></style> + </head> + <body> + <table> + <tr> + <td><img src="support/black20x20.png" width="40" height="40" alt="Image download support must be enabled" /></td> + <td><img src="support/swatch-blue.png" width="40" height="40" alt="Image download support must be enabled" /></td> + <td><img src="support/swatch-blue.png" width="40" height="40" alt="Image download support must be enabled" /></td> + <td><img src="support/black20x20.png" width="40" height="40" alt="Image download support must be enabled" /></td> + </tr> + </table> + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/multicol-inherit-002-ref.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/multicol-inherit-002-ref.xht new file mode 100644 index 00000000000..b99c00d0f27 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/multicol-inherit-002-ref.xht @@ -0,0 +1,39 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> +<head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> + <title>CSS Reftest Reference</title> + <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" /> + <link rel="reviewer" title="Gรฉrard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-08 --> + <meta name="flags" content="image" /> + <style type="text/css"><![CDATA[ + div + { + background-color: blue; + font: 1.25em/1 serif; + margin: 1em; + padding: 0em 1em 1em; + width: 30em; + } + + img {vertical-align: top;} + + img.column-gap + { + margin-left: -2em; + margin-right: 3em; + vertical-align: bottom; + } + + img#last + { + margin-left: -2em; + vertical-align: bottom; + } + ]]></style> + </head> + <body> + + <div><img src="support/black20x20.png" width="40" height="60" alt="Image download support must be enabled" /><img src="support/swatch-yellow.png" width="20" height="60" alt="Image download support must be enabled" /><img src="support/black20x20.png" width="40" height="60" alt="Image download support must be enabled" /><img src="support/swatch-yellow.png" width="20" height="60" alt="Image download support must be enabled" /><img src="support/black20x20.png" width="40" height="40" alt="Image download support must be enabled" /><img class="column-gap" src="support/swatch-yellow.png" width="40" height="20" alt="Image download support must be enabled" /><img src="support/black20x20.png" width="40" height="60" alt="Image download support must be enabled" /><img src="support/swatch-yellow.png" width="20" height="60" alt="Image download support must be enabled" /><img src="support/black20x20.png" width="40" height="60" alt="Image download support must be enabled" /><img src="support/swatch-yellow.png" width="20" height="60" alt="Image download support must be enabled" /><img src="support/black20x20.png" width="40" height="40" alt="Image download support must be enabled" /><img class="column-gap" src="support/swatch-yellow.png" width="40" height="20" alt="Image download support must be enabled" /><img src="support/black20x20.png" width="40" height="60" alt="Image download support must be enabled" /><img src="support/swatch-yellow.png" width="20" height="60" alt="Image download support must be enabled" /><img src="support/black20x20.png" width="40" height="60" alt="Image download support must be enabled" /><img src="support/swatch-yellow.png" width="20" height="60" alt="Image download support must be enabled" /><img src="support/black20x20.png" width="40" height="40" alt="Image download support must be enabled" /><img id="last" src="support/swatch-yellow.png" width="40" height="20" alt="Image download support must be enabled" /></div> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/multicol-rule-color-inherit-001-ref.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/multicol-rule-color-inherit-001-ref.xht new file mode 100644 index 00000000000..3a2cd30b451 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/multicol-rule-color-inherit-001-ref.xht @@ -0,0 +1,22 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> +<head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> + <title>CSS Reftest Reference</title> + <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" /> + <link rel="reviewer" title="Gรฉrard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-09-03 --> + <meta name="flags" content="image" /> + <style type="text/css"><![CDATA[ + div {font-size: 1.25em;} + img {padding-left: 1em;} + ]]></style> + </head> + <body> + + <p>Test passes if there are 6 vertical green stripes and <strong>no red</strong>.</p> + + <div> + <img src="support/swatch-green.png" width="20" height="120" alt="Image download support must be enabled" /><img src="support/swatch-green.png" width="20" height="120" alt="Image download support must be enabled" /><img src="support/swatch-white.png" width="20" height="120" alt="Image download support must be enabled" /><img src="support/swatch-green.png" width="20" height="120" alt="Image download support must be enabled" /><img src="support/swatch-green.png" width="20" height="120" alt="Image download support must be enabled" /><img src="support/swatch-white.png" width="20" height="120" alt="Image download support must be enabled" /><img src="support/swatch-green.png" width="20" height="120" alt="Image download support must be enabled" /><img src="support/swatch-green.png" width="20" height="120" alt="Image download support must be enabled" /> + </div> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/regions-resizing-001-ref.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/regions-resizing-001-ref.xht new file mode 100644 index 00000000000..337a3d100fd --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/regions-resizing-001-ref.xht @@ -0,0 +1,11 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Reftest Reference</title> + <link href="mailto:mibalan@adobe.com" rel="author" title="Mihai Balan" /> + </head> + <body> + <p>Test passes if you see a green square below and no red.</p> + <p>The test also fails if the there's a green block that is <strong>not</strong> a square (e.g. rectangle or polygon).</p> + <iframe width="160" height="400" frameborder="0" src="../support/80px-block-ref.html"></iframe> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/1x1-green.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/1x1-green.png new file mode 100644 index 0000000000000000000000000000000000000000..b98ca0ba0a03c580ac339e4a3653539cfa8edc71 GIT binary patch literal 135 zcmeAS@N?(olHy`uVBq!ia0vp^j3CU&3?x-=hn)gaEa{HEjtmUzPnffIy#(@^1AIbU z85$Vo{9HN_$mQ~MaSW-rm7D-%GchneRloNK$dW8^jVKAuPb(=;EJ|f?Ovz75Rq)JB bOiv9;O-!jQJeg_(RK(!v>gTe~DWM4f4{;-! literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/1x1-lime.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/1x1-lime.png new file mode 100644 index 0000000000000000000000000000000000000000..cb397fb090e199c51e80e4243d1ede03a79aa8d9 GIT binary patch literal 135 zcmeAS@N?(olHy`uVBq!ia0vp^j3CU&3?x-=hn)gaEa{HEjtmUzPnffIy#(@^1AIbU z8U8bv#2r`x<Z^ksIEGZ*N=^W>nHU(Ks^9wqWJ#8|MwA5Sr<If^7Ns&crsOB3DtP85 brl$s_CZ<#to=mj?Dq`?-^>bP0l+XkK_<AEq literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/1x1-maroon.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/1x1-maroon.png new file mode 100644 index 0000000000000000000000000000000000000000..3f86b0721955eb4e0f014102c68c2a9764ef7593 GIT binary patch literal 109 zcmeAS@N?(olHy`uVBq!ia0vp^j3CUx1|;Q0k8}blwj^(N7lsBPi@{?l_gf&vS>O>_ v4B~>Z+sSM@AcNP_#W95AdU8fW!Vi81W){YV4{giyfD#Ozu6{1-oD!M<@rf3U literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/1x1-navy.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/1x1-navy.png new file mode 100644 index 0000000000000000000000000000000000000000..9b9a03955baea7abde9e056e8604e18694e49b66 GIT binary patch literal 109 zcmeAS@N?(olHy`uVBq!ia0vp^j3CUx1|;Q0k8}blwj^(N7a+~R&>-^LA|6O{7I;J! w18EO1b~~AE2W0Six;Tb#Tu)9&$oRp}z{JAX(7`d=3n;<h>FVdQ&MBb@0MNe`HUIzs literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/1x1-red.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/1x1-red.png new file mode 100644 index 0000000000000000000000000000000000000000..6bd73ac101874f306d007e9cea8fa3a1f62dce16 GIT binary patch literal 135 zcmeAS@N?(olHy`uVBq!ia0vp^j3CU&3?x-=hn)gaEa{HEjtmUzPnffIy#(@^1AIbU z|1&U1KH@Y7a=AQR978H@B_{ycObm=q)$jcQvLs7fBT9nv(@M${i&7aJQ}UBi6+Ckj b(^G>|6H_V+Po~-c6)||a`njxgN@xNA!@(kn literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/1x1-white.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/1x1-white.png new file mode 100644 index 0000000000000000000000000000000000000000..dd43faec54ae60a210f1eab6ff4e7c88b8e34c97 GIT binary patch literal 109 zcmeAS@N?(olHy`uVBq!ia0vp^j3CUx1|;Q0k8}blwj^(N7l!{JxM1({$v_d#0*}aI wAngIhZYQ(tfDB$w7sn8e>&ZX<|Nmdl!1<f`@5Sbx4?qb9Pgg&ebxsLQ020p~!2kdN literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/2-80px-block-ref.html b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/2-80px-block-ref.html new file mode 100644 index 00000000000..f616001554c --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/2-80px-block-ref.html @@ -0,0 +1,33 @@ +<!DOCTYPE html> +<html lang="en"><head> + <meta charset="UTF-8"> + <title>One region in body</title> + <style> + html, body { + margin: 0; + padding: 0; + } + .content { + margin: 10px; + font-family: Ahem; + font-size: 20px; + line-height: 1em; + color: green; + } + </style> +</head> +<body> + <div class="content"> + xxxx<br> + xxxx<br> + xxxx<br> + xxxx + </div> + <div class="content"> + xxxx<br> + xxxx<br> + xxxx<br> + xxxx + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/60x60-gg-rr.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/60x60-gg-rr.png new file mode 100644 index 0000000000000000000000000000000000000000..84f5b2a4f1d1865d763cac875bfa6a8c5c576c91 GIT binary patch literal 224 zcmeAS@N?(olHy`uVBq!ia0vp^HXzKw1SGf4^HT*<jKx9jP7LeL$-D$|I14-?iy0WW zg+Z8+Vb&Z8pdfpRr>`sfEmlzu3&R;K0lq*X$r9Iy66gHf+|;}h2Ir#G#FEq$h4Rdj z3<Y;j-+=H&K5?KTUr!gukc@k8FBtMN81S%c^q)Ar(pb!~&BKo6T4>(2QlSh?@M7jG eOI|GCZ+2WP<2UBa)$Kro89ZJ6T-G@yGywqpiaLV; literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/60x60-green.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/60x60-green.png new file mode 100644 index 0000000000000000000000000000000000000000..b3c8cf3eb4c89bd8f2d1ffde051856f375e3a3de GIT binary patch literal 218 zcmeAS@N?(olHy`uVBq!ia0vp^HXzKw1SGf4^HT*<jKx9jP7LeL$-D$|I14-?iy0WW zg+Z8+Vb&Z8pdfpRr>`sfEmlzu3yE9XPACF}BuiW)N}Tg^b5rw57@Uhz6H8K46v{J8 zG8EiBeFMT9`NV;W+&x_!Lo)8YJ?F^Fz`((>;PMkU^HzRy4~NuGe(INq1>ePjdKrGS TIXtNc8p+`4>gTe~DWM4fy9-d) literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/60x60-red.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/60x60-red.png new file mode 100644 index 0000000000000000000000000000000000000000..823f125b8e4a60f780f00443c9c9a10b9fa1f447 GIT binary patch literal 217 zcmeAS@N?(olHy`uVBq!ia0vp^HXzKw1SGf4^HT*<jKx9jP7LeL$-D$|I14-?iy0WW zg+Z8+Vb&Z8pdfpRr>`sfEmlzuQ<1cFzubXBk|nMYCC>S|xv6<249-QVi6yBi3gww4 z84B*6z5(HleBwYwZk{fVAsP4Ho@3->VBlchkp2JMEhm9(EUQo2%VrV@UNUpX$1;`+ Ty_~-WXd;8BtDnm{r-UW|v1>m& literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/80px-block-float-ref.html b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/80px-block-float-ref.html new file mode 100644 index 00000000000..6adeeb6fa99 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/80px-block-float-ref.html @@ -0,0 +1,27 @@ +<!DOCTYPE html> +<html lang="en"><head> + <meta charset="UTF-8"> + <title>One region in body</title> + <style> + html, body { + margin: 0; + padding: 0; + } + #content { + font-family: Ahem; + font-size: 20px; + line-height: 1em; + color: green; + float: right; + } + </style> +</head> +<body> + <div id="content"> + xxxx<br> + xxxx<br> + xxxx<br> + xxxx + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/80px-block-ref.html b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/80px-block-ref.html new file mode 100644 index 00000000000..2c910e93411 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/80px-block-ref.html @@ -0,0 +1,26 @@ +<!DOCTYPE html> +<html lang="en"><head> + <meta charset="UTF-8"> + <title>One region in body</title> + <style> + html, body { + margin: 0; + padding: 0; + } + #content { + font-family: Ahem; + font-size: 20px; + line-height: 1em; + color: green; + } + </style> +</head> +<body> + <div id="content"> + xxxx<br> + xxxx<br> + xxxx<br> + xxxx + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/README b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/README new file mode 100644 index 00000000000..69d1737bead --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/README @@ -0,0 +1,29 @@ +CSS Global Support Directory +============================ + +This directory contains common support files (such as images and external +style sheets). These are sync'ed into the support directories of all our +test suites. If you have test-suite-specific support files, please add +them to the appropriate test-suite-specific support/ directory. + +If you add to a support/ directory, please run the tools/supportprop.py +script from the top of the repository to cascade support files into the +lower-level support directories. + +Description of the Common Support File Collection +------------------------------------------------- + +The 1x1-* images are all exactly one pixel. + +The swatch-* images all use 15x15 cells. + +The square-* images all use 15x15 cells with one pixel borders. + +The pattern-* images use cells of various sizes: + + pattern-gg-gr.png 20x20 + pattern-grg-rgr-grg.png 20x20 + pattern-rgr-grg-rgr.png 20x20 + pattern-tr.png 15x15 + pattern-grg-rrg-rgg.png 15x15 + diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/a-green.css b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/a-green.css new file mode 100644 index 00000000000..b0dbb071d5b --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/a-green.css @@ -0,0 +1 @@ +.a { color: green; } diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/b-green.css b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/b-green.css new file mode 100644 index 00000000000..a0473f5ca26 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/b-green.css @@ -0,0 +1 @@ +.b { color: green; } \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/black20x20.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/black20x20.png new file mode 100644 index 0000000000000000000000000000000000000000..ebf7027ee785af8acf0bf6c213c616b4055ee10f GIT binary patch literal 165 zcmeAS@N?(olHy`uVBq!ia0vp^A|TAc1SFYWcSQjy#^NA%Cx&(BWL^R}oCO|{#S9F5 zM?jcysy3fAP>{XE)7O>#4vV<BhIm+`Vi!<Ivcxr_#5q4VH#M(>!MP|ku_QG`p**uB zL&4qCHz2%`PaLR7$kW9!#Nu>vf&}a01d*Pmh1?7*M;I8N6kM?a$})Jm`njxgN@xNA DYH%n_ literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/c-red.css b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/c-red.css new file mode 100644 index 00000000000..d4ba5c64e95 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/c-red.css @@ -0,0 +1 @@ +.c { color: red; } \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/cat.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/cat.png new file mode 100644 index 0000000000000000000000000000000000000000..85dd7324815b8f8ef1a1d0496224c1a0661db9d8 GIT binary patch literal 1883 zcmV-h2c-CkP)<h;3K|Lk000e1NJLTq003eD003hM0ssI3n4EHI0000LbVXQnLvm$d zbZKvHAXI5>WdH}z3>gRm8%$Aad;kCd2XskIMF-Ff83-yN8ye1400009a7bBm000id z000id0mpBsWB>pL*-1n}RCwC$Tnn<>HVmXZK1a^ho3&SK4-(g{9GN13#R7t8y*I%m zZ)BMw!6g9VLwR{T9*v;e^Z&9e>xbnR^*7(`)-M11{_j7xFNSfJ@$>S&(_i1@5GH@m zhpeXC{afFEKhVJCt^WWpLj3iQEg77_JYJnk79anUvL0gx`(AYZ27s0x;q_WRcJD`A zg+R7jBu}y@4l@kFdQJ7DGoh@H-xD(&>S?#kV5MJwAHN8ovs16uEnknmyyLJw3_Dz} z-2t_1y-WcyWmd+)eVZDoh>C$4rk3Oju)y$mQ#%^)+P>PB74gM`GN6$$a17nlNge7- z3RmB|dPjb|$p?mh6-(D?ThB@WuYf>+sj1twj=G%GFkj5O!mZqLtqotF8cC*N$ri;H z2HQ+$17ses$k7#RTbJz}gD2-`@wiB%W8DFRH7rLV$VR8C-{$0BU^7QA)6xcOPkeLG zIC+y8#pH<ZE4DkLuB$eJu=YD09p6saU_=3B*q=j^t+sjfsKzKVsF6<N*#6N`(<ECy zIXKz+z9s_>H3S(N>pr`5y87*;bv|b^HW*-n7#c-VH5l06wfM%K8tMv%QYu1VMJ&`q zXuT9g-DjG%ok+2IhK&G~#M;r0zu4sf-`3+KmoX<0eCv7>JZuYAQ4+JlXds3Yz$`iq zO!pQ9wr}Yor1)n9bJP~%@)tD+crwU7nJ%PeORd0)1m4F<)qG~XO2nT^iMivEf)z-D zBxjR-YQ3Q3>4*f>(%TkH;D#Ki*aVYot>nkyxLr9zV62-PtQAsVZ<)M&ROZ`q=r-yb zxV0FojhaWJa00$t-zE`xTYXArX#ra%P+dk^apt~h+vO{<A@@#@ZFd70kl?YRKP5&g zb`j&Qn9|8fN_S*$P|_f3a(aM4y>N9i$&>6i;Se`Xu#!Aka_7=8lY{bL`gE8-D*^)! zY7!?ohKiqcXDjd>0jZICXBl_KZ$6sC00LyW54V5*dj5-!>hm-t>Ht(52LoWuR*1xE z2G*{@twTZxdhmIo{825j6wMk`;$*SKGZc>R!t=-#&gkXa<yH8pw79M3dp_ikAFn&8 zlrN9ORLOJsca5=ic6o}b2pc1mIER3bjmUh7pG>kkRkQfHYSKVRo~#WuBph;XemDuD z6qUJ989evMeRwkDj)54kU$UA#IGU-IZHnWTVRA#9kA1APN3ZjwA2_hn2Ug_Nvo#=1 zvdA6|8~BUnoI@62w{|P|2@lwrchE#7bJ6Kq6kBhZllSFE87tja$&a^Vsv9DzjxZA* zQVOrQc2nyJWb8G&wn4GZFkUv;Z=ATnxIprXHN_9;9UHeyvrlY2*kxbFPXGYML&r3) zen%FSp5K}|`|V@N#w>xf>JHCqGnQ($o1mTz0Za^NSrBZ!onF6dnw<3&y(VH1bndXf z391*{FlywkRueb2`q*Y`c5i|#c-`R1y$R0#>_jShsA?F))d087sWd*L&RJQPVgO6z zuKDv)`2I=hc!ut73ss<T4Sc(1p2frAo70eTGSQX~W-TmJr(%YaR!iQ`4Ur=@=?jjU zfTygMe0q~vry0lFm|`8tJ+roq*(WDI6R9%w#!|-Y#%eR(ke!N@^4>>?(GbUMv>AFu zU<y*Z1YJ38rx1Sr_(M)_9Tc=-h}Yr*n2uA=E}I+loFj7auyHJrfHI|Po@I%y`4tj7 zZ|2XgMqBeQS(s^b?xD;O6`XX77pU2u-JQEex9#}uQe_K^?kYOxRi<VJVwG%9W16&C zB}3F3+z%GVHY()dth0|pcjvht>SWGaq^ijA)f<0KH8%k6{9y7l%|MvpgU?6jsh(M$ z5N*sz^783ghS!jcq!BDms81L*G}VLWyHB!u>=8qC&htH>PmP{A<v#~L#&MqpRv4yG zw4r_l@+VBe#^s0kwg9GF@{ms(MG=X;Z*q>HB})c5>>6kFjvP9zMaPHfq~YhEr7DrH zD;~lup<3-juf%_Prr9Z-V4nORxcT&~FF{{2Nk&bqG}pd>$n(1*n4sj(w0;RH6sT{j zbhUJqyjT6iN>h5jrHP`lGXxi;LI(=%bR`2^fsT95-&yGjH)}sb@TGCA(mUti&QX<4 z{U$^U=I18hwKL%pN^cWLwM6MtTI+-Up~5fcjt@Bxe*M77{d?${Py^67eTt4eFFZ)l zh8I~nmB}UQ_u%EtP`CsPA88ZuaO!(Y>9V^z>txmUh$SjH&7r>5XT86X<2m!DSg2-= z-<rS@<i5Y4N=-ro_(K1~{gF<l7M3R7QZPDFa>~W*e9lSUNASn#NOM-@)>-Im^e@d- V<q-+yJ<<RG002ovPDHLkV1mLWjBEe^ literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/generalParallelTest.js b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/generalParallelTest.js new file mode 100644 index 00000000000..1a4bf343df0 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/generalParallelTest.js @@ -0,0 +1,231 @@ +(function(root) { +'use strict'; +// +var index = 0; +var suite = root.generalParallelTest = { + // prepare individual test + setup: function(data, options) { + suite._setupDom(data, options); + suite._setupEvents(data, options); + }, + // clone fixture and prepare data containers + _setupDom: function(data, options) { + // clone fixture into off-viewport test-canvas + data.fixture = document.getElementById('fixture').cloneNode(true); + data.fixture.id = 'test-' + (index++); + (document.getElementById('offscreen') || document.body).appendChild(data.fixture); + + // data container for #fixture > .container > .transition + data.transition = { + node: data.fixture.querySelector('.transition'), + values: [], + events: [], + computedStyle: function(property) { + return computedStyle(data.transition.node, property); + } + }; + + // data container for #fixture > .container + data.container = { + node: data.transition.node.parentNode, + values: [], + events: [], + computedStyle: function(property) { + return computedStyle(data.container.node, property); + } + }; + + // data container for #fixture > .container > .transition[:before | :after] + if (data.pseudo) { + data.pseudo = { + name: data.pseudo, + values: [], + computedStyle: function(property) { + return computedStyle(data.transition.node, property, ':' + data.pseudo.name); + } + }; + } + }, + // bind TransitionEnd event listeners + _setupEvents: function(data, options) { + ['transition', 'container'].forEach(function(elem) { + var handler = function(event) { + event.stopPropagation(); + var name = event.propertyName; + var time = Math.round(event.elapsedTime * 1000) / 1000; + var pseudo = event.pseudoElement ? (':' + event.pseudoElement) : ''; + data[elem].events.push(name + pseudo + ":" + time + "s"); + }; + data[elem].node.addEventListener('transitionend', handler, false); + data[elem]._events = {'transitionend': handler}; + }); + }, + // cleanup after individual test + teardown: function(data, options) { + // data.fixture.remove(); + if (data.fixture.parentNode) { + data.fixture.parentNode.removeChild(data.fixture); + } + }, + // invoked prior to running a slice of tests + sliceStart: function(options, tests) { + // inject styles into document + setStyle(options.styles); + // kick off value collection loop + generalParallelTest.startValueCollection(options); + }, + // invoked after running a slice of tests + sliceDone: function(options, tests) { + // stop value collection loop + generalParallelTest.stopValueCollection(options); + // reset styles cache + options.styles = {}; + }, + // called once all tests are done + done: function(options) { + // reset document styles + setStyle(); + reflow(); + }, + // add styles of individual test to slice cache + addStyles: function(data, options, styles) { + if (!options.styles) { + options.styles = {}; + } + + Object.keys(styles).forEach(function(key) { + var selector = '#' + data.fixture.id + // fixture must become #fixture.fixture rather than a child selector + + (key.substring(0, 8) === '.fixture' ? '' : ' ') + + key; + + options.styles[selector] = styles[key]; + }); + }, + // set style and compute values for container and transition + getStyle: function(data) { + reflow(); + // grab current styles: "initial state" + suite._getStyleFor(data, 'from'); + // apply target state + suite._addClass(data, 'to', true); + // grab current styles: "target state" + suite._getStyleFor(data, 'to'); + // remove target state + suite._removeClass(data, 'to', true); + + // clean up the mess created for value collection + data.container._values = []; + data.transition._values = []; + if (data.pseudo) { + data.pseudo._values = []; + } + }, + // grab current styles and store in respective element's data container + _getStyleFor: function(data, key) { + data.container[key] = data.container.computedStyle(data.property); + data.transition[key] = data.transition.computedStyle(data.property); + if (data.pseudo) { + data.pseudo[key] = data.pseudo.computedStyle(data.property); + } + }, + // add class to test's elements and possibly reflow + _addClass: function(data, className, forceReflow) { + data.container.node.classList.add(className); + data.transition.node.classList.add(className); + if (forceReflow) { + reflow(); + } + }, + // remove class from test's elements and possibly reflow + _removeClass: function(data, className, forceReflow) { + data.container.node.classList.remove(className); + data.transition.node.classList.remove(className); + if (forceReflow) { + reflow(); + } + }, + // add transition and to classes to container and transition + startTransition: function(data) { + // add transition-defining class + suite._addClass(data, 'how', true); + // add target state (without reflowing) + suite._addClass(data, 'to', false); + }, + // requestAnimationFrame runLoop to collect computed values + startValueCollection: function(options) { + var raf = window.requestAnimationFrame || function(callback){ + setTimeout(callback, 20); + }; + + // flag denoting if the runLoop should continue (true) or exit (false) + options._collectValues = true; + + function runLoop() { + if (!options._collectValues) { + // test's are done, stop annoying the CPU + return; + } + + // collect current style for test's elements + options.tests.forEach(function(data) { + if (!data.property) { + return; + } + + ['transition', 'container', 'pseudo'].forEach(function(elem) { + var pseudo = null; + if (!data[elem] || (elem === 'pseudo' && !data.pseudo)) { + return; + } + + var current = data[elem].computedStyle(data.property); + var values = data[elem].values; + var length = values.length; + if (!length || values[length - 1] !== current) { + values.push(current); + } + }); + }); + + // rinse and repeat + raf(runLoop); + } + + runLoop(); + }, + // stop requestAnimationFrame runLoop collecting computed values + stopValueCollection: function(options) { + options._collectValues = false; + }, + + // generate test.step function asserting collected events match expected + assertExpectedEventsFunc: function(data, elem, expected) { + return function() { + var _result = data[elem].events.sort().join(" "); + var _expected = typeof expected === 'string' ? expected : expected.sort().join(" "); + assert_equals(_result, _expected, "Expected TransitionEnd events triggered on ." + elem); + }; + }, + // generate test.step function asserting collected values are neither initial nor target + assertIntermediateValuesFunc: function(data, elem) { + return function() { + // the first value (index: 0) is always going to be the initial value + // the last value is always going to be the target value + var values = data[elem].values; + if (data.flags.discrete) { + // a discrete value will just switch from one state to another without having passed intermediate states. + assert_equals(values[0], data[elem].from, "must be initial value while transitioning on ." + elem); + assert_equals(values[1], data[elem].to, "must be target value after transitioning on ." + elem); + assert_equals(values.length, 2, "discrete property only has 2 values ." + elem); + } else { + assert_not_equals(values[1], data[elem].from, "may not be initial value while transitioning on ." + elem); + assert_not_equals(values[1], data[elem].to, "may not be target value while transitioning on ." + elem); + } + + // TODO: first value must be initial, last value must be target + }; + } +}; + +})(window); diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/helper.js b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/helper.js new file mode 100644 index 00000000000..242cd3ca635 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/helper.js @@ -0,0 +1,96 @@ +// +// Simple Helper Functions For Testing CSS +// + +(function(root) { +'use strict'; + +// serialize styles object and dump to dom +// appends <style id="dynamic-style"> to <head> +// setStyle("#some-selector", {"some-style" : "value"}) +// setStyle({"#some-selector": {"some-style" : "value"}}) +root.setStyle = function(selector, styles) { + var target = document.getElementById('dynamic-style'); + if (!target) { + target = document.createElement('style'); + target.id = 'dynamic-style'; + target.type = "text/css"; + document.getElementsByTagName('head')[0].appendChild(target); + } + + var data = []; + // single selector/styles + if (typeof selector === 'string' && styles !== undefined) { + data = [selector, '{', serializeStyles(styles), '}']; + target.textContent = data.join("\n"); + return; + } + // map of selector/styles + for (var key in selector) { + if (Object.prototype.hasOwnProperty.call(selector, key)) { + var _data = [key, '{', serializeStyles(selector[key]), '}']; + data.push(_data.join('\n')); + } + } + + target.textContent = data.join("\n"); +}; + +function serializeStyles(styles) { + var data = []; + for (var property in styles) { + if (Object.prototype.hasOwnProperty.call(styles, property)) { + var prefixedProperty = addVendorPrefix(property); + data.push(prefixedProperty + ":" + styles[property] + ";"); + } + } + + return data.join('\n'); +} + + +// shorthand for computed style +root.computedStyle = function(element, property, pseudo) { + var prefixedProperty = addVendorPrefix(property); + return window + .getComputedStyle(element, pseudo || null) + .getPropertyValue(prefixedProperty); +}; + +// flush rendering buffer +root.reflow = function() { + document.body.offsetWidth; +}; + +// merge objects +root.extend = function(target /*, ..rest */) { + Array.prototype.slice.call(arguments, 1).forEach(function(obj) { + Object.keys(obj).forEach(function(key) { + target[key] = obj[key]; + }); + }); + + return target; +}; + +// dom fixture helper ("resetting dom test elements") +var _domFixture; +var _domFixtureSelector; +root.domFixture = function(selector) { + var fixture = document.querySelector(selector || _domFixtureSelector); + if (!fixture) { + throw new Error('fixture ' + (selector || _domFixtureSelector) + ' not found!'); + } + if (!_domFixture && selector) { + // save a copy + _domFixture = fixture.cloneNode(true); + _domFixtureSelector = selector; + } else if (_domFixture) { + // restore the copy + var tmp = _domFixture.cloneNode(true); + fixture.parentNode.replaceChild(tmp, fixture); + } else { + throw new Error('domFixture must be initialized first!'); + } +}; +})(window); diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/import-green.css b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/import-green.css new file mode 100644 index 00000000000..537104e6633 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/import-green.css @@ -0,0 +1 @@ +.import { color: green; } diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/import-red.css b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/import-red.css new file mode 100644 index 00000000000..9945ef47114 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/import-red.css @@ -0,0 +1 @@ +.import { color: red; } diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/min-width-tables-001-iframe.html b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/min-width-tables-001-iframe.html new file mode 100644 index 00000000000..edc548a6aab --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/min-width-tables-001-iframe.html @@ -0,0 +1,59 @@ +<!DOCTYPE html> +<html><head> + <meta charset="utf-8"> + <title>iframe containing the meat of the test</title> + <style> +body { + margin: 0; + overflow: hidden; +} +/* green div that should cover the red divs */ +#green { + position: absolute; + left: 0; + top: 0; + background-color: green; + width: 100%; + height: 600px; +} +.spacer { + height: 98px; + width: 20px; +} +.item { + background-color: red; + display: block;/* property under test */ + /* border to aid understanding of boundaries between items */ + border-style: solid; + border-width: 1px; + border-color: red;/* Note: if you're trying to debug this, use a different color here */ +} +/* 100px = 10*(1 + 8 + 1) */ +@media (min-width: 100px) { + #green { + width: 100px; + height: 100px;/* = 1 + 98 + 1 */ + } + .item { + display: table-cell;/* property and value under test */ + } +} + </style> +</head> +<body> + <div> + <div class="item"><div class="spacer"></div></div> + <div class="item"><div class="spacer"></div></div> + <div class="item"><div class="spacer"></div></div> + <div class="item"><div class="spacer"></div></div> + <div class="item"><div class="spacer"></div></div> + <div class="item"><div class="spacer"></div></div> + <div class="item"><div class="spacer"></div></div> + <div class="item"><div class="spacer"></div></div> + <div class="item"><div class="spacer"></div></div> + <div class="item"><div class="spacer"></div></div> + </div> + <div id="green"></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/one.gif b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/one.gif new file mode 100644 index 0000000000000000000000000000000000000000..74cf7839c9fc0f1572d600ef559972b8e1ae57fc GIT binary patch literal 184 zcmZ?wbh9u|G-5Dfc+3C-|NsBLfB*je{rltN<K^Y$>+9?1&!2B^Zx5D4Cv-ppAiWGM zxdJCVSMRlWeRlW%1dYCw%y}8B*5$n3SD<sgB=>&By7x8j|C=6ca1apCb6WIKbpj6; z^Ah1xGH#0-ni*&B*~iu3C>+hvz?e|@qg2M`BvZ?hziHe&N0WD0?0??a(Ad=6(%RPE R(b?7A)7#fSp+S(r8UVwOMW_G( literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/parsing-utils.js b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/parsing-utils.js new file mode 100644 index 00000000000..beea4958ce8 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/parsing-utils.js @@ -0,0 +1,866 @@ +var ParsingUtils = (function() { +function testInlineStyle(value, expected) { + var div = document.createElement('div'); + div.style.setProperty('shape-outside', value); + var actual = div.style.getPropertyValue('shape-outside'); + assert_equals(actual, expected); +} + +function testComputedStyle(value, expected) { + var div = document.createElement('div'); + div.style.setProperty('shape-outside', value); + document.body.appendChild(div); + var style = getComputedStyle(div); + var actual = style.getPropertyValue('shape-outside'); + actual = roundResultStr(actual); + document.body.removeChild(div); + + // Some of the tests in this suite have either/or expected results + // so this check allows for testing that at least one of them passes. + // Description of the 2 expecteds is below near calcTestValues. + if(Object.prototype.toString.call( expected ) === '[object Array]' && expected.length == 2) { + assert_true(expected[0] == actual || expected[1] == actual) + } else { + assert_equals(actual, typeof expected !== 'undefined' ? expected : value); + } +} + +function testShapeMarginInlineStyle(value, expected) { + var div = document.createElement('div'); + div.style.setProperty('shape-outside', "border-box inset(10px)"); + div.style.setProperty('shape-margin', value); + var actual = div.style.getPropertyValue('shape-margin'); + assert_equals(actual, expected); +} + +function testShapeMarginComputedStyle(value, expected) { + + var outerDiv = document.createElement('div'); + outerDiv.style.setProperty('width', '100px'); + + var innerDiv = document.createElement('div'); + innerDiv.style.setProperty('shape-outside', "border-box inset(10px)"); + innerDiv.style.setProperty('shape-margin', value); + + outerDiv.appendChild(innerDiv); + document.body.appendChild(outerDiv); + + var style = getComputedStyle(innerDiv); + var actual = style.getPropertyValue('shape-margin'); + + assert_not_equals(actual, null); + if(actual.indexOf('calc') == -1 ) + actual = roundResultStr(actual); + document.body.removeChild(outerDiv); + + // See comment above about multiple expected results + if(Object.prototype.toString.call( expected ) === '[object Array]' && expected.length == 2) { + assert_true(expected[0] == actual || expected[1] == actual) + } else { + assert_equals(actual, !expected ? '0px' : expected); + } +} + +function testShapeThresholdInlineStyle(value, expected) { + var div = document.createElement('div'); + div.style.setProperty('shape-outside', 'url(someimage.png)'); + div.style.setProperty('shape-image-threshold', value); + var actual = div.style.getPropertyValue('shape-image-threshold'); + assert_equals(actual, expected); +} + +function testShapeThresholdComputedStyle(value, expected) { + + var div = document.createElement('div'); + div.style.setProperty('shape-outside', 'url(someimage.png)'); + div.style.setProperty('shape-image-threshold', value); + document.body.appendChild(div); + + var style = getComputedStyle(div); + var actual = style.getPropertyValue('shape-image-threshold'); + + assert_not_equals(actual, null); + if(actual.indexOf('calc') == -1 ) + actual = roundResultStr(actual); + document.body.removeChild(div); + + // See comment above about multiple expected results + if(Object.prototype.toString.call( expected ) === '[object Array]' && expected.length == 2) { + assert_true(expected[0] == actual || expected[1] == actual) + } else { + assert_equals(actual, !expected ? '0' : expected); + } +} + +// Builds an array of test cases to send to testharness.js where one test case is: [name, actual, expected] +// These test cases will verify results from testInlineStyle() or testComputedStyle() +function buildTestCases(testCases, testType) { + var results = []; + + // If test_type isn't specified, test inline style + var type = typeof testType == 'undefined' ? 'invalid': testType; + + testCases.forEach(function(test) { + oneTestCase = []; + + // name - annotated by type (inline vs. computed) + if ( test.hasOwnProperty('name') ) { + oneTestCase.push(test['name'] +' - '+ type); + } else { + // If test_name isn't specified, use the actual + oneTestCase.push(test['actual'] +' - '+ type); + } + + // actual + oneTestCase.push(test['actual']) + + // expected + if( type.indexOf('invalid') != -1 ){ + oneTestCase.push(null) + } else if( type == 'inline' ) { + oneTestCase.push(test['expected_inline']); + } else if( type == 'computed' ){ + oneTestCase.push( convertToPx(test['expected_computed']) ); + } + results.push(oneTestCase); + }); + return results; +} + + +function buildPositionTests(shape, valid, type, units) { + var results = new Array(); + var convert = type.indexOf('computed') != -1 ? true : false; + + if(Object.prototype.toString.call( units ) === '[object Array]') { + units.forEach(function(unit) { + positionTests = buildPositionTests(shape, valid, type, unit); + results = results.concat(positionTests); + }); + } else { + if (valid) { + validPositions.forEach(function(test) { + var testCase = [], testName, actual, expected; + // skip if this isn't explicitly testing length units + if( !(type.indexOf('lengthUnit') != -1 && test[0].indexOf("u1") == -1)) { + // actual + actual = shape + '(at ' + setUnit(test[0], false, units) +')'; + + // expected + // if(convert && shape == 'circle') + // expected = shape + '(at ' + setUnit(test[1], convert, units) +')'; + // else if(convert && shape == 'ellipse') + // expected = shape + '(at ' + setUnit(test[1], convert, units) +')'; + // else + expected = shape + '(at ' + setUnit(test[1], convert, units) +')'; + + // name + if (type == 'lengthUnit + inline') + testName = 'test unit (inline): ' + units +' - '+ actual; + else if (type == 'lengthUnit + computed') + testName = 'test unit (computed): ' + units +' - '+ actual; + else + testName = (actual + ' serializes as ' + expected +' - '+ type); + + testCase.push(testName) + testCase.push(actual); + testCase.push(expected); + results.push(testCase); + } + }); + } else { + invalidPositions.forEach(function(test) { + var testValue = shape + '(at ' + setUnit(test, false, units) +')'; + testCase = new Array(); + testCase.push(testValue + ' is invalid'); + testCase.push(testValue); + testCase.push(null); + results.push(testCase); + }); + } + } + return unique(results); +} + +function buildRadiiTests(shape, type, units) { + var results = new Array(); + var testUnits = typeof units == 'undefined' ? 'px': units; + var convert = type.indexOf('computed') != -1 ? true : false; + + if(Object.prototype.toString.call( testUnits ) === '[object Array]') { + testUnits.forEach(function(unit) { + radiiTests = buildRadiiTests(shape, type, unit); + results = results.concat(radiiTests); + }); + } else { + var validRadii = shape == 'circle' ? validCircleRadii : validEllipseRadii; + validRadii.forEach(function(test) { + var testCase = [], name, actual, expected; + + // skip if this isn't explicitly testing length units + if( !(type.indexOf('lengthUnit') != -1 && test[0].indexOf("u1") == -1) ) { + actual = shape + '(' + setUnit(test[0], false, testUnits) +')'; + // name + if (type.indexOf('lengthUnit') != -1) { + name = 'test unit: ' + units +' - '+ actual; + if(type.indexOf('computed') != -1) + name = name + ' - computed'; + else + name = name + ' - inline'; + } + else + name = actual +' - '+ type; + + testCase.push(name); + + // actual + testCase.push(actual); + + // expected + if(type.indexOf('computed') != -1 && test.length == 3) { + expected = shape + '(' + setUnit(test[2], convert, testUnits) +')'; + } else { + expected = shape + '(' + setUnit(test[1], convert, testUnits) +')'; + } + testCase.push(expected); + results.push(testCase); + } + }); + } + return unique(results); +} + +function buildInsetTests(unit1, unit2, type) { + var results = new Array(); + var convert = type == 'computed' ? true : false; + + if(Object.prototype.toString.call( unit1 ) === '[object Array]') { + unit1.forEach(function(unit) { + insetTests = buildInsetTests(unit, unit2, type); + results = results.concat(insetTests); + }); + } else { + validInsets.forEach(function(test) { + var testCase = [], name, actual, expected; + + name = setUnit(test[0], false, unit1, unit2) +' - '+ type; + actual = 'inset(' + setUnit(test[1], convert, unit1, unit2) +')'; + expected = actual; + + testCase.push(name); + testCase.push(actual); + testCase.push(expected); + + results.push(testCase); + }); + } + return unique(results); +} + +function buildPolygonTests(unitSet, type) { + var results = new Array(); + var convert = type == 'computed' ? true : false; + + unitSet.forEach(function(set) { + validPolygons.forEach(function(test) { + var testCase = []; + // name + testCase.push(setUnit(test[0], false, set[0], set[1], set[2]) +' - '+ type); + // actual + testCase.push('polygon(' + setUnit(test[1], false, set[0], set[1], set[2]) +')'); + // expected + testCase.push('polygon(' + setUnit(test[1], convert, set[0], set[1], set[2]) +')'); + results.push(testCase); + }); + }); + return unique(results); +} + +function buildCalcTests(testCases, type) { + var results = new Array(); + testCases.forEach(function(test){ + var testCase = []; + if(type == 'computed') { + testCase.push(test[0] + ' - computed style'); + testCase.push(test[0]); + testCase.push(test[2]); + } + else { + testCase.push(test[0] + ' - inline style'); + testCase.push(test[0]); + testCase.push(test[1]); + } + testCase.push(type); + results.push(testCase) + }); + return unique(results); +} + +function unique(tests) { + var list = tests.concat(); + for(var i = 0; i< list.length; ++i) { + for(var j = i+1; j < list.length; ++j) { + if(list[i][0] === list[j][0]) + list.splice(j--, 1); + } + } + return list; +} + +function setUnit(str, convert, unit1, unit2, unit3) { + var retStr = str; + if(typeof unit1 !== 'undefined') { + retStr = retStr.replace(new RegExp('u1', 'g'), unit1); + } + if(typeof unit2 !== 'undefined') { + retStr = retStr.replace(new RegExp("u2", 'g'), unit2); + } + if(typeof unit3 !== 'undefined') { + retStr = retStr.replace(new RegExp("u3", 'g'), unit3); + } + retStr = convert ? convertToPx(retStr) : retStr; + return retStr; +} + +function convertToPx(origValue) { + + var valuesToConvert = origValue.match(/[0-9]+(\.[0-9]+)?([a-z]{2,4}|%)/g); + if(!valuesToConvert) + return origValue; + + var retStr = origValue; + for(var i = 0; i < valuesToConvert.length; i++) { + var unit = valuesToConvert[i].match(/[a-z]{2,4}|%/).toString(); + var numberStr = valuesToConvert[i].match(/[0-9]+(\.[0-9]+)?/)[0]; + + var number = parseFloat(numberStr); + var convertedUnit = 'px'; + if( typeof number !== 'NaN' ) + { + if (unit == 'in') { + number = (96 * number); + } else if (unit == 'cm') { + number = (37.795275591 * number); + } else if (unit == 'mm') { + number = (3.779527559 * number); + } else if (unit == 'pt') { + number = (1.333333333333 * number); + } else if (unit == 'pc') { + number = (16 * number); + } else if (unit == 'em') { + number = (16 * number); + } else if (unit == 'ex') { + number = (7.1796875 * number); + } else if (unit == 'ch') { + number = (8 * number); + } else if (unit == 'rem') { + number = (16 * number); + } else if (unit == 'vw') { + number = ((.01 * window.innerWidth) * number); + } else if (unit == 'vh') { + number = ((.01 * window.innerHeight) * number); + } else if (unit == 'vmin') { + number = Math.min( (.01 * window.innerWidth), (.01 * window.innerHeight) ) * number; + } else if (unit == 'vmax') { + number = Math.max( (.01 * window.innerWidth), (.01 * window.innerHeight) ) * number; + } + else { + convertedUnit = unit; + } + number = Math.round(number * 1000) / 1000; + var find = valuesToConvert[i]; + var replace = number.toString() + convertedUnit; + retStr = retStr.replace(valuesToConvert[i], number.toString() + convertedUnit); + } + } + return retStr.replace(',,', ','); +} + +function roundResultStr(str) { + if(Object.prototype.toString.call( str ) !== '[object String]') + return str; + + var numbersToRound = str.match(/[0-9]+\.[0-9]+/g); + if(!numbersToRound) + return str; + + var retStr = str; + for(var i = 0; i < numbersToRound.length; i++) { + num = parseFloat(numbersToRound[i]); + if( !isNaN(num) ) { + roundedNum = Math.round(num*1000)/1000; + retStr = retStr.replace(numbersToRound[i].toString(), roundedNum.toString()); + } + } + + return retStr; +} + +function generateInsetRoundCases(units, testType) { + var convert = testType.indexOf('computed') != -1 ? true : false; + var testUnit = units; + var sizes = [ + '10' + units, + '20' + units, + '30' + units, + '40' + units + ]; + + function insetRound(value) { + return 'inset(10' +testUnit+ ' round ' + value + ')'; + } + + function serializedInsetRound(lhsValues, rhsValues, convert) { + var retStr = ''; + if(!rhsValues) + retStr = 'inset(10' +testUnit+ ' round ' + lhsValues +')'; + else + retStr = 'inset(10' +testUnit+ ' round ' + lhsValues +' / '+ rhsValues +')'; + + if(convert) + return convertToPx(retStr); + + return retStr; + } + + var results = [], left, lhs, right, rhs; + for (left = 1; left <= 4; left++) { + lhs = sizes.slice(0, left).join(' '); + results.push([insetRound(lhs) +' - '+ testType, insetRound(lhs), serializedInsetRound(lhs, null, convert)]); + for (right = 1; right <= 4; right++) { + rhs = sizes.slice(0, right).join(' '); + if(lhs == rhs) + results.push([insetRound(lhs + ' / ' + rhs) +' - '+ testType, insetRound(lhs + ' / ' + rhs), serializedInsetRound(lhs, null, convert)]); + else + results.push([insetRound(lhs + ' / ' + rhs) +' - '+ testType, insetRound(lhs + ' / ' + rhs), serializedInsetRound(lhs, rhs, convert)]); + } + } + return results; +} + +var validUnits = [ + "cm","mm","in","pt","pc", // Absolute length units (omitting px b/c we default to that in all tests) + "em","ex","ch","rem", // Font relative length units + "vw","vh","vmin","vmax" // Viewport percentage units + ] + +/// [actual, expected] +var validPositions = [ + +/// [ percent ], [ length ], [ percent | percent ], [ percent | length ], [ length | percent ], [ length | length ] + ["50%", "50% 50%"], + ["50u1", "50u1 50%"], + ["50% 50%", "50% 50%"], + ["50% 50u1", "50% 50u1"], + ["50u1 50%", "50u1 50%"], + ["50u1 50u1", "50u1 50u1"], + +///// [ keyword ], [ keyword keyword ] x 5 keywords + ["left", "0% 50%"], + ["top", "50% 0%"], + ["right", "100% 50%"], + ["bottom", "50% 100%"], + ["center", "50% 50%"], + + ["left top", "0% 0%"], + ["left bottom", "0% 100%"], + ["left center", "0% 50%"], + + ["top left", "0% 0%"], + ["top right", "100% 0%"], + ["top center", "50% 0%"], + + ["right top", "100% 0%"], + ["right bottom", "100% 100%"], + ["right center", "100% 50%"], + + ["bottom left", "0% 100%"], + ["bottom right", "100% 100%"], + ["bottom center", "50% 100%"], + + ["center top", "50% 0%"], + ["center left", "0% 50%"], + ["center right", "100% 50%"], + ["center bottom", "50% 100%"], + ["center center", "50% 50%"], + +////// [ keyword | percent ], [ keyword | length ], [ percent | keyword ], [ length | keyword ] x 5 keywords + ["left 50%", "0% 50%"], + ["left 50u1", "0% 50u1"], + + ["50% top", "50% 0%"], + ["50u1 top", "50u1 0%"], + + ["right 80%", "100% 80%"], + ["right 80u1", "100% 80u1"], + + ["70% bottom", "70% 100%"], + ["70u1 bottom", "70u1 100%"], + + ["center 60%", "50% 60%"], + ["center 60u1", "50% 60u1"], + ["60% center", "60% 50%"], + ["60u1 center", "60u1 50%"], + +////// [ keyword | keyword percent ], [ keyword | keyword length ] x 5 keywords + ["center top 50%", "50% 50%"], + ["center top 50u1", "50% 50u1"], + ["center left 50%", "50% 50%"], + ["center left 50u1", "50u1 50%"], + ["center right 70%", "30% 50%"], + ["center right 70u1", "right 70u1 top 50%"], + ["center bottom 70%", "50% 30%"], + ["center bottom 70u1", "left 50% bottom 70u1"], + + ["left top 50%", "0% 50%"], + ["left top 50u1", "0% 50u1"], + ["left bottom 70%", "0% 30%"], + ["left bottom 70u1", "left 0% bottom 70u1"], + + ["top left 50%", "50% 0%"], + ["top left 50u1", "50u1 0%"], + ["top right 70%", "30% 0%"], + ["top right 70u1", "right 70u1 top 0%"], + + ["bottom left 50%", "50% 100%"], + ["bottom left 50u1", "50u1 100%"], + ["bottom right 70%", "30% 100%"], + ["bottom right 70u1", "right 70u1 top 100%"], + + ["right bottom 70%", "100% 30%"], + ["right bottom 70u1", "left 100% bottom 70u1"], + ["right top 50%", "100% 50%"], + ["right top 50u1", "100% 50u1"], + +////// [ keyword percent | keyword], [ keyword length | keyword ] x 5 keywords + ["left 50% center", "50% 50%"], + ["left 50u1 center", "50u1 50%"], + ["left 50% top", "50% 0%"], + ["left 50u1 top", "50u1 0%"], + ["left 50% bottom", "50% 100%"], + ["left 50u1 bottom", "50u1 100%"], + + ["top 50% center", "50% 50%"], + ["top 50u1 center", "50% 50u1"], + ["top 50% left", "0% 50%"], + ["top 50u1 left", "0% 50u1"], + ["top 50% right", "100% 50%"], + ["top 50u1 right", "100% 50u1"], + + ["bottom 70% center", "50% 30%"], + ["bottom 70u1 center", "left 50% bottom 70u1"], + ["bottom 70% left", "0% 30%"], + ["bottom 70u1 left", "left 0% bottom 70u1"], + ["bottom 70% right", "100% 30%"], + ["bottom 70u1 right", "left 100% bottom 70u1"], + + ["right 80% center", "20% 50%"], + ["right 80u1 center", "right 80u1 top 50%"], + ["right 80% bottom", "20% 100%"], + ["right 80u1 bottom", "right 80u1 top 100%"], + ["right 80% top", "20% 0%"], + ["right 80u1 top", "right 80u1 top 0%"], + +////// [ keyword percent | keyword percent], [ keyword percent | keyword length], +////// [ keyword length | keyword length], [ keyword length | keyword percent] x 5 keywords + ["left 50% top 50%", "50% 50%"], + ["left 50% top 50u1", "50% 50u1"], + ["left 50% bottom 70%", "50% 30%"], + ["left 50% bottom 70u1", "left 50% bottom 70u1"], + ["left 50u1 top 50%", "50u1 50%"], + ["left 50u1 top 50u1", "50u1 50u1"], + ["left 50u1 bottom 70%", "50u1 30%"], + ["left 50u1 bottom 70u1", "left 50u1 bottom 70u1"], + + ["top 50% left 50%", "50% 50%"], + ["top 50% left 50u1", "50u1 50%"], + ["top 50% right 80%", "20% 50%"], + ["top 50% right 80u1", "right 80u1 top 50%"], + ["top 50u1 left 50%", "50% 50u1"], + ["top 50u1 left 50u1", "50u1 50u1"], + ["top 50u1 right 80%", "20% 50u1"], + ["top 50u1 right 80u1", "right 80u1 top 50u1"], + + ["bottom 70% left 50%", "50% 30%"], + ["bottom 70% left 50u1", "50u1 30%"], + ["bottom 70% right 80%", "20% 30%"], + ["bottom 70% right 80u1", "right 80u1 top 30%"], + ["bottom 70u1 left 50%", "left 50% bottom 70u1"], + ["bottom 70u1 left 50u1", "left 50u1 bottom 70u1"], + ["bottom 70u1 right 80%", "left 20% bottom 70u1"], + ["bottom 70u1 right 80u1", "right 80u1 bottom 70u1"], + + ["right 80% top 50%", "20% 50%"], + ["right 80% top 50u1", "20% 50u1"], + ["right 80% bottom 70%", "20% 30%"], + ["right 80% bottom 70u1", "left 20% bottom 70u1"], + ["right 80u1 top 50%", "right 80u1 top 50%"], + ["right 80u1 top 50u1", "right 80u1 top 50u1"], + ["right 80u1 bottom 70%", "right 80u1 top 30%"], + ["right 80u1 bottom 70u1", "right 80u1 bottom 70u1"], +]; + +var invalidPositions = [ +////// [ keyword | percent ], [ keyword | length ], [ percent | keyword ], [ length | keyword ] x 5 keywords + "50% left", + "50px left", + "top 50%", + "80% right", + "80px right", + "bottom 70%", + "bottom 70px", + +////// [ keyword | keyword percent ], [ keyword | keyword length ] x 5 keywords + "center center 60%", + "center center 60px", + + "left center 60%", + "left center 60px", + "left right 80%", + "left right 80px", + "left left 50%", + "left left 50px", + + "top center 60%", + "top center 60px", + "top bottom 80%", + "top bottom 80px", + "top top 50%", + "top top 50px", + + "bottom center 60%", + "bottom center 60px", + "bottom top 50%", + "bottom top 50px", + "bottom bottom 50%", + "bottom bottom 50px", + + "right center 60%", + "right center 60px", + "right left 50%", + "right left 50px", + "right right 70%", + "right right 70px", + +////// [ keyword percent | keyword], [ keyword length | keyword ] x 5 keywords + "center 60% top", + "center 60px top", + "center 60% bottom", + "center 60px bottom", + "center 60% left", + "center 60px left", + "center 60% right", + "center 60px right", + "center 60% center", + "center 60px center", + + "left 50% right", + "left 50px right", + "left 50% left", + "left 50px left", + + "top 50% bottom", + "top 50px bottom", + "top 50% top", + "top 50px top", + + "bottom 70% top", + "bottom 70px top", + "bottom 70% bottom", + "bottom 70px bottom", + + "right 80% left", + "right 80px left", + +////// [ keyword percent | keyword percent], [ keyword percent | keyword length], +////// [ keyword length | keyword length], [ keyword length | keyword percent] x 5 keywords + "center 60% top 50%", + "center 60% top 50px", + "center 60% bottom 70%", + "center 60% bottom 70px", + "center 60% left 50%", + "center 60% left 50px", + "center 60% right 70%", + "center 60% right 70px", + "center 60% center 65%", + "center 60% center 65px", + "center 60px top 50%", + "center 60px top 50px", + "center 60px bottom 70%", + "center 60px bottom 70px", + "center 60px left 50%", + "center 60px left 50px", + "center 60px right 70%", + "center 60px right 70px", + "center 60px center 65%", + "center 60px center 65px", + + "left 50% center 60%", + "left 50% center 60px", + "left 50% right 80%", + "left 50% right 80px", + "left 50% left 50%", + "left 50% left 50px", + "left 50px center 60%", + "left 50px center 60px", + "left 50px right 80%", + "left 50px right 80px", + "left 50px left 50%", + "left 50px left 50px", + + "top 50% center 60%", + "top 50% center 60px", + "top 50% bottom 50%", + "top 50% bottom 50px", + "top 50% top 50%", + "top 50% top 50px", + "top 50px center 60%", + "top 50px center 60px", + "top 50px bottom 70%", + "top 50px bottom 70px", + "top 50px top 50%", + "top 50px top 50px", + + "bottom 70% center 60%", + "bottom 70% center 60px", + "bottom 70% top 50%", + "bottom 70% top 50px", + "bottom 70% bottom 50%", + "bottom 70% bottom 50px", + "bottom 70px center 60%", + "bottom 70px center 60px", + "bottom 70px top 50%", + "bottom 70px top 50px", + "bottom 70px bottom 50%", + "bottom 70px bottom 50px", + + "right 80% center 60%", + "right 80% center 60px", + "right 80% left 50%", + "right 80% left 50px", + "right 80% right 85%", + "right 80% right 85px", + "right 80px center 60%", + "right 80px center 60px", + "right 80px left 50%", + "right 80px left 50px", + "right 80px right 85%", + "right 80px right 85px" +]; + +// valid radii values for circle + ellipse +// [value, expected_inline, [expected_computed?]] +var validCircleRadii = [ + ['', 'at 50% 50%', 'at 50% 50%'], + ['50u1', '50u1 at 50% 50%'], + ['50%', '50% at 50% 50%'], + ['closest-side', 'at 50% 50%'], + ['farthest-side', 'farthest-side at 50% 50%'] +] +var validEllipseRadii = [ + ['', 'at 50% 50%', 'at 50% 50%'], + ['50u1', '50u1 at 50% 50%', '50u1 at 50% 50%'], + ['50%', '50% at 50% 50%', '50% at 50% 50%'], + ['closest-side', 'at 50% 50%', 'at 50% 50%'], + ['farthest-side', 'farthest-side at 50% 50%', 'farthest-side at 50% 50%'], + ['50u1 100u1', '50u1 100u1 at 50% 50%'], + ['100u1 100px', '100u1 100px at 50% 50%'], + ['25% 50%', '25% 50% at 50% 50%'], + ['50u1 25%', '50u1 25% at 50% 50%'], + ['25% 50u1', '25% 50u1 at 50% 50%'], + ['25% closest-side', '25% at 50% 50%'], + ['25u1 closest-side', '25u1 at 50% 50%'], + ['closest-side 75%', 'closest-side 75% at 50% 50%'], + ['closest-side 75u1', 'closest-side 75u1 at 50% 50%'], + ['25% farthest-side', '25% farthest-side at 50% 50%'], + ['25u1 farthest-side', '25u1 farthest-side at 50% 50%'], + ['farthest-side 75%', 'farthest-side 75% at 50% 50%'], + ['farthest-side 75u1', 'farthest-side 75u1 at 50% 50%'], + ['closest-side closest-side', 'at 50% 50%'], + ['farthest-side farthest-side', 'farthest-side farthest-side at 50% 50%'], + ['closest-side farthest-side', 'closest-side farthest-side at 50% 50%'], + ['farthest-side closest-side', 'farthest-side at 50% 50%'] +] + +var validInsets = [ + ["One arg - u1", "10u1"], + ["One arg - u2", "10u2"], + ["Two args - u1 u1", "10u1 20u1"], + ["Two args - u1 u2", "10u1 20u2"], + ["Two args - u2 u1", "10u2 20u1"], + ["Two args - u2 u2", "10u2 20u2"], + ["Three args - u1 u1 u1", "10u1 20u1 30u1"], + ["Three args - u1 u1 u2", "10u1 20u1 30u2"], + ["Three args - u1 u2 u1", "10u1 20u2 30u1"], + ["Three args - u1 u2 u2 ", "10u1 20u2 30u2"], + ["Three args - u2 u1 u1", "10u2 20u1 30u1"], + ["Three args - u2 u1 u2 ", "10u2 20u1 30u2"], + ["Three args - u2 u2 u1 ", "10u2 20u2 30u1"], + ["Three args - u2 u2 u2 ","10u2 20u2 30u2"], + ["Four args - u1 u1 u1 u1", "10u1 20u1 30u1 40u1"], + ["Four args - u1 u1 u1 u2", "10u1 20u1 30u1 40u2"], + ["Four args - u1 u1 u2 u1", "10u1 20u1 30u2 40u1"], + ["Four args - u1 u1 u2 u2", "10u1 20u1 30u2 40u2"], + ["Four args - u1 u2 u1 u1", "10u1 20u2 30u1 40u1"], + ["Four args - u1 u2 u1 u2", "10u1 20u2 30u1 40u2"], + ["Four args - u1 u2 u2 u1", "10u1 20u2 30u2 40u1"], + ["Four args - u1 u2 u2 u2", "10u1 20u2 30u2 40u2"], + ["Four args - u2 u1 u1 u1", "10u2 20u1 30u1 40u1"], + ["Four args - u2 u1 u1 u2", "10u2 20u1 30u1 40u2"], + ["Four args - u2 u1 u2 u1", "10u2 20u1 30u2 40u1"], + ["Four args - u2 u1 u2 u2", "10u2 20u1 30u2 40u2"], + ["Four args - u2 u2 u1 u1", "10u2 20u2 30u1 40u1"], + ["Four args - u2 u2 u1 u2", "10u2 20u2 30u1 40u2"], + ["Four args - u2 u2 u2 u1", "10u2 20u2 30u2 40u1"], + ["Four args - u2 u2 u2 u2", "10u2 20u2 30u2 40u2"] +] + +var validPolygons = [ + ["One vertex - u1 u1", "10u1 20u1"], + ["One vertex - u1 u2", "10u1 20u2"], + ["Two vertices - u1 u1, u1 u1", "10u1 20u1, 30u1 40u1"], + ["Two vertices - u1 u1, u2 u2", "10u1 20u1, 30u2 40u2"], + ["Two vertices - u2 u2, u1 u1", "10u2 20u2, 30u1 40u1"], + ["Two vertices - u1 u2, u2 u1", "10u1 20u2, 30u2 40u1"], + ["Three vertices - u1 u1, u1 u1, u1 u1", "10u1 20u1, 30u1 40u1, 50u1 60u1"], + ["Three vertices - u2 u2, u2 u2, u2 u2", "10u2 20u2, 30u2 40u2, 50u2 60u2"], + ["Three vertices - u3 u3, u3 u3, u3 u3", "10u3 20u3, 30u3 40u3, 50u3 60u3"], + ["Three vertices - u1 u1, u2 u2, u3 u3", "10u1 20u1, 30u2 40u2, 50u3 60u3"], + ["Three vertices - u3 u3, u1, u1, u2 u2", "10u3 20u3, 30u1 40u1, 50u2 60u2"], +] + +// [test value, expected property value, expected computed style] +var calcTestValues = [ + ["calc(10in)", "calc(10in)", "960px"], + ["calc(10in + 20px)", "calc(980px)", "980px"], + ["calc(30%)", "calc(30%)", "30%"], + ["calc(100%/4)", "calc(25%)", "25%"], + ["calc(25%*3)", "calc(75%)", "75%"], + // These following two test cases represent an either/or situation in the spec + // computed value is always supposed to be, at most, a tuple of a length and a percentage. + // the computed value of a โ€˜calc()โ€™ expression can be represented as either a number or a tuple + // of a dimension and a percentage. + // http://www.w3.org/TR/css3-values/#calc-notation + ["calc(25%*3 - 10in)", "calc(75% - 10in)", ["calc(75% - 960px)", "calc(-960px + 75%)"]], + ["calc((12.5%*6 + 10in) / 4)", "calc((75% + 10in) / 4)", ["calc((75% + 960px) / 4)", "calc(240px + 18.75%)"]] +] + +return { + testInlineStyle: testInlineStyle, + testComputedStyle: testComputedStyle, + testShapeMarginInlineStyle: testShapeMarginInlineStyle, + testShapeMarginComputedStyle: testShapeMarginComputedStyle, + testShapeThresholdInlineStyle: testShapeThresholdInlineStyle, + testShapeThresholdComputedStyle: testShapeThresholdComputedStyle, + buildTestCases: buildTestCases, + buildRadiiTests: buildRadiiTests, + buildPositionTests: buildPositionTests, + buildInsetTests: buildInsetTests, + buildPolygonTests: buildPolygonTests, + generateInsetRoundCases: generateInsetRoundCases, + buildCalcTests: buildCalcTests, + validUnits: validUnits, + calcTestValues: calcTestValues, + roundResultStr: roundResultStr +} +})(); diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/pattern-gg-gr.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/pattern-gg-gr.png new file mode 100644 index 0000000000000000000000000000000000000000..091de70bb72541dda90cafaa4a2eb68d82fb5bdb GIT binary patch literal 203 zcmeAS@N?(olHy`uVBq!ia0vp^8X(NU1SFZ~=vx6P#^NA%Cx&(BWL^R}oCO|{#S9F5 zM?jcysy3fAP>{XE)7O>#4zs*CpV-thX~%&=k|nMYCC>S|xv6<249-QVi6yBi3gww4 z84B*6z5(HleBwYw7M?DSArXh)UO33fpdi3}P(!S4ZZ<c&U5&+WerCy)HkoP(1`<4M m%?I}%c%8QA^i?RYmoGe?DKLBT?xjF87(8A5T-G@yGywqU{5T8% literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/pattern-grg-rgr-grg.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/pattern-grg-rgr-grg.png new file mode 100644 index 0000000000000000000000000000000000000000..6fcfeb4883edea810f880fabb861e09df7871695 GIT binary patch literal 222 zcmV<403rX0P)<h;3K|Lk000e1NJLTq001fg001fo0ssI3J*IA&0001`Nkl<Zc-rli z!4iWo2t*%#Ie$(sX|)yGI5;(q%PA9Jmkl8?93ULP9AIK)7R>(GjOxRBMQwxx1mJBk z?aXifhV@+AVlyc!*ZYwgelQCuviAYh+_OT<gcQNg6t-;4S{PYlcfkL&YW~~R`(A2{ zSbtgn)%$nx`tP29_xaQNq4OWFf2l=xr1`(fKl$`TFZx42zT!BA22b>&*N-Q9(T_&| Y0MVE_0ae*F0000007*qoM6N<$f~59g2LJ#7 literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/pattern-grg-rrg-rgg.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/pattern-grg-rrg-rgg.png new file mode 100644 index 0000000000000000000000000000000000000000..fcf4f3fd7d95431b8cd1bc5f5129fcb724c5e40f GIT binary patch literal 231 zcmeAS@N?(olHy`uVBq!ia0vp^x**KK#K6FKsNOXi$XVy<;uunK>uuO>p#}vW?s@X} z?5{Vn@(E1fdg>#_p5-zBiX+1VA%+4b26mx2|7={&ovNQ>6SXtcysBl-)c><WmS!Y( zv7BNEzPH=%x{1!KjWd@lmbz(awP;VviDQ{7SW3K#guH|K-#!i8$dVG=UlQ?2Ho)uu z>9DyExiv#HMbsD$XX>p~Q&Z4f6DV?h!MD37E_}{<nz@wk)ekYNY^%>svR6Ky{&{h` fDhG(UQO-Q~pMsNotNvM_%Naaf{an^LB{Ts5h3Hy_ literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/pattern-rgr-grg-rgr.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/pattern-rgr-grg-rgr.png new file mode 100644 index 0000000000000000000000000000000000000000..db8ed5cf7bd1837d4810f2885309f8413c6c77d5 GIT binary patch literal 222 zcmV<403rX0P)<h;3K|Lk000e1NJLTq001fg001fo0ssI3J*IA&0001`Nkl<Zc-rli z%Myby2t^NmIe$(!ZH+By>?EUcysXRv&Lsq60f0F`IKaY}8O6F)ckPNrKmh*ySgNcF zsO2B!z+X<jPG+J~4Ii%NgDF80`5mJXpl^B2u+(g0*rz5I>8xiL(f<$Mv|j(s)%z{g zX4K!E|JCbvas7AqzkC1b|Dp4ruYT+<YHHy}$v^q@gcpA3!`InPrp6Oqc)fVS3qKqF Y0cy8C_Kbk@N&o-=07*qoM6N<$g27Q_GXMYp literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/pattern-tr.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/pattern-tr.png new file mode 100644 index 0000000000000000000000000000000000000000..8b4b25364e0ffbe09e563e13b567fa57330e48d5 GIT binary patch literal 137 zcmeAS@N?(olHy`uVBq!ia0vp^azM<_!N$PA*s|9jBoW~0;uunKD><d1=|2z8e@O`m zi5U_X7?eM1T?jqI(8f2(=fLXOHJ)xxeNNw5J?)fkN19wc<FT&3eZzeBMQLtcCc<9q mCdFSHSg)@*x>)QnGsEKzd}=q=PizO8&EV<k=d#Wzp$Pzi&n><H literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/properties.js b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/properties.js new file mode 100644 index 00000000000..ddecfb6e336 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/properties.js @@ -0,0 +1,449 @@ +(function(root){ + +/* + * General Value Types definition + * they return an object of arrays of type { <name>: [<start-value>, <end-value>], ... } + */ +var values = { + 'length' : function() { + // http://www.w3.org/TR/css3-values/#lengths + return { + // CSS Values and Module Level 3 + // ch: ['1ch', '10ch'], + // rem: ['1rem', '10rem'], + // vw: ['1vw', '10vw'], + // vh: ['1vh', '10vh'], + // vmin: ['1vmin', '10vmin'], + // vmax: ['1vmax', '10vmax'], + // CSS Values and Module Level 2 + pt: ['1pt', '10pt'], + pc: ['1pc', '10pc'], + px: ['1px', '10px'], + // CSS Values and Module Level 1 + em: ['1em', '10em'], + ex: ['1ex', '10ex'], + mm: ['1mm', '10mm'], + cm: ['1cm', '10cm'], + 'in': ['1in', '10in'] + }; + }, + 'length-em': function() { + return { + em: ['1.1em', '1.5em'] + }; + }, + 'percentage': function() { + // http://www.w3.org/TR/css3-values/#percentages + return { + '%': ['33%', '80%'] + }; + }, + 'color': function() { + // http://www.w3.org/TR/css3-values/#colors + // http://www.w3.org/TR/css3-color/ + return { + rgba: ['rgba(100,100,100,1)', 'rgba(10,10,10,0.4)'] + }; + }, + 'rectangle': function() { + // http://www.w3.org/TR/CSS2/visufx.html#value-def-shape + return { + rectangle: ['rect(10px,10px,10px,10px)', 'rect(15px,15px,5px,5px)'] + }; + }, + 'font-weight': function() { + // http://www.w3.org/TR/css3-fonts/#font-weight-prop + return { + keyword: ["normal", "bold"], + numeric: ["100", "900"] + }; + }, + 'number': function() { + // http://www.w3.org/TR/css3-values/#number + return { + integer: ["1", "10"], + decimal: ["1.1", "9.55"] + }; + }, + 'number[0,1]': function() { + // http://www.w3.org/TR/css3-values/#number + // applies to [0,1]-ranged properties like opacity + return { + "zero-to-one": ["0.2", "0.9"] + }; + }, + 'integer': function() { + // http://www.w3.org/TR/css3-values/#integer + return { + integer: ["1", "10"] + }; + }, + 'shadow': function() { + // http://www.w3.org/TR/css-text-decor-3/#text-shadow-property + return { + shadow: ['rgba(0,0,0,0.1) 5px 6px 7px', 'rgba(10,10,10,0.9) 5px 6px 7px'] + }; + }, + 'visibility': function() { + // http://www.w3.org/TR/CSS2/visufx.html#visibility + return { + keyword: ['visible', 'hidden', {discrete: true}] + }; + }, + 'auto': function(property) { + var types = properties[property] || unspecified_properties[property]; + var val = values[types[0]](property); + var key = Object.keys(val).shift(); + return { + to: [val[key][1], 'auto'], + from: ['auto', val[key][1]] + }; + }, + // types reqired for non-specified properties + 'border-radius': function() { + return { + px: ['1px', '10px'], + "px-px": ['1px 3px', '10px 13px'] + }; + }, + 'image' : function() { + var prefix = getValueVendorPrefix('background-image', 'linear-gradient(top, hsl(0, 80%, 70%), #bada55)'); + return { + // Chrome implements this + url: ['url(support/one.gif)', 'url(support/two.gif)'], + data: ['url(data:image/gif;base64,R0lGODlhAQABAAD/ACwAAAAAAQABAAACADs=)', 'url(data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///ywAAAAAAQABAAACAUwAOw==)'], + // A hunch, as from the spec: + // http://www.w3.org/TR/css3-transitions/#animatable-types + // gradient: interpolated via the positions and colors of each stop. They must have the same type (radial or linear) and same number of stops in order to be animated. Note: [CSS3-IMAGES] may extend this definition. + gradient: [prefix + 'linear-gradient(top, hsl(0, 80%, 70%), #bada55)', prefix + 'linear-gradient(top, #bada55, hsl(0, 80%, 70%))'] + }; + }, + 'background-size': function() { + return { + keyword: ['cover', 'contain'] + }; + }, + 'box-shadow': function() { + // http://www.w3.org/TR/css3-background/#ltshadowgt + return { + shadow: ['60px -16px teal', '60px -16px red'] + }; + }, + 'vertical': function() { + return { + keyword: ['top', 'bottom'] + }; + }, + 'horizontal': function() { + return { + keyword: ['left', 'right'] + }; + }, + 'font-stretch': function() { + return { + keyword: ['condensed', 'expanded'] + }; + }, + 'transform': function() { + return { + rotate: ['rotate(10deg)', 'rotate(20deg)'] + }; + }, + 'position': function() { + return { + 'static to absolute': ['static', 'absolute', {discrete: true}], + 'relative to absolute': ['relative', 'absolute', {discrete: true}], + 'absolute to fixed': ['absolute', 'fixed', {discrete: true}] + }; + }, + 'display': function() { + return { + 'static to absolute': ['none', 'block', {discrete: true}], + 'block to inline-block': ['block', 'inline-block', {discrete: true}] + }; + } +}; + +/* + * Property to Type table + * (as stated in specification) + */ +var properties = { + 'background-color': ['color'], + 'background-position': ['length', 'percentage'], + + 'border-top-width': ['length'], + 'border-right-width': ['length'], + 'border-bottom-width': ['length'], + 'border-left-width': ['length'], + + 'border-top-color': ['color'], + 'border-right-color': ['color'], + 'border-bottom-color': ['color'], + 'border-left-color': ['color'], + + 'padding-bottom': ['length'], + 'padding-left': ['length'], + 'padding-right': ['length'], + 'padding-top': ['length'], + + 'margin-bottom': ['length'], + 'margin-left': ['length'], + 'margin-right': ['length'], + 'margin-top': ['length'], + + 'height': ['length', 'percentage'], + 'width': ['length', 'percentage'], + 'min-height': ['length', 'percentage'], + 'min-width': ['length', 'percentage'], + 'max-height': ['length', 'percentage'], + 'max-width': ['length', 'percentage'], + + 'top': ['length', 'percentage'], + 'right': ['length', 'percentage'], + 'bottom': ['length', 'percentage'], + 'left': ['length', 'percentage'], + + 'color': ['color'], + 'font-size': ['length', 'percentage'], + 'font-weight': ['font-weight'], + 'line-height': ['number', 'length', 'percentage'], + 'letter-spacing': ['length'], + // Note: percentage is Level3 and not implemented anywhere yet + // https://drafts.csswg.org/css3-text/#word-spacing + 'word-spacing': ['length', 'percentage'], + 'text-indent': ['length', 'percentage'], + 'text-shadow': ['shadow'], + + 'outline-color': ['color'], + // outline-offset <integer> used to be an error in the spec + 'outline-offset': ['length'], + 'outline-width': ['length'], + + 'clip': ['rectangle'], + // Note: doesn't seem implemented anywhere + 'crop': ['rectangle'], + + 'vertical-align': ['length', 'percentage'], + 'opacity': ['number[0,1]'], + 'visibility': ['visibility'], + 'z-index': ['integer'] +}; + +/* + * Property to auto-value mapping + * (lazily taken from http://www.siliconbaytraining.com/pages/csspv.html) + */ +var properties_auto = [ + 'margin-top', + 'margin-right', + 'margin-bottom', + 'margin-left', + 'height', + 'width', + 'clip', + 'marker-offset', + 'top', + 'right', + 'left', + 'bottom', + 'z-index' +]; + +/* + * Property to Type table + * (missing value-types of specified properties) + */ +var missing_properties = { + 'margin-bottom': ['percentage'], + 'margin-left': ['percentage'], + 'margin-right': ['percentage'], + 'margin-top': ['percentage'], + 'padding-bottom': ['percentage'], + 'padding-left': ['percentage'], + 'padding-right': ['percentage'], + 'padding-top': ['percentage'], + 'vertical-align': ['vertical'] +}; + +/* + * Property to Type table + * (properties that haven't been specified but implemented) + */ +var unspecified_properties = { + // http://oli.jp/2010/css-animatable-properties/ + 'border-top-left-radius': ['border-radius'], + 'border-top-right-radius': ['border-radius'], + 'border-bottom-left-radius': ['border-radius'], + 'border-bottom-right-radius': ['border-radius'], + 'background-image': ['image'], + 'background-size': ['background-size'], + // https://drafts.csswg.org/css3-background/#the-box-shadow + // Animatable: yes, except between inner and outer shadows (Transition to/from an absent shadow is a transition to/from โ€˜0 0 transparentโ€™ or โ€˜0 0 transparent insetโ€™, as appropriate.) + 'box-shadow': ['box-shadow'], + 'font-size-adjust': ['number'], + 'font-stretch': ['font-stretch'], + 'marker-offset': ['length'], + 'text-decoration-color': ['color'], + 'column-count': ['integer'], + 'column-gap': ['length'], + 'column-rule-color': ['color'], + 'column-rule-width': ['length'], + 'column-width': ['length'], + 'transform': ['transform'], + 'transform-origin': ['horizontal'], + 'zoom': ['number'], + 'outline-radius-topleft': ['length', 'percentage'], + 'outline-radius-topright': ['length', 'percentage'], + 'outline-radius-bottomright': ['length', 'percentage'], + 'outline-radius-bottomleft': ['length', 'percentage'], + 'display': ['display'], + 'position': ['position'] +}; + +/* + * additional styles required to actually render + * (different browsers expect different environment) + */ +var additional_styles = { + // all browsers + 'border-top-width': {'border-top-style' : 'solid'}, + 'border-right-width': {'border-right-style' : 'solid'}, + 'border-bottom-width': {'border-bottom-style' : 'solid'}, + 'border-left-width': {'border-left-style' : 'solid'}, + 'top': {'position': 'absolute'}, + 'right': {'position': 'absolute'}, + 'bottom': {'position': 'absolute'}, + 'left': {'position': 'absolute'}, + 'z-index': {'position': 'absolute'}, + 'outline-offset': {'outline-style': 'solid'}, + 'outline-width': {'outline-style': 'solid'}, + 'word-spacing': {'width': '100px', 'height': '100px'}, + // unspecified properties + 'column-rule-width': {'column-rule-style': 'solid'}, + 'position': {'width': '50px', 'height': '50px', top: '10px', left: '50px'} +}; + +/* + * additional styles required *on the parent* to actually render + * (different browsers expect different environment) + */ +var parent_styles = { + 'border-top-width': {'border-top-style' : 'solid'}, + 'border-right-width': {'border-right-style' : 'solid'}, + 'border-bottom-width': {'border-bottom-style' : 'solid'}, + 'border-left-width': {'border-left-style' : 'solid'}, + 'height': {'width': '100px', 'height': '100px'}, + 'min-height': {'width': '100px', 'height': '100px'}, + 'max-height': {'width': '100px', 'height': '100px'}, + 'width': {'width': '100px', 'height': '100px'}, + 'min-width': {'width': '100px', 'height': '100px'}, + 'max-width': {'width': '100px', 'height': '100px'}, + // unspecified properties + 'position': {'position': 'relative', 'width': '100px', 'height': '100px'}, + // inheritance tests + 'top': {'width': '100px', 'height': '100px', 'position': 'relative'}, + 'right': {'width': '100px', 'height': '100px', 'position': 'relative'}, + 'bottom': {'width': '100px', 'height': '100px', 'position': 'relative'}, + 'left': {'width': '100px', 'height': '100px', 'position': 'relative'} +}; + + +function assemble(props) { + var tests = []; + + // assemble tests + for (var property in props) { + props[property].forEach(function(type) { + var _values = values[type](property); + Object.keys(_values).forEach(function(unit) { + var data = { + name: property + ' ' + type + '(' + unit + ')', + property: property, + valueType : type, + unit : unit, + parentStyle: extend({}, parent_styles[property] || {}), + from: extend({}, additional_styles[property] || {}), + to: {} + }; + + data.from[property] = _values[unit][0]; + data.to[property] = _values[unit][1]; + data.flags = _values[unit][2] || {}; + + tests.push(data); + }); + }); + } + + return tests; +} + +root.getPropertyTests = function() { + return assemble(properties); +}; + +root.getMissingPropertyTests = function() { + return assemble(missing_properties); +}; + +root.getUnspecifiedPropertyTests = function() { + return assemble(unspecified_properties); +}; + +root.getFontSizeRelativePropertyTests = function() { + var accepted = {}; + + for (var key in properties) { + if (!Object.prototype.hasOwnProperty.call(properties, key) || key === "font-size") { + continue; + } + + if (properties[key].indexOf('length') > -1) { + accepted[key] = ['length-em']; + } + } + + return assemble(accepted); +}; + +root.getAutoPropertyTests = function() { + var accepted = {}; + + for (var i = 0, key; key = properties_auto[i]; i++) { + accepted[key] = ['auto']; + } + + return assemble(accepted); +}; + +root.filterPropertyTests = function(tests, names) { + var allowed = {}; + var accepted = []; + + if (typeof names === "string") { + names = [names]; + } + + if (!(names instanceof RegExp)) { + names.forEach(function(name) { + allowed[name] = true; + }); + } + + tests.forEach(function(test) { + if (names instanceof RegExp) { + if (!test.name.match(names)) { + return; + } + } else if (!allowed[test.name]) { + return; + } + + accepted.push(test); + }); + + return accepted; +}; + +})(window); \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/red20x20.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/red20x20.png new file mode 100644 index 0000000000000000000000000000000000000000..5d44ef210e1132a7de6c5442ee47d3a220dfc2ab GIT binary patch literal 160 zcmeAS@N?(olHy`uVBq!ia0vp^A|TAc1SFYWcSQjy&H|6fVg?3oVGw3ym^DWND9B#o z>FdgV7pRU^Vw#v22T(||#5JPCIX^cyHLrxhxhOTUBsE2$JhLQ2!QIn0AiR-J9H>aj y)5S5w;&k$#^A2_iNfK9WR#k?4Uh$0aDi4Fw97c5^KZPQoDh5wiKbLh*2~7YTawj1G literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/region-in-body.html b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/region-in-body.html new file mode 100644 index 00000000000..78038fd28ff --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/region-in-body.html @@ -0,0 +1,36 @@ +<!DOCTYPE html> +<html lang="en"><head> + <meta charset="UTF-8"> + <title>One region in body</title> + <style> + html, body { + margin: 0; + padding: 0; + } + #container { + background: red; + } + #content { + flow-into: flow; + font-family: Ahem; + font-size: 20px; + line-height: 1em; + color: green; + } + #region { + flow-from: flow; + } + </style> + <script src="util.js" type="text/javascript"></script> +</head> +<body> + <div id="container"> + <!-- The &#8203; entity is a zerowidth space. It enables me to create nicely reflowing rectangles of Ahem text --> + <div id="content"> + xxxx&#x200B;xxxx&#x200B;xxxx&#x200B;xxxx + </div> + </div> + <div id="region"> + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/region-in-container.html b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/region-in-container.html new file mode 100644 index 00000000000..219fce6503c --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/region-in-container.html @@ -0,0 +1,38 @@ +<!DOCTYPE html> +<html lang="en"><head> + <meta charset="UTF-8"> + <title>One region in body</title> + <style> + html, body { + margin: 0; + padding: 0; + } + #container { + background: red; + } + #content { + flow-into: flow; + font-family: Ahem; + font-size: 20px; + line-height: 1em; + color: green; + } + #region { + flow-from: flow; + } + </style> +</head> +<body> + <div id="container"> + <!-- The &#8203; entity is a zerowidth space. It enables me to create nicely reflowing rectangles of Ahem text --> + <div id="content"> + xxxx&#x200B;xxxx&#x200B;xxxx&#x200B;xxxx + </div> + </div> + <div id="region-parent"> + <div id="region"> + </div> + </div> + <script src="util.js" type="text/javascript"></script> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/ruler-h-50%.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/ruler-h-50%.png new file mode 100644 index 0000000000000000000000000000000000000000..cf2eea6b438a11503a89414cbb2f9f1fde55df0c GIT binary patch literal 691 zcmV;k0!;mhP)<h;3K|Lk000e1NJLTq0077U001%w0ssI3;WRTK0007dNkl<Zc-rlq zy{h6s7=~wbiC|&k#KzV}uoP2RSPBY)sHIn;ot@^CYHeD*0k6SU@&o=<wt~SzQP6LT z+1+9bIY?G>_PkGJCLw%0c_-t<Byu8R0TE%rfqnf#2=STCc!0-|BNJiWm+$+t+3XF+ zG01&|R6WZ2a%FMO8DoZFSe6xdSs{%)dLqg~Sttu-y|XONIp^Fk491wQ>y1Vu;JWBp zVzJoqc$A+V$Du&M;PW30)i^&u7Gwd)f-J~_EXabafA}Ss^LRYITrL@7hr_}5ea4uo zs-EXfr_-?8qSw;z_hYfxZnq<%d_G?&6l8n7UMHeNA~7D1DXd_+^X%M^b1Xhu#0egw zA!I?;mp#FUr6!IGxafwE1t1HuAPce}3$g%YK^9~|*6&HOysvn(*(i##-EJ9UsZ`3c zEZerjZtKO@{G-umsZ=7OWHL!ax~|LH&Qw+HcDr($*H`sP-cZ*0d?q4I(}+k2AsaiL zj;3j@>xNm@j~53yo6Tl2nfZLaSS%Dp@jOqqx7+P>I$bK2_WONkdm(-b!)ORuq3(u{ zuZ3eR);?H^UI=h{2M87b0ALRNMpGQFFcbm=3m{kkAXosw0tglW2o^xF0D=Vof&~yP zfM5aey@Mqmboq;Vy>6Q3^?Ef;v)OFQ#$+;S+qUC4@()R>)vA0j20RIU1AN~f3<kMe zPA*0wk^B8lM7P^58jZ@v;czH~5JH%ySu7Suqmd9o*Y(L{67t7~@KDnmXti3a)#`LQ z^?JQ>xhxxNwc21XxLhtDA0P5nd4E{1*Of{|zC6!y9M^SKRYkDydOv{gSOCES0Ko#G Z;3u}YJM}AuyWao+002ovPDHLkV1h`wI+p+d literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/ruler-h-50px.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/ruler-h-50px.png new file mode 100644 index 0000000000000000000000000000000000000000..9f46583665ca6471075227f9e2244f1ba1ffece0 GIT binary patch literal 671 zcmV;Q0$}}#P)<h;3K|Lk000e1NJLTq0074T001%w0ssI35I<<G0007JNkl<Zc-rlq zv8v)g6oyYUj*(OvJMF|<*xQPQHX;gQ=Q9YtMk4qIcD_Uk3p+s&EW|>6gP<0o<3OBS z1j1$6y@J=>jmiI2W)i~T^Pfp3CPtA`(u;`E>xkCAIOm38{A6Fs3%^GNnFzqX(&;o2 zDT)%hOaxRt$_h?dilXdxyZwIuAIl18<k1sR7Ro|dDC@73<(+Ub#)4IrH|Pr?i0E>; z;NbHP*$SvFj1Q0nSpc#i3$h>!vLNd#s;X8h6(Y)HGDMWkW{IfR>*e!#BI@`1L^K!- zq999sxJ98*&~=@N=JPpYY_r)A(Q>)W<#PTuuIolY7N$GT%2E_8{&5kbJC1`e1yhkZ z{QWZiAyepm0H$CHreF%DU<$w#Ou-aPy%*}kd9U|DN?9(KiD<D{L{ydh79vWeQmfTU zN_jXOj>n_dsO!3I+fqu~wx`pn*C<1c`p_d0X`044S5?*jCFXoSGsc7vhGD3xigAie z)6_I=x7!g>wOXy$>t1^zkyx+So-)UAqG0No%Wt8-X!kNxI7<M}X6pN1hP7CW{s%Cs z1EdN70HQYojOJV%M?e6ODu7f0qzV9}3LsSgsR9700!S4=ssK_208$0QoT}fxKB3)i zTb3n+uq><7>A-U2c*&C|r_;$a%~Gl4EyiN8`~5DZbX_+dkNXem%w{vr`D8LF7K>iv z?RKlxYUA;^)oKYL{4FJTXMQ?Xb-Uf|cFP#!ocsSC*Jw0`!=VsjG#WLVO@HH$j}Ibp z9OvtMgBWAUWb%5w;_jEw@bB(q!d+8H6#$q60;CFrn@_JUXnGtsT_OMg002ovPDHLk FV1h+lHID!Q literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/ruler-v-100px.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/ruler-v-100px.png new file mode 100644 index 0000000000000000000000000000000000000000..a837eca2225082917dc952efd5c689e1b51d7bbd GIT binary patch literal 760 zcmeAS@N?(olHy`uVBq!ia0vp^MnHU=gNcEGaWU)iTMP_L`#oJ8Ln>~)opsRfQGkd; ze)kq>afh25lNKiW9??&5?NHJA%O>=XS@{0}+4zG^EwY_?F_M#iv9}3z1aeiSUzA*K zu(aV(kHK?2k3BK|`KL4QXWugp33W=8Xj?T)Nc8vQ(%9`GT4(2eudkH7c2+NL?u$dR z-nKS2Z~j`Y^K+f^ZT|OzL59~vJ9g=>@?L(q?{UxZ$KUny^7DVzuDt!h?mmN?plfyf zmG|FWk8IKrjGUqMkB_(Yd8N`MAGQ3vyhA@<bgG)GyNbMZyBKBu{M65@X^X#_xz|N( zNI2NE)qRbRnzGW(oG=%g^U{3n2NQ}bDsH?iaanTtWy$WlscV`SSj{;6?RV|zP4C{l zb6FCjH+xxSZLO}-<dZ7%&v$p^-rjt(=cAyQ4#>1ywbzy(%Ux#+<}|T#gG9?_n$GnL zUK#SiePsyOw7;>}x9Vgku7B`~<KEgPU54g^2R_?``Yyk`>Xk*`s(JJ0KQFQj%{7r) zbt}iL)bq?nx5a@6yp{&7nsqXz>CffMm(RcYnakO|rl9#~(#I!HTteT!e?R%;lGnRd zMQMom`TO7h&1I+D{M{YwHHiH{KeA^3UX!~oKff$N`Q3$OHK!M>^?md}Ue5YP`;WJ` zoGPcdSKa}V$916$caR7I{lB!WCtmR1qOjFlqjc|ok6s(LH?H5a&h2Na;zQo04{aAN z%iOnj@5)!NUuP>#?C|XJSbx2`vNCh~ZFhHf$0DPdQ%*l!y?XWL&Bph?D}P^q>`h+m zFXb?;somY&_rL4w>#x3=<rC!6*Wd5@<m1PSg>$|yNsZi=Yj1B~pCFjW&0YS{yFmW8 z{%3D_dwKh-9vNpof7j<_ShMfbl=P&-N7}Xp$UV*Eei}Fr#*lj&2u6iKLAmWf*~0AY cw|+4$pP;3B^U*VLV7g}TboFyt=akR{0G}~+v;Y7A literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/ruler-v-50px.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/ruler-v-50px.png new file mode 100644 index 0000000000000000000000000000000000000000..84141028020b7e8cdf2412acbca3c799ba50a534 GIT binary patch literal 757 zcmeAS@N?(olHy`uVBq!ia0vp^MnHU=gNcEGaWU)iTMP_LdpunnLn>~)o#p7Q6)4em z{$d*2BG*@!Lc3jVdA+?Q+2PW(<&`<hUq0SH>~H^wHaWhIaoO!ruE(m{QKE2v_l)kA z-e(KKcYm$vKGDDac}?&6nKO$m!Y2I`xEAGUC@i-6WK{O=zyHpiJNNeO+xv#s?=j!Z zxcM?)V^6`#D~}&Pp5?A$`q-&{Ubpelh>!(auZC((&D%cv^wS>0zQ+>Dv(7%_|5v|q zao)lohkkPybSa7E=I2W%vo$wv-F7j<M5=efqK_3hJ(iZ1hR5E#eOo#2c)7cvt4QFM zmy258?Tg>%?^YeP{?keR*WWj6TXu)LZemGAMMlrg{rmeFE-(LJ<A3S&Y482_`L|4a zV$ruGZ1vX<9}HH``Sp4I^9xs8BD45(?Git7i|IscNI2NU%6%<AQFrUQr?(D+*uNsK z-AeFYem8ITy4x>H79F(9J8|Uk$H$M8Jv&{Tg0!YiDk&_S=(k)oHZIO<*REZcdS={{ zuBxt{yk+-pZOxfJY$vZ@zkcEDg32{MYQY*JDz>(^mVKA=wyUOYzPWhuV$b-4=Px{% z$%e2T?g|j&pZPVd@7osh<~-+>HNJ0@q3xBETkz(j;nVk5#ZE1@IrSJs=KbBV&8b#r zs@K)5tKa`-ZH>~KK0UlH?2I+Pa;AYqh}P8R=H>^<I%3lO$0yypfB*5vA5Q|#-o1Ob zz+%ny*S~-Nb}TZHdiwe2?Afz7Z#KUF-I?$98QU)7&slTl&$qX?-@VRShVSyrk_kFu z-9WGGdw)G^>*dRrJqy()8y@>owKqh|)N|Lm*OhSvei_W#^M7W~=v`a$@8~4GJx?va z-#4{oh}c&&{rS;0ap_x5l~b1MPI0e<Gk|OmIt~)N1C)g`AmVT`zVHuY?mGL;&f7B= Q0uwcZr>mdKI;Vst0OKlsf&c&j literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/runParallelAsyncHarness.js b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/runParallelAsyncHarness.js new file mode 100644 index 00000000000..460f467930e --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/runParallelAsyncHarness.js @@ -0,0 +1,145 @@ +(function(root){ +'use strict'; +// testharness doesn't know about async test queues, +// so this wrapper takes care of that + +/* USAGE: + runParallelAsyncHarness({ + // list of data to test, must be array of objects. + // each object must contain a "name" property to describe the test + // besides name, the object can contain whatever data you need + tests: [ + {name: "name of test 1", custom: "data"}, + {name: "name of test 2", custom: "data"}, + // ... + ], + + // number of tests (tests, not test-cases!) to run concurrently + testsPerSlice: 100, + + // time in milliseconds a test-run takes + duration: 1000, + + // test-cases to run for for the test - there must be at least one + // each case creates its separate async_test() instance + cases: { + // test case named "test1" + test1: { + // run as a async_test.step() this callback contains your primary assertions + start: function(testCaseKey, data, options){}, + // run as a async_test.step() this callback contains assertions to be run + // when the test ended, immediately before teardown + done: function(testCaseKey, data, options){} + }, + // ... + } + + // all callbacks are optional: + + // invoked for individual test before it starts so you can setup the environment + // like DOM, CSS, adding event listeners and such + setup: function(data, options){}, + + // invoked after a test ended, so you can clean up the environment + // like DOM, CSS, removing event listeners and such + teardown: function(data, options){}, + + // invoked before a batch of tests ("slice") are run concurrently + // tests is an array of test data objects + sliceStart: function(options, tests) + + // invoked after a batch of tests ("slice") were run concurrently + // tests is an array of test data objects + sliceDone: function(options, tests) + + // invoked once all tests are done + done: function(options){} + }) +*/ +root.runParallelAsyncHarness = function(options) { + if (!options.cases) { + throw new Error("Options don't contain test cases!"); + } + + var noop = function(){}; + + // add a 100ms buffer to the test timeout, just in case + var duration = Math.ceil(options.duration + 100); + + // names of individual tests + var cases = Object.keys(options.cases); + + // run tests in a batch of slices + // primarily not to overload weak devices (tablets, phones, โ€ฆ) + // with too many tests running simultaneously + var iteration = -1; + var testPerSlice = options.testsPerSlice || 100; + var slices = Math.ceil(options.tests.length / testPerSlice); + + // initialize all async test cases + // Note: satisfying testharness.js needs to know all async tests before load-event + options.tests.forEach(function(data, index) { + data.cases = {}; + cases.forEach(function(name) { + data.cases[name] = async_test(data.name + " / " + name, {timeout: options.timeout || 60000}); + }); + }); + + function runLoop() { + iteration++; + if (iteration >= slices) { + // no more slice, we're done + (options.done || noop)(options); + return; + } + + // grab a slice of testss and initialize them + var offset = iteration * testPerSlice; + var tests = options.tests.slice(offset, offset + testPerSlice); + tests.forEach(function(data) { + (options.setup || noop)(data, options); + + }); + + // kick off the current slice of tests + (options.sliceStart || noop)(options, tests); + + // perform individual "start" test-case + tests.forEach(function(data) { + cases.forEach(function(name) { + data.cases[name].step(function() { + (options.cases[name].start || noop)(data.cases[name], data, options); + }); + }); + }); + + // conclude test (possibly abort) + setTimeout(function() { + tests.forEach(function(data) { + // perform individual "done" test-case + cases.forEach(function(name) { + data.cases[name].step(function() { + (options.cases[name].done || noop)(data.cases[name], data, options); + }); + }); + // clean up after individual test + (options.teardown || noop)(data, options); + // tell harness we're done with individual test-cases + cases.forEach(function(name) { + data.cases[name].done(); + }); + }); + + // finish the test for current slice of tests + (options.sliceDone || noop)(options, tests); + + // next test please, give the browser 50ms to do catch its breath + setTimeout(runLoop, 50); + }, duration); + } + + // allow DOMContentLoaded before actually doing something + setTimeout(runLoop, 100); +}; + +})(window); \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/square-purple.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/square-purple.png new file mode 100644 index 0000000000000000000000000000000000000000..0f522d78728417b0f74b694e2e47cd41c00359d1 GIT binary patch literal 92 zcmeAS@N?(olHy`uVBq!ia0vp^f*{Pu3?vyBU)>3$*aCb)TpJh~{xkePDssRFB<<<q n7*cU7`N#kLjg3MaSNIuL+z|fjF-g!1D9PaI>gTe~DWM4f*isp& literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/square-teal.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/square-teal.png new file mode 100644 index 0000000000000000000000000000000000000000..e567f51b91bbe40754cb0e0cae066201219cbb4a GIT binary patch literal 92 zcmeAS@N?(olHy`uVBq!ia0vp^f*{Pu3?vyBU)>3$*aCb)Tp1b~82<lv|F?D~NZQlI nF{I*F@{j-f8ykf<uJALgxFP)4W0Ig3P?EvZ)z4*}Q$iB}@>Uv7 literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/square-white.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/square-white.png new file mode 100644 index 0000000000000000000000000000000000000000..5853cbb238cb2d4aba3dd49af3f2ba64d6c7a2de GIT binary patch literal 78 zcmeAS@N?(olHy`uVBq!ia0vp^f*{NRBpBq_B-DVEsHcl#NX4yWiv~UkzCZ4)$}udm Z3=C_{1@!OB{@4Xl=;`X`vd$@?2>|f05A6T| literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/swatch-blue.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/swatch-blue.png new file mode 100644 index 0000000000000000000000000000000000000000..bf2759634d45dbe3df13868341eddb7e4bf24172 GIT binary patch literal 84 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K83?vyP*g1g|bAV5XD+9y-u8K?HKrWA`i(^Q| dt>gp+Mj%g@f$_JNuojTT;OXk;vd$@?2>>P$4{-nh literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/swatch-gray.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/swatch-gray.png new file mode 100644 index 0000000000000000000000000000000000000000..92c73561f3a8b74b279c2859a0b13145ef12f40a GIT binary patch literal 163 zcmeAS@N?(olHy`uVBq!ia0vp^A|TAc1SFYWcSQjy&H|6fVg?3oVGw3ym^DWND9B#o z>FdgVmt9swTFAKFy%s1WS>hT|;+&tGo0?a`;9QiNSdyBeP@Y+mq2TW68xY>eCk|93 z>*?YcVsSb-CnF<4LEOMFfWghQKTGba&8nG2XBpaS8CUo{xWf)q$l&Sf=d#Wzp$Pz< CekfxA literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/swatch-green.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/swatch-green.png new file mode 100644 index 0000000000000000000000000000000000000000..0aa79b0c86bd72c2220ecce39b9553e2cd3605b9 GIT binary patch literal 84 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K83?vyP*g1g|bAV5XD?<aroS#c40=Yb%E{-7; dw~`YS7=b)p2FBl7!dgHUgQu&X%Q~loCIBjB50U@? literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/swatch-lime.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/swatch-lime.png new file mode 100644 index 0000000000000000000000000000000000000000..55fd7fdaedfc1ed505b111f20fabbca568c68fa5 GIT binary patch literal 84 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K83?vyP*g1g|bAV5XE5m;VlehybfLtC=7srr_ dTgeFuj6j|)1LJQkVJ#qw!PC{xWt~$(6968w4?q9_ literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/swatch-navy.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/swatch-navy.png new file mode 100644 index 0000000000000000000000000000000000000000..28dae8a3e12bea03cf41b020bf05540adf9da17f GIT binary patch literal 159 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K11SGd?VUh(>oCO|{#S9GG!XV7ZFl&wkP>{XE z)7O>#E{A}KxioXY?P{QqWQl7;iF1B#Zfaf$gL6@8Vo7R>LV0FMhJw4NZ$Nk>pEyX7 xr;B5V#`)xwgp33QDFed^Om3n5tCsD{VrW{=FfT{-zcNq}gQu&X%Q~loCIIazCb<9r literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/swatch-orange.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/swatch-orange.png new file mode 100644 index 0000000000000000000000000000000000000000..d3cd498b52bd88ea6c991f050f1ecb1cfdd136bb GIT binary patch literal 84 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K83?vyP*g1g|bAV5X>;I(;rzSbh26A~kT^vIy dZY3uuFamkH42-|EgtdSy22WQ%mvv4FO#nq@5F-Ep literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/swatch-pink.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/swatch-pink.png new file mode 100644 index 0000000000000000000000000000000000000000..95b84499a3d849cfd74eb8711f5d2a1bc45d0c39 GIT binary patch literal 160 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K11SGd?VUh(>oCO|{#S9GG!XV7ZFl&wkP>{XE z)7O>#F1v)dmTbUZVN;-xWQl7;iF1B#Zfaf$gL6@8Vo7R>LV0FMhJw4NZ$Nk>pEyvF zl&6bhh{pNkKlKkxm@hVTHi{UmstPgv8p_P@ua9X3)ACoBfT|cgUHx3vIVCg!0A2AZ AjsO4v literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/swatch-purple.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/swatch-purple.png new file mode 100644 index 0000000000000000000000000000000000000000..73bea775175e9bab0dfe664eaea9ceaa566de787 GIT binary patch literal 153 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K11SGd?VUh(>jKx9jP7LeL$-D$|*pj^6T^Rm@ z;DWu&Cj&(|3p^r=85p>QL70(Y)*K0-AbW|YuPgf<CN?H@8SBFiJU}5yPZ!4!jq}Ml p2^k3rQU-<-nA}49S1sF@#c<n>Q7&8X=USj522WQ%mvv4FO#s*6C0hUh literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/swatch-red.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/swatch-red.png new file mode 100644 index 0000000000000000000000000000000000000000..1caf25c992aa8e23483cddb3334b5f51ec967f4a GIT binary patch literal 84 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K83?vyP*g1g|bAV5X>wg9Y$w!>#KrWA`i(^Q| dt>gp+Mj%g@f$_JNuojTT;OXk;vd$@?2>=8a4uJpw literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/swatch-teal.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/swatch-teal.png new file mode 100644 index 0000000000000000000000000000000000000000..0293ce89dea5c9413e4c829cc83a4e39d8f23300 GIT binary patch literal 156 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K11|+SoP4xm&jKx9jP7LeL$-D$|*pj^6T^Rm@ z;DWu&Cj&(|3p^r=85p>QL70(Y)*K0-AbW|YuPgg4R#65`cCM1`H9#R5PZ!4!jq}MV s85uv$JE$cjEnw)$lDlfNN|Kv_A+(E0c5RvdE}%LFPgg&ebxsLQ0IVw~FaQ7m literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/swatch-white.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/swatch-white.png new file mode 100644 index 0000000000000000000000000000000000000000..1a7d4323d77287d8eb03a89c635b09d099d94869 GIT binary patch literal 85 zcmeAS@N?(olHy`uVBq!ia0vp^{2<H-Bp8I(u6Pcln3BBRT^Jbeb_p*5^7uSm978H@ gCI9%}-<ZL|Fh5TA$_Ah94}dZZp00i_>zopr0Qo5vZ~y=R literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/swatch-yellow.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/swatch-yellow.png new file mode 100644 index 0000000000000000000000000000000000000000..1591aa0e2e274854ed836cf582235ea0202f9c8e GIT binary patch literal 84 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K83?vyP*g1g|bAV5X>;L}@UB|w-0=Yb%E{-7; dw~`YS7=b)p2FBl7!dgHUgQu&X%Q~loCIDbL5Y7Mq literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/test-bl.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/test-bl.png new file mode 100644 index 0000000000000000000000000000000000000000..904e24e996a3e5da93bef89e10c49e24c07d0ed2 GIT binary patch literal 1368 zcmV-e1*iInP)<h;3K|Lk000e1NJLTq003kF003kJ0{{R3g3O3#0000aP)t-s005aY zGnr;)nE(LHGc(L)X3UwH%*@QpW@i7Hng7hp|NsC0s-1y@0000CbW%=J|NsC0|NsC0 z|Ns9065r0w00001VoOIv3m@0SzyJUQ%1J~)RCwC$mrHKsHV}qI#0OA$)CUNV+0PNC z5z>1FDgrZWOHO<59>534BKsDgp7p3B>I7zAF2$Eby&QX;;i_BGr>dV-tSTkfVYNIl zi$7l1mTrsB_C8C-i#4X^3LaLG>jn4e0?941+dy=QV9i9xkG(@4H;@(~ogt^a`43yj z^`**Zh^{Td#Pj%+Qr%fKN-5`g;nYOF+LzqmXhmO+m0gFk>gfe#F-NRAhUdXXT_P3& z5hZ>zhPowUE`a<#=%qb^0(KmTs?O^A;`TX0ocz1q{qO362uJ`J02e5qdmo1g`RwHP z!A7z7fk;yZJFK4j+J<J_!!kFwGv}DTl*m6N!y-fSp;zS$vG4R+^f3f3FkDp6`iZB@ z9Rq0{yOh5|GFgnv$G$b5jmSNW@=3{zpgZ``cV=57#LB;M$gx-;>{j+R-gEgot3{VQ zT_EJMJvHm{U-0*2vCJ(xH5>9<9E?yX{cn>?Cg7{`b(@FBIAj4b8LLlxUA}&DNX9v( z3NQA_a4!BS*5!`~%BqqjA5Y&4uFEHnEyD3&j#zU)o^f5S%cniIzr|OZ3i>ow5`DiR zKV-E(ZYQ3EdZkb6@<UeNeUB?iBFq`D*X2*MI!I#{X}9FZS$$Qmwt_`|Y{-wZnqKV6 z1blp+IyR9XXEjwg7bU<2vXH;?C)8Cq%49XyvL(Ou3A1w<`?`EvZGvCF2-_3drF_v3 zWsvc|O+gEO*$ta$@sA0cmcFE8)2I`NWRx;N{9|`#gBRBOOq5lHKJ|AG{lc-r?c}4) zL-$z5Md6GLEg?qSW3G#N#pKN%xTocLj)Y#BeKpr}_iC1cFHVHGREV^M$HW)&`;U1U zqa(S7SZ8*J-qhDnFUE@G8)EF3n+2Q$s`7)uute1_k<QgF7t5n>rGpW1SV4To*jSQh zlcG$a4=ps-GU>1C2_a&@$I%?>7`aa!VnfzdIeZ#?+sUD|PY~B%U0^7GO|Nu@sDsJ# z@KlWWEXlsO1AjC<{IhGw<M`A>1$M}i5N36xL4oHW;3LYQL{&USeE7rWXggil@q+qy zcqZ;IV<F)o1Yw4G7>JjWW`PLt<%)`T&`L8>V}>Oa<kn^+iI7n5LHubaqvh(*WJr7^ z)T>O$2em@zx|mEC771}cDVqgE!@z!yT>QYv82lFP(%@F<5;wl4TqknAA$72YTMI-# zh4f`KPMMiy>XyGdc~Of)_A<zfoj!JJF(=#0d7SY)+PJ~38KUdBOaRb$*jPKdJK=EV zrkm0Z8xVG(YE0}Yt@-e>+14L1KJ#R!khI&B)WtXi&X5b{lL3*@ZkLC@MvW|+A?7gN zW^9D0T;2*9*?`>~p)-$sKP@gC`DhvB0@0TW$+>vr68OLZ|AFHIA?8UIVp5VL8#iJF zp>x%gNY!OhEyLo1uORl+--}g*Wst2R?yDkOfv7^I8;JRK;rXg-$rj?i69C?WTvb<5 z-Ama!5K|d3=PQC<K{RE8uwP1VM##=LEUkC!&4^ZAZE86{8mYSe$D&=JS`K8398A-< zAkI6YxS&bnwNTEyqw<esfq5o26J~CRQnjl~iN@O75YIKX+q?rYE}CZZF2t>$$WP>d ai~I`(b4pM507-ZN0000<MNUMnLSTZUYM}!F literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/test-br.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/test-br.png new file mode 100644 index 0000000000000000000000000000000000000000..f413ff5c1a0f2ad9f9a345d3e07be57a59a82207 GIT binary patch literal 1045 zcmV+w1nT>VP)<h;3K|Lk000e1NJLTq003kF003kJ0{{R3g3O3#0000aP)t-s005aY zGnr;)nE(LHGc(L)X3UwH%*@QpW@i7Hng7hp|NsC0s-1y@0000CbW%=J|NsC0|NsC0 z|Ns9065r0w00001VoOIv3m@0SzyJUPhe<?1RCwC$ms@V5FcgLlnk;}*nH@}b&;=9; z`W^{0$~+gU<h>dx3m9n@P^7faO%<|&!sf>KZm^B!d3qut2z>beeU2{xp@)&j(02`` zTY^Y(yls!8j-g6{#iqXUOZZmq^{tQRnwIpYptOGKE#wg=geU|udB&pePc3cOueFKs zvzd?t6~fN!7xtH~ecHeFR|~mNE=(hU<zcj=XW{%Yp6UJ6N@ftUzmC!P5cbt`?6jy? zkn>j9-;D~v`nZNntt8~9LC7xNOec_RZz1(-9N|5dP=m0v9-_#(n4W^-V2~txiYhzj z!i$YK*$mpxEQDn<+Gk7q?5d2K>8gc&fN~c@-gEJg62@yGi)KdJFKsVL7OffK1s(gk zuDvn5Y{BU<F%-%e((qKG8u5Ul%idy$ct({KxR(KBlCq)lwQ%n=>I*USjd;i%YrdEb z{Sn*_^roe9hCXX0U8@*Tm5}W<;uM1)L8qv|EjeFw?$DQBbYc7Y_+{2Z;0_;OA3x6W z0PY|Sr^RF&+^N9lo^nJde+0T>e|Q%!CAxA~?GMkwJ^q*@L1D^DW{@@e8aZfW&HlL( zh^h58`-7ZbHV<zaS+W1w2>0aSI!6vcWNu~EzD%TLWzD`y<i?s$R_yCU8Y@az$o?{s ztJ8(Yy+rUffV?jfsir=p{xwOCNIQ`VxeF})mt`W=%)g=j#qveyLfcAweUa7TT2Y9% zj|Z80xYL7JBN#v$SuMm7!T-APcUV_RUG7#w6p(kTFo<b#?tbL$mc9)MbD|J81-xCa zu1iy(+!eIf8G_WOYv>wDV7Xr)zJ+r5pkj?+g<rb&*<VHdwnQ#%k*B`?n)b<=Z)r8M z*w%Y?pY@=}iIK&e%yly-p3Gaau$<qAqFp+%WF>S_u|SWDG`g}53&gW~H?kPATZn)^ z{pHpDF0f_Yc)Al>7VPVTai^XiPQR;MAxJ&d2ec|FrET5HXc}tCS~{7gaV(KcTp<oc zQD|B7>QZ^Z1TjZ~gu`3RQzOf}P2=}cU|fp)kR|{zS!z=9ML<>z3CM~dAz5JrL$V?W z4Q^@!)=5xS07+PK!ylVGm5`=3ktPvYvS1MHR5ItZK3>BJtE{TnlF}3mey44O;Kkq6 ztd@0Ivcj%UvClb}M#-r)(X{Qa==a|U(_!d)YlyiY`vK(N;tTmg{#)cPVxOudoeJ1E P00000NkvXXu0mjfoHYWE literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/test-inner-half-size.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/test-inner-half-size.png new file mode 100644 index 0000000000000000000000000000000000000000..e473bf80efc66766cb32ec2cc60244ed37dc1157 GIT binary patch literal 180 zcmV;l089UgP)<h;3K|Lk000e1NJLTq0015U001%w1^@s7JXu?L0001cNkl<Zc-rli z!4AM62t%pa|Nk<(E?zL=Fq+2^X)3e<nYr61nsxC@Ld$8rPiTZTB&ja&s6as%ZJL|M z=rOcU${2vp2YUvrojv1iz<}=oKePMm#BU3e)Gz&dnG;ue53v^M#Hf!LH5!*`jH~Z= iHN+4@%ynW{5626)ITymFxuX~W0000<MNUMnLSTZVu1667 literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/test-outer.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/test-outer.png new file mode 100644 index 0000000000000000000000000000000000000000..82eeace7fc0c4202f79610978ab423e62abf8939 GIT binary patch literal 2412 zcmZ{mdpOg78^=c{EOMMh4qF~6Bd3rFi9{I*a|(^Nvdq~?QjT*?4xw_Itd@FmT1%@; zkHai-Y6->Aa{4*!H%&eKiag(`-yhHQT+j9WT%Y^CzTeON{@nNL{(P?Mo9&Krl9f@D z0f9iW&L<o^0NV)yNkF9}fteqx$p(R>O`RQ%dM1nrDqQhOXQ7#ug?V#Sa2fmTSTTg# zq5n>b3YP6~G}vwrp{7((H(F%s9=vs(d(vdsw5S`*{!`K=^0e|Hs;%}@ZAe9;YhM#o z_ToaBZbi>ZoPth;c~{8~-g5bm@{$}EyaCQ}|KNtGC?`*cg`T-jp?`3qQTBgZTv?v{ zsdiqg_=L}TaeDHp)WEMH?m}9l;@m~8p=7pF>!36@MZO>-W1E4=+P#fwf=QndMcXv7 z8Z8-fF2Q7mdllSkqq$$v5O4Max@#iK>)>}|J2%opy`et}FlLkY$|k=MPb|h-F&GS# z`yPH&Q53dkQkZ<87kdVuoRE+pLOXW`h4H>u8uuqXC&Rob*li9oo;cl8K)zjxUvIBg z$)w}LH2k-=iDKc?$`Kh8{tr6}PB1uTuEZnV2}8sH8=6vc={^tU1@E=j4k~YXOGQ|X zkJ7bc);}A=x!>Q|ZjgqKn<q^%>txci{z1vOpT5iHp(Eo0q?hU&McH@xcJuaJ!&r=t z?vM4Ew=lmncbCv<w<by^%~!2EMkjjnd54&X#Od#j14r-;{%H*anvq+xT4z&^R~p5` z!xS#*RhyBq#-3+TSq9ZKkNp)WoXPH4H-m1)g6J1}?lL8tMqKR^6?)~97d2-4DhB+5 zUdGN1RJ+xB<5yKLk0NkP^&6b`?>%iQg%g%g!y>UhwjyyUTO+MrE;m#Qlfbq|*dc(4 zZC|6qC(sSHP6V-iNf|!edmH+^^*p7Z*`Fr|qZ;SsTT5vuq{VfH<xT}KU7pO%=gQ-v zpl}EV2Ej;R3K*TfdooFmy;Lk8A$M$3@V7ALWqa%n93N4h!H9%#CFmf!JRkt3OVQHb z4OBETnat*91Ne0G$7cc;8XW%MV(Eh}E-|2Hw!aen*h^t9zNtCIQK#4?o8<B4NzKA= zJ-KtNi74c~C_F{C-09RZX5o7;K}%g#V~>E_u(9E~{{7oy($sRI!r_#kERyw=)upx! zFkJKpcdtUCXezrquiN45{@FUmzL;55Wac?m%0{3=Y46O}udzZQvI2GYkbbEmgW{O# zB*tP_1EQvt8AEX}i1ucwo7Do-=J@@}d(C-#{nOcUixx3CVB}<e`Lw}_xWS0LbrOGg z-0$$Y+G<jqNui?4Zdoxsu$TaOYd=pOXKWEl=;Q$~#Yp}}11wlrY@mF@rT&tjQx2Kc z;EdG(+Qw=(0gQccTmb_LX#GO@-=ToE{*}o1S&Q<qR$oGG$H$7QsF?VyQgL%mGamZB zN8AN0>yfx&o9U9a{k9oC*L+CRvNc6NGmAaSr-%G%isWSVX*Ri;gJFYDY61-RZMJ9s z-`z?*?sVx<BY`>k?ebatm>?cmkvn8n>~gVoVD9PAWg?M?$DhQ9`wq>_JP04nEs0as zGCYyp$>C%Uz4Sbg-8nx$KQdBELKqs3JZpaXR0kdt6C;QpRUl$8ZN2BT1ay8+QeDwI zu62>#lKkWL24UmrHRFc%C7-=lR_WXembP{E_3D{)24gRLd3m`56V=JI3W>Gc@|ghD zM4FnK`Yo)lucxJLsZJ~`ENt|1#h-mVSROoe^Uf(EVVw0btkFTIuq)O|12?%MoRDpA z2yb%N3pEM(Fd#*y6-Dy|)=~4^T7Ra;qxZn6bJQv8eU-G*cUmx99|SwF1S^VO>?Mcy ziKu&}Y5&7fzUR%+PBa2D*ec=Nds+$#Hi85rKsnpQ4u~Tuc0eH#V&@ut(`oSm91zDY za+r0m+14Xz`N-u=du{O&XwC%ls)q~AieIs$nYA?j`i;>+?lE4qb*u__4g0>Wic&zo zR+V36^t{R_-%yv8wr}-_^1lgZWPfdu3O$yvqYW912-Zu#GoWhgovH3+iIzI{A=E)V zcQydV*I><E=u_da(q7DH+)<GXMo3AvA=y+6U6e})iPP3*DUDxWlG~X9WJt}Yx1=aW z9f9!2A{3*A+uM>n-slX6bO6zsU?5t4944(oUP5)GKA$4KLQ4haDC`}{Ps+Ey(|x}` zyBd9~%hyJlk{^d?Lo)0)dE5l)3+)ni{3Zg_i0Xi|wj6^6BU*ew>BPGjg>hpsG84#F zFtJR+%|k#s!XCqF_ng1k)XQe2ZTWsnZZ|ncg`BfZy2~e>2r%0X?)0(asHJc|7s;{V zAyLed^iYKNI1KWOw{~cQNG_eYN!$n`KQ1lw1ky25mK1-sOUN<}du0+Jm-|WOJ}UZk z;MD^*RM{7)%54F<f89d$AT43&eEZMXjD>{-bX|b)&Pma9Hxh~L<9I*zLO^8O^&sR* z+Z4@)s8v757MByxkbSog24S(-^4S*wgp`yZd~#%@yPop)OUea1c4?kMp-^sa!(oST zlOoZRWmaIl?bWsCD++LG;;LvBull2<z%AUo%!0tXV5Zh=aOTXJiC4)n)<ylZJ1#8> zTKN2P=4FEB_A-kIhbh4*)5)gT&@Gq#)33|s%4+1d`N2!(NL$;9utxEAWYvRMlM?)J zUGmy09Ze5xzD#Sp`sH(nNMyos$)$75^*zJVnHX>A58rdx9N!z~iBj0<W}FS}{WTSS zYe(Kh?$^;NgZyZ(TL-Pc;QQJ0!or2b!LYc9i2f%v0)ZgFaP|`7cK3seBhSK1u{4h_ z@XA$Y?)2*bv%CGWDk&;eV+0`iroein?E{ZT1m@$$KVz-tVqdPbjg5@~%n0G(y?uRF z>IU6@K0Y6KJQh(%2_L<F(zQbdtgfyO+|gmbe_i?OiRXdC>Z+=$Xf!%}G|=DQ-_LJ; z{R@v*PI@{ju&;VMdI8E|v)OrCwr%pJojwJ7oSpnX!a|OIC{+5t7cWF27_n5j0g~u3 VAD}`@1i=3k$k`F)P-h>U`X3Goc2EES literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/test-tl.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/test-tl.png new file mode 100644 index 0000000000000000000000000000000000000000..f6ac0ef7e8f6e192c9c26239884bf92b13cf67b8 GIT binary patch literal 1025 zcmV+c1pfPpP)<h;3K|Lk000e1NJLTq003kF003kJ0{{R3g3O3#0000aP)t-s005aY zGnr;)nE(LHGc(L)X3UwH%*@QpW@i7Hng7hp|NsC0s-1y@0000CbW%=J|NsC0|NsC0 z|Ns9065r0w00001VoOIv3m@0SzyJUPb4f%&RCwC$mQ8M}Fc5&T!~r@I9HIMngrJ)4 zQ(^kjbwEn?FN@yb9iWkt>{9_J2)W!F@R;Dg)Lp$zS!5CX;rV991JU){SM-DYAV0|e zM%uPHwukYjIUJ7B*Q=ZTu2z>QMR^bD+hKK83n7YJaQrDaUiXl8N2@a^ART^^rwFp> z9#IKgok0Td0KkTyXt?~yXZ<2qM=a7Vzey#Q*6RDnL2!78qHiE=Ex4QTA^lz~J%kTw zstmq|U|5-t@E~V@SRUkpVNEL-i@q);x>HzkHGJJLeJv;~hO4ub=d-q4IFZka!eTMc zu`{buHGh%+at79akO>1WhSi7Zh!q^12-bv5K>WppZFh6@Am?f!<BIe8<ZyJvwWFFq zUcMXE0yolD)G8oeTdi8;=!mNz`J_B*yPwI?M)m~}`KHs5imGL+R7;7ZWotYNJV;A* zWckKOJq2tdq{0$$(*LL3ZKU7Jv@p{|rJmVH#VIZ=UDrmLfQ3*?VqE$rdu3uFswG*f z%lCCbgf){JI*%YWuFdgL!bDU{f?kyVyi~}>KvZ5Be|6^zTf#t8UO;S(JZAKN+3ASN z3j@6)uNUz|&Al}d$_w_F78jlrimN;suUD0qIN$0jWDohucq6MjSV#Rh_J5@Pc!G3f z_wwM3t6xj|WYw9-AC(uqCDDE%<9fTAh~QL5JzvTmP~Jf3VT_w`oktbsK$-$vb-dY+ zEip&>4?ZIC^U;m)Hw&SbOn!F;BHM*_pCjsYrK_unjA?=AlYvYnPPY~!(~?^V6%rmz z<RXVlV(+q3UGZ)qa4U<3RPu9z8&h()Lr7;MvMclhIow%G<k?0tDQT)8vXJ#M5t59J znRmOBS}sb`n8kPXi@9Ww{-vOHwGp3wv!1nUm_EL5ha0)Qi>kimBF|Bjt{e!>7aIY` z$e-!kZF!dZ$<~h?Ekqu$Hyc?mW_>Y3_Tv~aU&L~krJRVP<{Xh@#O3lKU&e81AT)VW z+l8Kn<$pJj%%^`<NBnV^?sG(rO721gjrZ5ir7vt3{7A{<<H{~jA7`ID<MD7X!t_;S zAdaE>s>@+0W|%%6zicXInEvpcG8HpS|5i+Fr$GIwnD~MX)K@9PlerDlpNfeu>p=af vm<;kz{V6gHxvP)gcJytThUyO|QzGyW8di!g0nvTM00000NkvXXu0mjfqXF-V literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/test-tr.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/test-tr.png new file mode 100644 index 0000000000000000000000000000000000000000..59843ae54b64f6ce4f7e616d4be491c911ea84cf GIT binary patch literal 1235 zcmV;^1T6cBP)<h;3K|Lk000e1NJLTq003kF003kJ0{{R3g3O3#0000aP)t-s005aY zGnr;)nE(LHGc(L)X3UwH%*@QpW@i7Hng7hp|NsC0s-1y@0000CbW%=J|NsC0|NsC0 z|Ns9065r0w00001VoOIv3m@0SzyJUQMM*?KRCwC$mrYXRI26aFnjFBd+de=qdOt_N zRTBGjNv4=J5|!QqHQb;NfD32Vom9jLqFiod>%)>Qhp^}!Di#F%(|iB->7dhx5Bfwt zkx%50BC1n|tx|6vK%_mLQWqnX6K;;U`FDFEg`lc|)m4wlpBK4@05B8)B_V|J%_Vlw za4<$t6qwQ5?fVe&2b-UQ(B}DF=TLGmWzFWjfTsuoBj{dz2tgQl^A0mb5R|kzAGjHU zzt-QIvk5};13=E&LB-q-)byMklsg#6^|GA>1kTt&3kTTsQcmN$3rJ$UlvDpmfxi-B zs(OsZVotq*l2F1pfdVHvT}FC0ny!_MGKlO{^1lTH|7D!$)SEgOs2&9Y@Lbr2kd{<# zhySTga0aoQC4`TSr6hxqDd{GMq~)Oxf{zHUHg7p3EkeB)qa9pj)F50=N<;4i33kkV z+Zkfqoh0ngavtIa&CE4aHM11QcA(<ZnS*i}9_-kZ;*#IbkX(ZM7}U-VnO=(WZJ}O6 zN?{sklqJk*eYL?f(2HA43tsrLxw#P83GW(do-aa9$Cseyd*a!d^}6HVyqYAe5u#PP zW%Z*kP*_6LlYHvTg7zzOR0H&%9HKkXNYMzhoi|%+O@~02w{IClNzOR!w=8e?lQnb@ z%pq|-dqh2QW;SdM6#?$Yk>1_eQZqwfj_k!6`W4$RXtT;($sb=Vf=Ltr<fHQ=Orru; zUn;qEfp&3@JVRc|I^G&)9Ni4A9mSQOHEM$Fe1C)nz8+lD!g*#oEk#T?Ym^*pUDLa@ zP0fmiPIHK0vlU}q+Y5`}FTpe9;sq1LWPGS!Et$V!6C--}V}{^za7DM=t4WauJA@K$ zMP={GAs~J}TSO4+Obz2!!c-2PJ^BD}6(L7%qhFFWlm_w*{A_jB&gyf79BgCs?>w9n z=2B#u(Pr7sL0tWekex*^{dF&8!>RY)KGWH*ffTXTQc}}ioq82%jI{MEgls^5+h<%O z^>H1Z@tJtBVk*~XX#88aM!5hI=gDs?hBhOj+jXMvWV-~H?(^Z!I&l*r!fNriI&I;K z<Iv6+Vk^Q0%(qeN5a+0NAxn^9#sT%s+L9uce-sc;vjLIT_kg$%QSX=-v{o_lKqih2 zSFAju?}mC>UB`|wTQ4r~E*vl-*0C6Qu@PH2eTrR0Wf{T~%Xbknf3wf*S&<+a`6o9M zz*S7^KKgFY$UnJ0HVgZg8jXfF%*c<rs4-Jtxk{$Dr$zap4viTq<*Snt>L({(KZLbt zzRNL^s?W;zZP~w5L&>g+M15Ai**#&3n|Wb>4eGP<`;PGlMsC0muRbf^cs3p5##&fh zIr(FkMaZ}vrt)1Swj2@$kLqXgyORsRw`3xZBX}-f+RL=$<nPGNDtben%J*+U`~KZM xFqlMZdn&(j3r#(mcWQ87&CEBe=q+_3|9^_Lp+#u>Ntgft002ovPDHLkV1lbeOeO#T literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/two-regions-in-container.html b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/two-regions-in-container.html new file mode 100644 index 00000000000..2fc65261da0 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/two-regions-in-container.html @@ -0,0 +1,38 @@ +<!DOCTYPE html> +<html lang="en"><head> + <meta charset="UTF-8"> + <title>One region in body</title> + <style> + html, body { + margin: 0; + padding: 0; + } + #container { + background: red; + } + #content { + flow-into: flow; + font-family: Ahem; + font-size: 20px; + line-height: 1em; + color: green; + } + #region1, #region2 { + flow-from: flow; + } + </style> +</head> +<body> + <div id="container"> + <!-- The &#8203; entity is a zerowidth space. It enables me to create nicely reflowing rectangles of Ahem text --> + <div id="content"> + xxxx&#x200B;xxxx&#x200B;xxxx&#x200B;xxxx&#x200B;xxxx&#x200B;xxxx&#x200B;xxxx&#x200B;xxxx + </div> + </div> + <div id="region-parent"> + <div id="region1"></div> + <div id="region2"></div> + </div> + <script src="util.js" type="text/javascript"></script> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/two.gif b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/two.gif new file mode 100644 index 0000000000000000000000000000000000000000..01435c80209d533dc2164ac48279574c7ba4615e GIT binary patch literal 184 zcmZ?wbh9u|G-5Dfc+9}?|Nnmm1_pU~d3$^N`Sa)Bzkk2JzCJ!ae*gacKygf<0}=x1 zWnjq_IN`Z^uf^-LyZ<L>^rd9Z%UHE8=k>k<o%1ER_bb-DuX+F9^k9R7fPkLUqK~Q* zc(|CC2%nO1TinphID5}Nt_DZpXpRQPgu)-CGBzifT9*7x<K{V<yu)Ju^Tvk8rskH` Tw)T$BuI`@RzWxaff(+IGsD?$T literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/util.js b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/util.js new file mode 100644 index 00000000000..a7ce4283e45 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/util.js @@ -0,0 +1,29 @@ +function resizeViewportTo(viewportSelector, width, height) { + var iframe = document.querySelector(viewportSelector); + // Commonly used trick to trigger a layout + iframe.contentWindow.document.body.offsetTop; + + iframe.width = width; + iframe.height = height; + + iframe.contentWindow.document.body.offsetTop; +} + +function injectStylesInIFrame(styleSelector, frameSelector) { + var style = document.querySelector(styleSelector), + frame = document.querySelector(frameSelector); + + frame.contentWindow.addNewStyles(style.textContent); +} + + +if (window.parent != window) { + // we're in an iframe, so expose the bits that allow setting styles inside + window.addNewStyles = function (cssText) { + var styleTag = document.createElement("style"), + textNode = document.createTextNode(cssText); + + styleTag.appendChild(textNode); + document.head.appendChild(styleTag); + } +} \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/vendorPrefix.js b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/vendorPrefix.js new file mode 100644 index 00000000000..6cf3c5a3783 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/support/vendorPrefix.js @@ -0,0 +1,86 @@ +// +// Vendor-Prefix Helper Functions For Testing CSS +// + +(function(root) { +'use strict'; + +var prefixCache = {}; + +// convert "foo-bar" to "fooBar" +function camelCase(str) { + return str.replace(/\-(\w)/g, function(match, letter){ + return letter.toUpperCase(); + }); +} + +// vendor-prefix a css property +root.addVendorPrefix = function (name) { + var prefix = getVendorPrefix(name); + if (prefix === false) { + // property unknown to browser + return name; + } + + return prefix + name; +}; + +// vendor-prefix a css property value +root.addValueVendorPrefix = function (property, value) { + var prefix = getValueVendorPrefix(property, value); + if (prefix === false) { + // property unknown to browser + return name; + } + + return prefix + value; +}; + +// identify vendor-prefix for css property +root.getVendorPrefix = function(name) { + if (prefixCache[name] !== undefined) { + return prefixCache[name]; + } + + var elem = document.createElement("div"); + name = camelCase(name); + + if (name in elem.style) { + return prefixCache[name] = ""; + } + + var prefixes = ["Webkit", "Moz", "O", "ms"]; + var styles = ["-webkit-", "-moz-", "-o-", "-ms-"]; + var _name = name.substring(0, 1).toUpperCase() + name.substring(1); + + for (var i = 0, length = prefixes.length; i < length; i++) { + if (prefixes[i] + _name in elem.style) { + return prefixCache[name] = styles[i]; + } + } + + return prefixCache[name] = name in elem.style ? "" : false; +}; + +// identify vendor-prefix for css property value +root.getValueVendorPrefix = function(property, value) { + var elem = document.createElement("div"); + // note: webkit needs the element to be attached to the dom + document.body.appendChild(elem); + var styles = ["-webkit-", "-moz-", "-o-", "-ms-", ""]; + var _property = getVendorPrefix(property) + property; + for (var i=0, length = styles.length; i < length; i++) { + var _value = styles[i] + value; + elem.setAttribute('style', _property + ": " + _value); + var _computed = computedStyle(elem, _property); + if (_computed && _computed !== 'none') { + document.body.removeChild(elem); + return styles[i]; + } + } + document.body.removeChild(elem); + return false; +}; + + +})(window); \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/vh_not_refreshing_on_chrome-ref.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/vh_not_refreshing_on_chrome-ref.xht new file mode 100644 index 00000000000..ebe18dae540 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reference/vh_not_refreshing_on_chrome-ref.xht @@ -0,0 +1,49 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><!-- Submitted from TestTWF Paris --><head> + + <title>CSS Reference File</title> + <link href="mailto:marc@bourlon.com" rel="author" title="Marc Bourlon" /> + + <style type="text/css"> + + * { margin: 0; padding: 0; font-family: Arial, Helvetica, sans-serif; font-size: 13px; } + + #frameTest { width: 600px; height: 200px; border: 1px solid #000; } + + </style> + + <script type="text/javascript"> + var height = 200; + + function resizeReference() { + + var frameTest = document.getElementById('frameTest'); + + // let's resize the iframe vertically only, showing that the vh sizes is not updated. + if (height &lt;= 300) { + + //frameTest.style.width = height++ + "px"; + frameTest.style.height = height++ + "px"; + + setTimeout(resizeReference, 10); + + } else { + + // uncomment the next line to see how a width resize triggers a layout recalculation + //frameTest.style.width = (parseInt(window.getComputedStyle(document.getElementById('frameTest'))['width'], 10) + 1) + "px"; + + } + + } + + setTimeout(resizeReference, 10); + </script> + +</head> +<body> + +<iframe src="vh_not_refreshing_on_chrome_iframe-ref.html" id="frameTest" frameborder="0"></iframe> + + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reftest-toc.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reftest-toc.xht new file mode 100644 index 00000000000..81b546e585a --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reftest-toc.xht @@ -0,0 +1,486 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>CSS Values and Units Module Level 3 CR Test Suite Reftest Index</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSS Values and Units Module Level 3 CR Test Suite Reftest Index</h1> + <table width="100%"> + <col id="test-column"></col> + <col id="ref-column"></col> + <col id="flags-column"></col> + <thead> + <tr> + <th>Test</th> + <th>Reference</th> + <th>Flags</th> + </tr> + </thead> + <tbody id="calc-background-image-gradient-1" class=""> + <tr> + <td rowspan="1" title="Test for calc() on background-image gradients"> + <a href="calc-background-image-gradient-1.xht">calc-background-image-gradient-1</a></td> + <td><a href="reference/calc-background-image-gradient-1-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-background-linear-gradient-1" class=""> + <tr> + <td rowspan="1" title="Support calc() on gradient stop positions"> + <a href="calc-background-linear-gradient-1.xht">calc-background-linear-gradient-1</a></td> + <td><a href="reference/calc-background-linear-gradient-1-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-background-position-1" class=""> + <tr> + <td rowspan="1" title="Test for calc() on background-position"> + <a href="calc-background-position-1.xht">calc-background-position-1</a></td> + <td><a href="reference/calc-background-position-1-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-background-size-1" class=""> + <tr> + <td rowspan="1" title="Test for calc() on background-size"> + <a href="calc-background-size-1.xht">calc-background-size-1</a></td> + <td><a href="reference/calc-background-size-1-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-border-radius-1" class=""> + <tr> + <td rowspan="1" title="test for border-radius: calc()"> + <a href="calc-border-radius-1.xht">calc-border-radius-1</a></td> + <td><a href="reference/calc-border-radius-1-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-height-block-1" class=""> + <tr> + <td rowspan="1" title="Test for height:calc() on blocks"> + <a href="calc-height-block-1.xht">calc-height-block-1</a></td> + <td><a href="reference/calc-height-block-1-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-height-table-1" class=""> + <tr> + <td rowspan="1" title="Test that height:calc() with no percentages has an effect on inner table elements"> + <a href="calc-height-table-1.xht">calc-height-table-1</a></td> + <td><a href="reference/calc-height-table-1-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-margin-block-1" class=""> + <tr> + <td rowspan="1" title="Test of margin-*: calc()"> + <a href="calc-margin-block-1.xht">calc-margin-block-1</a></td> + <td><a href="reference/calc-margin-block-1-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-max-height-block-1" class=""> + <tr> + <td rowspan="1" title="Test for max-height:calc() on blocks"> + <a href="calc-max-height-block-1.xht">calc-max-height-block-1</a></td> + <td><a href="reference/calc-max-height-block-1-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-max-width-block-1" class=""> + <tr> + <td rowspan="1" title="max-width: calc() on blocks"> + <a href="calc-max-width-block-1.xht">calc-max-width-block-1</a></td> + <td><a href="reference/calc-width-block-1-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-max-width-block-intrinsic-1" class=""> + <tr> + <td rowspan="1" title="intrinsic width of max-width: calc() on blocks"> + <a href="calc-max-width-block-intrinsic-1.xht">calc-max-width-block-intrinsic-1</a></td> + <td><a href="reference/calc-max-width-block-intrinsic-1-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-min-height-block-1" class=""> + <tr> + <td rowspan="1" title="Test for min-height:calc() on blocks"> + <a href="calc-min-height-block-1.xht">calc-min-height-block-1</a></td> + <td><a href="reference/calc-height-block-1-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-min-width-block-1" class=""> + <tr> + <td rowspan="1" title="min-width: calc() on blocks"> + <a href="calc-min-width-block-1.xht">calc-min-width-block-1</a></td> + <td><a href="reference/calc-width-block-1-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-min-width-block-intrinsic-1" class=""> + <tr> + <td rowspan="1" title="intrinsic width of min-width: calc() on blocks"> + <a href="calc-min-width-block-intrinsic-1.xht">calc-min-width-block-intrinsic-1</a></td> + <td><a href="reference/calc-min-width-block-intrinsic-1-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-offsets-absolute-bottom-1" class=""> + <tr> + <td rowspan="1" title="Test for bottom:calc() on absolutely positioned elements"> + <a href="calc-offsets-absolute-bottom-1.xht">calc-offsets-absolute-bottom-1</a></td> + <td><a href="reference/calc-offsets-absolute-top-1-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-offsets-absolute-left-1" class=""> + <tr> + <td rowspan="1" title="Test for left:calc() on absolutely positioned elements"> + <a href="calc-offsets-absolute-left-1.xht">calc-offsets-absolute-left-1</a></td> + <td><a href="reference/calc-offsets-relative-left-1-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-offsets-absolute-right-1" class=""> + <tr> + <td rowspan="1" title="Test for right:calc() on absolutely positioned elements"> + <a href="calc-offsets-absolute-right-1.xht">calc-offsets-absolute-right-1</a></td> + <td><a href="reference/calc-offsets-relative-left-1-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-offsets-absolute-top-1" class=""> + <tr> + <td rowspan="1" title="Test for top:calc() on absolutely positioned elements"> + <a href="calc-offsets-absolute-top-1.xht">calc-offsets-absolute-top-1</a></td> + <td><a href="reference/calc-offsets-absolute-top-1-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-offsets-relative-bottom-1" class=""> + <tr> + <td rowspan="1" title="Test for bottom:calc() on relatively positioned elements"> + <a href="calc-offsets-relative-bottom-1.xht">calc-offsets-relative-bottom-1</a></td> + <td><a href="reference/calc-offsets-relative-top-1-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-offsets-relative-left-1" class=""> + <tr> + <td rowspan="1" title="Test for left:calc() on relatively positioned elements"> + <a href="calc-offsets-relative-left-1.xht">calc-offsets-relative-left-1</a></td> + <td><a href="reference/calc-offsets-relative-left-1-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-offsets-relative-right-1" class=""> + <tr> + <td rowspan="1" title="Test for right:calc() on relatively positioned elements"> + <a href="calc-offsets-relative-right-1.xht">calc-offsets-relative-right-1</a></td> + <td><a href="reference/calc-offsets-relative-left-1-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-offsets-relative-top-1" class=""> + <tr> + <td rowspan="1" title="Test for top:calc() on relatively positioned elements"> + <a href="calc-offsets-relative-top-1.xht">calc-offsets-relative-top-1</a></td> + <td><a href="reference/calc-offsets-relative-top-1-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-padding-block-1" class=""> + <tr> + <td rowspan="1" title="Test of padding-*: calc()"> + <a href="calc-padding-block-1.xht">calc-padding-block-1</a></td> + <td><a href="reference/calc-padding-block-1-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-text-indent-1" class=""> + <tr> + <td rowspan="1" title="text-indent: calc() on blocks"> + <a href="calc-text-indent-1.xht">calc-text-indent-1</a></td> + <td><a href="reference/calc-text-indent-1-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-text-indent-intrinsic-1" class=""> + <tr> + <td rowspan="1" title="intrinsic width of text-indent: calc() on blocks"> + <a href="calc-text-indent-intrinsic-1.xht">calc-text-indent-intrinsic-1</a></td> + <td><a href="reference/calc-text-indent-intrinsic-1-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-transform-origin-1" class=""> + <tr> + <td rowspan="1" title="Test for calc() on transform-origin"> + <a href="calc-transform-origin-1.xht">calc-transform-origin-1</a></td> + <td><a href="reference/calc-transform-origin-1-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-vertical-align-1" class=""> + <tr> + <td rowspan="1" title="Test for vertical-align:calc()"> + <a href="calc-vertical-align-1.xht">calc-vertical-align-1</a></td> + <td><a href="reference/calc-vertical-align-1-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-width-block-1" class=""> + <tr> + <td rowspan="1" title="width: calc() on blocks"> + <a href="calc-width-block-1.xht">calc-width-block-1</a></td> + <td><a href="reference/calc-width-block-1-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-width-block-intrinsic-1" class=""> + <tr> + <td rowspan="1" title="intrinsic width of width: calc() on blocks"> + <a href="calc-width-block-intrinsic-1.xht">calc-width-block-intrinsic-1</a></td> + <td><a href="reference/calc-width-block-intrinsic-1-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-width-table-auto-1" class=""> + <tr> + <td rowspan="1" title="width: calc() on table-layout: auto tables"> + <a href="calc-width-table-auto-1.xht">calc-width-table-auto-1</a></td> + <td><a href="reference/calc-width-table-auto-1-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="calc-width-table-fixed-1" class=""> + <tr> + <td rowspan="1" title="width: calc() on table-layout: auto tables"> + <a href="calc-width-table-fixed-1.xht">calc-width-table-fixed-1</a></td> + <td><a href="reference/calc-width-table-fixed-1-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="ch-unit-001" class=""> + <tr> + <td rowspan="1" title="support for the ch unit"> + <a href="ch-unit-001.xht">ch-unit-001</a></td> + <td><a href="reference/ch-unit-001-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="min-width-001" class=""> + <tr> + <td rowspan="1" title="min-width length value approximation"> + <a href="min-width-001.xht">min-width-001</a></td> + <td><a href="ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="multicol-count-non-integer-001" class="ahem invalid"> + <tr> + <td rowspan="1" title="non-integer 'column-count' value"> + <a href="multicol-count-non-integer-001.xht">multicol-count-non-integer-001</a></td> + <td><a href="reference/multicol-columns-invalid-001-ref.xht">=</a> </td> + <td rowspan="1"><abbr class="ahem" title="Requires Ahem font">Ahem</abbr><abbr class="invalid" title="Tests invalid CSS">Invalid</abbr></td> + </tr> + </tbody> + <tbody id="multicol-count-non-integer-002" class="ahem invalid"> + <tr> + <td rowspan="1" title="non-integer 'column-count' value"> + <a href="multicol-count-non-integer-002.xht">multicol-count-non-integer-002</a></td> + <td><a href="reference/multicol-columns-invalid-001-ref.xht">=</a> </td> + <td rowspan="1"><abbr class="ahem" title="Requires Ahem font">Ahem</abbr><abbr class="invalid" title="Tests invalid CSS">Invalid</abbr></td> + </tr> + </tbody> + <tbody id="multicol-count-non-integer-003" class="ahem invalid"> + <tr> + <td rowspan="1" title="non-integer 'column-count' value"> + <a href="multicol-count-non-integer-003.xht">multicol-count-non-integer-003</a></td> + <td><a href="reference/multicol-columns-invalid-001-ref.xht">=</a> </td> + <td rowspan="1"><abbr class="ahem" title="Requires Ahem font">Ahem</abbr><abbr class="invalid" title="Tests invalid CSS">Invalid</abbr></td> + </tr> + </tbody> + <tbody id="multicol-inherit-002" class="ahem"> + <tr> + <td rowspan="1" title="'column-count' and inherit"> + <a href="multicol-inherit-002.xht">multicol-inherit-002</a></td> + <td><a href="reference/multicol-inherit-002-ref.xht">=</a> </td> + <td rowspan="1"><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + </tr> + </tbody> + <tbody id="multicol-rule-color-inherit-001" class="ahem"> + <tr> + <td rowspan="1" title="column-rule-color: inherit"> + <a href="multicol-rule-color-inherit-001.xht">multicol-rule-color-inherit-001</a></td> + <td><a href="reference/multicol-rule-color-inherit-001-ref.xht">=</a> </td> + <td rowspan="1"><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + </tr> + </tbody> + <tbody id="multicol-rule-color-inherit-002" class="ahem"> + <tr> + <td rowspan="1" title="column-rule-color: inherit (complex)"> + <a href="multicol-rule-color-inherit-002.xht">multicol-rule-color-inherit-002</a></td> + <td><a href="reference/multicol-rule-color-inherit-001-ref.xht">=</a> </td> + <td rowspan="1"><abbr class="ahem" title="Requires Ahem font">Ahem</abbr></td> + </tr> + </tbody> + <tbody id="regions-resizing-003" class="ahem dom http"> + <tr> + <td rowspan="1" title="CSS Regions: resizing region that is sized using viewport units"> + <a href="regions-resizing-003.xht">regions-resizing-003</a></td> + <td><a href="reference/regions-resizing-001-ref.xht">=</a> </td> + <td rowspan="1"><abbr class="ahem" title="Requires Ahem font">Ahem</abbr><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="http" title="Requires HTTP headers">HTTP</abbr></td> + </tr> + </tbody> + <tbody id="regions-resizing-007" class="ahem dom http"> + <tr> + <td rowspan="1" title="CSS Regions: resizing region with percentage size inside a container that has size set in viewport units"> + <a href="regions-resizing-007.xht">regions-resizing-007</a></td> + <td><a href="reference/regions-resizing-001-ref.xht">=</a> </td> + <td rowspan="1"><abbr class="ahem" title="Requires Ahem font">Ahem</abbr><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="http" title="Requires HTTP headers">HTTP</abbr></td> + </tr> + </tbody> + <tbody id="regions-resizing-009" class="ahem dom http"> + <tr> + <td rowspan="1" title="CSS Regions: resizing autosized region when content flowed in it is sized with viewport units"> + <a href="regions-resizing-009.xht">regions-resizing-009</a></td> + <td><a href="reference/regions-resizing-001-ref.xht">=</a> </td> + <td rowspan="1"><abbr class="ahem" title="Requires Ahem font">Ahem</abbr><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="http" title="Requires HTTP headers">HTTP</abbr></td> + </tr> + </tbody> + <tbody id="vh-calc-support" class=""> + <tr> + <td rowspan="1" title="Viewport units are supported inside calc expressions."> + <a href="vh-calc-support.xht">vh-calc-support</a></td> + <td><a href="reference/all-green.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="vh-calc-support-pct" class=""> + <tr> + <td rowspan="1" title="Viewport units are supported inside calc expressions."> + <a href="vh-calc-support-pct.xht">vh-calc-support-pct</a></td> + <td><a href="reference/all-green.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="vh-em-inherit" class=""> + <tr> + <td rowspan="1" title="0vh and 0vw are correctly treated as 0px"> + <a href="vh-em-inherit.xht">vh-em-inherit</a></td> + <td><a href="reference/all-green.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="vh-inherit" class=""> + <tr> + <td rowspan="1" title="Viewport units are inherited properly"> + <a href="vh-inherit.xht">vh-inherit</a></td> + <td><a href="reference/all-green.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="vh-interpolate-pct" class=""> + <tr> + <td rowspan="1" title="Viewport units are interpolated correctly"> + <a href="vh-interpolate-pct.xht">vh-interpolate-pct</a></td> + <td><a href="reference/all-green.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="vh-interpolate-px" class=""> + <tr> + <td rowspan="1" title="Viewport units are interpolated correctly"> + <a href="vh-interpolate-px.xht">vh-interpolate-px</a></td> + <td><a href="reference/all-green.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="vh-interpolate-vh" class=""> + <tr> + <td rowspan="1" title="Viewport units are interpolated correctly"> + <a href="vh-interpolate-vh.xht">vh-interpolate-vh</a></td> + <td><a href="reference/all-green.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="vh-support" class=""> + <tr> + <td rowspan="1" title="Viewports units are supported in sizing properties"> + <a href="vh-support.xht">vh-support</a></td> + <td><a href="reference/all-green.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="vh-support-atviewport" class=""> + <tr> + <td rowspan="1" title="Viewports units are supported in @viewport rules"> + <a href="vh-support-atviewport.xht">vh-support-atviewport</a></td> + <td><a href="reference/all-green.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="vh-support-margin" class=""> + <tr> + <td rowspan="1" title="Viewports units are supported in margin properties"> + <a href="vh-support-margin.xht">vh-support-margin</a></td> + <td><a href="reference/all-green.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="vh-support-transform-origin" class=""> + <tr> + <td rowspan="1" title="Viewports units are supported in transform properties"> + <a href="vh-support-transform-origin.xht">vh-support-transform-origin</a></td> + <td><a href="reference/all-green.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="vh-support-transform-translate" class=""> + <tr> + <td rowspan="1" title="Viewports units are supported in transform properties"> + <a href="vh-support-transform-translate.xht">vh-support-transform-translate</a></td> + <td><a href="reference/all-green.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="vh-zero-support" class=""> + <tr> + <td rowspan="1" title="0vh and 0vw are correctly treated as 0px"> + <a href="vh-zero-support.xht">vh-zero-support</a></td> + <td><a href="reference/all-green.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="vh_not_refreshing_on_chrome" class=""> + <tr> + <td rowspan="1" title="vh-based dimension doesn't change when the element's other dimension doesn't change."> + <a href="vh_not_refreshing_on_chrome.xht">vh_not_refreshing_on_chrome</a></td> + <td><a href="reference/vh_not_refreshing_on_chrome-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + <tbody id="vh_not_refreshing_on_chrome_iframe" class=""> + <tr> + <td rowspan="1" title="vh-based dimension doesn't change when the element other dimension doesn't change."> + <a href="vh_not_refreshing_on_chrome_iframe.xht">vh_not_refreshing_on_chrome_iframe</a></td> + <td><a href="reference/vh_not_refreshing_on_chrome-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> + </table> + + </body> +</html> diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/reftest.list b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reftest.list new file mode 100644 index 00000000000..3087d767568 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/reftest.list @@ -0,0 +1,58 @@ + +calc-background-image-gradient-1.xht == reference/calc-background-image-gradient-1-ref.xht +calc-background-linear-gradient-1.xht == reference/calc-background-linear-gradient-1-ref.xht +calc-background-position-1.xht == reference/calc-background-position-1-ref.xht +calc-background-size-1.xht == reference/calc-background-size-1-ref.xht +calc-border-radius-1.xht == reference/calc-border-radius-1-ref.xht +calc-height-block-1.xht == reference/calc-height-block-1-ref.xht +calc-height-table-1.xht == reference/calc-height-table-1-ref.xht +calc-margin-block-1.xht == reference/calc-margin-block-1-ref.xht +calc-max-height-block-1.xht == reference/calc-max-height-block-1-ref.xht +calc-max-width-block-1.xht == reference/calc-width-block-1-ref.xht +calc-max-width-block-intrinsic-1.xht == reference/calc-max-width-block-intrinsic-1-ref.xht +calc-min-height-block-1.xht == reference/calc-height-block-1-ref.xht +calc-min-width-block-1.xht == reference/calc-width-block-1-ref.xht +calc-min-width-block-intrinsic-1.xht == reference/calc-min-width-block-intrinsic-1-ref.xht +calc-offsets-absolute-bottom-1.xht == reference/calc-offsets-absolute-top-1-ref.xht +calc-offsets-absolute-left-1.xht == reference/calc-offsets-relative-left-1-ref.xht +calc-offsets-absolute-right-1.xht == reference/calc-offsets-relative-left-1-ref.xht +calc-offsets-absolute-top-1.xht == reference/calc-offsets-absolute-top-1-ref.xht +calc-offsets-relative-bottom-1.xht == reference/calc-offsets-relative-top-1-ref.xht +calc-offsets-relative-left-1.xht == reference/calc-offsets-relative-left-1-ref.xht +calc-offsets-relative-right-1.xht == reference/calc-offsets-relative-left-1-ref.xht +calc-offsets-relative-top-1.xht == reference/calc-offsets-relative-top-1-ref.xht +calc-padding-block-1.xht == reference/calc-padding-block-1-ref.xht +calc-text-indent-1.xht == reference/calc-text-indent-1-ref.xht +calc-text-indent-intrinsic-1.xht == reference/calc-text-indent-intrinsic-1-ref.xht +calc-transform-origin-1.xht == reference/calc-transform-origin-1-ref.xht +calc-vertical-align-1.xht == reference/calc-vertical-align-1-ref.xht +calc-width-block-1.xht == reference/calc-width-block-1-ref.xht +calc-width-block-intrinsic-1.xht == reference/calc-width-block-intrinsic-1-ref.xht +calc-width-table-auto-1.xht == reference/calc-width-table-auto-1-ref.xht +calc-width-table-fixed-1.xht == reference/calc-width-table-fixed-1-ref.xht +ch-unit-001.xht == reference/ch-unit-001-ref.xht +min-width-001.xht == ref.xht +multicol-count-non-integer-001.xht == reference/multicol-columns-invalid-001-ref.xht +multicol-count-non-integer-002.xht == reference/multicol-columns-invalid-001-ref.xht +multicol-count-non-integer-003.xht == reference/multicol-columns-invalid-001-ref.xht +multicol-inherit-002.xht == reference/multicol-inherit-002-ref.xht +multicol-rule-color-inherit-001.xht == reference/multicol-rule-color-inherit-001-ref.xht +multicol-rule-color-inherit-002.xht == reference/multicol-rule-color-inherit-001-ref.xht +regions-resizing-003.xht == reference/regions-resizing-001-ref.xht +regions-resizing-007.xht == reference/regions-resizing-001-ref.xht +regions-resizing-009.xht == reference/regions-resizing-001-ref.xht +vh-calc-support.xht == reference/all-green.xht +vh-calc-support-pct.xht == reference/all-green.xht +vh-em-inherit.xht == reference/all-green.xht +vh-inherit.xht == reference/all-green.xht +vh-interpolate-pct.xht == reference/all-green.xht +vh-interpolate-px.xht == reference/all-green.xht +vh-interpolate-vh.xht == reference/all-green.xht +vh-support.xht == reference/all-green.xht +vh-support-atviewport.xht == reference/all-green.xht +vh-support-margin.xht == reference/all-green.xht +vh-support-transform-origin.xht == reference/all-green.xht +vh-support-transform-translate.xht == reference/all-green.xht +vh-zero-support.xht == reference/all-green.xht +vh_not_refreshing_on_chrome.xht == reference/vh_not_refreshing_on_chrome-ref.xht +vh_not_refreshing_on_chrome_iframe.xht == reference/vh_not_refreshing_on_chrome-ref.xht diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/regions-resizing-003.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/regions-resizing-003.xht new file mode 100644 index 00000000000..aae2512e97a --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/regions-resizing-003.xht @@ -0,0 +1,33 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Regions: resizing region that is sized using viewport units</title> + <link href="mailto:mibalan@adobe.com" rel="author" title="Mihai Balan" /> + <link href="http://www.w3.org/TR/css3-regions/#the-flow-into-property" rel="help" /> + <link href="http://www.w3.org/TR/css3-regions/#flow-from" rel="help" /> + <link href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" rel="help" /> + <meta content="dom ahem http" name="flags" /> + <meta content="Test checks that resizing the viewport of a page containing a region + sized using viewport units correctly relayouts the region's contents." name="assert" /> + <link href="reference/regions-resizing-001-ref.xht" rel="match" /> + <!-- The <script type="text/css"> below is just a textual container for styles that will be + injected in the iframe at load time.--> + <script type="text/css" id="test-styles"> + #region { + width: 80vw; + height: 100vh; + } + </script> + <script src="support/util.js" type="text/javascript"></script> + <script type="text/javascript"> + window.addEventListener("load", function() { + injectStylesInIFrame("#test-styles", "iframe"); + resizeViewportTo("iframe", 100, 100); + }) + </script> + </head> + <body> + <p>Test passes if you see a green square below and no red.</p> + <p>The test also fails if the there's a green block that is <strong>not</strong> a square (e.g. rectangle or polygon).</p> + <iframe width="400" height="400" frameborder="0" src="support/region-in-body.html"></iframe> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/regions-resizing-007.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/regions-resizing-007.xht new file mode 100644 index 00000000000..7978fd22f08 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/regions-resizing-007.xht @@ -0,0 +1,41 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Regions: resizing region with percentage size inside a container that has size set in viewport units</title> + <link href="mailto:mibalan@adobe.com" rel="author" title="Mihai Balan" /> + <link href="http://www.w3.org/TR/css3-regions/#the-flow-into-property" rel="help" /> + <link href="http://www.w3.org/TR/css3-regions/#flow-from" rel="help" /> + <link href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" rel="help" /> + <meta content="dom ahem http" name="flags" /> + <meta content="Test checks that resizing the viewport of a page containing a region + that has a percentage size relative to a parent sized using viewport units correctly + relayouts the region's contents." name="assert" /> + <link href="reference/regions-resizing-001-ref.xht" rel="match" /> + <!-- The <script type="text/css"> below is just a textual container for styles that will be + injected in the iframe at load time.--> + <script type="text/css" id="test-styles"> + html, body { + height: 100%; + } + #region-parent { + width: 50vw; + height: 80vh; + } + #region { + width: 80%; + height: 70%; + } + </script> + <script src="support/util.js" type="text/javascript"></script> + <script type="text/javascript"> + window.addEventListener("load", function() { + injectStylesInIFrame("#test-styles", "iframe"); + resizeViewportTo("iframe", 200, 200); + }) + </script> + </head> + <body> + <p>Test passes if you see a green square below and no red.</p> + <p>The test also fails if the there's a green block that is <strong>not</strong> a square (e.g. rectangle or polygon).</p> + <iframe width="437" height="143" frameborder="0" src="support/region-in-container.html"></iframe> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/regions-resizing-009.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/regions-resizing-009.xht new file mode 100644 index 00000000000..d7255bdd971 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/regions-resizing-009.xht @@ -0,0 +1,39 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Regions: resizing autosized region when content flowed in it is sized with viewport units</title> + <link href="mailto:mibalan@adobe.com" rel="author" title="Mihai Balan" /> + <link href="http://www.w3.org/TR/css3-regions/#the-flow-into-property" rel="help" /> + <link href="http://www.w3.org/TR/css3-regions/#flow-from" rel="help" /> + <link href="http://www.w3.org/TR/css3-regions/#regions-visual-formatting-details" rel="help" /> + <link href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" rel="help" /> + <meta content="dom ahem http" name="flags" /> + <meta content="Test checks that resizing the viewport of a page containing an + autosized region when the content flowed in it is sized with viewport units correctly + relayouts the region's contents." name="assert" /> + <link href="reference/regions-resizing-001-ref.xht" rel="match" /> + <!-- The <script type="text/css"> below is just a textual container for styles that will be + injected in the iframe at load time.--> + <script type="text/css" id="test-styles"> + #content { + width: 40vw; + height: 40vh; + } + #region { + width: auto; + height: auto; + } + </script> + <script src="support/util.js" type="text/javascript"></script> + <script type="text/javascript"> + window.addEventListener("load", function() { + injectStylesInIFrame("#test-styles", "iframe"); + resizeViewportTo("iframe", 200, 200); + }) + </script> + </head> + <body> + <p>Test passes if you see a green square below and no red.</p> + <p>The test also fails if the there's a green block that is <strong>not</strong> a square (e.g. rectangle or polygon).</p> + <iframe width="437" height="143" frameborder="0" src="support/region-in-body.html"></iframe> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/shape-outside-circle-002.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/shape-outside-circle-002.xht new file mode 100644 index 00000000000..c1586399674 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/shape-outside-circle-002.xht @@ -0,0 +1,30 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>Shape Outside Circle Valid Positions</title> + <link href="http://html.adobe.com/" rel="author" title="Adobe" /> + <link href="mailto:betravis@adobe.com" rel="author" title="Bear Travis" /> + <link href="mailto:rhauck@adobe.com" rel="author" title="Rebecca Hauck" /> + <link href="mailto:stearns@adobe.com" rel="reviewer" title="Alan Stearns" /> <!-- 2014-03-04 --> + <link href="http://www.w3.org/TR/css-shapes-1/#funcdef-circle" rel="help" /> + <link href="http://www.w3.org/TR/css-shapes-1/#shape-outside-property" rel="help" /> + <link href="http://www.w3.org/TR/css3-values/#lengths" rel="help" /> + <meta content="A circle's position argument may be any of the valid combinations: + [ percentage|length left|center|right ] + or [ percentage|length left|center|right ] [ percentage|length top|center|bottom ] + or [ left|center|right ] + or [ left|center|right top|center|bottom ] + or [ top|center|bottom ]. " name="assert" /> + <meta content="dom" name="flags" /> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> + <script src="support/parsing-utils.js"></script> + </head> + <body> + <div id="log"></div> + <script type="text/javascript"> + generate_tests(ParsingUtils.testInlineStyle, ParsingUtils.buildPositionTests('circle', true, 'inline', 'px')); + generate_tests(ParsingUtils.testComputedStyle, ParsingUtils.buildPositionTests('circle', true, 'computed', 'px')); + </script> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/shape-outside-circle-004.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/shape-outside-circle-004.xht new file mode 100644 index 00000000000..2b06df0a4ba --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/shape-outside-circle-004.xht @@ -0,0 +1,26 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>Shape Outside Circle - Position Length Units</title> + <link href="http://html.adobe.com/" rel="author" title="Adobe" /> + <link href="mailto:rhauck@adobe.com" rel="author" title="Rebecca Hauck" /> + <link href="mailto:stearns@adobe.com" rel="reviewer" title="Alan Stearns" /> <!-- 2014-03-04 --> + <link href="http://www.w3.org/TR/css-shapes-1/#funcdef-circle" rel="help" /> + <link href="http://www.w3.org/TR/css-shapes-1/#shape-outside-property" rel="help" /> + <link href="http://www.w3.org/TR/css3-values/#lengths" rel="help" /> + <meta content="A circle's position arguments may in any valid &lt;length> unit allowed by a &lt;position> value." name="assert" /> + <meta content="dom" name="flags" /> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> + <script src="support/parsing-utils.js"></script> + </head> + <body> + <div id="log"></div> + <script type="text/javascript"> + generate_tests( ParsingUtils.testInlineStyle, + ParsingUtils.buildPositionTests("circle", true, 'lengthUnit + inline', ParsingUtils.validUnits) ); + generate_tests( ParsingUtils.testComputedStyle, + ParsingUtils.buildPositionTests("circle", true, 'lengthUnit + computed', ParsingUtils.validUnits) ); + </script> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/shape-outside-ellipse-002.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/shape-outside-ellipse-002.xht new file mode 100644 index 00000000000..b62861f81de --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/shape-outside-ellipse-002.xht @@ -0,0 +1,30 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>Shape Outside Ellipse Valid Positions</title> + <link href="http://html.adobe.com/" rel="author" title="Adobe" /> + <link href="mailto:betravis@adobe.com" rel="author" title="Bear Travis" /> + <link href="mailto:rhauck@adobe.com" rel="author" title="Rebecca Hauck" /> + <link href="mailto:stearns@adobe.com" rel="reviewer" title="Alan Stearns" /> <!-- 2014-03-04 --> + <link href="http://www.w3.org/TR/css-shapes-1/#funcdef-ellipse" rel="help" /> + <link href="http://www.w3.org/TR/css-shapes-1/#shape-outside-property" rel="help" /> + <link href="http://www.w3.org/TR/css3-values/#lengths" rel="help" /> + <meta content="An ellipse's position argument may be any of the valid combinations: + [ percentage|length left|center|right ] + or [ percentage|length left|center|right ] [ percentage|length top|center|bottom ] + or [ left|center|right ] + or [ left|center|right top|center|bottom ] + or [ top|center|bottom ]. " name="assert" /> + <meta content="dom" name="flags" /> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> + <script src="support/parsing-utils.js"></script> + </head> + <body> + <div id="log"></div> + <script type="text/javascript"> + generate_tests(ParsingUtils.testInlineStyle, ParsingUtils.buildPositionTests('ellipse', true, 'inline', 'px')); + generate_tests(ParsingUtils.testComputedStyle, ParsingUtils.buildPositionTests('ellipse', true, 'computed', 'px')); + </script> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/shape-outside-ellipse-004.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/shape-outside-ellipse-004.xht new file mode 100644 index 00000000000..ff027d7deea --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/shape-outside-ellipse-004.xht @@ -0,0 +1,26 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>Shape Outside Ellipse - Position Length Units</title> + <link href="http://html.adobe.com/" rel="author" title="Adobe" /> + <link href="mailto:rhauck@adobe.com" rel="author" title="Rebecca Hauck" /> + <link href="mailto:stearns@adobe.com" rel="reviewer" title="Alan Stearns" /> <!-- 2014-03-04 --> + <link href="http://www.w3.org/TR/css-shapes-1/#funcdef-ellipse" rel="help" /> + <link href="http://www.w3.org/TR/css-shapes-1/#shape-outside-property" rel="help" /> + <link href="http://www.w3.org/TR/css3-values/#lengths" rel="help" /> + <meta content="An ellipse's position arguments may in any valid &lt;length> unit allowed by a &lt;position> value." name="assert" /> + <meta content="dom" name="flags" /> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> + <script src="support/parsing-utils.js"></script> + </head> + <body> + <div id="log"></div> + <script type="text/javascript"> + generate_tests( ParsingUtils.testInlineStyle, + ParsingUtils.buildPositionTests("ellipse", true, 'lengthUnit + inline', ParsingUtils.validUnits) ); + generate_tests( ParsingUtils.testComputedStyle, + ParsingUtils.buildPositionTests("ellipse", true, 'lengthUnit + computed', ParsingUtils.validUnits) ); + </script> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/shape-outside-inset-003.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/shape-outside-inset-003.xht new file mode 100644 index 00000000000..80bed79f39e --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/shape-outside-inset-003.xht @@ -0,0 +1,28 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>Shape Outside Inset Valid Round Length Units</title> + <link href="http://html.adobe.com/" rel="author" title="Adobe" /> + <link href="mailto:rhauck@adobe.com" rel="author" title="Rebecca Hauck" /> + <link href="mailto:stearns@adobe.com" rel="reviewer" title="Alan Stearns" /> <!-- 2014-03-04 --> + <link href="http://www.w3.org/TR/css-shapes-1/#funcdef-inset" rel="help" /> + <link href="http://www.w3.org/TR/css-shapes-1/#shape-outside-property" rel="help" /> + <link href="http://www.w3.org/TR/css3-values/#lengths" rel="help" /> + <meta content="An inset's radial component's values can be in any length unit" name="assert" /> + <meta content="dom" name="flags" /> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> + <script src="support/parsing-utils.js"></script> + </head> + <body> + <div id="log"></div> + <script type="text/javascript"> + ParsingUtils.validUnits.forEach(function(unit) { + generate_tests(ParsingUtils.testInlineStyle, ParsingUtils.generateInsetRoundCases(unit, 'inline')); + }); + ParsingUtils.validUnits.forEach(function(unit) { + generate_tests(ParsingUtils.testComputedStyle, ParsingUtils.generateInsetRoundCases(unit, 'computed')); + }); + </script> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/shape-outside-polygon-004.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/shape-outside-polygon-004.xht new file mode 100644 index 00000000000..6f94e32b4d4 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/shape-outside-polygon-004.xht @@ -0,0 +1,38 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>Shape Outside Polygon - Argument Length Units</title> + <link href="http://html.adobe.com/" rel="author" title="Adobe" /> + <link href="mailto:rhauck@adobe.com" rel="author" title="Rebecca Hauck" /> + <link href="mailto:stearns@adobe.com" rel="reviewer" title="Alan Stearns" /> <!-- 2014-03-04 --> + <link href="http://www.w3.org/TR/css-shapes-1/#funcdef-polygon" rel="help" /> + <link href="http://www.w3.org/TR/css-shapes-1/#shape-outside-property" rel="help" /> + <link href="http://www.w3.org/TR/css3-values/#lengths" rel="help" /> + <meta content="A polygon's veritices may in percentage or any valid &lt;length> units." name="assert" /> + <meta content="dom" name="flags" /> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> + <script src="support/parsing-utils.js"></script> + </head> + <body> + <div id="log"></div> + <script type="text/javascript"> + var arg_length_units_tests = [ + ['%', 'px', 'px'], + ['px', '%', 'px'], + ['px', 'px', '%'], + ['%', '%', '%'], + ['em', 'em', 'ex'], + ['vw', 'vh', '%'], + ['cm', 'mm', 'pc'], + ['vmin', 'vmin', 'vmax'], + ['rem', 'ch', 'rem'], + ['in', 'pt', '%'] + ]; + generate_tests( ParsingUtils.testInlineStyle, + ParsingUtils.buildPolygonTests(arg_length_units_tests, 'inline') ); + generate_tests( ParsingUtils.testComputedStyle, + ParsingUtils.buildPolygonTests(arg_length_units_tests, 'computed') ); + </script> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/1x1-green.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/1x1-green.png new file mode 100644 index 0000000000000000000000000000000000000000..b98ca0ba0a03c580ac339e4a3653539cfa8edc71 GIT binary patch literal 135 zcmeAS@N?(olHy`uVBq!ia0vp^j3CU&3?x-=hn)gaEa{HEjtmUzPnffIy#(@^1AIbU z85$Vo{9HN_$mQ~MaSW-rm7D-%GchneRloNK$dW8^jVKAuPb(=;EJ|f?Ovz75Rq)JB bOiv9;O-!jQJeg_(RK(!v>gTe~DWM4f4{;-! literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/1x1-lime.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/1x1-lime.png new file mode 100644 index 0000000000000000000000000000000000000000..cb397fb090e199c51e80e4243d1ede03a79aa8d9 GIT binary patch literal 135 zcmeAS@N?(olHy`uVBq!ia0vp^j3CU&3?x-=hn)gaEa{HEjtmUzPnffIy#(@^1AIbU z8U8bv#2r`x<Z^ksIEGZ*N=^W>nHU(Ks^9wqWJ#8|MwA5Sr<If^7Ns&crsOB3DtP85 brl$s_CZ<#to=mj?Dq`?-^>bP0l+XkK_<AEq literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/1x1-maroon.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/1x1-maroon.png new file mode 100644 index 0000000000000000000000000000000000000000..3f86b0721955eb4e0f014102c68c2a9764ef7593 GIT binary patch literal 109 zcmeAS@N?(olHy`uVBq!ia0vp^j3CUx1|;Q0k8}blwj^(N7lsBPi@{?l_gf&vS>O>_ v4B~>Z+sSM@AcNP_#W95AdU8fW!Vi81W){YV4{giyfD#Ozu6{1-oD!M<@rf3U literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/1x1-navy.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/1x1-navy.png new file mode 100644 index 0000000000000000000000000000000000000000..9b9a03955baea7abde9e056e8604e18694e49b66 GIT binary patch literal 109 zcmeAS@N?(olHy`uVBq!ia0vp^j3CUx1|;Q0k8}blwj^(N7a+~R&>-^LA|6O{7I;J! w18EO1b~~AE2W0Six;Tb#Tu)9&$oRp}z{JAX(7`d=3n;<h>FVdQ&MBb@0MNe`HUIzs literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/1x1-red.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/1x1-red.png new file mode 100644 index 0000000000000000000000000000000000000000..6bd73ac101874f306d007e9cea8fa3a1f62dce16 GIT binary patch literal 135 zcmeAS@N?(olHy`uVBq!ia0vp^j3CU&3?x-=hn)gaEa{HEjtmUzPnffIy#(@^1AIbU z|1&U1KH@Y7a=AQR978H@B_{ycObm=q)$jcQvLs7fBT9nv(@M${i&7aJQ}UBi6+Ckj b(^G>|6H_V+Po~-c6)||a`njxgN@xNA!@(kn literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/1x1-white.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/1x1-white.png new file mode 100644 index 0000000000000000000000000000000000000000..dd43faec54ae60a210f1eab6ff4e7c88b8e34c97 GIT binary patch literal 109 zcmeAS@N?(olHy`uVBq!ia0vp^j3CUx1|;Q0k8}blwj^(N7l!{JxM1({$v_d#0*}aI wAngIhZYQ(tfDB$w7sn8e>&ZX<|Nmdl!1<f`@5Sbx4?qb9Pgg&ebxsLQ020p~!2kdN literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/2-80px-block-ref.html b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/2-80px-block-ref.html new file mode 100644 index 00000000000..f616001554c --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/2-80px-block-ref.html @@ -0,0 +1,33 @@ +<!DOCTYPE html> +<html lang="en"><head> + <meta charset="UTF-8"> + <title>One region in body</title> + <style> + html, body { + margin: 0; + padding: 0; + } + .content { + margin: 10px; + font-family: Ahem; + font-size: 20px; + line-height: 1em; + color: green; + } + </style> +</head> +<body> + <div class="content"> + xxxx<br> + xxxx<br> + xxxx<br> + xxxx + </div> + <div class="content"> + xxxx<br> + xxxx<br> + xxxx<br> + xxxx + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/60x60-gg-rr.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/60x60-gg-rr.png new file mode 100644 index 0000000000000000000000000000000000000000..84f5b2a4f1d1865d763cac875bfa6a8c5c576c91 GIT binary patch literal 224 zcmeAS@N?(olHy`uVBq!ia0vp^HXzKw1SGf4^HT*<jKx9jP7LeL$-D$|I14-?iy0WW zg+Z8+Vb&Z8pdfpRr>`sfEmlzu3&R;K0lq*X$r9Iy66gHf+|;}h2Ir#G#FEq$h4Rdj z3<Y;j-+=H&K5?KTUr!gukc@k8FBtMN81S%c^q)Ar(pb!~&BKo6T4>(2QlSh?@M7jG eOI|GCZ+2WP<2UBa)$Kro89ZJ6T-G@yGywqpiaLV; literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/60x60-green.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/60x60-green.png new file mode 100644 index 0000000000000000000000000000000000000000..b3c8cf3eb4c89bd8f2d1ffde051856f375e3a3de GIT binary patch literal 218 zcmeAS@N?(olHy`uVBq!ia0vp^HXzKw1SGf4^HT*<jKx9jP7LeL$-D$|I14-?iy0WW zg+Z8+Vb&Z8pdfpRr>`sfEmlzu3yE9XPACF}BuiW)N}Tg^b5rw57@Uhz6H8K46v{J8 zG8EiBeFMT9`NV;W+&x_!Lo)8YJ?F^Fz`((>;PMkU^HzRy4~NuGe(INq1>ePjdKrGS TIXtNc8p+`4>gTe~DWM4fy9-d) literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/60x60-red.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/60x60-red.png new file mode 100644 index 0000000000000000000000000000000000000000..823f125b8e4a60f780f00443c9c9a10b9fa1f447 GIT binary patch literal 217 zcmeAS@N?(olHy`uVBq!ia0vp^HXzKw1SGf4^HT*<jKx9jP7LeL$-D$|I14-?iy0WW zg+Z8+Vb&Z8pdfpRr>`sfEmlzuQ<1cFzubXBk|nMYCC>S|xv6<249-QVi6yBi3gww4 z84B*6z5(HleBwYwZk{fVAsP4Ho@3->VBlchkp2JMEhm9(EUQo2%VrV@UNUpX$1;`+ Ty_~-WXd;8BtDnm{r-UW|v1>m& literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/80px-block-float-ref.html b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/80px-block-float-ref.html new file mode 100644 index 00000000000..6adeeb6fa99 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/80px-block-float-ref.html @@ -0,0 +1,27 @@ +<!DOCTYPE html> +<html lang="en"><head> + <meta charset="UTF-8"> + <title>One region in body</title> + <style> + html, body { + margin: 0; + padding: 0; + } + #content { + font-family: Ahem; + font-size: 20px; + line-height: 1em; + color: green; + float: right; + } + </style> +</head> +<body> + <div id="content"> + xxxx<br> + xxxx<br> + xxxx<br> + xxxx + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/80px-block-ref.html b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/80px-block-ref.html new file mode 100644 index 00000000000..2c910e93411 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/80px-block-ref.html @@ -0,0 +1,26 @@ +<!DOCTYPE html> +<html lang="en"><head> + <meta charset="UTF-8"> + <title>One region in body</title> + <style> + html, body { + margin: 0; + padding: 0; + } + #content { + font-family: Ahem; + font-size: 20px; + line-height: 1em; + color: green; + } + </style> +</head> +<body> + <div id="content"> + xxxx<br> + xxxx<br> + xxxx<br> + xxxx + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/README b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/README new file mode 100644 index 00000000000..69d1737bead --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/README @@ -0,0 +1,29 @@ +CSS Global Support Directory +============================ + +This directory contains common support files (such as images and external +style sheets). These are sync'ed into the support directories of all our +test suites. If you have test-suite-specific support files, please add +them to the appropriate test-suite-specific support/ directory. + +If you add to a support/ directory, please run the tools/supportprop.py +script from the top of the repository to cascade support files into the +lower-level support directories. + +Description of the Common Support File Collection +------------------------------------------------- + +The 1x1-* images are all exactly one pixel. + +The swatch-* images all use 15x15 cells. + +The square-* images all use 15x15 cells with one pixel borders. + +The pattern-* images use cells of various sizes: + + pattern-gg-gr.png 20x20 + pattern-grg-rgr-grg.png 20x20 + pattern-rgr-grg-rgr.png 20x20 + pattern-tr.png 15x15 + pattern-grg-rrg-rgg.png 15x15 + diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/a-green.css b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/a-green.css new file mode 100644 index 00000000000..b0dbb071d5b --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/a-green.css @@ -0,0 +1 @@ +.a { color: green; } diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/b-green.css b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/b-green.css new file mode 100644 index 00000000000..a0473f5ca26 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/b-green.css @@ -0,0 +1 @@ +.b { color: green; } \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/black20x20.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/black20x20.png new file mode 100644 index 0000000000000000000000000000000000000000..ebf7027ee785af8acf0bf6c213c616b4055ee10f GIT binary patch literal 165 zcmeAS@N?(olHy`uVBq!ia0vp^A|TAc1SFYWcSQjy#^NA%Cx&(BWL^R}oCO|{#S9F5 zM?jcysy3fAP>{XE)7O>#4vV<BhIm+`Vi!<Ivcxr_#5q4VH#M(>!MP|ku_QG`p**uB zL&4qCHz2%`PaLR7$kW9!#Nu>vf&}a01d*Pmh1?7*M;I8N6kM?a$})Jm`njxgN@xNA DYH%n_ literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/c-red.css b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/c-red.css new file mode 100644 index 00000000000..d4ba5c64e95 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/c-red.css @@ -0,0 +1 @@ +.c { color: red; } \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/cat.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/cat.png new file mode 100644 index 0000000000000000000000000000000000000000..85dd7324815b8f8ef1a1d0496224c1a0661db9d8 GIT binary patch literal 1883 zcmV-h2c-CkP)<h;3K|Lk000e1NJLTq003eD003hM0ssI3n4EHI0000LbVXQnLvm$d zbZKvHAXI5>WdH}z3>gRm8%$Aad;kCd2XskIMF-Ff83-yN8ye1400009a7bBm000id z000id0mpBsWB>pL*-1n}RCwC$Tnn<>HVmXZK1a^ho3&SK4-(g{9GN13#R7t8y*I%m zZ)BMw!6g9VLwR{T9*v;e^Z&9e>xbnR^*7(`)-M11{_j7xFNSfJ@$>S&(_i1@5GH@m zhpeXC{afFEKhVJCt^WWpLj3iQEg77_JYJnk79anUvL0gx`(AYZ27s0x;q_WRcJD`A zg+R7jBu}y@4l@kFdQJ7DGoh@H-xD(&>S?#kV5MJwAHN8ovs16uEnknmyyLJw3_Dz} z-2t_1y-WcyWmd+)eVZDoh>C$4rk3Oju)y$mQ#%^)+P>PB74gM`GN6$$a17nlNge7- z3RmB|dPjb|$p?mh6-(D?ThB@WuYf>+sj1twj=G%GFkj5O!mZqLtqotF8cC*N$ri;H z2HQ+$17ses$k7#RTbJz}gD2-`@wiB%W8DFRH7rLV$VR8C-{$0BU^7QA)6xcOPkeLG zIC+y8#pH<ZE4DkLuB$eJu=YD09p6saU_=3B*q=j^t+sjfsKzKVsF6<N*#6N`(<ECy zIXKz+z9s_>H3S(N>pr`5y87*;bv|b^HW*-n7#c-VH5l06wfM%K8tMv%QYu1VMJ&`q zXuT9g-DjG%ok+2IhK&G~#M;r0zu4sf-`3+KmoX<0eCv7>JZuYAQ4+JlXds3Yz$`iq zO!pQ9wr}Yor1)n9bJP~%@)tD+crwU7nJ%PeORd0)1m4F<)qG~XO2nT^iMivEf)z-D zBxjR-YQ3Q3>4*f>(%TkH;D#Ki*aVYot>nkyxLr9zV62-PtQAsVZ<)M&ROZ`q=r-yb zxV0FojhaWJa00$t-zE`xTYXArX#ra%P+dk^apt~h+vO{<A@@#@ZFd70kl?YRKP5&g zb`j&Qn9|8fN_S*$P|_f3a(aM4y>N9i$&>6i;Se`Xu#!Aka_7=8lY{bL`gE8-D*^)! zY7!?ohKiqcXDjd>0jZICXBl_KZ$6sC00LyW54V5*dj5-!>hm-t>Ht(52LoWuR*1xE z2G*{@twTZxdhmIo{825j6wMk`;$*SKGZc>R!t=-#&gkXa<yH8pw79M3dp_ikAFn&8 zlrN9ORLOJsca5=ic6o}b2pc1mIER3bjmUh7pG>kkRkQfHYSKVRo~#WuBph;XemDuD z6qUJ989evMeRwkDj)54kU$UA#IGU-IZHnWTVRA#9kA1APN3ZjwA2_hn2Ug_Nvo#=1 zvdA6|8~BUnoI@62w{|P|2@lwrchE#7bJ6Kq6kBhZllSFE87tja$&a^Vsv9DzjxZA* zQVOrQc2nyJWb8G&wn4GZFkUv;Z=ATnxIprXHN_9;9UHeyvrlY2*kxbFPXGYML&r3) zen%FSp5K}|`|V@N#w>xf>JHCqGnQ($o1mTz0Za^NSrBZ!onF6dnw<3&y(VH1bndXf z391*{FlywkRueb2`q*Y`c5i|#c-`R1y$R0#>_jShsA?F))d087sWd*L&RJQPVgO6z zuKDv)`2I=hc!ut73ss<T4Sc(1p2frAo70eTGSQX~W-TmJr(%YaR!iQ`4Ur=@=?jjU zfTygMe0q~vry0lFm|`8tJ+roq*(WDI6R9%w#!|-Y#%eR(ke!N@^4>>?(GbUMv>AFu zU<y*Z1YJ38rx1Sr_(M)_9Tc=-h}Yr*n2uA=E}I+loFj7auyHJrfHI|Po@I%y`4tj7 zZ|2XgMqBeQS(s^b?xD;O6`XX77pU2u-JQEex9#}uQe_K^?kYOxRi<VJVwG%9W16&C zB}3F3+z%GVHY()dth0|pcjvht>SWGaq^ijA)f<0KH8%k6{9y7l%|MvpgU?6jsh(M$ z5N*sz^783ghS!jcq!BDms81L*G}VLWyHB!u>=8qC&htH>PmP{A<v#~L#&MqpRv4yG zw4r_l@+VBe#^s0kwg9GF@{ms(MG=X;Z*q>HB})c5>>6kFjvP9zMaPHfq~YhEr7DrH zD;~lup<3-juf%_Prr9Z-V4nORxcT&~FF{{2Nk&bqG}pd>$n(1*n4sj(w0;RH6sT{j zbhUJqyjT6iN>h5jrHP`lGXxi;LI(=%bR`2^fsT95-&yGjH)}sb@TGCA(mUti&QX<4 z{U$^U=I18hwKL%pN^cWLwM6MtTI+-Up~5fcjt@Bxe*M77{d?${Py^67eTt4eFFZ)l zh8I~nmB}UQ_u%EtP`CsPA88ZuaO!(Y>9V^z>txmUh$SjH&7r>5XT86X<2m!DSg2-= z-<rS@<i5Y4N=-ro_(K1~{gF<l7M3R7QZPDFa>~W*e9lSUNASn#NOM-@)>-Im^e@d- V<q-+yJ<<RG002ovPDHLkV1mLWjBEe^ literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/generalParallelTest.js b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/generalParallelTest.js new file mode 100644 index 00000000000..1a4bf343df0 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/generalParallelTest.js @@ -0,0 +1,231 @@ +(function(root) { +'use strict'; +// +var index = 0; +var suite = root.generalParallelTest = { + // prepare individual test + setup: function(data, options) { + suite._setupDom(data, options); + suite._setupEvents(data, options); + }, + // clone fixture and prepare data containers + _setupDom: function(data, options) { + // clone fixture into off-viewport test-canvas + data.fixture = document.getElementById('fixture').cloneNode(true); + data.fixture.id = 'test-' + (index++); + (document.getElementById('offscreen') || document.body).appendChild(data.fixture); + + // data container for #fixture > .container > .transition + data.transition = { + node: data.fixture.querySelector('.transition'), + values: [], + events: [], + computedStyle: function(property) { + return computedStyle(data.transition.node, property); + } + }; + + // data container for #fixture > .container + data.container = { + node: data.transition.node.parentNode, + values: [], + events: [], + computedStyle: function(property) { + return computedStyle(data.container.node, property); + } + }; + + // data container for #fixture > .container > .transition[:before | :after] + if (data.pseudo) { + data.pseudo = { + name: data.pseudo, + values: [], + computedStyle: function(property) { + return computedStyle(data.transition.node, property, ':' + data.pseudo.name); + } + }; + } + }, + // bind TransitionEnd event listeners + _setupEvents: function(data, options) { + ['transition', 'container'].forEach(function(elem) { + var handler = function(event) { + event.stopPropagation(); + var name = event.propertyName; + var time = Math.round(event.elapsedTime * 1000) / 1000; + var pseudo = event.pseudoElement ? (':' + event.pseudoElement) : ''; + data[elem].events.push(name + pseudo + ":" + time + "s"); + }; + data[elem].node.addEventListener('transitionend', handler, false); + data[elem]._events = {'transitionend': handler}; + }); + }, + // cleanup after individual test + teardown: function(data, options) { + // data.fixture.remove(); + if (data.fixture.parentNode) { + data.fixture.parentNode.removeChild(data.fixture); + } + }, + // invoked prior to running a slice of tests + sliceStart: function(options, tests) { + // inject styles into document + setStyle(options.styles); + // kick off value collection loop + generalParallelTest.startValueCollection(options); + }, + // invoked after running a slice of tests + sliceDone: function(options, tests) { + // stop value collection loop + generalParallelTest.stopValueCollection(options); + // reset styles cache + options.styles = {}; + }, + // called once all tests are done + done: function(options) { + // reset document styles + setStyle(); + reflow(); + }, + // add styles of individual test to slice cache + addStyles: function(data, options, styles) { + if (!options.styles) { + options.styles = {}; + } + + Object.keys(styles).forEach(function(key) { + var selector = '#' + data.fixture.id + // fixture must become #fixture.fixture rather than a child selector + + (key.substring(0, 8) === '.fixture' ? '' : ' ') + + key; + + options.styles[selector] = styles[key]; + }); + }, + // set style and compute values for container and transition + getStyle: function(data) { + reflow(); + // grab current styles: "initial state" + suite._getStyleFor(data, 'from'); + // apply target state + suite._addClass(data, 'to', true); + // grab current styles: "target state" + suite._getStyleFor(data, 'to'); + // remove target state + suite._removeClass(data, 'to', true); + + // clean up the mess created for value collection + data.container._values = []; + data.transition._values = []; + if (data.pseudo) { + data.pseudo._values = []; + } + }, + // grab current styles and store in respective element's data container + _getStyleFor: function(data, key) { + data.container[key] = data.container.computedStyle(data.property); + data.transition[key] = data.transition.computedStyle(data.property); + if (data.pseudo) { + data.pseudo[key] = data.pseudo.computedStyle(data.property); + } + }, + // add class to test's elements and possibly reflow + _addClass: function(data, className, forceReflow) { + data.container.node.classList.add(className); + data.transition.node.classList.add(className); + if (forceReflow) { + reflow(); + } + }, + // remove class from test's elements and possibly reflow + _removeClass: function(data, className, forceReflow) { + data.container.node.classList.remove(className); + data.transition.node.classList.remove(className); + if (forceReflow) { + reflow(); + } + }, + // add transition and to classes to container and transition + startTransition: function(data) { + // add transition-defining class + suite._addClass(data, 'how', true); + // add target state (without reflowing) + suite._addClass(data, 'to', false); + }, + // requestAnimationFrame runLoop to collect computed values + startValueCollection: function(options) { + var raf = window.requestAnimationFrame || function(callback){ + setTimeout(callback, 20); + }; + + // flag denoting if the runLoop should continue (true) or exit (false) + options._collectValues = true; + + function runLoop() { + if (!options._collectValues) { + // test's are done, stop annoying the CPU + return; + } + + // collect current style for test's elements + options.tests.forEach(function(data) { + if (!data.property) { + return; + } + + ['transition', 'container', 'pseudo'].forEach(function(elem) { + var pseudo = null; + if (!data[elem] || (elem === 'pseudo' && !data.pseudo)) { + return; + } + + var current = data[elem].computedStyle(data.property); + var values = data[elem].values; + var length = values.length; + if (!length || values[length - 1] !== current) { + values.push(current); + } + }); + }); + + // rinse and repeat + raf(runLoop); + } + + runLoop(); + }, + // stop requestAnimationFrame runLoop collecting computed values + stopValueCollection: function(options) { + options._collectValues = false; + }, + + // generate test.step function asserting collected events match expected + assertExpectedEventsFunc: function(data, elem, expected) { + return function() { + var _result = data[elem].events.sort().join(" "); + var _expected = typeof expected === 'string' ? expected : expected.sort().join(" "); + assert_equals(_result, _expected, "Expected TransitionEnd events triggered on ." + elem); + }; + }, + // generate test.step function asserting collected values are neither initial nor target + assertIntermediateValuesFunc: function(data, elem) { + return function() { + // the first value (index: 0) is always going to be the initial value + // the last value is always going to be the target value + var values = data[elem].values; + if (data.flags.discrete) { + // a discrete value will just switch from one state to another without having passed intermediate states. + assert_equals(values[0], data[elem].from, "must be initial value while transitioning on ." + elem); + assert_equals(values[1], data[elem].to, "must be target value after transitioning on ." + elem); + assert_equals(values.length, 2, "discrete property only has 2 values ." + elem); + } else { + assert_not_equals(values[1], data[elem].from, "may not be initial value while transitioning on ." + elem); + assert_not_equals(values[1], data[elem].to, "may not be target value while transitioning on ." + elem); + } + + // TODO: first value must be initial, last value must be target + }; + } +}; + +})(window); diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/helper.js b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/helper.js new file mode 100644 index 00000000000..242cd3ca635 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/helper.js @@ -0,0 +1,96 @@ +// +// Simple Helper Functions For Testing CSS +// + +(function(root) { +'use strict'; + +// serialize styles object and dump to dom +// appends <style id="dynamic-style"> to <head> +// setStyle("#some-selector", {"some-style" : "value"}) +// setStyle({"#some-selector": {"some-style" : "value"}}) +root.setStyle = function(selector, styles) { + var target = document.getElementById('dynamic-style'); + if (!target) { + target = document.createElement('style'); + target.id = 'dynamic-style'; + target.type = "text/css"; + document.getElementsByTagName('head')[0].appendChild(target); + } + + var data = []; + // single selector/styles + if (typeof selector === 'string' && styles !== undefined) { + data = [selector, '{', serializeStyles(styles), '}']; + target.textContent = data.join("\n"); + return; + } + // map of selector/styles + for (var key in selector) { + if (Object.prototype.hasOwnProperty.call(selector, key)) { + var _data = [key, '{', serializeStyles(selector[key]), '}']; + data.push(_data.join('\n')); + } + } + + target.textContent = data.join("\n"); +}; + +function serializeStyles(styles) { + var data = []; + for (var property in styles) { + if (Object.prototype.hasOwnProperty.call(styles, property)) { + var prefixedProperty = addVendorPrefix(property); + data.push(prefixedProperty + ":" + styles[property] + ";"); + } + } + + return data.join('\n'); +} + + +// shorthand for computed style +root.computedStyle = function(element, property, pseudo) { + var prefixedProperty = addVendorPrefix(property); + return window + .getComputedStyle(element, pseudo || null) + .getPropertyValue(prefixedProperty); +}; + +// flush rendering buffer +root.reflow = function() { + document.body.offsetWidth; +}; + +// merge objects +root.extend = function(target /*, ..rest */) { + Array.prototype.slice.call(arguments, 1).forEach(function(obj) { + Object.keys(obj).forEach(function(key) { + target[key] = obj[key]; + }); + }); + + return target; +}; + +// dom fixture helper ("resetting dom test elements") +var _domFixture; +var _domFixtureSelector; +root.domFixture = function(selector) { + var fixture = document.querySelector(selector || _domFixtureSelector); + if (!fixture) { + throw new Error('fixture ' + (selector || _domFixtureSelector) + ' not found!'); + } + if (!_domFixture && selector) { + // save a copy + _domFixture = fixture.cloneNode(true); + _domFixtureSelector = selector; + } else if (_domFixture) { + // restore the copy + var tmp = _domFixture.cloneNode(true); + fixture.parentNode.replaceChild(tmp, fixture); + } else { + throw new Error('domFixture must be initialized first!'); + } +}; +})(window); diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/import-green.css b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/import-green.css new file mode 100644 index 00000000000..537104e6633 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/import-green.css @@ -0,0 +1 @@ +.import { color: green; } diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/import-red.css b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/import-red.css new file mode 100644 index 00000000000..9945ef47114 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/import-red.css @@ -0,0 +1 @@ +.import { color: red; } diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/min-width-tables-001-iframe.html b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/min-width-tables-001-iframe.html new file mode 100644 index 00000000000..edc548a6aab --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/min-width-tables-001-iframe.html @@ -0,0 +1,59 @@ +<!DOCTYPE html> +<html><head> + <meta charset="utf-8"> + <title>iframe containing the meat of the test</title> + <style> +body { + margin: 0; + overflow: hidden; +} +/* green div that should cover the red divs */ +#green { + position: absolute; + left: 0; + top: 0; + background-color: green; + width: 100%; + height: 600px; +} +.spacer { + height: 98px; + width: 20px; +} +.item { + background-color: red; + display: block;/* property under test */ + /* border to aid understanding of boundaries between items */ + border-style: solid; + border-width: 1px; + border-color: red;/* Note: if you're trying to debug this, use a different color here */ +} +/* 100px = 10*(1 + 8 + 1) */ +@media (min-width: 100px) { + #green { + width: 100px; + height: 100px;/* = 1 + 98 + 1 */ + } + .item { + display: table-cell;/* property and value under test */ + } +} + </style> +</head> +<body> + <div> + <div class="item"><div class="spacer"></div></div> + <div class="item"><div class="spacer"></div></div> + <div class="item"><div class="spacer"></div></div> + <div class="item"><div class="spacer"></div></div> + <div class="item"><div class="spacer"></div></div> + <div class="item"><div class="spacer"></div></div> + <div class="item"><div class="spacer"></div></div> + <div class="item"><div class="spacer"></div></div> + <div class="item"><div class="spacer"></div></div> + <div class="item"><div class="spacer"></div></div> + </div> + <div id="green"></div> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/one.gif b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/one.gif new file mode 100644 index 0000000000000000000000000000000000000000..74cf7839c9fc0f1572d600ef559972b8e1ae57fc GIT binary patch literal 184 zcmZ?wbh9u|G-5Dfc+3C-|NsBLfB*je{rltN<K^Y$>+9?1&!2B^Zx5D4Cv-ppAiWGM zxdJCVSMRlWeRlW%1dYCw%y}8B*5$n3SD<sgB=>&By7x8j|C=6ca1apCb6WIKbpj6; z^Ah1xGH#0-ni*&B*~iu3C>+hvz?e|@qg2M`BvZ?hziHe&N0WD0?0??a(Ad=6(%RPE R(b?7A)7#fSp+S(r8UVwOMW_G( literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/parsing-utils.js b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/parsing-utils.js new file mode 100644 index 00000000000..beea4958ce8 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/parsing-utils.js @@ -0,0 +1,866 @@ +var ParsingUtils = (function() { +function testInlineStyle(value, expected) { + var div = document.createElement('div'); + div.style.setProperty('shape-outside', value); + var actual = div.style.getPropertyValue('shape-outside'); + assert_equals(actual, expected); +} + +function testComputedStyle(value, expected) { + var div = document.createElement('div'); + div.style.setProperty('shape-outside', value); + document.body.appendChild(div); + var style = getComputedStyle(div); + var actual = style.getPropertyValue('shape-outside'); + actual = roundResultStr(actual); + document.body.removeChild(div); + + // Some of the tests in this suite have either/or expected results + // so this check allows for testing that at least one of them passes. + // Description of the 2 expecteds is below near calcTestValues. + if(Object.prototype.toString.call( expected ) === '[object Array]' && expected.length == 2) { + assert_true(expected[0] == actual || expected[1] == actual) + } else { + assert_equals(actual, typeof expected !== 'undefined' ? expected : value); + } +} + +function testShapeMarginInlineStyle(value, expected) { + var div = document.createElement('div'); + div.style.setProperty('shape-outside', "border-box inset(10px)"); + div.style.setProperty('shape-margin', value); + var actual = div.style.getPropertyValue('shape-margin'); + assert_equals(actual, expected); +} + +function testShapeMarginComputedStyle(value, expected) { + + var outerDiv = document.createElement('div'); + outerDiv.style.setProperty('width', '100px'); + + var innerDiv = document.createElement('div'); + innerDiv.style.setProperty('shape-outside', "border-box inset(10px)"); + innerDiv.style.setProperty('shape-margin', value); + + outerDiv.appendChild(innerDiv); + document.body.appendChild(outerDiv); + + var style = getComputedStyle(innerDiv); + var actual = style.getPropertyValue('shape-margin'); + + assert_not_equals(actual, null); + if(actual.indexOf('calc') == -1 ) + actual = roundResultStr(actual); + document.body.removeChild(outerDiv); + + // See comment above about multiple expected results + if(Object.prototype.toString.call( expected ) === '[object Array]' && expected.length == 2) { + assert_true(expected[0] == actual || expected[1] == actual) + } else { + assert_equals(actual, !expected ? '0px' : expected); + } +} + +function testShapeThresholdInlineStyle(value, expected) { + var div = document.createElement('div'); + div.style.setProperty('shape-outside', 'url(someimage.png)'); + div.style.setProperty('shape-image-threshold', value); + var actual = div.style.getPropertyValue('shape-image-threshold'); + assert_equals(actual, expected); +} + +function testShapeThresholdComputedStyle(value, expected) { + + var div = document.createElement('div'); + div.style.setProperty('shape-outside', 'url(someimage.png)'); + div.style.setProperty('shape-image-threshold', value); + document.body.appendChild(div); + + var style = getComputedStyle(div); + var actual = style.getPropertyValue('shape-image-threshold'); + + assert_not_equals(actual, null); + if(actual.indexOf('calc') == -1 ) + actual = roundResultStr(actual); + document.body.removeChild(div); + + // See comment above about multiple expected results + if(Object.prototype.toString.call( expected ) === '[object Array]' && expected.length == 2) { + assert_true(expected[0] == actual || expected[1] == actual) + } else { + assert_equals(actual, !expected ? '0' : expected); + } +} + +// Builds an array of test cases to send to testharness.js where one test case is: [name, actual, expected] +// These test cases will verify results from testInlineStyle() or testComputedStyle() +function buildTestCases(testCases, testType) { + var results = []; + + // If test_type isn't specified, test inline style + var type = typeof testType == 'undefined' ? 'invalid': testType; + + testCases.forEach(function(test) { + oneTestCase = []; + + // name - annotated by type (inline vs. computed) + if ( test.hasOwnProperty('name') ) { + oneTestCase.push(test['name'] +' - '+ type); + } else { + // If test_name isn't specified, use the actual + oneTestCase.push(test['actual'] +' - '+ type); + } + + // actual + oneTestCase.push(test['actual']) + + // expected + if( type.indexOf('invalid') != -1 ){ + oneTestCase.push(null) + } else if( type == 'inline' ) { + oneTestCase.push(test['expected_inline']); + } else if( type == 'computed' ){ + oneTestCase.push( convertToPx(test['expected_computed']) ); + } + results.push(oneTestCase); + }); + return results; +} + + +function buildPositionTests(shape, valid, type, units) { + var results = new Array(); + var convert = type.indexOf('computed') != -1 ? true : false; + + if(Object.prototype.toString.call( units ) === '[object Array]') { + units.forEach(function(unit) { + positionTests = buildPositionTests(shape, valid, type, unit); + results = results.concat(positionTests); + }); + } else { + if (valid) { + validPositions.forEach(function(test) { + var testCase = [], testName, actual, expected; + // skip if this isn't explicitly testing length units + if( !(type.indexOf('lengthUnit') != -1 && test[0].indexOf("u1") == -1)) { + // actual + actual = shape + '(at ' + setUnit(test[0], false, units) +')'; + + // expected + // if(convert && shape == 'circle') + // expected = shape + '(at ' + setUnit(test[1], convert, units) +')'; + // else if(convert && shape == 'ellipse') + // expected = shape + '(at ' + setUnit(test[1], convert, units) +')'; + // else + expected = shape + '(at ' + setUnit(test[1], convert, units) +')'; + + // name + if (type == 'lengthUnit + inline') + testName = 'test unit (inline): ' + units +' - '+ actual; + else if (type == 'lengthUnit + computed') + testName = 'test unit (computed): ' + units +' - '+ actual; + else + testName = (actual + ' serializes as ' + expected +' - '+ type); + + testCase.push(testName) + testCase.push(actual); + testCase.push(expected); + results.push(testCase); + } + }); + } else { + invalidPositions.forEach(function(test) { + var testValue = shape + '(at ' + setUnit(test, false, units) +')'; + testCase = new Array(); + testCase.push(testValue + ' is invalid'); + testCase.push(testValue); + testCase.push(null); + results.push(testCase); + }); + } + } + return unique(results); +} + +function buildRadiiTests(shape, type, units) { + var results = new Array(); + var testUnits = typeof units == 'undefined' ? 'px': units; + var convert = type.indexOf('computed') != -1 ? true : false; + + if(Object.prototype.toString.call( testUnits ) === '[object Array]') { + testUnits.forEach(function(unit) { + radiiTests = buildRadiiTests(shape, type, unit); + results = results.concat(radiiTests); + }); + } else { + var validRadii = shape == 'circle' ? validCircleRadii : validEllipseRadii; + validRadii.forEach(function(test) { + var testCase = [], name, actual, expected; + + // skip if this isn't explicitly testing length units + if( !(type.indexOf('lengthUnit') != -1 && test[0].indexOf("u1") == -1) ) { + actual = shape + '(' + setUnit(test[0], false, testUnits) +')'; + // name + if (type.indexOf('lengthUnit') != -1) { + name = 'test unit: ' + units +' - '+ actual; + if(type.indexOf('computed') != -1) + name = name + ' - computed'; + else + name = name + ' - inline'; + } + else + name = actual +' - '+ type; + + testCase.push(name); + + // actual + testCase.push(actual); + + // expected + if(type.indexOf('computed') != -1 && test.length == 3) { + expected = shape + '(' + setUnit(test[2], convert, testUnits) +')'; + } else { + expected = shape + '(' + setUnit(test[1], convert, testUnits) +')'; + } + testCase.push(expected); + results.push(testCase); + } + }); + } + return unique(results); +} + +function buildInsetTests(unit1, unit2, type) { + var results = new Array(); + var convert = type == 'computed' ? true : false; + + if(Object.prototype.toString.call( unit1 ) === '[object Array]') { + unit1.forEach(function(unit) { + insetTests = buildInsetTests(unit, unit2, type); + results = results.concat(insetTests); + }); + } else { + validInsets.forEach(function(test) { + var testCase = [], name, actual, expected; + + name = setUnit(test[0], false, unit1, unit2) +' - '+ type; + actual = 'inset(' + setUnit(test[1], convert, unit1, unit2) +')'; + expected = actual; + + testCase.push(name); + testCase.push(actual); + testCase.push(expected); + + results.push(testCase); + }); + } + return unique(results); +} + +function buildPolygonTests(unitSet, type) { + var results = new Array(); + var convert = type == 'computed' ? true : false; + + unitSet.forEach(function(set) { + validPolygons.forEach(function(test) { + var testCase = []; + // name + testCase.push(setUnit(test[0], false, set[0], set[1], set[2]) +' - '+ type); + // actual + testCase.push('polygon(' + setUnit(test[1], false, set[0], set[1], set[2]) +')'); + // expected + testCase.push('polygon(' + setUnit(test[1], convert, set[0], set[1], set[2]) +')'); + results.push(testCase); + }); + }); + return unique(results); +} + +function buildCalcTests(testCases, type) { + var results = new Array(); + testCases.forEach(function(test){ + var testCase = []; + if(type == 'computed') { + testCase.push(test[0] + ' - computed style'); + testCase.push(test[0]); + testCase.push(test[2]); + } + else { + testCase.push(test[0] + ' - inline style'); + testCase.push(test[0]); + testCase.push(test[1]); + } + testCase.push(type); + results.push(testCase) + }); + return unique(results); +} + +function unique(tests) { + var list = tests.concat(); + for(var i = 0; i< list.length; ++i) { + for(var j = i+1; j < list.length; ++j) { + if(list[i][0] === list[j][0]) + list.splice(j--, 1); + } + } + return list; +} + +function setUnit(str, convert, unit1, unit2, unit3) { + var retStr = str; + if(typeof unit1 !== 'undefined') { + retStr = retStr.replace(new RegExp('u1', 'g'), unit1); + } + if(typeof unit2 !== 'undefined') { + retStr = retStr.replace(new RegExp("u2", 'g'), unit2); + } + if(typeof unit3 !== 'undefined') { + retStr = retStr.replace(new RegExp("u3", 'g'), unit3); + } + retStr = convert ? convertToPx(retStr) : retStr; + return retStr; +} + +function convertToPx(origValue) { + + var valuesToConvert = origValue.match(/[0-9]+(\.[0-9]+)?([a-z]{2,4}|%)/g); + if(!valuesToConvert) + return origValue; + + var retStr = origValue; + for(var i = 0; i < valuesToConvert.length; i++) { + var unit = valuesToConvert[i].match(/[a-z]{2,4}|%/).toString(); + var numberStr = valuesToConvert[i].match(/[0-9]+(\.[0-9]+)?/)[0]; + + var number = parseFloat(numberStr); + var convertedUnit = 'px'; + if( typeof number !== 'NaN' ) + { + if (unit == 'in') { + number = (96 * number); + } else if (unit == 'cm') { + number = (37.795275591 * number); + } else if (unit == 'mm') { + number = (3.779527559 * number); + } else if (unit == 'pt') { + number = (1.333333333333 * number); + } else if (unit == 'pc') { + number = (16 * number); + } else if (unit == 'em') { + number = (16 * number); + } else if (unit == 'ex') { + number = (7.1796875 * number); + } else if (unit == 'ch') { + number = (8 * number); + } else if (unit == 'rem') { + number = (16 * number); + } else if (unit == 'vw') { + number = ((.01 * window.innerWidth) * number); + } else if (unit == 'vh') { + number = ((.01 * window.innerHeight) * number); + } else if (unit == 'vmin') { + number = Math.min( (.01 * window.innerWidth), (.01 * window.innerHeight) ) * number; + } else if (unit == 'vmax') { + number = Math.max( (.01 * window.innerWidth), (.01 * window.innerHeight) ) * number; + } + else { + convertedUnit = unit; + } + number = Math.round(number * 1000) / 1000; + var find = valuesToConvert[i]; + var replace = number.toString() + convertedUnit; + retStr = retStr.replace(valuesToConvert[i], number.toString() + convertedUnit); + } + } + return retStr.replace(',,', ','); +} + +function roundResultStr(str) { + if(Object.prototype.toString.call( str ) !== '[object String]') + return str; + + var numbersToRound = str.match(/[0-9]+\.[0-9]+/g); + if(!numbersToRound) + return str; + + var retStr = str; + for(var i = 0; i < numbersToRound.length; i++) { + num = parseFloat(numbersToRound[i]); + if( !isNaN(num) ) { + roundedNum = Math.round(num*1000)/1000; + retStr = retStr.replace(numbersToRound[i].toString(), roundedNum.toString()); + } + } + + return retStr; +} + +function generateInsetRoundCases(units, testType) { + var convert = testType.indexOf('computed') != -1 ? true : false; + var testUnit = units; + var sizes = [ + '10' + units, + '20' + units, + '30' + units, + '40' + units + ]; + + function insetRound(value) { + return 'inset(10' +testUnit+ ' round ' + value + ')'; + } + + function serializedInsetRound(lhsValues, rhsValues, convert) { + var retStr = ''; + if(!rhsValues) + retStr = 'inset(10' +testUnit+ ' round ' + lhsValues +')'; + else + retStr = 'inset(10' +testUnit+ ' round ' + lhsValues +' / '+ rhsValues +')'; + + if(convert) + return convertToPx(retStr); + + return retStr; + } + + var results = [], left, lhs, right, rhs; + for (left = 1; left <= 4; left++) { + lhs = sizes.slice(0, left).join(' '); + results.push([insetRound(lhs) +' - '+ testType, insetRound(lhs), serializedInsetRound(lhs, null, convert)]); + for (right = 1; right <= 4; right++) { + rhs = sizes.slice(0, right).join(' '); + if(lhs == rhs) + results.push([insetRound(lhs + ' / ' + rhs) +' - '+ testType, insetRound(lhs + ' / ' + rhs), serializedInsetRound(lhs, null, convert)]); + else + results.push([insetRound(lhs + ' / ' + rhs) +' - '+ testType, insetRound(lhs + ' / ' + rhs), serializedInsetRound(lhs, rhs, convert)]); + } + } + return results; +} + +var validUnits = [ + "cm","mm","in","pt","pc", // Absolute length units (omitting px b/c we default to that in all tests) + "em","ex","ch","rem", // Font relative length units + "vw","vh","vmin","vmax" // Viewport percentage units + ] + +/// [actual, expected] +var validPositions = [ + +/// [ percent ], [ length ], [ percent | percent ], [ percent | length ], [ length | percent ], [ length | length ] + ["50%", "50% 50%"], + ["50u1", "50u1 50%"], + ["50% 50%", "50% 50%"], + ["50% 50u1", "50% 50u1"], + ["50u1 50%", "50u1 50%"], + ["50u1 50u1", "50u1 50u1"], + +///// [ keyword ], [ keyword keyword ] x 5 keywords + ["left", "0% 50%"], + ["top", "50% 0%"], + ["right", "100% 50%"], + ["bottom", "50% 100%"], + ["center", "50% 50%"], + + ["left top", "0% 0%"], + ["left bottom", "0% 100%"], + ["left center", "0% 50%"], + + ["top left", "0% 0%"], + ["top right", "100% 0%"], + ["top center", "50% 0%"], + + ["right top", "100% 0%"], + ["right bottom", "100% 100%"], + ["right center", "100% 50%"], + + ["bottom left", "0% 100%"], + ["bottom right", "100% 100%"], + ["bottom center", "50% 100%"], + + ["center top", "50% 0%"], + ["center left", "0% 50%"], + ["center right", "100% 50%"], + ["center bottom", "50% 100%"], + ["center center", "50% 50%"], + +////// [ keyword | percent ], [ keyword | length ], [ percent | keyword ], [ length | keyword ] x 5 keywords + ["left 50%", "0% 50%"], + ["left 50u1", "0% 50u1"], + + ["50% top", "50% 0%"], + ["50u1 top", "50u1 0%"], + + ["right 80%", "100% 80%"], + ["right 80u1", "100% 80u1"], + + ["70% bottom", "70% 100%"], + ["70u1 bottom", "70u1 100%"], + + ["center 60%", "50% 60%"], + ["center 60u1", "50% 60u1"], + ["60% center", "60% 50%"], + ["60u1 center", "60u1 50%"], + +////// [ keyword | keyword percent ], [ keyword | keyword length ] x 5 keywords + ["center top 50%", "50% 50%"], + ["center top 50u1", "50% 50u1"], + ["center left 50%", "50% 50%"], + ["center left 50u1", "50u1 50%"], + ["center right 70%", "30% 50%"], + ["center right 70u1", "right 70u1 top 50%"], + ["center bottom 70%", "50% 30%"], + ["center bottom 70u1", "left 50% bottom 70u1"], + + ["left top 50%", "0% 50%"], + ["left top 50u1", "0% 50u1"], + ["left bottom 70%", "0% 30%"], + ["left bottom 70u1", "left 0% bottom 70u1"], + + ["top left 50%", "50% 0%"], + ["top left 50u1", "50u1 0%"], + ["top right 70%", "30% 0%"], + ["top right 70u1", "right 70u1 top 0%"], + + ["bottom left 50%", "50% 100%"], + ["bottom left 50u1", "50u1 100%"], + ["bottom right 70%", "30% 100%"], + ["bottom right 70u1", "right 70u1 top 100%"], + + ["right bottom 70%", "100% 30%"], + ["right bottom 70u1", "left 100% bottom 70u1"], + ["right top 50%", "100% 50%"], + ["right top 50u1", "100% 50u1"], + +////// [ keyword percent | keyword], [ keyword length | keyword ] x 5 keywords + ["left 50% center", "50% 50%"], + ["left 50u1 center", "50u1 50%"], + ["left 50% top", "50% 0%"], + ["left 50u1 top", "50u1 0%"], + ["left 50% bottom", "50% 100%"], + ["left 50u1 bottom", "50u1 100%"], + + ["top 50% center", "50% 50%"], + ["top 50u1 center", "50% 50u1"], + ["top 50% left", "0% 50%"], + ["top 50u1 left", "0% 50u1"], + ["top 50% right", "100% 50%"], + ["top 50u1 right", "100% 50u1"], + + ["bottom 70% center", "50% 30%"], + ["bottom 70u1 center", "left 50% bottom 70u1"], + ["bottom 70% left", "0% 30%"], + ["bottom 70u1 left", "left 0% bottom 70u1"], + ["bottom 70% right", "100% 30%"], + ["bottom 70u1 right", "left 100% bottom 70u1"], + + ["right 80% center", "20% 50%"], + ["right 80u1 center", "right 80u1 top 50%"], + ["right 80% bottom", "20% 100%"], + ["right 80u1 bottom", "right 80u1 top 100%"], + ["right 80% top", "20% 0%"], + ["right 80u1 top", "right 80u1 top 0%"], + +////// [ keyword percent | keyword percent], [ keyword percent | keyword length], +////// [ keyword length | keyword length], [ keyword length | keyword percent] x 5 keywords + ["left 50% top 50%", "50% 50%"], + ["left 50% top 50u1", "50% 50u1"], + ["left 50% bottom 70%", "50% 30%"], + ["left 50% bottom 70u1", "left 50% bottom 70u1"], + ["left 50u1 top 50%", "50u1 50%"], + ["left 50u1 top 50u1", "50u1 50u1"], + ["left 50u1 bottom 70%", "50u1 30%"], + ["left 50u1 bottom 70u1", "left 50u1 bottom 70u1"], + + ["top 50% left 50%", "50% 50%"], + ["top 50% left 50u1", "50u1 50%"], + ["top 50% right 80%", "20% 50%"], + ["top 50% right 80u1", "right 80u1 top 50%"], + ["top 50u1 left 50%", "50% 50u1"], + ["top 50u1 left 50u1", "50u1 50u1"], + ["top 50u1 right 80%", "20% 50u1"], + ["top 50u1 right 80u1", "right 80u1 top 50u1"], + + ["bottom 70% left 50%", "50% 30%"], + ["bottom 70% left 50u1", "50u1 30%"], + ["bottom 70% right 80%", "20% 30%"], + ["bottom 70% right 80u1", "right 80u1 top 30%"], + ["bottom 70u1 left 50%", "left 50% bottom 70u1"], + ["bottom 70u1 left 50u1", "left 50u1 bottom 70u1"], + ["bottom 70u1 right 80%", "left 20% bottom 70u1"], + ["bottom 70u1 right 80u1", "right 80u1 bottom 70u1"], + + ["right 80% top 50%", "20% 50%"], + ["right 80% top 50u1", "20% 50u1"], + ["right 80% bottom 70%", "20% 30%"], + ["right 80% bottom 70u1", "left 20% bottom 70u1"], + ["right 80u1 top 50%", "right 80u1 top 50%"], + ["right 80u1 top 50u1", "right 80u1 top 50u1"], + ["right 80u1 bottom 70%", "right 80u1 top 30%"], + ["right 80u1 bottom 70u1", "right 80u1 bottom 70u1"], +]; + +var invalidPositions = [ +////// [ keyword | percent ], [ keyword | length ], [ percent | keyword ], [ length | keyword ] x 5 keywords + "50% left", + "50px left", + "top 50%", + "80% right", + "80px right", + "bottom 70%", + "bottom 70px", + +////// [ keyword | keyword percent ], [ keyword | keyword length ] x 5 keywords + "center center 60%", + "center center 60px", + + "left center 60%", + "left center 60px", + "left right 80%", + "left right 80px", + "left left 50%", + "left left 50px", + + "top center 60%", + "top center 60px", + "top bottom 80%", + "top bottom 80px", + "top top 50%", + "top top 50px", + + "bottom center 60%", + "bottom center 60px", + "bottom top 50%", + "bottom top 50px", + "bottom bottom 50%", + "bottom bottom 50px", + + "right center 60%", + "right center 60px", + "right left 50%", + "right left 50px", + "right right 70%", + "right right 70px", + +////// [ keyword percent | keyword], [ keyword length | keyword ] x 5 keywords + "center 60% top", + "center 60px top", + "center 60% bottom", + "center 60px bottom", + "center 60% left", + "center 60px left", + "center 60% right", + "center 60px right", + "center 60% center", + "center 60px center", + + "left 50% right", + "left 50px right", + "left 50% left", + "left 50px left", + + "top 50% bottom", + "top 50px bottom", + "top 50% top", + "top 50px top", + + "bottom 70% top", + "bottom 70px top", + "bottom 70% bottom", + "bottom 70px bottom", + + "right 80% left", + "right 80px left", + +////// [ keyword percent | keyword percent], [ keyword percent | keyword length], +////// [ keyword length | keyword length], [ keyword length | keyword percent] x 5 keywords + "center 60% top 50%", + "center 60% top 50px", + "center 60% bottom 70%", + "center 60% bottom 70px", + "center 60% left 50%", + "center 60% left 50px", + "center 60% right 70%", + "center 60% right 70px", + "center 60% center 65%", + "center 60% center 65px", + "center 60px top 50%", + "center 60px top 50px", + "center 60px bottom 70%", + "center 60px bottom 70px", + "center 60px left 50%", + "center 60px left 50px", + "center 60px right 70%", + "center 60px right 70px", + "center 60px center 65%", + "center 60px center 65px", + + "left 50% center 60%", + "left 50% center 60px", + "left 50% right 80%", + "left 50% right 80px", + "left 50% left 50%", + "left 50% left 50px", + "left 50px center 60%", + "left 50px center 60px", + "left 50px right 80%", + "left 50px right 80px", + "left 50px left 50%", + "left 50px left 50px", + + "top 50% center 60%", + "top 50% center 60px", + "top 50% bottom 50%", + "top 50% bottom 50px", + "top 50% top 50%", + "top 50% top 50px", + "top 50px center 60%", + "top 50px center 60px", + "top 50px bottom 70%", + "top 50px bottom 70px", + "top 50px top 50%", + "top 50px top 50px", + + "bottom 70% center 60%", + "bottom 70% center 60px", + "bottom 70% top 50%", + "bottom 70% top 50px", + "bottom 70% bottom 50%", + "bottom 70% bottom 50px", + "bottom 70px center 60%", + "bottom 70px center 60px", + "bottom 70px top 50%", + "bottom 70px top 50px", + "bottom 70px bottom 50%", + "bottom 70px bottom 50px", + + "right 80% center 60%", + "right 80% center 60px", + "right 80% left 50%", + "right 80% left 50px", + "right 80% right 85%", + "right 80% right 85px", + "right 80px center 60%", + "right 80px center 60px", + "right 80px left 50%", + "right 80px left 50px", + "right 80px right 85%", + "right 80px right 85px" +]; + +// valid radii values for circle + ellipse +// [value, expected_inline, [expected_computed?]] +var validCircleRadii = [ + ['', 'at 50% 50%', 'at 50% 50%'], + ['50u1', '50u1 at 50% 50%'], + ['50%', '50% at 50% 50%'], + ['closest-side', 'at 50% 50%'], + ['farthest-side', 'farthest-side at 50% 50%'] +] +var validEllipseRadii = [ + ['', 'at 50% 50%', 'at 50% 50%'], + ['50u1', '50u1 at 50% 50%', '50u1 at 50% 50%'], + ['50%', '50% at 50% 50%', '50% at 50% 50%'], + ['closest-side', 'at 50% 50%', 'at 50% 50%'], + ['farthest-side', 'farthest-side at 50% 50%', 'farthest-side at 50% 50%'], + ['50u1 100u1', '50u1 100u1 at 50% 50%'], + ['100u1 100px', '100u1 100px at 50% 50%'], + ['25% 50%', '25% 50% at 50% 50%'], + ['50u1 25%', '50u1 25% at 50% 50%'], + ['25% 50u1', '25% 50u1 at 50% 50%'], + ['25% closest-side', '25% at 50% 50%'], + ['25u1 closest-side', '25u1 at 50% 50%'], + ['closest-side 75%', 'closest-side 75% at 50% 50%'], + ['closest-side 75u1', 'closest-side 75u1 at 50% 50%'], + ['25% farthest-side', '25% farthest-side at 50% 50%'], + ['25u1 farthest-side', '25u1 farthest-side at 50% 50%'], + ['farthest-side 75%', 'farthest-side 75% at 50% 50%'], + ['farthest-side 75u1', 'farthest-side 75u1 at 50% 50%'], + ['closest-side closest-side', 'at 50% 50%'], + ['farthest-side farthest-side', 'farthest-side farthest-side at 50% 50%'], + ['closest-side farthest-side', 'closest-side farthest-side at 50% 50%'], + ['farthest-side closest-side', 'farthest-side at 50% 50%'] +] + +var validInsets = [ + ["One arg - u1", "10u1"], + ["One arg - u2", "10u2"], + ["Two args - u1 u1", "10u1 20u1"], + ["Two args - u1 u2", "10u1 20u2"], + ["Two args - u2 u1", "10u2 20u1"], + ["Two args - u2 u2", "10u2 20u2"], + ["Three args - u1 u1 u1", "10u1 20u1 30u1"], + ["Three args - u1 u1 u2", "10u1 20u1 30u2"], + ["Three args - u1 u2 u1", "10u1 20u2 30u1"], + ["Three args - u1 u2 u2 ", "10u1 20u2 30u2"], + ["Three args - u2 u1 u1", "10u2 20u1 30u1"], + ["Three args - u2 u1 u2 ", "10u2 20u1 30u2"], + ["Three args - u2 u2 u1 ", "10u2 20u2 30u1"], + ["Three args - u2 u2 u2 ","10u2 20u2 30u2"], + ["Four args - u1 u1 u1 u1", "10u1 20u1 30u1 40u1"], + ["Four args - u1 u1 u1 u2", "10u1 20u1 30u1 40u2"], + ["Four args - u1 u1 u2 u1", "10u1 20u1 30u2 40u1"], + ["Four args - u1 u1 u2 u2", "10u1 20u1 30u2 40u2"], + ["Four args - u1 u2 u1 u1", "10u1 20u2 30u1 40u1"], + ["Four args - u1 u2 u1 u2", "10u1 20u2 30u1 40u2"], + ["Four args - u1 u2 u2 u1", "10u1 20u2 30u2 40u1"], + ["Four args - u1 u2 u2 u2", "10u1 20u2 30u2 40u2"], + ["Four args - u2 u1 u1 u1", "10u2 20u1 30u1 40u1"], + ["Four args - u2 u1 u1 u2", "10u2 20u1 30u1 40u2"], + ["Four args - u2 u1 u2 u1", "10u2 20u1 30u2 40u1"], + ["Four args - u2 u1 u2 u2", "10u2 20u1 30u2 40u2"], + ["Four args - u2 u2 u1 u1", "10u2 20u2 30u1 40u1"], + ["Four args - u2 u2 u1 u2", "10u2 20u2 30u1 40u2"], + ["Four args - u2 u2 u2 u1", "10u2 20u2 30u2 40u1"], + ["Four args - u2 u2 u2 u2", "10u2 20u2 30u2 40u2"] +] + +var validPolygons = [ + ["One vertex - u1 u1", "10u1 20u1"], + ["One vertex - u1 u2", "10u1 20u2"], + ["Two vertices - u1 u1, u1 u1", "10u1 20u1, 30u1 40u1"], + ["Two vertices - u1 u1, u2 u2", "10u1 20u1, 30u2 40u2"], + ["Two vertices - u2 u2, u1 u1", "10u2 20u2, 30u1 40u1"], + ["Two vertices - u1 u2, u2 u1", "10u1 20u2, 30u2 40u1"], + ["Three vertices - u1 u1, u1 u1, u1 u1", "10u1 20u1, 30u1 40u1, 50u1 60u1"], + ["Three vertices - u2 u2, u2 u2, u2 u2", "10u2 20u2, 30u2 40u2, 50u2 60u2"], + ["Three vertices - u3 u3, u3 u3, u3 u3", "10u3 20u3, 30u3 40u3, 50u3 60u3"], + ["Three vertices - u1 u1, u2 u2, u3 u3", "10u1 20u1, 30u2 40u2, 50u3 60u3"], + ["Three vertices - u3 u3, u1, u1, u2 u2", "10u3 20u3, 30u1 40u1, 50u2 60u2"], +] + +// [test value, expected property value, expected computed style] +var calcTestValues = [ + ["calc(10in)", "calc(10in)", "960px"], + ["calc(10in + 20px)", "calc(980px)", "980px"], + ["calc(30%)", "calc(30%)", "30%"], + ["calc(100%/4)", "calc(25%)", "25%"], + ["calc(25%*3)", "calc(75%)", "75%"], + // These following two test cases represent an either/or situation in the spec + // computed value is always supposed to be, at most, a tuple of a length and a percentage. + // the computed value of a โ€˜calc()โ€™ expression can be represented as either a number or a tuple + // of a dimension and a percentage. + // http://www.w3.org/TR/css3-values/#calc-notation + ["calc(25%*3 - 10in)", "calc(75% - 10in)", ["calc(75% - 960px)", "calc(-960px + 75%)"]], + ["calc((12.5%*6 + 10in) / 4)", "calc((75% + 10in) / 4)", ["calc((75% + 960px) / 4)", "calc(240px + 18.75%)"]] +] + +return { + testInlineStyle: testInlineStyle, + testComputedStyle: testComputedStyle, + testShapeMarginInlineStyle: testShapeMarginInlineStyle, + testShapeMarginComputedStyle: testShapeMarginComputedStyle, + testShapeThresholdInlineStyle: testShapeThresholdInlineStyle, + testShapeThresholdComputedStyle: testShapeThresholdComputedStyle, + buildTestCases: buildTestCases, + buildRadiiTests: buildRadiiTests, + buildPositionTests: buildPositionTests, + buildInsetTests: buildInsetTests, + buildPolygonTests: buildPolygonTests, + generateInsetRoundCases: generateInsetRoundCases, + buildCalcTests: buildCalcTests, + validUnits: validUnits, + calcTestValues: calcTestValues, + roundResultStr: roundResultStr +} +})(); diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/pattern-gg-gr.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/pattern-gg-gr.png new file mode 100644 index 0000000000000000000000000000000000000000..091de70bb72541dda90cafaa4a2eb68d82fb5bdb GIT binary patch literal 203 zcmeAS@N?(olHy`uVBq!ia0vp^8X(NU1SFZ~=vx6P#^NA%Cx&(BWL^R}oCO|{#S9F5 zM?jcysy3fAP>{XE)7O>#4zs*CpV-thX~%&=k|nMYCC>S|xv6<249-QVi6yBi3gww4 z84B*6z5(HleBwYw7M?DSArXh)UO33fpdi3}P(!S4ZZ<c&U5&+WerCy)HkoP(1`<4M m%?I}%c%8QA^i?RYmoGe?DKLBT?xjF87(8A5T-G@yGywqU{5T8% literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/pattern-grg-rgr-grg.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/pattern-grg-rgr-grg.png new file mode 100644 index 0000000000000000000000000000000000000000..6fcfeb4883edea810f880fabb861e09df7871695 GIT binary patch literal 222 zcmV<403rX0P)<h;3K|Lk000e1NJLTq001fg001fo0ssI3J*IA&0001`Nkl<Zc-rli z!4iWo2t*%#Ie$(sX|)yGI5;(q%PA9Jmkl8?93ULP9AIK)7R>(GjOxRBMQwxx1mJBk z?aXifhV@+AVlyc!*ZYwgelQCuviAYh+_OT<gcQNg6t-;4S{PYlcfkL&YW~~R`(A2{ zSbtgn)%$nx`tP29_xaQNq4OWFf2l=xr1`(fKl$`TFZx42zT!BA22b>&*N-Q9(T_&| Y0MVE_0ae*F0000007*qoM6N<$f~59g2LJ#7 literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/pattern-grg-rrg-rgg.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/pattern-grg-rrg-rgg.png new file mode 100644 index 0000000000000000000000000000000000000000..fcf4f3fd7d95431b8cd1bc5f5129fcb724c5e40f GIT binary patch literal 231 zcmeAS@N?(olHy`uVBq!ia0vp^x**KK#K6FKsNOXi$XVy<;uunK>uuO>p#}vW?s@X} z?5{Vn@(E1fdg>#_p5-zBiX+1VA%+4b26mx2|7={&ovNQ>6SXtcysBl-)c><WmS!Y( zv7BNEzPH=%x{1!KjWd@lmbz(awP;VviDQ{7SW3K#guH|K-#!i8$dVG=UlQ?2Ho)uu z>9DyExiv#HMbsD$XX>p~Q&Z4f6DV?h!MD37E_}{<nz@wk)ekYNY^%>svR6Ky{&{h` fDhG(UQO-Q~pMsNotNvM_%Naaf{an^LB{Ts5h3Hy_ literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/pattern-rgr-grg-rgr.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/pattern-rgr-grg-rgr.png new file mode 100644 index 0000000000000000000000000000000000000000..db8ed5cf7bd1837d4810f2885309f8413c6c77d5 GIT binary patch literal 222 zcmV<403rX0P)<h;3K|Lk000e1NJLTq001fg001fo0ssI3J*IA&0001`Nkl<Zc-rli z%Myby2t^NmIe$(!ZH+By>?EUcysXRv&Lsq60f0F`IKaY}8O6F)ckPNrKmh*ySgNcF zsO2B!z+X<jPG+J~4Ii%NgDF80`5mJXpl^B2u+(g0*rz5I>8xiL(f<$Mv|j(s)%z{g zX4K!E|JCbvas7AqzkC1b|Dp4ruYT+<YHHy}$v^q@gcpA3!`InPrp6Oqc)fVS3qKqF Y0cy8C_Kbk@N&o-=07*qoM6N<$g27Q_GXMYp literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/pattern-tr.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/pattern-tr.png new file mode 100644 index 0000000000000000000000000000000000000000..8b4b25364e0ffbe09e563e13b567fa57330e48d5 GIT binary patch literal 137 zcmeAS@N?(olHy`uVBq!ia0vp^azM<_!N$PA*s|9jBoW~0;uunKD><d1=|2z8e@O`m zi5U_X7?eM1T?jqI(8f2(=fLXOHJ)xxeNNw5J?)fkN19wc<FT&3eZzeBMQLtcCc<9q mCdFSHSg)@*x>)QnGsEKzd}=q=PizO8&EV<k=d#Wzp$Pzi&n><H literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/properties.js b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/properties.js new file mode 100644 index 00000000000..ddecfb6e336 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/properties.js @@ -0,0 +1,449 @@ +(function(root){ + +/* + * General Value Types definition + * they return an object of arrays of type { <name>: [<start-value>, <end-value>], ... } + */ +var values = { + 'length' : function() { + // http://www.w3.org/TR/css3-values/#lengths + return { + // CSS Values and Module Level 3 + // ch: ['1ch', '10ch'], + // rem: ['1rem', '10rem'], + // vw: ['1vw', '10vw'], + // vh: ['1vh', '10vh'], + // vmin: ['1vmin', '10vmin'], + // vmax: ['1vmax', '10vmax'], + // CSS Values and Module Level 2 + pt: ['1pt', '10pt'], + pc: ['1pc', '10pc'], + px: ['1px', '10px'], + // CSS Values and Module Level 1 + em: ['1em', '10em'], + ex: ['1ex', '10ex'], + mm: ['1mm', '10mm'], + cm: ['1cm', '10cm'], + 'in': ['1in', '10in'] + }; + }, + 'length-em': function() { + return { + em: ['1.1em', '1.5em'] + }; + }, + 'percentage': function() { + // http://www.w3.org/TR/css3-values/#percentages + return { + '%': ['33%', '80%'] + }; + }, + 'color': function() { + // http://www.w3.org/TR/css3-values/#colors + // http://www.w3.org/TR/css3-color/ + return { + rgba: ['rgba(100,100,100,1)', 'rgba(10,10,10,0.4)'] + }; + }, + 'rectangle': function() { + // http://www.w3.org/TR/CSS2/visufx.html#value-def-shape + return { + rectangle: ['rect(10px,10px,10px,10px)', 'rect(15px,15px,5px,5px)'] + }; + }, + 'font-weight': function() { + // http://www.w3.org/TR/css3-fonts/#font-weight-prop + return { + keyword: ["normal", "bold"], + numeric: ["100", "900"] + }; + }, + 'number': function() { + // http://www.w3.org/TR/css3-values/#number + return { + integer: ["1", "10"], + decimal: ["1.1", "9.55"] + }; + }, + 'number[0,1]': function() { + // http://www.w3.org/TR/css3-values/#number + // applies to [0,1]-ranged properties like opacity + return { + "zero-to-one": ["0.2", "0.9"] + }; + }, + 'integer': function() { + // http://www.w3.org/TR/css3-values/#integer + return { + integer: ["1", "10"] + }; + }, + 'shadow': function() { + // http://www.w3.org/TR/css-text-decor-3/#text-shadow-property + return { + shadow: ['rgba(0,0,0,0.1) 5px 6px 7px', 'rgba(10,10,10,0.9) 5px 6px 7px'] + }; + }, + 'visibility': function() { + // http://www.w3.org/TR/CSS2/visufx.html#visibility + return { + keyword: ['visible', 'hidden', {discrete: true}] + }; + }, + 'auto': function(property) { + var types = properties[property] || unspecified_properties[property]; + var val = values[types[0]](property); + var key = Object.keys(val).shift(); + return { + to: [val[key][1], 'auto'], + from: ['auto', val[key][1]] + }; + }, + // types reqired for non-specified properties + 'border-radius': function() { + return { + px: ['1px', '10px'], + "px-px": ['1px 3px', '10px 13px'] + }; + }, + 'image' : function() { + var prefix = getValueVendorPrefix('background-image', 'linear-gradient(top, hsl(0, 80%, 70%), #bada55)'); + return { + // Chrome implements this + url: ['url(support/one.gif)', 'url(support/two.gif)'], + data: ['url(data:image/gif;base64,R0lGODlhAQABAAD/ACwAAAAAAQABAAACADs=)', 'url(data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///ywAAAAAAQABAAACAUwAOw==)'], + // A hunch, as from the spec: + // http://www.w3.org/TR/css3-transitions/#animatable-types + // gradient: interpolated via the positions and colors of each stop. They must have the same type (radial or linear) and same number of stops in order to be animated. Note: [CSS3-IMAGES] may extend this definition. + gradient: [prefix + 'linear-gradient(top, hsl(0, 80%, 70%), #bada55)', prefix + 'linear-gradient(top, #bada55, hsl(0, 80%, 70%))'] + }; + }, + 'background-size': function() { + return { + keyword: ['cover', 'contain'] + }; + }, + 'box-shadow': function() { + // http://www.w3.org/TR/css3-background/#ltshadowgt + return { + shadow: ['60px -16px teal', '60px -16px red'] + }; + }, + 'vertical': function() { + return { + keyword: ['top', 'bottom'] + }; + }, + 'horizontal': function() { + return { + keyword: ['left', 'right'] + }; + }, + 'font-stretch': function() { + return { + keyword: ['condensed', 'expanded'] + }; + }, + 'transform': function() { + return { + rotate: ['rotate(10deg)', 'rotate(20deg)'] + }; + }, + 'position': function() { + return { + 'static to absolute': ['static', 'absolute', {discrete: true}], + 'relative to absolute': ['relative', 'absolute', {discrete: true}], + 'absolute to fixed': ['absolute', 'fixed', {discrete: true}] + }; + }, + 'display': function() { + return { + 'static to absolute': ['none', 'block', {discrete: true}], + 'block to inline-block': ['block', 'inline-block', {discrete: true}] + }; + } +}; + +/* + * Property to Type table + * (as stated in specification) + */ +var properties = { + 'background-color': ['color'], + 'background-position': ['length', 'percentage'], + + 'border-top-width': ['length'], + 'border-right-width': ['length'], + 'border-bottom-width': ['length'], + 'border-left-width': ['length'], + + 'border-top-color': ['color'], + 'border-right-color': ['color'], + 'border-bottom-color': ['color'], + 'border-left-color': ['color'], + + 'padding-bottom': ['length'], + 'padding-left': ['length'], + 'padding-right': ['length'], + 'padding-top': ['length'], + + 'margin-bottom': ['length'], + 'margin-left': ['length'], + 'margin-right': ['length'], + 'margin-top': ['length'], + + 'height': ['length', 'percentage'], + 'width': ['length', 'percentage'], + 'min-height': ['length', 'percentage'], + 'min-width': ['length', 'percentage'], + 'max-height': ['length', 'percentage'], + 'max-width': ['length', 'percentage'], + + 'top': ['length', 'percentage'], + 'right': ['length', 'percentage'], + 'bottom': ['length', 'percentage'], + 'left': ['length', 'percentage'], + + 'color': ['color'], + 'font-size': ['length', 'percentage'], + 'font-weight': ['font-weight'], + 'line-height': ['number', 'length', 'percentage'], + 'letter-spacing': ['length'], + // Note: percentage is Level3 and not implemented anywhere yet + // https://drafts.csswg.org/css3-text/#word-spacing + 'word-spacing': ['length', 'percentage'], + 'text-indent': ['length', 'percentage'], + 'text-shadow': ['shadow'], + + 'outline-color': ['color'], + // outline-offset <integer> used to be an error in the spec + 'outline-offset': ['length'], + 'outline-width': ['length'], + + 'clip': ['rectangle'], + // Note: doesn't seem implemented anywhere + 'crop': ['rectangle'], + + 'vertical-align': ['length', 'percentage'], + 'opacity': ['number[0,1]'], + 'visibility': ['visibility'], + 'z-index': ['integer'] +}; + +/* + * Property to auto-value mapping + * (lazily taken from http://www.siliconbaytraining.com/pages/csspv.html) + */ +var properties_auto = [ + 'margin-top', + 'margin-right', + 'margin-bottom', + 'margin-left', + 'height', + 'width', + 'clip', + 'marker-offset', + 'top', + 'right', + 'left', + 'bottom', + 'z-index' +]; + +/* + * Property to Type table + * (missing value-types of specified properties) + */ +var missing_properties = { + 'margin-bottom': ['percentage'], + 'margin-left': ['percentage'], + 'margin-right': ['percentage'], + 'margin-top': ['percentage'], + 'padding-bottom': ['percentage'], + 'padding-left': ['percentage'], + 'padding-right': ['percentage'], + 'padding-top': ['percentage'], + 'vertical-align': ['vertical'] +}; + +/* + * Property to Type table + * (properties that haven't been specified but implemented) + */ +var unspecified_properties = { + // http://oli.jp/2010/css-animatable-properties/ + 'border-top-left-radius': ['border-radius'], + 'border-top-right-radius': ['border-radius'], + 'border-bottom-left-radius': ['border-radius'], + 'border-bottom-right-radius': ['border-radius'], + 'background-image': ['image'], + 'background-size': ['background-size'], + // https://drafts.csswg.org/css3-background/#the-box-shadow + // Animatable: yes, except between inner and outer shadows (Transition to/from an absent shadow is a transition to/from โ€˜0 0 transparentโ€™ or โ€˜0 0 transparent insetโ€™, as appropriate.) + 'box-shadow': ['box-shadow'], + 'font-size-adjust': ['number'], + 'font-stretch': ['font-stretch'], + 'marker-offset': ['length'], + 'text-decoration-color': ['color'], + 'column-count': ['integer'], + 'column-gap': ['length'], + 'column-rule-color': ['color'], + 'column-rule-width': ['length'], + 'column-width': ['length'], + 'transform': ['transform'], + 'transform-origin': ['horizontal'], + 'zoom': ['number'], + 'outline-radius-topleft': ['length', 'percentage'], + 'outline-radius-topright': ['length', 'percentage'], + 'outline-radius-bottomright': ['length', 'percentage'], + 'outline-radius-bottomleft': ['length', 'percentage'], + 'display': ['display'], + 'position': ['position'] +}; + +/* + * additional styles required to actually render + * (different browsers expect different environment) + */ +var additional_styles = { + // all browsers + 'border-top-width': {'border-top-style' : 'solid'}, + 'border-right-width': {'border-right-style' : 'solid'}, + 'border-bottom-width': {'border-bottom-style' : 'solid'}, + 'border-left-width': {'border-left-style' : 'solid'}, + 'top': {'position': 'absolute'}, + 'right': {'position': 'absolute'}, + 'bottom': {'position': 'absolute'}, + 'left': {'position': 'absolute'}, + 'z-index': {'position': 'absolute'}, + 'outline-offset': {'outline-style': 'solid'}, + 'outline-width': {'outline-style': 'solid'}, + 'word-spacing': {'width': '100px', 'height': '100px'}, + // unspecified properties + 'column-rule-width': {'column-rule-style': 'solid'}, + 'position': {'width': '50px', 'height': '50px', top: '10px', left: '50px'} +}; + +/* + * additional styles required *on the parent* to actually render + * (different browsers expect different environment) + */ +var parent_styles = { + 'border-top-width': {'border-top-style' : 'solid'}, + 'border-right-width': {'border-right-style' : 'solid'}, + 'border-bottom-width': {'border-bottom-style' : 'solid'}, + 'border-left-width': {'border-left-style' : 'solid'}, + 'height': {'width': '100px', 'height': '100px'}, + 'min-height': {'width': '100px', 'height': '100px'}, + 'max-height': {'width': '100px', 'height': '100px'}, + 'width': {'width': '100px', 'height': '100px'}, + 'min-width': {'width': '100px', 'height': '100px'}, + 'max-width': {'width': '100px', 'height': '100px'}, + // unspecified properties + 'position': {'position': 'relative', 'width': '100px', 'height': '100px'}, + // inheritance tests + 'top': {'width': '100px', 'height': '100px', 'position': 'relative'}, + 'right': {'width': '100px', 'height': '100px', 'position': 'relative'}, + 'bottom': {'width': '100px', 'height': '100px', 'position': 'relative'}, + 'left': {'width': '100px', 'height': '100px', 'position': 'relative'} +}; + + +function assemble(props) { + var tests = []; + + // assemble tests + for (var property in props) { + props[property].forEach(function(type) { + var _values = values[type](property); + Object.keys(_values).forEach(function(unit) { + var data = { + name: property + ' ' + type + '(' + unit + ')', + property: property, + valueType : type, + unit : unit, + parentStyle: extend({}, parent_styles[property] || {}), + from: extend({}, additional_styles[property] || {}), + to: {} + }; + + data.from[property] = _values[unit][0]; + data.to[property] = _values[unit][1]; + data.flags = _values[unit][2] || {}; + + tests.push(data); + }); + }); + } + + return tests; +} + +root.getPropertyTests = function() { + return assemble(properties); +}; + +root.getMissingPropertyTests = function() { + return assemble(missing_properties); +}; + +root.getUnspecifiedPropertyTests = function() { + return assemble(unspecified_properties); +}; + +root.getFontSizeRelativePropertyTests = function() { + var accepted = {}; + + for (var key in properties) { + if (!Object.prototype.hasOwnProperty.call(properties, key) || key === "font-size") { + continue; + } + + if (properties[key].indexOf('length') > -1) { + accepted[key] = ['length-em']; + } + } + + return assemble(accepted); +}; + +root.getAutoPropertyTests = function() { + var accepted = {}; + + for (var i = 0, key; key = properties_auto[i]; i++) { + accepted[key] = ['auto']; + } + + return assemble(accepted); +}; + +root.filterPropertyTests = function(tests, names) { + var allowed = {}; + var accepted = []; + + if (typeof names === "string") { + names = [names]; + } + + if (!(names instanceof RegExp)) { + names.forEach(function(name) { + allowed[name] = true; + }); + } + + tests.forEach(function(test) { + if (names instanceof RegExp) { + if (!test.name.match(names)) { + return; + } + } else if (!allowed[test.name]) { + return; + } + + accepted.push(test); + }); + + return accepted; +}; + +})(window); \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/red20x20.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/red20x20.png new file mode 100644 index 0000000000000000000000000000000000000000..5d44ef210e1132a7de6c5442ee47d3a220dfc2ab GIT binary patch literal 160 zcmeAS@N?(olHy`uVBq!ia0vp^A|TAc1SFYWcSQjy&H|6fVg?3oVGw3ym^DWND9B#o z>FdgV7pRU^Vw#v22T(||#5JPCIX^cyHLrxhxhOTUBsE2$JhLQ2!QIn0AiR-J9H>aj y)5S5w;&k$#^A2_iNfK9WR#k?4Uh$0aDi4Fw97c5^KZPQoDh5wiKbLh*2~7YTawj1G literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/region-in-body.html b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/region-in-body.html new file mode 100644 index 00000000000..78038fd28ff --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/region-in-body.html @@ -0,0 +1,36 @@ +<!DOCTYPE html> +<html lang="en"><head> + <meta charset="UTF-8"> + <title>One region in body</title> + <style> + html, body { + margin: 0; + padding: 0; + } + #container { + background: red; + } + #content { + flow-into: flow; + font-family: Ahem; + font-size: 20px; + line-height: 1em; + color: green; + } + #region { + flow-from: flow; + } + </style> + <script src="util.js" type="text/javascript"></script> +</head> +<body> + <div id="container"> + <!-- The &#8203; entity is a zerowidth space. It enables me to create nicely reflowing rectangles of Ahem text --> + <div id="content"> + xxxx&#x200B;xxxx&#x200B;xxxx&#x200B;xxxx + </div> + </div> + <div id="region"> + </div> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/region-in-container.html b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/region-in-container.html new file mode 100644 index 00000000000..219fce6503c --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/region-in-container.html @@ -0,0 +1,38 @@ +<!DOCTYPE html> +<html lang="en"><head> + <meta charset="UTF-8"> + <title>One region in body</title> + <style> + html, body { + margin: 0; + padding: 0; + } + #container { + background: red; + } + #content { + flow-into: flow; + font-family: Ahem; + font-size: 20px; + line-height: 1em; + color: green; + } + #region { + flow-from: flow; + } + </style> +</head> +<body> + <div id="container"> + <!-- The &#8203; entity is a zerowidth space. It enables me to create nicely reflowing rectangles of Ahem text --> + <div id="content"> + xxxx&#x200B;xxxx&#x200B;xxxx&#x200B;xxxx + </div> + </div> + <div id="region-parent"> + <div id="region"> + </div> + </div> + <script src="util.js" type="text/javascript"></script> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/ruler-h-50%.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/ruler-h-50%.png new file mode 100644 index 0000000000000000000000000000000000000000..cf2eea6b438a11503a89414cbb2f9f1fde55df0c GIT binary patch literal 691 zcmV;k0!;mhP)<h;3K|Lk000e1NJLTq0077U001%w0ssI3;WRTK0007dNkl<Zc-rlq zy{h6s7=~wbiC|&k#KzV}uoP2RSPBY)sHIn;ot@^CYHeD*0k6SU@&o=<wt~SzQP6LT z+1+9bIY?G>_PkGJCLw%0c_-t<Byu8R0TE%rfqnf#2=STCc!0-|BNJiWm+$+t+3XF+ zG01&|R6WZ2a%FMO8DoZFSe6xdSs{%)dLqg~Sttu-y|XONIp^Fk491wQ>y1Vu;JWBp zVzJoqc$A+V$Du&M;PW30)i^&u7Gwd)f-J~_EXabafA}Ss^LRYITrL@7hr_}5ea4uo zs-EXfr_-?8qSw;z_hYfxZnq<%d_G?&6l8n7UMHeNA~7D1DXd_+^X%M^b1Xhu#0egw zA!I?;mp#FUr6!IGxafwE1t1HuAPce}3$g%YK^9~|*6&HOysvn(*(i##-EJ9UsZ`3c zEZerjZtKO@{G-umsZ=7OWHL!ax~|LH&Qw+HcDr($*H`sP-cZ*0d?q4I(}+k2AsaiL zj;3j@>xNm@j~53yo6Tl2nfZLaSS%Dp@jOqqx7+P>I$bK2_WONkdm(-b!)ORuq3(u{ zuZ3eR);?H^UI=h{2M87b0ALRNMpGQFFcbm=3m{kkAXosw0tglW2o^xF0D=Vof&~yP zfM5aey@Mqmboq;Vy>6Q3^?Ef;v)OFQ#$+;S+qUC4@()R>)vA0j20RIU1AN~f3<kMe zPA*0wk^B8lM7P^58jZ@v;czH~5JH%ySu7Suqmd9o*Y(L{67t7~@KDnmXti3a)#`LQ z^?JQ>xhxxNwc21XxLhtDA0P5nd4E{1*Of{|zC6!y9M^SKRYkDydOv{gSOCES0Ko#G Z;3u}YJM}AuyWao+002ovPDHLkV1h`wI+p+d literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/ruler-h-50px.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/ruler-h-50px.png new file mode 100644 index 0000000000000000000000000000000000000000..9f46583665ca6471075227f9e2244f1ba1ffece0 GIT binary patch literal 671 zcmV;Q0$}}#P)<h;3K|Lk000e1NJLTq0074T001%w0ssI35I<<G0007JNkl<Zc-rlq zv8v)g6oyYUj*(OvJMF|<*xQPQHX;gQ=Q9YtMk4qIcD_Uk3p+s&EW|>6gP<0o<3OBS z1j1$6y@J=>jmiI2W)i~T^Pfp3CPtA`(u;`E>xkCAIOm38{A6Fs3%^GNnFzqX(&;o2 zDT)%hOaxRt$_h?dilXdxyZwIuAIl18<k1sR7Ro|dDC@73<(+Ub#)4IrH|Pr?i0E>; z;NbHP*$SvFj1Q0nSpc#i3$h>!vLNd#s;X8h6(Y)HGDMWkW{IfR>*e!#BI@`1L^K!- zq999sxJ98*&~=@N=JPpYY_r)A(Q>)W<#PTuuIolY7N$GT%2E_8{&5kbJC1`e1yhkZ z{QWZiAyepm0H$CHreF%DU<$w#Ou-aPy%*}kd9U|DN?9(KiD<D{L{ydh79vWeQmfTU zN_jXOj>n_dsO!3I+fqu~wx`pn*C<1c`p_d0X`044S5?*jCFXoSGsc7vhGD3xigAie z)6_I=x7!g>wOXy$>t1^zkyx+So-)UAqG0No%Wt8-X!kNxI7<M}X6pN1hP7CW{s%Cs z1EdN70HQYojOJV%M?e6ODu7f0qzV9}3LsSgsR9700!S4=ssK_208$0QoT}fxKB3)i zTb3n+uq><7>A-U2c*&C|r_;$a%~Gl4EyiN8`~5DZbX_+dkNXem%w{vr`D8LF7K>iv z?RKlxYUA;^)oKYL{4FJTXMQ?Xb-Uf|cFP#!ocsSC*Jw0`!=VsjG#WLVO@HH$j}Ibp z9OvtMgBWAUWb%5w;_jEw@bB(q!d+8H6#$q60;CFrn@_JUXnGtsT_OMg002ovPDHLk FV1h+lHID!Q literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/ruler-v-100px.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/ruler-v-100px.png new file mode 100644 index 0000000000000000000000000000000000000000..a837eca2225082917dc952efd5c689e1b51d7bbd GIT binary patch literal 760 zcmeAS@N?(olHy`uVBq!ia0vp^MnHU=gNcEGaWU)iTMP_L`#oJ8Ln>~)opsRfQGkd; ze)kq>afh25lNKiW9??&5?NHJA%O>=XS@{0}+4zG^EwY_?F_M#iv9}3z1aeiSUzA*K zu(aV(kHK?2k3BK|`KL4QXWugp33W=8Xj?T)Nc8vQ(%9`GT4(2eudkH7c2+NL?u$dR z-nKS2Z~j`Y^K+f^ZT|OzL59~vJ9g=>@?L(q?{UxZ$KUny^7DVzuDt!h?mmN?plfyf zmG|FWk8IKrjGUqMkB_(Yd8N`MAGQ3vyhA@<bgG)GyNbMZyBKBu{M65@X^X#_xz|N( zNI2NE)qRbRnzGW(oG=%g^U{3n2NQ}bDsH?iaanTtWy$WlscV`SSj{;6?RV|zP4C{l zb6FCjH+xxSZLO}-<dZ7%&v$p^-rjt(=cAyQ4#>1ywbzy(%Ux#+<}|T#gG9?_n$GnL zUK#SiePsyOw7;>}x9Vgku7B`~<KEgPU54g^2R_?``Yyk`>Xk*`s(JJ0KQFQj%{7r) zbt}iL)bq?nx5a@6yp{&7nsqXz>CffMm(RcYnakO|rl9#~(#I!HTteT!e?R%;lGnRd zMQMom`TO7h&1I+D{M{YwHHiH{KeA^3UX!~oKff$N`Q3$OHK!M>^?md}Ue5YP`;WJ` zoGPcdSKa}V$916$caR7I{lB!WCtmR1qOjFlqjc|ok6s(LH?H5a&h2Na;zQo04{aAN z%iOnj@5)!NUuP>#?C|XJSbx2`vNCh~ZFhHf$0DPdQ%*l!y?XWL&Bph?D}P^q>`h+m zFXb?;somY&_rL4w>#x3=<rC!6*Wd5@<m1PSg>$|yNsZi=Yj1B~pCFjW&0YS{yFmW8 z{%3D_dwKh-9vNpof7j<_ShMfbl=P&-N7}Xp$UV*Eei}Fr#*lj&2u6iKLAmWf*~0AY cw|+4$pP;3B^U*VLV7g}TboFyt=akR{0G}~+v;Y7A literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/ruler-v-50px.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/ruler-v-50px.png new file mode 100644 index 0000000000000000000000000000000000000000..84141028020b7e8cdf2412acbca3c799ba50a534 GIT binary patch literal 757 zcmeAS@N?(olHy`uVBq!ia0vp^MnHU=gNcEGaWU)iTMP_LdpunnLn>~)o#p7Q6)4em z{$d*2BG*@!Lc3jVdA+?Q+2PW(<&`<hUq0SH>~H^wHaWhIaoO!ruE(m{QKE2v_l)kA z-e(KKcYm$vKGDDac}?&6nKO$m!Y2I`xEAGUC@i-6WK{O=zyHpiJNNeO+xv#s?=j!Z zxcM?)V^6`#D~}&Pp5?A$`q-&{Ubpelh>!(auZC((&D%cv^wS>0zQ+>Dv(7%_|5v|q zao)lohkkPybSa7E=I2W%vo$wv-F7j<M5=efqK_3hJ(iZ1hR5E#eOo#2c)7cvt4QFM zmy258?Tg>%?^YeP{?keR*WWj6TXu)LZemGAMMlrg{rmeFE-(LJ<A3S&Y482_`L|4a zV$ruGZ1vX<9}HH``Sp4I^9xs8BD45(?Git7i|IscNI2NU%6%<AQFrUQr?(D+*uNsK z-AeFYem8ITy4x>H79F(9J8|Uk$H$M8Jv&{Tg0!YiDk&_S=(k)oHZIO<*REZcdS={{ zuBxt{yk+-pZOxfJY$vZ@zkcEDg32{MYQY*JDz>(^mVKA=wyUOYzPWhuV$b-4=Px{% z$%e2T?g|j&pZPVd@7osh<~-+>HNJ0@q3xBETkz(j;nVk5#ZE1@IrSJs=KbBV&8b#r zs@K)5tKa`-ZH>~KK0UlH?2I+Pa;AYqh}P8R=H>^<I%3lO$0yypfB*5vA5Q|#-o1Ob zz+%ny*S~-Nb}TZHdiwe2?Afz7Z#KUF-I?$98QU)7&slTl&$qX?-@VRShVSyrk_kFu z-9WGGdw)G^>*dRrJqy()8y@>owKqh|)N|Lm*OhSvei_W#^M7W~=v`a$@8~4GJx?va z-#4{oh}c&&{rS;0ap_x5l~b1MPI0e<Gk|OmIt~)N1C)g`AmVT`zVHuY?mGL;&f7B= Q0uwcZr>mdKI;Vst0OKlsf&c&j literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/runParallelAsyncHarness.js b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/runParallelAsyncHarness.js new file mode 100644 index 00000000000..460f467930e --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/runParallelAsyncHarness.js @@ -0,0 +1,145 @@ +(function(root){ +'use strict'; +// testharness doesn't know about async test queues, +// so this wrapper takes care of that + +/* USAGE: + runParallelAsyncHarness({ + // list of data to test, must be array of objects. + // each object must contain a "name" property to describe the test + // besides name, the object can contain whatever data you need + tests: [ + {name: "name of test 1", custom: "data"}, + {name: "name of test 2", custom: "data"}, + // ... + ], + + // number of tests (tests, not test-cases!) to run concurrently + testsPerSlice: 100, + + // time in milliseconds a test-run takes + duration: 1000, + + // test-cases to run for for the test - there must be at least one + // each case creates its separate async_test() instance + cases: { + // test case named "test1" + test1: { + // run as a async_test.step() this callback contains your primary assertions + start: function(testCaseKey, data, options){}, + // run as a async_test.step() this callback contains assertions to be run + // when the test ended, immediately before teardown + done: function(testCaseKey, data, options){} + }, + // ... + } + + // all callbacks are optional: + + // invoked for individual test before it starts so you can setup the environment + // like DOM, CSS, adding event listeners and such + setup: function(data, options){}, + + // invoked after a test ended, so you can clean up the environment + // like DOM, CSS, removing event listeners and such + teardown: function(data, options){}, + + // invoked before a batch of tests ("slice") are run concurrently + // tests is an array of test data objects + sliceStart: function(options, tests) + + // invoked after a batch of tests ("slice") were run concurrently + // tests is an array of test data objects + sliceDone: function(options, tests) + + // invoked once all tests are done + done: function(options){} + }) +*/ +root.runParallelAsyncHarness = function(options) { + if (!options.cases) { + throw new Error("Options don't contain test cases!"); + } + + var noop = function(){}; + + // add a 100ms buffer to the test timeout, just in case + var duration = Math.ceil(options.duration + 100); + + // names of individual tests + var cases = Object.keys(options.cases); + + // run tests in a batch of slices + // primarily not to overload weak devices (tablets, phones, โ€ฆ) + // with too many tests running simultaneously + var iteration = -1; + var testPerSlice = options.testsPerSlice || 100; + var slices = Math.ceil(options.tests.length / testPerSlice); + + // initialize all async test cases + // Note: satisfying testharness.js needs to know all async tests before load-event + options.tests.forEach(function(data, index) { + data.cases = {}; + cases.forEach(function(name) { + data.cases[name] = async_test(data.name + " / " + name, {timeout: options.timeout || 60000}); + }); + }); + + function runLoop() { + iteration++; + if (iteration >= slices) { + // no more slice, we're done + (options.done || noop)(options); + return; + } + + // grab a slice of testss and initialize them + var offset = iteration * testPerSlice; + var tests = options.tests.slice(offset, offset + testPerSlice); + tests.forEach(function(data) { + (options.setup || noop)(data, options); + + }); + + // kick off the current slice of tests + (options.sliceStart || noop)(options, tests); + + // perform individual "start" test-case + tests.forEach(function(data) { + cases.forEach(function(name) { + data.cases[name].step(function() { + (options.cases[name].start || noop)(data.cases[name], data, options); + }); + }); + }); + + // conclude test (possibly abort) + setTimeout(function() { + tests.forEach(function(data) { + // perform individual "done" test-case + cases.forEach(function(name) { + data.cases[name].step(function() { + (options.cases[name].done || noop)(data.cases[name], data, options); + }); + }); + // clean up after individual test + (options.teardown || noop)(data, options); + // tell harness we're done with individual test-cases + cases.forEach(function(name) { + data.cases[name].done(); + }); + }); + + // finish the test for current slice of tests + (options.sliceDone || noop)(options, tests); + + // next test please, give the browser 50ms to do catch its breath + setTimeout(runLoop, 50); + }, duration); + } + + // allow DOMContentLoaded before actually doing something + setTimeout(runLoop, 100); +}; + +})(window); \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/square-purple.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/square-purple.png new file mode 100644 index 0000000000000000000000000000000000000000..0f522d78728417b0f74b694e2e47cd41c00359d1 GIT binary patch literal 92 zcmeAS@N?(olHy`uVBq!ia0vp^f*{Pu3?vyBU)>3$*aCb)TpJh~{xkePDssRFB<<<q n7*cU7`N#kLjg3MaSNIuL+z|fjF-g!1D9PaI>gTe~DWM4f*isp& literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/square-teal.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/square-teal.png new file mode 100644 index 0000000000000000000000000000000000000000..e567f51b91bbe40754cb0e0cae066201219cbb4a GIT binary patch literal 92 zcmeAS@N?(olHy`uVBq!ia0vp^f*{Pu3?vyBU)>3$*aCb)Tp1b~82<lv|F?D~NZQlI nF{I*F@{j-f8ykf<uJALgxFP)4W0Ig3P?EvZ)z4*}Q$iB}@>Uv7 literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/square-white.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/square-white.png new file mode 100644 index 0000000000000000000000000000000000000000..5853cbb238cb2d4aba3dd49af3f2ba64d6c7a2de GIT binary patch literal 78 zcmeAS@N?(olHy`uVBq!ia0vp^f*{NRBpBq_B-DVEsHcl#NX4yWiv~UkzCZ4)$}udm Z3=C_{1@!OB{@4Xl=;`X`vd$@?2>|f05A6T| literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/swatch-blue.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/swatch-blue.png new file mode 100644 index 0000000000000000000000000000000000000000..bf2759634d45dbe3df13868341eddb7e4bf24172 GIT binary patch literal 84 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K83?vyP*g1g|bAV5XD+9y-u8K?HKrWA`i(^Q| dt>gp+Mj%g@f$_JNuojTT;OXk;vd$@?2>>P$4{-nh literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/swatch-gray.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/swatch-gray.png new file mode 100644 index 0000000000000000000000000000000000000000..92c73561f3a8b74b279c2859a0b13145ef12f40a GIT binary patch literal 163 zcmeAS@N?(olHy`uVBq!ia0vp^A|TAc1SFYWcSQjy&H|6fVg?3oVGw3ym^DWND9B#o z>FdgVmt9swTFAKFy%s1WS>hT|;+&tGo0?a`;9QiNSdyBeP@Y+mq2TW68xY>eCk|93 z>*?YcVsSb-CnF<4LEOMFfWghQKTGba&8nG2XBpaS8CUo{xWf)q$l&Sf=d#Wzp$Pz< CekfxA literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/swatch-green.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/swatch-green.png new file mode 100644 index 0000000000000000000000000000000000000000..0aa79b0c86bd72c2220ecce39b9553e2cd3605b9 GIT binary patch literal 84 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K83?vyP*g1g|bAV5XD?<aroS#c40=Yb%E{-7; dw~`YS7=b)p2FBl7!dgHUgQu&X%Q~loCIBjB50U@? literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/swatch-lime.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/swatch-lime.png new file mode 100644 index 0000000000000000000000000000000000000000..55fd7fdaedfc1ed505b111f20fabbca568c68fa5 GIT binary patch literal 84 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K83?vyP*g1g|bAV5XE5m;VlehybfLtC=7srr_ dTgeFuj6j|)1LJQkVJ#qw!PC{xWt~$(6968w4?q9_ literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/swatch-navy.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/swatch-navy.png new file mode 100644 index 0000000000000000000000000000000000000000..28dae8a3e12bea03cf41b020bf05540adf9da17f GIT binary patch literal 159 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K11SGd?VUh(>oCO|{#S9GG!XV7ZFl&wkP>{XE z)7O>#E{A}KxioXY?P{QqWQl7;iF1B#Zfaf$gL6@8Vo7R>LV0FMhJw4NZ$Nk>pEyX7 xr;B5V#`)xwgp33QDFed^Om3n5tCsD{VrW{=FfT{-zcNq}gQu&X%Q~loCIIazCb<9r literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/swatch-orange.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/swatch-orange.png new file mode 100644 index 0000000000000000000000000000000000000000..d3cd498b52bd88ea6c991f050f1ecb1cfdd136bb GIT binary patch literal 84 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K83?vyP*g1g|bAV5X>;I(;rzSbh26A~kT^vIy dZY3uuFamkH42-|EgtdSy22WQ%mvv4FO#nq@5F-Ep literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/swatch-pink.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/swatch-pink.png new file mode 100644 index 0000000000000000000000000000000000000000..95b84499a3d849cfd74eb8711f5d2a1bc45d0c39 GIT binary patch literal 160 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K11SGd?VUh(>oCO|{#S9GG!XV7ZFl&wkP>{XE z)7O>#F1v)dmTbUZVN;-xWQl7;iF1B#Zfaf$gL6@8Vo7R>LV0FMhJw4NZ$Nk>pEyvF zl&6bhh{pNkKlKkxm@hVTHi{UmstPgv8p_P@ua9X3)ACoBfT|cgUHx3vIVCg!0A2AZ AjsO4v literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/swatch-purple.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/swatch-purple.png new file mode 100644 index 0000000000000000000000000000000000000000..73bea775175e9bab0dfe664eaea9ceaa566de787 GIT binary patch literal 153 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K11SGd?VUh(>jKx9jP7LeL$-D$|*pj^6T^Rm@ z;DWu&Cj&(|3p^r=85p>QL70(Y)*K0-AbW|YuPgf<CN?H@8SBFiJU}5yPZ!4!jq}Ml p2^k3rQU-<-nA}49S1sF@#c<n>Q7&8X=USj522WQ%mvv4FO#s*6C0hUh literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/swatch-red.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/swatch-red.png new file mode 100644 index 0000000000000000000000000000000000000000..1caf25c992aa8e23483cddb3334b5f51ec967f4a GIT binary patch literal 84 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K83?vyP*g1g|bAV5X>wg9Y$w!>#KrWA`i(^Q| dt>gp+Mj%g@f$_JNuojTT;OXk;vd$@?2>=8a4uJpw literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/swatch-teal.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/swatch-teal.png new file mode 100644 index 0000000000000000000000000000000000000000..0293ce89dea5c9413e4c829cc83a4e39d8f23300 GIT binary patch literal 156 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K11|+SoP4xm&jKx9jP7LeL$-D$|*pj^6T^Rm@ z;DWu&Cj&(|3p^r=85p>QL70(Y)*K0-AbW|YuPgg4R#65`cCM1`H9#R5PZ!4!jq}MV s85uv$JE$cjEnw)$lDlfNN|Kv_A+(E0c5RvdE}%LFPgg&ebxsLQ0IVw~FaQ7m literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/swatch-white.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/swatch-white.png new file mode 100644 index 0000000000000000000000000000000000000000..1a7d4323d77287d8eb03a89c635b09d099d94869 GIT binary patch literal 85 zcmeAS@N?(olHy`uVBq!ia0vp^{2<H-Bp8I(u6Pcln3BBRT^Jbeb_p*5^7uSm978H@ gCI9%}-<ZL|Fh5TA$_Ah94}dZZp00i_>zopr0Qo5vZ~y=R literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/swatch-yellow.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/swatch-yellow.png new file mode 100644 index 0000000000000000000000000000000000000000..1591aa0e2e274854ed836cf582235ea0202f9c8e GIT binary patch literal 84 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K83?vyP*g1g|bAV5X>;L}@UB|w-0=Yb%E{-7; dw~`YS7=b)p2FBl7!dgHUgQu&X%Q~loCIDbL5Y7Mq literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/test-bl.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/test-bl.png new file mode 100644 index 0000000000000000000000000000000000000000..904e24e996a3e5da93bef89e10c49e24c07d0ed2 GIT binary patch literal 1368 zcmV-e1*iInP)<h;3K|Lk000e1NJLTq003kF003kJ0{{R3g3O3#0000aP)t-s005aY zGnr;)nE(LHGc(L)X3UwH%*@QpW@i7Hng7hp|NsC0s-1y@0000CbW%=J|NsC0|NsC0 z|Ns9065r0w00001VoOIv3m@0SzyJUQ%1J~)RCwC$mrHKsHV}qI#0OA$)CUNV+0PNC z5z>1FDgrZWOHO<59>534BKsDgp7p3B>I7zAF2$Eby&QX;;i_BGr>dV-tSTkfVYNIl zi$7l1mTrsB_C8C-i#4X^3LaLG>jn4e0?941+dy=QV9i9xkG(@4H;@(~ogt^a`43yj z^`**Zh^{Td#Pj%+Qr%fKN-5`g;nYOF+LzqmXhmO+m0gFk>gfe#F-NRAhUdXXT_P3& z5hZ>zhPowUE`a<#=%qb^0(KmTs?O^A;`TX0ocz1q{qO362uJ`J02e5qdmo1g`RwHP z!A7z7fk;yZJFK4j+J<J_!!kFwGv}DTl*m6N!y-fSp;zS$vG4R+^f3f3FkDp6`iZB@ z9Rq0{yOh5|GFgnv$G$b5jmSNW@=3{zpgZ``cV=57#LB;M$gx-;>{j+R-gEgot3{VQ zT_EJMJvHm{U-0*2vCJ(xH5>9<9E?yX{cn>?Cg7{`b(@FBIAj4b8LLlxUA}&DNX9v( z3NQA_a4!BS*5!`~%BqqjA5Y&4uFEHnEyD3&j#zU)o^f5S%cniIzr|OZ3i>ow5`DiR zKV-E(ZYQ3EdZkb6@<UeNeUB?iBFq`D*X2*MI!I#{X}9FZS$$Qmwt_`|Y{-wZnqKV6 z1blp+IyR9XXEjwg7bU<2vXH;?C)8Cq%49XyvL(Ou3A1w<`?`EvZGvCF2-_3drF_v3 zWsvc|O+gEO*$ta$@sA0cmcFE8)2I`NWRx;N{9|`#gBRBOOq5lHKJ|AG{lc-r?c}4) zL-$z5Md6GLEg?qSW3G#N#pKN%xTocLj)Y#BeKpr}_iC1cFHVHGREV^M$HW)&`;U1U zqa(S7SZ8*J-qhDnFUE@G8)EF3n+2Q$s`7)uute1_k<QgF7t5n>rGpW1SV4To*jSQh zlcG$a4=ps-GU>1C2_a&@$I%?>7`aa!VnfzdIeZ#?+sUD|PY~B%U0^7GO|Nu@sDsJ# z@KlWWEXlsO1AjC<{IhGw<M`A>1$M}i5N36xL4oHW;3LYQL{&USeE7rWXggil@q+qy zcqZ;IV<F)o1Yw4G7>JjWW`PLt<%)`T&`L8>V}>Oa<kn^+iI7n5LHubaqvh(*WJr7^ z)T>O$2em@zx|mEC771}cDVqgE!@z!yT>QYv82lFP(%@F<5;wl4TqknAA$72YTMI-# zh4f`KPMMiy>XyGdc~Of)_A<zfoj!JJF(=#0d7SY)+PJ~38KUdBOaRb$*jPKdJK=EV zrkm0Z8xVG(YE0}Yt@-e>+14L1KJ#R!khI&B)WtXi&X5b{lL3*@ZkLC@MvW|+A?7gN zW^9D0T;2*9*?`>~p)-$sKP@gC`DhvB0@0TW$+>vr68OLZ|AFHIA?8UIVp5VL8#iJF zp>x%gNY!OhEyLo1uORl+--}g*Wst2R?yDkOfv7^I8;JRK;rXg-$rj?i69C?WTvb<5 z-Ama!5K|d3=PQC<K{RE8uwP1VM##=LEUkC!&4^ZAZE86{8mYSe$D&=JS`K8398A-< zAkI6YxS&bnwNTEyqw<esfq5o26J~CRQnjl~iN@O75YIKX+q?rYE}CZZF2t>$$WP>d ai~I`(b4pM507-ZN0000<MNUMnLSTZUYM}!F literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/test-br.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/test-br.png new file mode 100644 index 0000000000000000000000000000000000000000..f413ff5c1a0f2ad9f9a345d3e07be57a59a82207 GIT binary patch literal 1045 zcmV+w1nT>VP)<h;3K|Lk000e1NJLTq003kF003kJ0{{R3g3O3#0000aP)t-s005aY zGnr;)nE(LHGc(L)X3UwH%*@QpW@i7Hng7hp|NsC0s-1y@0000CbW%=J|NsC0|NsC0 z|Ns9065r0w00001VoOIv3m@0SzyJUPhe<?1RCwC$ms@V5FcgLlnk;}*nH@}b&;=9; z`W^{0$~+gU<h>dx3m9n@P^7faO%<|&!sf>KZm^B!d3qut2z>beeU2{xp@)&j(02`` zTY^Y(yls!8j-g6{#iqXUOZZmq^{tQRnwIpYptOGKE#wg=geU|udB&pePc3cOueFKs zvzd?t6~fN!7xtH~ecHeFR|~mNE=(hU<zcj=XW{%Yp6UJ6N@ftUzmC!P5cbt`?6jy? zkn>j9-;D~v`nZNntt8~9LC7xNOec_RZz1(-9N|5dP=m0v9-_#(n4W^-V2~txiYhzj z!i$YK*$mpxEQDn<+Gk7q?5d2K>8gc&fN~c@-gEJg62@yGi)KdJFKsVL7OffK1s(gk zuDvn5Y{BU<F%-%e((qKG8u5Ul%idy$ct({KxR(KBlCq)lwQ%n=>I*USjd;i%YrdEb z{Sn*_^roe9hCXX0U8@*Tm5}W<;uM1)L8qv|EjeFw?$DQBbYc7Y_+{2Z;0_;OA3x6W z0PY|Sr^RF&+^N9lo^nJde+0T>e|Q%!CAxA~?GMkwJ^q*@L1D^DW{@@e8aZfW&HlL( zh^h58`-7ZbHV<zaS+W1w2>0aSI!6vcWNu~EzD%TLWzD`y<i?s$R_yCU8Y@az$o?{s ztJ8(Yy+rUffV?jfsir=p{xwOCNIQ`VxeF})mt`W=%)g=j#qveyLfcAweUa7TT2Y9% zj|Z80xYL7JBN#v$SuMm7!T-APcUV_RUG7#w6p(kTFo<b#?tbL$mc9)MbD|J81-xCa zu1iy(+!eIf8G_WOYv>wDV7Xr)zJ+r5pkj?+g<rb&*<VHdwnQ#%k*B`?n)b<=Z)r8M z*w%Y?pY@=}iIK&e%yly-p3Gaau$<qAqFp+%WF>S_u|SWDG`g}53&gW~H?kPATZn)^ z{pHpDF0f_Yc)Al>7VPVTai^XiPQR;MAxJ&d2ec|FrET5HXc}tCS~{7gaV(KcTp<oc zQD|B7>QZ^Z1TjZ~gu`3RQzOf}P2=}cU|fp)kR|{zS!z=9ML<>z3CM~dAz5JrL$V?W z4Q^@!)=5xS07+PK!ylVGm5`=3ktPvYvS1MHR5ItZK3>BJtE{TnlF}3mey44O;Kkq6 ztd@0Ivcj%UvClb}M#-r)(X{Qa==a|U(_!d)YlyiY`vK(N;tTmg{#)cPVxOudoeJ1E P00000NkvXXu0mjfoHYWE literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/test-inner-half-size.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/test-inner-half-size.png new file mode 100644 index 0000000000000000000000000000000000000000..e473bf80efc66766cb32ec2cc60244ed37dc1157 GIT binary patch literal 180 zcmV;l089UgP)<h;3K|Lk000e1NJLTq0015U001%w1^@s7JXu?L0001cNkl<Zc-rli z!4AM62t%pa|Nk<(E?zL=Fq+2^X)3e<nYr61nsxC@Ld$8rPiTZTB&ja&s6as%ZJL|M z=rOcU${2vp2YUvrojv1iz<}=oKePMm#BU3e)Gz&dnG;ue53v^M#Hf!LH5!*`jH~Z= iHN+4@%ynW{5626)ITymFxuX~W0000<MNUMnLSTZVu1667 literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/test-outer.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/test-outer.png new file mode 100644 index 0000000000000000000000000000000000000000..82eeace7fc0c4202f79610978ab423e62abf8939 GIT binary patch literal 2412 zcmZ{mdpOg78^=c{EOMMh4qF~6Bd3rFi9{I*a|(^Nvdq~?QjT*?4xw_Itd@FmT1%@; zkHai-Y6->Aa{4*!H%&eKiag(`-yhHQT+j9WT%Y^CzTeON{@nNL{(P?Mo9&Krl9f@D z0f9iW&L<o^0NV)yNkF9}fteqx$p(R>O`RQ%dM1nrDqQhOXQ7#ug?V#Sa2fmTSTTg# zq5n>b3YP6~G}vwrp{7((H(F%s9=vs(d(vdsw5S`*{!`K=^0e|Hs;%}@ZAe9;YhM#o z_ToaBZbi>ZoPth;c~{8~-g5bm@{$}EyaCQ}|KNtGC?`*cg`T-jp?`3qQTBgZTv?v{ zsdiqg_=L}TaeDHp)WEMH?m}9l;@m~8p=7pF>!36@MZO>-W1E4=+P#fwf=QndMcXv7 z8Z8-fF2Q7mdllSkqq$$v5O4Max@#iK>)>}|J2%opy`et}FlLkY$|k=MPb|h-F&GS# z`yPH&Q53dkQkZ<87kdVuoRE+pLOXW`h4H>u8uuqXC&Rob*li9oo;cl8K)zjxUvIBg z$)w}LH2k-=iDKc?$`Kh8{tr6}PB1uTuEZnV2}8sH8=6vc={^tU1@E=j4k~YXOGQ|X zkJ7bc);}A=x!>Q|ZjgqKn<q^%>txci{z1vOpT5iHp(Eo0q?hU&McH@xcJuaJ!&r=t z?vM4Ew=lmncbCv<w<by^%~!2EMkjjnd54&X#Od#j14r-;{%H*anvq+xT4z&^R~p5` z!xS#*RhyBq#-3+TSq9ZKkNp)WoXPH4H-m1)g6J1}?lL8tMqKR^6?)~97d2-4DhB+5 zUdGN1RJ+xB<5yKLk0NkP^&6b`?>%iQg%g%g!y>UhwjyyUTO+MrE;m#Qlfbq|*dc(4 zZC|6qC(sSHP6V-iNf|!edmH+^^*p7Z*`Fr|qZ;SsTT5vuq{VfH<xT}KU7pO%=gQ-v zpl}EV2Ej;R3K*TfdooFmy;Lk8A$M$3@V7ALWqa%n93N4h!H9%#CFmf!JRkt3OVQHb z4OBETnat*91Ne0G$7cc;8XW%MV(Eh}E-|2Hw!aen*h^t9zNtCIQK#4?o8<B4NzKA= zJ-KtNi74c~C_F{C-09RZX5o7;K}%g#V~>E_u(9E~{{7oy($sRI!r_#kERyw=)upx! zFkJKpcdtUCXezrquiN45{@FUmzL;55Wac?m%0{3=Y46O}udzZQvI2GYkbbEmgW{O# zB*tP_1EQvt8AEX}i1ucwo7Do-=J@@}d(C-#{nOcUixx3CVB}<e`Lw}_xWS0LbrOGg z-0$$Y+G<jqNui?4Zdoxsu$TaOYd=pOXKWEl=;Q$~#Yp}}11wlrY@mF@rT&tjQx2Kc z;EdG(+Qw=(0gQccTmb_LX#GO@-=ToE{*}o1S&Q<qR$oGG$H$7QsF?VyQgL%mGamZB zN8AN0>yfx&o9U9a{k9oC*L+CRvNc6NGmAaSr-%G%isWSVX*Ri;gJFYDY61-RZMJ9s z-`z?*?sVx<BY`>k?ebatm>?cmkvn8n>~gVoVD9PAWg?M?$DhQ9`wq>_JP04nEs0as zGCYyp$>C%Uz4Sbg-8nx$KQdBELKqs3JZpaXR0kdt6C;QpRUl$8ZN2BT1ay8+QeDwI zu62>#lKkWL24UmrHRFc%C7-=lR_WXembP{E_3D{)24gRLd3m`56V=JI3W>Gc@|ghD zM4FnK`Yo)lucxJLsZJ~`ENt|1#h-mVSROoe^Uf(EVVw0btkFTIuq)O|12?%MoRDpA z2yb%N3pEM(Fd#*y6-Dy|)=~4^T7Ra;qxZn6bJQv8eU-G*cUmx99|SwF1S^VO>?Mcy ziKu&}Y5&7fzUR%+PBa2D*ec=Nds+$#Hi85rKsnpQ4u~Tuc0eH#V&@ut(`oSm91zDY za+r0m+14Xz`N-u=du{O&XwC%ls)q~AieIs$nYA?j`i;>+?lE4qb*u__4g0>Wic&zo zR+V36^t{R_-%yv8wr}-_^1lgZWPfdu3O$yvqYW912-Zu#GoWhgovH3+iIzI{A=E)V zcQydV*I><E=u_da(q7DH+)<GXMo3AvA=y+6U6e})iPP3*DUDxWlG~X9WJt}Yx1=aW z9f9!2A{3*A+uM>n-slX6bO6zsU?5t4944(oUP5)GKA$4KLQ4haDC`}{Ps+Ey(|x}` zyBd9~%hyJlk{^d?Lo)0)dE5l)3+)ni{3Zg_i0Xi|wj6^6BU*ew>BPGjg>hpsG84#F zFtJR+%|k#s!XCqF_ng1k)XQe2ZTWsnZZ|ncg`BfZy2~e>2r%0X?)0(asHJc|7s;{V zAyLed^iYKNI1KWOw{~cQNG_eYN!$n`KQ1lw1ky25mK1-sOUN<}du0+Jm-|WOJ}UZk z;MD^*RM{7)%54F<f89d$AT43&eEZMXjD>{-bX|b)&Pma9Hxh~L<9I*zLO^8O^&sR* z+Z4@)s8v757MByxkbSog24S(-^4S*wgp`yZd~#%@yPop)OUea1c4?kMp-^sa!(oST zlOoZRWmaIl?bWsCD++LG;;LvBull2<z%AUo%!0tXV5Zh=aOTXJiC4)n)<ylZJ1#8> zTKN2P=4FEB_A-kIhbh4*)5)gT&@Gq#)33|s%4+1d`N2!(NL$;9utxEAWYvRMlM?)J zUGmy09Ze5xzD#Sp`sH(nNMyos$)$75^*zJVnHX>A58rdx9N!z~iBj0<W}FS}{WTSS zYe(Kh?$^;NgZyZ(TL-Pc;QQJ0!or2b!LYc9i2f%v0)ZgFaP|`7cK3seBhSK1u{4h_ z@XA$Y?)2*bv%CGWDk&;eV+0`iroein?E{ZT1m@$$KVz-tVqdPbjg5@~%n0G(y?uRF z>IU6@K0Y6KJQh(%2_L<F(zQbdtgfyO+|gmbe_i?OiRXdC>Z+=$Xf!%}G|=DQ-_LJ; z{R@v*PI@{ju&;VMdI8E|v)OrCwr%pJojwJ7oSpnX!a|OIC{+5t7cWF27_n5j0g~u3 VAD}`@1i=3k$k`F)P-h>U`X3Goc2EES literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/test-tl.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/test-tl.png new file mode 100644 index 0000000000000000000000000000000000000000..f6ac0ef7e8f6e192c9c26239884bf92b13cf67b8 GIT binary patch literal 1025 zcmV+c1pfPpP)<h;3K|Lk000e1NJLTq003kF003kJ0{{R3g3O3#0000aP)t-s005aY zGnr;)nE(LHGc(L)X3UwH%*@QpW@i7Hng7hp|NsC0s-1y@0000CbW%=J|NsC0|NsC0 z|Ns9065r0w00001VoOIv3m@0SzyJUPb4f%&RCwC$mQ8M}Fc5&T!~r@I9HIMngrJ)4 zQ(^kjbwEn?FN@yb9iWkt>{9_J2)W!F@R;Dg)Lp$zS!5CX;rV991JU){SM-DYAV0|e zM%uPHwukYjIUJ7B*Q=ZTu2z>QMR^bD+hKK83n7YJaQrDaUiXl8N2@a^ART^^rwFp> z9#IKgok0Td0KkTyXt?~yXZ<2qM=a7Vzey#Q*6RDnL2!78qHiE=Ex4QTA^lz~J%kTw zstmq|U|5-t@E~V@SRUkpVNEL-i@q);x>HzkHGJJLeJv;~hO4ub=d-q4IFZka!eTMc zu`{buHGh%+at79akO>1WhSi7Zh!q^12-bv5K>WppZFh6@Am?f!<BIe8<ZyJvwWFFq zUcMXE0yolD)G8oeTdi8;=!mNz`J_B*yPwI?M)m~}`KHs5imGL+R7;7ZWotYNJV;A* zWckKOJq2tdq{0$$(*LL3ZKU7Jv@p{|rJmVH#VIZ=UDrmLfQ3*?VqE$rdu3uFswG*f z%lCCbgf){JI*%YWuFdgL!bDU{f?kyVyi~}>KvZ5Be|6^zTf#t8UO;S(JZAKN+3ASN z3j@6)uNUz|&Al}d$_w_F78jlrimN;suUD0qIN$0jWDohucq6MjSV#Rh_J5@Pc!G3f z_wwM3t6xj|WYw9-AC(uqCDDE%<9fTAh~QL5JzvTmP~Jf3VT_w`oktbsK$-$vb-dY+ zEip&>4?ZIC^U;m)Hw&SbOn!F;BHM*_pCjsYrK_unjA?=AlYvYnPPY~!(~?^V6%rmz z<RXVlV(+q3UGZ)qa4U<3RPu9z8&h()Lr7;MvMclhIow%G<k?0tDQT)8vXJ#M5t59J znRmOBS}sb`n8kPXi@9Ww{-vOHwGp3wv!1nUm_EL5ha0)Qi>kimBF|Bjt{e!>7aIY` z$e-!kZF!dZ$<~h?Ekqu$Hyc?mW_>Y3_Tv~aU&L~krJRVP<{Xh@#O3lKU&e81AT)VW z+l8Kn<$pJj%%^`<NBnV^?sG(rO721gjrZ5ir7vt3{7A{<<H{~jA7`ID<MD7X!t_;S zAdaE>s>@+0W|%%6zicXInEvpcG8HpS|5i+Fr$GIwnD~MX)K@9PlerDlpNfeu>p=af vm<;kz{V6gHxvP)gcJytThUyO|QzGyW8di!g0nvTM00000NkvXXu0mjfqXF-V literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/test-tr.png b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/test-tr.png new file mode 100644 index 0000000000000000000000000000000000000000..59843ae54b64f6ce4f7e616d4be491c911ea84cf GIT binary patch literal 1235 zcmV;^1T6cBP)<h;3K|Lk000e1NJLTq003kF003kJ0{{R3g3O3#0000aP)t-s005aY zGnr;)nE(LHGc(L)X3UwH%*@QpW@i7Hng7hp|NsC0s-1y@0000CbW%=J|NsC0|NsC0 z|Ns9065r0w00001VoOIv3m@0SzyJUQMM*?KRCwC$mrYXRI26aFnjFBd+de=qdOt_N zRTBGjNv4=J5|!QqHQb;NfD32Vom9jLqFiod>%)>Qhp^}!Di#F%(|iB->7dhx5Bfwt zkx%50BC1n|tx|6vK%_mLQWqnX6K;;U`FDFEg`lc|)m4wlpBK4@05B8)B_V|J%_Vlw za4<$t6qwQ5?fVe&2b-UQ(B}DF=TLGmWzFWjfTsuoBj{dz2tgQl^A0mb5R|kzAGjHU zzt-QIvk5};13=E&LB-q-)byMklsg#6^|GA>1kTt&3kTTsQcmN$3rJ$UlvDpmfxi-B zs(OsZVotq*l2F1pfdVHvT}FC0ny!_MGKlO{^1lTH|7D!$)SEgOs2&9Y@Lbr2kd{<# zhySTga0aoQC4`TSr6hxqDd{GMq~)Oxf{zHUHg7p3EkeB)qa9pj)F50=N<;4i33kkV z+Zkfqoh0ngavtIa&CE4aHM11QcA(<ZnS*i}9_-kZ;*#IbkX(ZM7}U-VnO=(WZJ}O6 zN?{sklqJk*eYL?f(2HA43tsrLxw#P83GW(do-aa9$Cseyd*a!d^}6HVyqYAe5u#PP zW%Z*kP*_6LlYHvTg7zzOR0H&%9HKkXNYMzhoi|%+O@~02w{IClNzOR!w=8e?lQnb@ z%pq|-dqh2QW;SdM6#?$Yk>1_eQZqwfj_k!6`W4$RXtT;($sb=Vf=Ltr<fHQ=Orru; zUn;qEfp&3@JVRc|I^G&)9Ni4A9mSQOHEM$Fe1C)nz8+lD!g*#oEk#T?Ym^*pUDLa@ zP0fmiPIHK0vlU}q+Y5`}FTpe9;sq1LWPGS!Et$V!6C--}V}{^za7DM=t4WauJA@K$ zMP={GAs~J}TSO4+Obz2!!c-2PJ^BD}6(L7%qhFFWlm_w*{A_jB&gyf79BgCs?>w9n z=2B#u(Pr7sL0tWekex*^{dF&8!>RY)KGWH*ffTXTQc}}ioq82%jI{MEgls^5+h<%O z^>H1Z@tJtBVk*~XX#88aM!5hI=gDs?hBhOj+jXMvWV-~H?(^Z!I&l*r!fNriI&I;K z<Iv6+Vk^Q0%(qeN5a+0NAxn^9#sT%s+L9uce-sc;vjLIT_kg$%QSX=-v{o_lKqih2 zSFAju?}mC>UB`|wTQ4r~E*vl-*0C6Qu@PH2eTrR0Wf{T~%Xbknf3wf*S&<+a`6o9M zz*S7^KKgFY$UnJ0HVgZg8jXfF%*c<rs4-Jtxk{$Dr$zap4viTq<*Snt>L({(KZLbt zzRNL^s?W;zZP~w5L&>g+M15Ai**#&3n|Wb>4eGP<`;PGlMsC0muRbf^cs3p5##&fh zIr(FkMaZ}vrt)1Swj2@$kLqXgyORsRw`3xZBX}-f+RL=$<nPGNDtben%J*+U`~KZM xFqlMZdn&(j3r#(mcWQ87&CEBe=q+_3|9^_Lp+#u>Ntgft002ovPDHLkV1lbeOeO#T literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/two-regions-in-container.html b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/two-regions-in-container.html new file mode 100644 index 00000000000..2fc65261da0 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/two-regions-in-container.html @@ -0,0 +1,38 @@ +<!DOCTYPE html> +<html lang="en"><head> + <meta charset="UTF-8"> + <title>One region in body</title> + <style> + html, body { + margin: 0; + padding: 0; + } + #container { + background: red; + } + #content { + flow-into: flow; + font-family: Ahem; + font-size: 20px; + line-height: 1em; + color: green; + } + #region1, #region2 { + flow-from: flow; + } + </style> +</head> +<body> + <div id="container"> + <!-- The &#8203; entity is a zerowidth space. It enables me to create nicely reflowing rectangles of Ahem text --> + <div id="content"> + xxxx&#x200B;xxxx&#x200B;xxxx&#x200B;xxxx&#x200B;xxxx&#x200B;xxxx&#x200B;xxxx&#x200B;xxxx + </div> + </div> + <div id="region-parent"> + <div id="region1"></div> + <div id="region2"></div> + </div> + <script src="util.js" type="text/javascript"></script> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/two.gif b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/two.gif new file mode 100644 index 0000000000000000000000000000000000000000..01435c80209d533dc2164ac48279574c7ba4615e GIT binary patch literal 184 zcmZ?wbh9u|G-5Dfc+9}?|Nnmm1_pU~d3$^N`Sa)Bzkk2JzCJ!ae*gacKygf<0}=x1 zWnjq_IN`Z^uf^-LyZ<L>^rd9Z%UHE8=k>k<o%1ER_bb-DuX+F9^k9R7fPkLUqK~Q* zc(|CC2%nO1TinphID5}Nt_DZpXpRQPgu)-CGBzifT9*7x<K{V<yu)Ju^Tvk8rskH` Tw)T$BuI`@RzWxaff(+IGsD?$T literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/util.js b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/util.js new file mode 100644 index 00000000000..a7ce4283e45 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/util.js @@ -0,0 +1,29 @@ +function resizeViewportTo(viewportSelector, width, height) { + var iframe = document.querySelector(viewportSelector); + // Commonly used trick to trigger a layout + iframe.contentWindow.document.body.offsetTop; + + iframe.width = width; + iframe.height = height; + + iframe.contentWindow.document.body.offsetTop; +} + +function injectStylesInIFrame(styleSelector, frameSelector) { + var style = document.querySelector(styleSelector), + frame = document.querySelector(frameSelector); + + frame.contentWindow.addNewStyles(style.textContent); +} + + +if (window.parent != window) { + // we're in an iframe, so expose the bits that allow setting styles inside + window.addNewStyles = function (cssText) { + var styleTag = document.createElement("style"), + textNode = document.createTextNode(cssText); + + styleTag.appendChild(textNode); + document.head.appendChild(styleTag); + } +} \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/vendorPrefix.js b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/vendorPrefix.js new file mode 100644 index 00000000000..6cf3c5a3783 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/support/vendorPrefix.js @@ -0,0 +1,86 @@ +// +// Vendor-Prefix Helper Functions For Testing CSS +// + +(function(root) { +'use strict'; + +var prefixCache = {}; + +// convert "foo-bar" to "fooBar" +function camelCase(str) { + return str.replace(/\-(\w)/g, function(match, letter){ + return letter.toUpperCase(); + }); +} + +// vendor-prefix a css property +root.addVendorPrefix = function (name) { + var prefix = getVendorPrefix(name); + if (prefix === false) { + // property unknown to browser + return name; + } + + return prefix + name; +}; + +// vendor-prefix a css property value +root.addValueVendorPrefix = function (property, value) { + var prefix = getValueVendorPrefix(property, value); + if (prefix === false) { + // property unknown to browser + return name; + } + + return prefix + value; +}; + +// identify vendor-prefix for css property +root.getVendorPrefix = function(name) { + if (prefixCache[name] !== undefined) { + return prefixCache[name]; + } + + var elem = document.createElement("div"); + name = camelCase(name); + + if (name in elem.style) { + return prefixCache[name] = ""; + } + + var prefixes = ["Webkit", "Moz", "O", "ms"]; + var styles = ["-webkit-", "-moz-", "-o-", "-ms-"]; + var _name = name.substring(0, 1).toUpperCase() + name.substring(1); + + for (var i = 0, length = prefixes.length; i < length; i++) { + if (prefixes[i] + _name in elem.style) { + return prefixCache[name] = styles[i]; + } + } + + return prefixCache[name] = name in elem.style ? "" : false; +}; + +// identify vendor-prefix for css property value +root.getValueVendorPrefix = function(property, value) { + var elem = document.createElement("div"); + // note: webkit needs the element to be attached to the dom + document.body.appendChild(elem); + var styles = ["-webkit-", "-moz-", "-o-", "-ms-", ""]; + var _property = getVendorPrefix(property) + property; + for (var i=0, length = styles.length; i < length; i++) { + var _value = styles[i] + value; + elem.setAttribute('style', _property + ": " + _value); + var _computed = computedStyle(elem, _property); + if (_computed && _computed !== 'none') { + document.body.removeChild(elem); + return styles[i]; + } + } + document.body.removeChild(elem); + return false; +}; + + +})(window); \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/toc.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/toc.xht new file mode 100644 index 00000000000..63effef1727 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/toc.xht @@ -0,0 +1,69 @@ + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>CSS Values and Units Module Level 3 CR Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> +<body> + <h1>CSS Values and Units Module Level 3 CR Test Suite By Chapter</h1> + + <p>This index contains both + <a href="http://wiki.csswg.org/test/selftest">self-describing tests</a> + and reftests. + A separate <a href="reftest-toc.xht">alphabetical reftest index</a> + is provided for tests in <a href="http://wiki.csswg.org/test/reftest">reftest + format</a> along with the <a href="reftest.list">reftest manifest</a>.</p> + + <table> + <tbody id="s1"> + <tr><th><a href="chapter-1.xht">Chapter 1 - + Introduction</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s2"> + <tr><th><a href="chapter-2.xht">Chapter 2 - + Value Definition Syntax</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s3"> + <tr><th><a href="chapter-3.xht">Chapter 3 - + Textual Data Types</a></th> + <td>(3 Tests)</td></tr> + </tbody> + <tbody id="s4"> + <tr><th><a href="chapter-4.xht">Chapter 4 - + Numeric Data Types</a></th> + <td>(3 Tests)</td></tr> + </tbody> + <tbody id="s5"> + <tr><th><a href="chapter-5.xht">Chapter 5 - + Distance Units: the <length> type</a></th> + <td>(30 Tests)</td></tr> + </tbody> + <tbody id="s6"> + <tr><th><a href="chapter-6.xht">Chapter 6 - + Other Quantities</a></th> + <td>(2 Tests)</td></tr> + </tbody> + <tbody id="s7"> + <tr><th><a href="chapter-7.xht">Chapter 7 - + Data Types Defined Elsewhere</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s8"> + <tr><th><a href="chapter-8.xht">Chapter 8 - + Functional Notations</a></th> + <td>(32 Tests)</td></tr> + </tbody> + <tbody id="s9"> + <tr><th><a href="chapter-9.xht">Chapter 9 - + Appendix A: IANA Considerations</a></th> + <td>(0 Tests)</td></tr> + </tbody> + </table> +</body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/transition-delay-001.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/transition-delay-001.xht new file mode 100644 index 00000000000..1a00c9b32d1 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/transition-delay-001.xht @@ -0,0 +1,106 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <meta charset="utf-8" /> + <title>CSS Transitions Test: Parsing transition-delay</title> + <meta content="Test checks that transition-delay values are parsed properly" name="assert" /> + <link href="http://www.w3.org/TR/css3-transitions/#transition-delay-property" rel="help" title="2.4. The 'transition-delay' Property" /> + <link href="http://www.w3.org/TR/css3-values/#time" rel="help" title="CSS Values and Units Module Level 3 - 6.2. Times: the โ€˜&lt;time>โ€™ type and โ€˜sโ€™, โ€˜msโ€™ units" /> + <link href="http://rodneyrehm.de/en/" rel="author" title="Rodney Rehm" /> + <meta content="dom" name="flags" /> + + <script src="/resources/testharness.js" type="text/javascript"></script> + <script src="/resources/testharnessreport.js" type="text/javascript"></script> + + <script src="./support/vendorPrefix.js" type="text/javascript"></script> + <script src="./support/helper.js" type="text/javascript"></script> + + <script id="metadata_cache">/* + { + "parse '10.2s'": {}, + "parse '1s'": {}, + "parse '0.1s'": {}, + "parse '0.01s'": {}, + "parse '0.001s'": {}, + "parse '0.009s'": {}, + "parse '0s'": {}, + "parse '.0s'": {}, + "parse '0.0s'": {}, + "parse '.3s'": {}, + "parse '-5s'": {}, + "parse '10200ms'": {}, + "parse '1000ms'": {}, + "parse '100ms'": {}, + "parse '10ms'": {}, + "parse '9ms'": {}, + "parse '1ms'": {}, + "parse '0ms'": {}, + "parse '-500ms'": {}, + "parse '1s, 0.1s, 10ms'": {}, + "parse 'foobar'": { "flags": "invalid" } + } + */</script> + </head> + <body> + <!-- required by testharnessreport.js --> + <div id="log"></div> + <!-- elements used for testing --> + <div id="container"> + <div id="transition"></div> + </div> + + <script> + var transition = document.getElementById('transition'); + // &lt;time&gt; [, &lt;time&gt;]* + var values = { + // seconds + '10.2s': '10.2s', + '1s': '1s', + '0.1s': '0.1s', + '0.01s': '0.01s', + '0.001s': '0.001s', + '0.009s': '0.009s', + '0s': '0s', + '0s': '0s', + '.0s': '0s', + '0.0s': '0s', + '.3s': '0.3s', + '-5s' : '-5s', + // milliseconds + '10200ms': '10.2s', + '1000ms': '1s', + '100ms': '0.1s', + '10ms': '0.01s', + '9ms': '0.009s', + '1ms': '0.001s', + '0ms': '0s', + '-500ms' : '-0.5s', + // combination + '1s, 0.1s, 10ms': '1s, 0.1s, 0.01s', + // invalid + 'foobar': '0s' + }; + + // these tests are supposed to fail and + // possibly make the engine issue a parser warning + var invalidTests = { + 'foobar': true + }; + + for (var key in values) { + if (Object.prototype.hasOwnProperty.call(values, key)) { + test(function() { + setStyle('#transition', { + 'transition-delay': key + }); + var result = computedStyle(transition, 'transition-delay'); + assert_equals(result, values[key], "Expected computed value"); + }, "parse '" + key + "'", + { + // mark tests that fail as such + flags: invalidTests[key] ? "invalid" : "" + }); + } + } + </script> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/transition-duration-001.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/transition-duration-001.xht new file mode 100644 index 00000000000..275b58d7b2c --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/transition-duration-001.xht @@ -0,0 +1,107 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <meta charset="utf-8" /> + <title>CSS Transitions Test: Parsing transition-duration</title> + <meta content="Test checks that transition-duration values are parsed properly" name="assert" /> + <link href="http://www.w3.org/TR/css3-transitions/#transition-duration-property" rel="help" title="2.2. The 'transition-duration' Property" /> + <link href="http://www.w3.org/TR/css3-values/#time" rel="help" title="CSS Values and Units Module Level 3 - 6.2. Times: the โ€˜&lt;time>โ€™ type and โ€˜sโ€™, โ€˜msโ€™ units" /> + <link href="http://rodneyrehm.de/en/" rel="author" title="Rodney Rehm" /> + <meta content="dom" name="flags" /> + + <script src="/resources/testharness.js" type="text/javascript"></script> + <script src="/resources/testharnessreport.js" type="text/javascript"></script> + + <script src="./support/vendorPrefix.js" type="text/javascript"></script> + <script src="./support/helper.js" type="text/javascript"></script> + + <script id="metadata_cache">/* + { + "parse '10.2s'": {}, + "parse '1s'": {}, + "parse '0.1s'": {}, + "parse '0.01s'": {}, + "parse '0.001s'": {}, + "parse '0.009s'": {}, + "parse '0s'": {}, + "parse '.0s'": {}, + "parse '0.0s'": {}, + "parse '.3s'": {}, + "parse '-5s'": { "flags": "invalid" }, + "parse '10200ms'": {}, + "parse '1000ms'": {}, + "parse '100ms'": {}, + "parse '10ms'": {}, + "parse '9ms'": {}, + "parse '1ms'": {}, + "parse '0ms'": {}, + "parse '-500ms'": { "flags": "invalid" }, + "parse '1s, 0.1s, 10ms'": {}, + "parse 'foobar'": { "flags": "invalid" } + } + */</script> + </head> + <body> + <!-- required by testharnessreport.js --> + <div id="log"></div> + <!-- elements used for testing --> + <div id="container"> + <div id="transition"></div> + </div> + + <script> + var transition = document.getElementById('transition'); + // &lt;time&gt; [, &lt;time&gt;]* + var values = { + // seconds + '10.2s': '10.2s', + '1s': '1s', + '0.1s': '0.1s', + '0.01s': '0.01s', + '0.001s': '0.001s', + '0.009s': '0.009s', + '0s': '0s', + '.0s': '0s', + '0.0s': '0s', + '.3s': '0.3s', + '-5s' : '0s', + // milliseconds + '10200ms': '10.2s', + '1000ms': '1s', + '100ms': '0.1s', + '10ms': '0.01s', + '9ms': '0.009s', + '1ms': '0.001s', + '0ms': '0s', + '-500ms' : '0s', + // combination + '1s, 0.1s, 10ms': '1s, 0.1s, 0.01s', + // invalid + 'foobar': '0s' + }; + + // these tests are supposed to fail and + // possibly make the engine issue a parser warning + var invalidTests = { + '-5s': true, + '-500ms': true, + 'foobar': true + }; + + for (var key in values) { + if (Object.prototype.hasOwnProperty.call(values, key)) { + test(function() { + setStyle('#transition', { + 'transition-duration': key + }); + var result = computedStyle(transition, 'transition-duration'); + assert_equals(result, values[key], "Expected computed value"); + }, "parse '" + key + "'", + { + // mark tests that fail as such + flags: invalidTests[key] ? "invalid" : "" + }); + } + } + </script> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-calc-support-pct.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-calc-support-pct.xht new file mode 100644 index 00000000000..35b5a772f90 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-calc-support-pct.xht @@ -0,0 +1,36 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + + <title> + CSS Values and Units Test: + Viewport units are supported inside calc expressions. + </title> + <meta content=" + Check that viewport units add correctly to percentages in calc() expressions + " name="assert" /> + + + <link href="mailto:fremycompany.developer@yahoo.fr" rel="author" title="Fran็ois REMY" /> + + <link href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" rel="help" /> + <link href="http://www.w3.org/TR/css3-values/#calc" rel="help" /> + + <link href="reference/all-green.xht" rel="match" /> + + <style type="text/css"> + + html, body { margin: 0px; padding: 0px; } + + html { background: red; } + #target { position: absolute; background: green; width: calc(100vw + 50%); height: calc(100vh + 50%); top: -50%; left: -50%; } + + </style> + +</head> +<body> + + <div id="target"></div> + + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-calc-support.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-calc-support.xht new file mode 100644 index 00000000000..fcd8260fd4b --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-calc-support.xht @@ -0,0 +1,36 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + + <title> + CSS Values and Units Test: + Viewport units are supported inside calc expressions. + </title> + <meta content=" + Check that viewport units add correctly to pixels in calc() expressions + " name="assert" /> + + + <link href="mailto:fremycompany.developer@yahoo.fr" rel="author" title="Fran็ois REMY" /> + + <link href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" rel="help" /> + <link href="http://www.w3.org/TR/css3-values/#calc" rel="help" /> + + <link href="reference/all-green.xht" rel="match" /> + + <style type="text/css"> + + html, body { margin: 0px; padding: 0px; } + + html { background: red; } + #target { position: absolute; background: green; width: calc(100vw + 50px); height: calc(100vh + 50px); top: -50px; left: -50px; } + + </style> + +</head> +<body> + + <div id="target"></div> + + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-em-inherit.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-em-inherit.xht new file mode 100644 index 00000000000..a99faef4d30 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-em-inherit.xht @@ -0,0 +1,34 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + + <title> + CSS Values and Units Test: + 0vh and 0vw are correctly treated as 0px + </title> + <meta content=" + 0vh and 0vw are correctly treated as 0px + " name="assert" /> + + <link href="mailto:fremycompany.developer@yahoo.fr" rel="author" title="Franรงois REMY" /> + + <link href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" rel="help" /> + + <link href="reference/all-green.xht" rel="match" /> + + <style type="text/css"> + + html, body { margin: 0px; padding: 0px; } + + html { background: red; font-size: 100vw; } + #target { background: green; width: 1rem; height: 1em; font-size: 100vh; } + + </style> + +</head> +<body> + + <div id="target"></div> + + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-inherit.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-inherit.xht new file mode 100644 index 00000000000..df89a9c338f --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-inherit.xht @@ -0,0 +1,35 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + + <title> + CSS Values and Units Test: + Viewport units are inherited properly + </title> + <meta content=" + Viewport units are inherited properly + " name="assert" /> + + <link href="mailto:fremycompany.developer@yahoo.fr" rel="author" title="Franรงois REMY" /> + + <link href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" rel="help" /> + + <link href="reference/all-green.xht" rel="match" /> + + <style type="text/css"> + + html, body { margin: 0px; padding: 0px; } + + html { background: red; } + #outer { position: relative; background: green; width: 50vw; height: 100vh; } + #inner { position: absolute; background: green; left: 100%; width: inherit; height: inherit; } + + </style> + +</head> +<body> + + <div id="outer"><div id="inner"></div></div> + + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-interpolate-pct.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-interpolate-pct.xht new file mode 100644 index 00000000000..1e8c0b817bb --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-interpolate-pct.xht @@ -0,0 +1,41 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + + <title> + CSS Values and Units Test: + Viewport units are interpolated correctly + </title> + <meta content=" + The interpolated size mid-way between 0px and 200vh is 100vh (respectively for vw) + " name="assert" /> + + <link href="mailto:fremycompany.developer@yahoo.fr" rel="author" title="Franรงois REMY" /> + + <link href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" rel="help" /> + <link href="http://www.w3.org/TR/css3-animations/#animations" rel="help" /> + + <link href="reference/all-green.xht" rel="match" /> + + <style type="text/css"> + + @keyframes anim { + from { width: 0%; height: 0%; } + to { width: 200vw; height: 200vh; } + } + + html, body { margin: 0px; padding: 0px; } + + html { background: red; overflow: hidden; } + #outer { position: relative; background: green; } + #outer { animation: anim 2000000s; animation-delay: -1000000s; } + + </style> + +</head> +<body> + + <div id="outer"></div> + + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-interpolate-px.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-interpolate-px.xht new file mode 100644 index 00000000000..ec81223cbb4 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-interpolate-px.xht @@ -0,0 +1,41 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + + <title> + CSS Values and Units Test: + Viewport units are interpolated correctly + </title> + <meta content=" + The interpolated size mid-way between 0px and 200vh is 100vh (respectively for vw) + " name="assert" /> + + <link href="mailto:fremycompany.developer@yahoo.fr" rel="author" title="Franรงois REMY" /> + + <link href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" rel="help" /> + <link href="http://www.w3.org/TR/css3-animations/#animations" rel="help" /> + + <link href="reference/all-green.xht" rel="match" /> + + <style type="text/css"> + + @keyframes anim { + from { width: 0px; height: 0px; } + to { width: 200vw; height: 200vh; } + } + + html, body { margin: 0px; padding: 0px; } + + html { background: red; overflow: hidden; } + #outer { position: relative; background: green; } + #outer { animation: anim 2000000s; animation-delay: -1000000s; } + + </style> + +</head> +<body> + + <div id="outer"></div> + + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-interpolate-vh.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-interpolate-vh.xht new file mode 100644 index 00000000000..88aefecc347 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-interpolate-vh.xht @@ -0,0 +1,41 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + + <title> + CSS Values and Units Test: + Viewport units are interpolated correctly + </title> + <meta content=" + The interpolated size mid-way between 75vh and 125vh is 100vh (respectively for vw) + " name="assert" /> + + <link href="mailto:fremycompany.developer@yahoo.fr" rel="author" title="Franรงois REMY" /> + + <link href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" rel="help" /> + <link href="http://www.w3.org/TR/css3-animations/#animations" rel="help" /> + + <link href="reference/all-green.xht" rel="match" /> + + <style type="text/css"> + + @keyframes anim { + from { width: 75vw; height: 75vh; } + to { width: 125vw; height: 125vh; } + } + + html, body { margin: 0px; padding: 0px; } + + html { background: red; overflow: hidden; } + #outer { position: relative; background: green; } + #outer { animation: anim 2000000s; animation-delay: -1000000s; } + + </style> + +</head> +<body> + + <div id="outer"></div> + + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-support-atviewport.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-support-atviewport.xht new file mode 100644 index 00000000000..e089fd664d4 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-support-atviewport.xht @@ -0,0 +1,37 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + + <title> + CSS Values and Units Test: + Viewports units are supported in @viewport rules + </title> + <meta content=" + Viewports units are supported in @viewport rules + " name="assert" /> + + <link href="mailto:fremycompany.developer@yahoo.fr" rel="author" title="Fran็ois REMY" /> + + <link href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" rel="help" /> + <link href="https://drafts.csswg.org/css-device-adapt-1/" rel="help" /> + + <link href="reference/all-green.xht" rel="match" /> + + <style type="text/css"> + + html, body { margin: 0px; padding: 0px; overflow: hidden; } + + @viewport { width: 1vw; } + + html { background: red; } + #target { background: green; width: 100vw; height: 100vh; } + + </style> + +</head> +<body> + + <div id="target"></div> + + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-support-margin.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-support-margin.xht new file mode 100644 index 00000000000..5a41e1bc307 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-support-margin.xht @@ -0,0 +1,34 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + + <title> + CSS Values and Units Test: + Viewports units are supported in margin properties + </title> + <meta content=" + Viewports units are supported in margin properties + " name="assert" /> + + <link href="mailto:fremycompany.developer@yahoo.fr" rel="author" title="Franรงois REMY" /> + + <link href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" rel="help" /> + + <link href="reference/all-green.xht" rel="match" /> + + <style type="text/css"> + + html, body { margin: 0px; padding: 0px; } + + html { background: green; } + #target { background: red; width: 100%; height: 100%; margin-left: -100vw; margin-top: -100vh; } + + </style> + +</head> +<body> + + <div id="target"></div> + + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-support-transform-origin.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-support-transform-origin.xht new file mode 100644 index 00000000000..6aea46f1810 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-support-transform-origin.xht @@ -0,0 +1,35 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + + <title> + CSS Values and Units Test: + Viewports units are supported in transform properties + </title> + <meta content=" + Viewports units are supported in transform properties + " name="assert" /> + + <link href="mailto:fremycompany.developer@yahoo.fr" rel="author" title="Fran็ois REMY" /> + + <link href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" rel="help" /> + <link href="http://www.w3.org/TR/css3-2d-transforms/#css-values" rel="help" /> + + <link href="reference/all-green.xht" rel="match" /> + + <style type="text/css"> + + html, body { margin: 0px; padding: 0px; overflow: hidden; } + + html { background: green; } + iframe { width: 400px; height: 400px; margin: 0px; padding: 0px; border: 0px none transparent; } + + </style> + +</head> +<body> + + <iframe src="iframe/vh-support-transform-origin.html"></iframe> + + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-support-transform-translate.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-support-transform-translate.xht new file mode 100644 index 00000000000..966eb4f4d5e --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-support-transform-translate.xht @@ -0,0 +1,35 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + + <title> + CSS Values and Units Test: + Viewports units are supported in transform properties + </title> + <meta content=" + Viewports units are supported in transform properties (translate) + " name="assert" /> + + <link href="mailto:fremycompany.developer@yahoo.fr" rel="author" title="Fran็ois REMY" /> + + <link href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" rel="help" /> + <link href="http://www.w3.org/TR/css3-2d-transforms/#css-values" rel="help" /> + + <link href="reference/all-green.xht" rel="match" /> + + <style type="text/css"> + + html, body { margin: 0px; padding: 0px; overflow: hidden; } + + html { background: green; } + iframe { width: 400px; height: 400px; margin: 0px; padding: 0px; border: 0px none transparent; } + + </style> + +</head> +<body> + + <iframe src="iframe/vh-support-transform-translate.html"></iframe> + + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-support.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-support.xht new file mode 100644 index 00000000000..68f7b65d36f --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-support.xht @@ -0,0 +1,32 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + + <title> + CSS Values and Units Test: + Viewports units are supported in sizing properties + </title> + <meta content=" + Viewports units are supported in sizing properties + " name="assert" /> + + <link href="mailto:fremycompany.developer@yahoo.fr" rel="author" title="Franรงois REMY" /> + + <link href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" rel="help" /> + + <link href="reference/all-green.xht" rel="match" /> + + <style type="text/css"> + + html, body { margin: 0px; padding: 0px; } + + #target { background: green; width: 100vw; height: 100vh; } + </style> + +</head> +<body> + + <div id="target"></div> + + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-zero-support.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-zero-support.xht new file mode 100644 index 00000000000..1c304dd7916 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh-zero-support.xht @@ -0,0 +1,34 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + + <title> + CSS Values and Units Test: + 0vh and 0vw are correctly treated as 0px + </title> + <meta content=" + 0vh and 0vw are correctly treated as 0px + " name="assert" /> + + <link href="mailto:fremycompany.developer@yahoo.fr" rel="author" title="Franรงois REMY" /> + + <link href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" rel="help" /> + + <link href="reference/all-green.xht" rel="match" /> + + <style type="text/css"> + + html, body { margin: 0px; padding: 0px; } + + html { background: green; } + #target { background: red; width: 0vw; height: 0vh; } + + </style> + +</head> +<body> + + <div id="target"></div> + + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh_not_refreshing_on_chrome.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh_not_refreshing_on_chrome.xht new file mode 100644 index 00000000000..61263c7baeb --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh_not_refreshing_on_chrome.xht @@ -0,0 +1,52 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<!-- Submitted from TestTWF Paris --><html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Values and Units Test: vh-based dimension doesn't change when the element's other dimension doesn't change.</title> + <link href="mailto:marc@bourlon.com" rel="author" title="Marc Bourlon" /> + <link href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" rel="help" /> + <link href="reference/vh_not_refreshing_on_chrome-ref.xht" rel="match" /> + <meta content="vh-based dimension doesn't change when the element's other dimension doesn't change." name="assert" /> + <!-- This test exhibits a bug for Chrome 19.0.1084.56 / Mac OS X 10.6.8 --> + + <style type="text/css"> + + * { margin: 0; padding: 0; font-family: Arial, Helvetica, sans-serif; font-size: 13px; } + + #frameTest { width: 600px; height: 200px; border: 1px solid #000; } + + </style> + + <script type="text/javascript"> + var height = 200; + + function resizeReference() { + + var frameTest = document.getElementById('frameTest'); + + // let's resize the iframe vertically only, showing that the vh sizes is not updated. + if (height &lt;= 300) { + + //frameTest.style.width = height++ + "px"; + frameTest.style.height = height++ + "px"; + + setTimeout(resizeReference, 10); + + } else { + + // uncomment the next line to see how a width resize triggers a layout recalculation + //frameTest.style.width = (parseInt(window.getComputedStyle(document.getElementById('frameTest'))['width'], 10) + 1) + "px"; + + } + + } + + setTimeout(resizeReference, 10); + </script> + +</head> +<body> + +<iframe src="vh_not_refreshing_on_chrome_iframe.html" id="frameTest" frameborder="0"></iframe> + + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh_not_refreshing_on_chrome_iframe.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh_not_refreshing_on_chrome_iframe.xht new file mode 100644 index 00000000000..c655927ce3a --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/vh_not_refreshing_on_chrome_iframe.xht @@ -0,0 +1,84 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><!-- Submitted from TestTWF Paris --><head> + + <title>CSS Values and Units Test: vh-based dimension doesn't change when the element other dimension doesn't change.</title> + <meta content="vh-based dimension doesn't change when the element other dimension doesn't change. Bug for Chrome 19.0.1084.56 / Mac OS X 10.6.8" name="assert" /> + <link href="mailto:marc@bourlon.com" rel="author" title="Marc Bourlon" /> + <link href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" rel="help" title="5.1.2. Viewport-percentage lengths: the 'vw', 'vh', 'vmin', 'vmax' units" /> + <link href="reference/vh_not_refreshing_on_chrome-ref.xht" rel="match" /> + + <style type="text/css"> + + * { margin: 0; padding: 0; font-family: Arial, Helvetica, sans-serif; font-size: 13px; } + + /* the first test box has its vertical dimension is set to some vh units */ + #testBoxWithVhOnly { background: #F00; width: 60px; height: 20vh; float: left; } + + /* the second test box, with fixed height */ + #testBoxNotGrownHorizontallyByJS { background: #F0F; width: 20vh; height: 60px; float: left; } + + /* third box, changed by using CSS transition */ + #testBoxWithTransition { background: #FF0; width: 20vh; height: 40px; float: left; + transition-property: width, height; + transition-duration: 1.5s; + transition-delay: 0; + } + + /* the reference box, growing in both directions (height by js, width by vh unit */ + #referenceBoxGrownHorizontallyByJS { background: #0F0; width: 20vh; height: 40px; float: left; } + + p { clear: both; margin: 10px 0; } + + </style> + +</head> +<body> + +<p> + All boxes should end up the same size. The green box is the reference one. +</p> + +<div id="testBoxWithVhOnly"></div> +<div id="testBoxNotGrownHorizontallyByJS"></div> +<div id="testBoxWithTransition"></div> +<div id="referenceBoxGrownHorizontallyByJS"></div> + +<script type="text/javascript"> + + // In case this file was opened by mistake, redirects to proper test + if (window.top.location.href === document.location.href) { + + window.top.location.href = "vh_not_refreshing_on_chrome.html"; + + } + + function setDimension(id, dimension, value) { + + var element = document.getElementById(id); + + element.style[dimension] = value + "px"; + + } + + function animate() { + + var viewportHeight = document.documentElement.clientHeight; + + var sizeH = 20; + + var referenceDimension = Math.round(sizeH * viewportHeight / 100); + + setDimension('referenceBoxGrownHorizontallyByJS', 'height', referenceDimension); + + setTimeout(animate, 20); + } + + setTimeout(animate, 20); + + var transitionedTestBoxStyle = document.getElementById('testBoxWithTransition').style; + transitionedTestBoxStyle.height = "60px"; +</script> + + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/viewport-relative-lengths-scaled-viewport.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/viewport-relative-lengths-scaled-viewport.xht new file mode 100644 index 00000000000..cf260482f8a --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/viewport-relative-lengths-scaled-viewport.xht @@ -0,0 +1,48 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><!-- Submitted from TestTWF Paris --><head> + <title>CSS Values and Units Test: Viewport units in scaled viewport</title> + <meta content="viewport relative units scale with viewport." name="assert" /> + <link href="mailto:eae@chromium.org" rel="author" title="Emil A Eklund" /> + <link href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" rel="help" /> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> + <style> + iframe { border: 0; } + </style> + </head> + <body> + <div id="log"></div> + <iframe src="javascript:void(0)" id="testFrame"></iframe> + <script> + test(function() { + var frameElement = document.getElementById('testFrame'); + var frameDocument = frameElement.contentDocument; + + var testElement = frameDocument.createElement('div'); + testElement.style.width = '50vw'; + testElement.style.height = '50vh'; + testElement.style.position = 'absolute'; + testElement.style.left = '0'; + testElement.style.top = '0'; + testElement.style.backgroundColor = 'black'; + frameDocument.body.appendChild(testElement); + + var frameWidth = frameElement.getBoundingClientRect().width; + var frameHeight = frameElement.getBoundingClientRect().height; + for (var i = 1; i &lt;= 200; i++) { + var scale = i / 100; + frameDocument.body.style.transform = 'scale(' + scale + ')'; + var rect = testElement.getBoundingClientRect(); + var actualWidth = rect.width; + var actualHeight = rect.height; + var expectedWidth = frameWidth * scale / 2; + var expectedHeight = frameHeight * scale / 2; + + assert_approx_equals(actualWidth, expectedWidth, 0.1, '50vw at ' + scale + ' scale'); + assert_approx_equals(actualHeight, expectedHeight, 0.1, '50vh at ' + scale + ' scale'); + } + }, 'viewport relative units in scaled viewport'); + </script> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css-values-3_dev/xhtml1/viewport-units-css2-001.xht b/tests/wpt/css-tests/css-values-3_dev/xhtml1/viewport-units-css2-001.xht new file mode 100644 index 00000000000..4feb0c35bf2 --- /dev/null +++ b/tests/wpt/css-tests/css-values-3_dev/xhtml1/viewport-units-css2-001.xht @@ -0,0 +1,255 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + + <title> + CSS Values and Units Test: + Checks viewport units against CSS 2.1 properties and the CSSOM + </title> + <meta content="Testing what happens when one applies and rereads viewport unit lengths to CSS 2.1 properties that accept length values" name="assert" /> + + <link href="mailto:schaepp@gmx.de" rel="author" title="Christian Schaefer" /> + + <!-- You must have at least one spec link, but may have as many as are covered in the test. --> + <!-- Be sure to make the main testing area first in the order --> + <link href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" rel="help" /> + + <!-- testharness inclusion for later submission --> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> + + <!-- testharness fallback for local testing --> + <script> + window.test || document.write('\ + &lt;script src="http://www.w3c-test.org/resources/testharness.js"&gt;&lt;\/script&gt;\ + &lt;script src="http://www.w3c-test.org/resources/testharnessreport.js"&gt;&lt;\/script&gt;\ + '); + </script> + + <style> + + #div { + position: relative; + width: 50vw; + height: 10vw; + background: green; + border: 0 green solid; + font-size: 4vw; + } + + #table td { + border: 1px solid green; + } + + </style> + +</head> +<body> + <div id="log"></div> + + <p> + Checks viewport units. Also re-check with zoom in/out. + </p> + + <div id="div"> + Test the Web Forward! + </div> + + <table id="table"> + <tbody> + <tr> + <td id="td">Test</td> + <td>T</td> + <td>W</td> + <td>F</td> + </tr> + </tbody> + </table> + + <script> + + /* Boilerplate code */ + + var camelize = function (str) { + return str.replace(/\-(\w)/g, function(str, letter){ + return letter.toUpperCase(); + }); + }; + + var retrieveComputedStyle = function(element,property){ + var result = + document + .defaultView + .getComputedStyle(element,null) + .getPropertyValue(property); + + // If there are multiple values, cut down to the first + result = result.split(' ')[0]; + + if(window.console) console.log('Retrieving ' + property + ' property. Result: ' + result); + + return result; + } + + var testit = function(element,vunit,property,expectedResult){ + + element.style[camelize(property)] = '0px'; + element.style[camelize(property)] = lengthAmount + vunit; + + if(window.console) console.log(element.nodeName.toLowerCase() + '.style.' + camelize(property) + ' = ' + lengthAmount + vunit); + + var result = retrieveComputedStyle(element,property); + + // Test against WebKit's getComputedStyle bug, where it does not return absolute values + // As required here: http://www.w3.org/TR/1998/REC-CSS2-19980512/cascade.html#computed-value + // If it returns a pixel value, but this value is 0px then it is considered a fail, too. + var px_result = result.search(/^[-\d\.]+px$/) !== -1 &amp;&amp; result !== '0px' ? 'non-zero px-based value' : result; + + // If browser returns pixel value, we compare against our expected pixel value + if(px_result === 'non-zero px-based value'){ + test(function(){ + assert_equals(Math.round(parseFloat(result.replace(/[^-\d\.]+/g,''))),expectedResult); + },vunit + ' length applied to ' + property); + } + // If not, we compare against the value we set initially + else { + test(function(){ + assert_equals(result,lengthAmount + vunit); + },vunit + ' length applied to ' + property); + } + + // Does the browser have a bug in getComputedStyle or not? + test(function(){ + assert_equals(px_result,'non-zero px-based value'); + },vunit + ' length applied to ' + property + ': getComputedStyle returns a non-zero px-based value'); + + element.style[camelize(property)] = ''; + } + + var lengthAmount = 10; + var layoutViewportWidth = document.documentElement.clientWidth; + var layoutViewportHeight = document.documentElement.clientHeight; + + var viewportUnits = [ + { + ident: 'vw', + expectedResult: Math.round(layoutViewportWidth * (lengthAmount / 100)) + } + ,{ + ident: 'vh', + expectedResult: Math.round(layoutViewportHeight * (lengthAmount / 100)) + } + ,{ + ident: 'vmin', + expectedResult: layoutViewportWidth &amp;lt; layoutViewportHeight ? Math.round(layoutViewportWidth * (lengthAmount / 100)) : Math.round(layoutViewportHeight * (lengthAmount / 100)) + } + ,{ + ident: 'vmax', + expectedResult: layoutViewportWidth &amp;gt; layoutViewportHeight ? Math.round(layoutViewportWidth * (lengthAmount / 100)) : Math.round(layoutViewportHeight * (lengthAmount / 100)) + } + ] + + // List of length accepting properties and which element they map to + // http://www.w3.org/TR/CSS21/propidx.html + var lengthAcceptingProperties = [ + { + name: 'width', + element: 'div' + } + ,{ + name: 'height', + element: 'div' + } + ,{ + name: 'min-width', + element: 'div' + } + ,{ + name: 'min-height', + element: 'div' + } + ,{ + name: 'max-width', + element: 'div' + } + ,{ + name: 'max-height', + element: 'div' + } + ,{ + name: 'margin-top', + element: 'div' + } + ,{ + name: 'padding-top', + element: 'div' + } + ,{ + name: 'border-top-width', + element: 'div' + } + ,{ + name: 'font-size', + element: 'div' + } + ,{ + name: 'line-height', + element: 'div' + } + ,{ + name: 'border-spacing', + element: 'table' + } + ,{ + name: 'top', + element: 'div' + } + ,{ + name: 'right', + element: 'div' + } + ,{ + name: 'bottom', + element: 'div' + } + ,{ + name: 'left', + element: 'div' + } + ,{ + name: 'letter-spacing', + element: 'div' + } + ,{ + name: 'text-indent', + element: 'div' + } + ,{ + name: 'vertical-align', + element: 'td' + } + ,{ + name: 'word-spacing', + element: 'div' + } + ]; + + var div = document.getElementById('div'); + var table = document.getElementById('table'); + var td = document.getElementById('td'); + + for(unitEntry in viewportUnits){ + for(propertyEntry in lengthAcceptingProperties){ + + var vunit = viewportUnits[unitEntry].ident; + var expectedResult = viewportUnits[unitEntry].expectedResult; + var property = lengthAcceptingProperties[propertyEntry].name; + var element = window[lengthAcceptingProperties[propertyEntry].element]; + + testit(element,vunit,property,expectedResult); + } + } + + </script> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css21_dev/html4/before-after-selector-001.htm b/tests/wpt/css-tests/css21_dev/html4/before-after-selector-001.htm index 0cfb66e420b..2a2c211ead4 100644 --- a/tests/wpt/css-tests/css21_dev/html4/before-after-selector-001.htm +++ b/tests/wpt/css-tests/css21_dev/html4/before-after-selector-001.htm @@ -4,6 +4,7 @@ <title>CSS Test: After and before pseudo-elements</title> <link rel="author" title="Microsoft" href="http://www.microsoft.com/"> <link rel="help" href="http://www.w3.org/TR/CSS21/selector.html#before-and-after"> + <link rel="match" href="reference/before-after-selector-001-ref.htm"> <meta name="flags" content=""> <meta name="assert" content="After and before pseudo-element allows inserted text after or before a given element."> <style type="text/css"> diff --git a/tests/wpt/css-tests/css21_dev/html4/chapter-5.htm b/tests/wpt/css-tests/css21_dev/html4/chapter-5.htm index 4350dac3f3a..3a54f05f7bd 100644 --- a/tests/wpt/css-tests/css21_dev/html4/chapter-5.htm +++ b/tests/wpt/css-tests/css21_dev/html4/chapter-5.htm @@ -1790,7 +1790,7 @@ <tr id="lang-selector-001-5.11.4" class="primary"> <td><strong> <a href="lang-selector-001.htm">lang-selector-001</a></strong></td> - <td></td> + <td><a href="reference/lang-selector-001-ref.htm">=</a> </td> <td></td> <td>Selectors :lang pseudo-class <ul class="assert"> @@ -7557,7 +7557,7 @@ <tr id="before-after-selector-001-5.12.3" class="primary"> <td><strong> <a href="before-after-selector-001.htm">before-after-selector-001</a></strong></td> - <td></td> + <td><a href="reference/before-after-selector-001-ref.htm">=</a> </td> <td></td> <td>After and before pseudo-elements <ul class="assert"> diff --git a/tests/wpt/css-tests/css21_dev/html4/lang-selector-001.htm b/tests/wpt/css-tests/css21_dev/html4/lang-selector-001.htm index 70d0ebdadd9..a49013e0605 100644 --- a/tests/wpt/css-tests/css21_dev/html4/lang-selector-001.htm +++ b/tests/wpt/css-tests/css21_dev/html4/lang-selector-001.htm @@ -4,6 +4,7 @@ <title>CSS Test: Selectors :lang pseudo-class</title> <link rel="author" title="Microsoft" href="http://www.microsoft.com/"> <link rel="help" href="http://www.w3.org/TR/CSS21/selector.html#lang"> + <link rel="match" href="reference/lang-selector-001-ref.htm"> <meta name="flags" content=""> <meta name="assert" content="The :lang pseudo-class selector matches any element with a matching lang attribute."> <style type="text/css"> diff --git a/tests/wpt/css-tests/css21_dev/html4/reference/before-after-selector-001-ref.htm b/tests/wpt/css-tests/css21_dev/html4/reference/before-after-selector-001-ref.htm new file mode 100644 index 00000000000..90d8d13db5b --- /dev/null +++ b/tests/wpt/css-tests/css21_dev/html4/reference/before-after-selector-001-ref.htm @@ -0,0 +1,16 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> +<html> +<head> +<title>CSS Reftest Reference</title> +<link rel="author" title="Ms2ger" href="mailto:Ms2ger@gmail.com"> +<style type="text/css"> +div { + color: green; +} +</style> +</head> +<body> +<p>Test passes if the "Filler Text" below is green.</p> +<div>Filler Text Filler Text</div> +</body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css21_dev/html4/reference/lang-selector-001-ref.htm b/tests/wpt/css-tests/css21_dev/html4/reference/lang-selector-001-ref.htm new file mode 100644 index 00000000000..fa170728956 --- /dev/null +++ b/tests/wpt/css-tests/css21_dev/html4/reference/lang-selector-001-ref.htm @@ -0,0 +1,18 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> +<html> +<head> +<title>CSS Reftest Reference</title> +<link rel="author" title="Ms2ger" href="mailto:Ms2ger@gmail.com"> +<style type="text/css"> +.green { + color: green; +} +</style> +</head> +<body> +<p>Test passes if only the first line of "Filler Text" below is green.</p> +<p class="green">Filler Text</p> +<p>Filler Text</p> +<div>Filler Text</div> +</body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css21_dev/html4/reftest-toc.htm b/tests/wpt/css-tests/css21_dev/html4/reftest-toc.htm index ea0ec95a63d..453a9ee78b0 100644 --- a/tests/wpt/css-tests/css21_dev/html4/reftest-toc.htm +++ b/tests/wpt/css-tests/css21_dev/html4/reftest-toc.htm @@ -8264,6 +8264,14 @@ <td rowspan="1"></td> </tr> </tbody> + <tbody id="before-after-selector-001" class=""> + <tr> + <td rowspan="1" title="After and before pseudo-elements"> + <a href="before-after-selector-001.htm">before-after-selector-001</a></td> + <td><a href="reference/before-after-selector-001-ref.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> <tbody id="before-after-table-parts-001" class=""> <tr> <td rowspan="1" title="generated content"> @@ -30372,6 +30380,14 @@ <td rowspan="1"></td> </tr> </tbody> + <tbody id="lang-selector-001" class=""> + <tr> + <td rowspan="1" title="Selectors :lang pseudo-class"> + <a href="lang-selector-001.htm">lang-selector-001</a></td> + <td><a href="reference/lang-selector-001-ref.htm">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> <tbody id="lang-selector-002" class="invalid"> <tr> <td rowspan="1" title="Empty :lang selector"> diff --git a/tests/wpt/css-tests/css21_dev/html4/reftest.list b/tests/wpt/css-tests/css21_dev/html4/reftest.list index e9714b258d4..3637397eefd 100644 --- a/tests/wpt/css-tests/css21_dev/html4/reftest.list +++ b/tests/wpt/css-tests/css21_dev/html4/reftest.list @@ -1063,6 +1063,7 @@ before-after-dynamic-restyle-001.htm == reference/before-after-dynamic-restyle-0 before-after-floated-001.htm == reference/before-after-floated-001-ref.htm before-after-images-001.htm == reference/before-after-images-001-ref.htm before-after-positioned-001.htm == reference/before-after-positioned-001-ref.htm +before-after-selector-001.htm == reference/before-after-selector-001-ref.htm before-after-table-parts-001.htm == reference/before-after-table-parts-001-ref.htm before-after-table-whitespace-001.htm == reference/before-after-table-whitespace-001-ref.htm before-content-display-001.htm == reference/after-content-display-001-ref.htm @@ -3848,6 +3849,7 @@ invalid-decl-at-rule-001.htm == reference/filler-text-below-green.htm invalid-decl-at-rule-002.htm == reference/filler-text-below-green.htm keywords-000.htm == reference/ref-green-background.htm keywords-001.htm == reference/keywords-001-ref.htm +lang-selector-001.htm == reference/lang-selector-001-ref.htm lang-selector-002.htm == reference/no-red-filler-text-ref.htm lang-selector-003.htm == reference/filler-text-below-green.htm leading-001.htm == reference/leading-001-ref.htm diff --git a/tests/wpt/css-tests/css21_dev/implementation-report-TEMPLATE.data b/tests/wpt/css-tests/css21_dev/implementation-report-TEMPLATE.data index 0cfae189d1b..b407fe76f88 100644 --- a/tests/wpt/css-tests/css21_dev/implementation-report-TEMPLATE.data +++ b/tests/wpt/css-tests/css21_dev/implementation-report-TEMPLATE.data @@ -2763,8 +2763,8 @@ html4/before-after-images-001.htm 23fb7143075f3176a02f65f2007270c735d26c7c ? xhtml1/before-after-images-001.xht 23fb7143075f3176a02f65f2007270c735d26c7c ? html4/before-after-positioned-001.htm d4b2c18aa9fd31a85b81c096236a24365ce08cb6 ? xhtml1/before-after-positioned-001.xht d4b2c18aa9fd31a85b81c096236a24365ce08cb6 ? -html4/before-after-selector-001.htm 3846e3a87d0d3df404ba8f07bffc39e1635722ed ? -xhtml1/before-after-selector-001.xht 3846e3a87d0d3df404ba8f07bffc39e1635722ed ? +html4/before-after-selector-001.htm e2d0e8fbd8f430c8b9465e8b069146ea5307db80 ? +xhtml1/before-after-selector-001.xht e2d0e8fbd8f430c8b9465e8b069146ea5307db80 ? html4/before-after-table-parts-001.htm 482090b305a6e97d70fc9782761a7e83cff3f936 ? xhtml1/before-after-table-parts-001.xht 482090b305a6e97d70fc9782761a7e83cff3f936 ? html4/before-after-table-whitespace-001.htm 7733835a7bcac98b89c7bb95ca28052944415826 ? @@ -13016,8 +13016,8 @@ html4/keywords-001.htm 13c37f2ae37cf36c4c63e048fda5b7e634131c79 ? xhtml1/keywords-001.xht 13c37f2ae37cf36c4c63e048fda5b7e634131c79 ? html4/lang-pseudoclass-001.htm 8c18cfa29028ff4f8dc0f6c8bbcb47aa62b41176 ? xhtml1/lang-pseudoclass-002.xht 7ff7a233c03f8673acf91b885456e645211ffc3d ? -html4/lang-selector-001.htm c62deff2754cdf81bc55ed4873786125c1378759 ? -xhtml1/lang-selector-001.xht c62deff2754cdf81bc55ed4873786125c1378759 ? +html4/lang-selector-001.htm 2cc3bcad14d2ae93e81330e70b355dc2d29fa55f ? +xhtml1/lang-selector-001.xht 2cc3bcad14d2ae93e81330e70b355dc2d29fa55f ? html4/lang-selector-002.htm b7b03b42293d2980dc7fe0c42c76fe4e42cf7b3f ? xhtml1/lang-selector-002.xht b7b03b42293d2980dc7fe0c42c76fe4e42cf7b3f ? html4/lang-selector-003.htm 6d29a53202efa69fd5ea4e147503c16d1b6510fc ? diff --git a/tests/wpt/css-tests/css21_dev/testinfo.data b/tests/wpt/css-tests/css21_dev/testinfo.data index bd01aad2201..a98c0a09950 100644 --- a/tests/wpt/css-tests/css21_dev/testinfo.data +++ b/tests/wpt/css-tests/css21_dev/testinfo.data @@ -1399,7 +1399,7 @@ before-after-dynamic-restyle-001 reference/before-after-dynamic-restyle-001-ref before-after-floated-001 reference/before-after-floated-001-ref generated content http://www.w3.org/TR/CSS21/generate.html#before-after-content 6fb70f083086a1093ed838ae95b64b8da117f9ff `Robert O'Callahan`<mailto:robert@ocallahan.org>,`Mozilla Corporation`<http://mozilla.com/> before-after-images-001 reference/before-after-images-001-ref generated content http://www.w3.org/TR/CSS21/generate.html#content 23fb7143075f3176a02f65f2007270c735d26c7c `Robert O'Callahan`<mailto:robert@ocallahan.org>,`Mozilla Corporation`<http://mozilla.com/> before-after-positioned-001 reference/before-after-positioned-001-ref generated content http://www.w3.org/TR/CSS21/generate.html#before-after-content d4b2c18aa9fd31a85b81c096236a24365ce08cb6 `Robert O'Callahan`<mailto:robert@ocallahan.org>,`Mozilla Corporation`<http://mozilla.com/> -before-after-selector-001 After and before pseudo-elements http://www.w3.org/TR/CSS21/selector.html#before-and-after 3846e3a87d0d3df404ba8f07bffc39e1635722ed `Microsoft`<http://www.microsoft.com/> After and before pseudo-element allows inserted text after or before a given element. +before-after-selector-001 reference/before-after-selector-001-ref After and before pseudo-elements http://www.w3.org/TR/CSS21/selector.html#before-and-after e2d0e8fbd8f430c8b9465e8b069146ea5307db80 `Microsoft`<http://www.microsoft.com/> After and before pseudo-element allows inserted text after or before a given element. before-after-table-parts-001 reference/before-after-table-parts-001-ref generated content http://www.w3.org/TR/CSS21/generate.html#before-after-content 482090b305a6e97d70fc9782761a7e83cff3f936 `Robert O'Callahan`<mailto:robert@ocallahan.org>,`Mozilla Corporation`<http://mozilla.com/> before-after-table-whitespace-001 reference/before-after-table-whitespace-001-ref generated content http://www.w3.org/TR/CSS21/generate.html#content 7733835a7bcac98b89c7bb95ca28052944415826 `Robert O'Callahan`<mailto:robert@ocallahan.org>,`Mozilla Corporation`<http://mozilla.com/> before-content-display-001 reference/after-content-display-001-ref :before generated content - display inline http://www.w3.org/TR/CSS21/generate.html#before-after-content,http://www.w3.org/TR/CSS21/visuren.html#display-prop 85a13608b3a68389d0dd8c734709829c98a0da39 `G&eacute;rard Talbot`<http://www.gtalbot.org/BrowserBugsSection/css21testsuite/> Generated content can have their own display value explicitly set in which case they behave as if they were real elements inserted just inside their associated element. @@ -6543,7 +6543,7 @@ keywords-000 reference/ref-green-background Keywords v. Strings (background) ht keywords-001 reference/keywords-001-ref Keywords v. Strings (width) http://www.w3.org/TR/CSS21/syndata.html#keywords 13c37f2ae37cf36c4c63e048fda5b7e634131c79 `L. David Baron`<http://dbaron.org/> lang-pseudoclass-001 :lang pseudoclass HTMLonly http://www.w3.org/TR/CSS21/selector.html#lang 8c18cfa29028ff4f8dc0f6c8bbcb47aa62b41176 `Richard Ishida`<mailto:ishida@w3.org>,`Eira Monstad, Opera Software ASA`<mailto:public-testsuites@opera.com> :lang pseudoclass in HTML should not be case-sensitive, and match a substring lang-pseudoclass-002 :lang pseudoclass nonHTML http://www.w3.org/TR/CSS21/selector.html#lang 7ff7a233c03f8673acf91b885456e645211ffc3d `Richard Ishida`<mailto:ishida@w3.org>,`Eira Monstad, Opera Software ASA`<mailto:public-testsuites@opera.com> :lang pseudoclass in XHTML should be case sensitive, and match a substring -lang-selector-001 Selectors :lang pseudo-class http://www.w3.org/TR/CSS21/selector.html#lang c62deff2754cdf81bc55ed4873786125c1378759 `Microsoft`<http://www.microsoft.com/> The :lang pseudo-class selector matches any element with a matching lang attribute. +lang-selector-001 reference/lang-selector-001-ref Selectors :lang pseudo-class http://www.w3.org/TR/CSS21/selector.html#lang 2cc3bcad14d2ae93e81330e70b355dc2d29fa55f `Microsoft`<http://www.microsoft.com/> The :lang pseudo-class selector matches any element with a matching lang attribute. lang-selector-002 reference/no-red-filler-text-ref Empty :lang selector invalid http://www.w3.org/TR/CSS21/selector.html#lang b7b03b42293d2980dc7fe0c42c76fe4e42cf7b3f `Microsoft`<http://www.microsoft.com/> Language identifier cannot be empty. lang-selector-003 reference/filler-text-below-green Invalid language name for :lang selector http://www.w3.org/TR/CSS21/selector.html#lang 6d29a53202efa69fd5ea4e147503c16d1b6510fc `Microsoft`<http://www.microsoft.com/> The language identifier in the :lang selector doesn't have to be a valid language name. lang-selector-004 Inherited lang attribute selected http://www.w3.org/TR/CSS21/selector.html#lang bee7dce082d7e5861d28582e0ea9d2cf5733bcf2 `Microsoft`<http://www.microsoft.com/> Lang attribute is inherited and lang selector works on children. diff --git a/tests/wpt/css-tests/css21_dev/xhtml1/before-after-selector-001.xht b/tests/wpt/css-tests/css21_dev/xhtml1/before-after-selector-001.xht index 88fb2c2b9a0..289474f7a8b 100644 --- a/tests/wpt/css-tests/css21_dev/xhtml1/before-after-selector-001.xht +++ b/tests/wpt/css-tests/css21_dev/xhtml1/before-after-selector-001.xht @@ -4,6 +4,7 @@ <title>CSS Test: After and before pseudo-elements</title> <link rel="author" title="Microsoft" href="http://www.microsoft.com/" /> <link rel="help" href="http://www.w3.org/TR/CSS21/selector.html#before-and-after" /> + <link rel="match" href="reference/before-after-selector-001-ref.xht" /> <meta name="flags" content="" /> <meta name="assert" content="After and before pseudo-element allows inserted text after or before a given element." /> <style type="text/css"> diff --git a/tests/wpt/css-tests/css21_dev/xhtml1/chapter-5.xht b/tests/wpt/css-tests/css21_dev/xhtml1/chapter-5.xht index 886f36341b5..73a3077fecc 100644 --- a/tests/wpt/css-tests/css21_dev/xhtml1/chapter-5.xht +++ b/tests/wpt/css-tests/css21_dev/xhtml1/chapter-5.xht @@ -1768,7 +1768,7 @@ <tr id="lang-selector-001-5.11.4" class="primary"> <td><strong> <a href="lang-selector-001.xht">lang-selector-001</a></strong></td> - <td></td> + <td><a href="reference/lang-selector-001-ref.xht">=</a> </td> <td></td> <td>Selectors :lang pseudo-class <ul class="assert"> @@ -7535,7 +7535,7 @@ <tr id="before-after-selector-001-5.12.3" class="primary"> <td><strong> <a href="before-after-selector-001.xht">before-after-selector-001</a></strong></td> - <td></td> + <td><a href="reference/before-after-selector-001-ref.xht">=</a> </td> <td></td> <td>After and before pseudo-elements <ul class="assert"> diff --git a/tests/wpt/css-tests/css21_dev/xhtml1/lang-selector-001.xht b/tests/wpt/css-tests/css21_dev/xhtml1/lang-selector-001.xht index f884c9f97f6..0625491b71f 100644 --- a/tests/wpt/css-tests/css21_dev/xhtml1/lang-selector-001.xht +++ b/tests/wpt/css-tests/css21_dev/xhtml1/lang-selector-001.xht @@ -4,6 +4,7 @@ <title>CSS Test: Selectors :lang pseudo-class</title> <link rel="author" title="Microsoft" href="http://www.microsoft.com/" /> <link rel="help" href="http://www.w3.org/TR/CSS21/selector.html#lang" /> + <link rel="match" href="reference/lang-selector-001-ref.xht" /> <meta name="flags" content="" /> <meta name="assert" content="The :lang pseudo-class selector matches any element with a matching lang attribute." /> <style type="text/css"> diff --git a/tests/wpt/css-tests/css21_dev/xhtml1/reference/before-after-selector-001-ref.xht b/tests/wpt/css-tests/css21_dev/xhtml1/reference/before-after-selector-001-ref.xht new file mode 100644 index 00000000000..9ae8a6299df --- /dev/null +++ b/tests/wpt/css-tests/css21_dev/xhtml1/reference/before-after-selector-001-ref.xht @@ -0,0 +1,16 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> +<head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> +<title>CSS Reftest Reference</title> +<link rel="author" title="Ms2ger" href="mailto:Ms2ger@gmail.com" /> +<style type="text/css"> +div { + color: green; +} +</style> +</head> +<body> +<p>Test passes if the "Filler Text" below is green.</p> +<div>Filler Text Filler Text</div> +</body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css21_dev/xhtml1/reference/lang-selector-001-ref.xht b/tests/wpt/css-tests/css21_dev/xhtml1/reference/lang-selector-001-ref.xht new file mode 100644 index 00000000000..fa8615a2943 --- /dev/null +++ b/tests/wpt/css-tests/css21_dev/xhtml1/reference/lang-selector-001-ref.xht @@ -0,0 +1,18 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> +<head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> +<title>CSS Reftest Reference</title> +<link rel="author" title="Ms2ger" href="mailto:Ms2ger@gmail.com" /> +<style type="text/css"> +.green { + color: green; +} +</style> +</head> +<body> +<p>Test passes if only the first line of "Filler Text" below is green.</p> +<p class="green">Filler Text</p> +<p>Filler Text</p> +<div>Filler Text</div> +</body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css21_dev/xhtml1/reftest-toc.xht b/tests/wpt/css-tests/css21_dev/xhtml1/reftest-toc.xht index f5ef94eede8..d72e0c009c2 100644 --- a/tests/wpt/css-tests/css21_dev/xhtml1/reftest-toc.xht +++ b/tests/wpt/css-tests/css21_dev/xhtml1/reftest-toc.xht @@ -8480,6 +8480,14 @@ <td rowspan="1"></td> </tr> </tbody> + <tbody id="before-after-selector-001" class=""> + <tr> + <td rowspan="1" title="After and before pseudo-elements"> + <a href="before-after-selector-001.xht">before-after-selector-001</a></td> + <td><a href="reference/before-after-selector-001-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> <tbody id="before-after-table-parts-001" class=""> <tr> <td rowspan="1" title="generated content"> @@ -30724,6 +30732,14 @@ <td rowspan="1"></td> </tr> </tbody> + <tbody id="lang-selector-001" class=""> + <tr> + <td rowspan="1" title="Selectors :lang pseudo-class"> + <a href="lang-selector-001.xht">lang-selector-001</a></td> + <td><a href="reference/lang-selector-001-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> <tbody id="lang-selector-002" class="invalid"> <tr> <td rowspan="1" title="Empty :lang selector"> diff --git a/tests/wpt/css-tests/css21_dev/xhtml1/reftest.list b/tests/wpt/css-tests/css21_dev/xhtml1/reftest.list index 134ba30bee7..544f0a7a9a8 100644 --- a/tests/wpt/css-tests/css21_dev/xhtml1/reftest.list +++ b/tests/wpt/css-tests/css21_dev/xhtml1/reftest.list @@ -1063,6 +1063,7 @@ before-after-dynamic-restyle-001.xht == reference/before-after-dynamic-restyle-0 before-after-floated-001.xht == reference/before-after-floated-001-ref.xht before-after-images-001.xht == reference/before-after-images-001-ref.xht before-after-positioned-001.xht == reference/before-after-positioned-001-ref.xht +before-after-selector-001.xht == reference/before-after-selector-001-ref.xht before-after-table-parts-001.xht == reference/before-after-table-parts-001-ref.xht before-after-table-whitespace-001.xht == reference/before-after-table-whitespace-001-ref.xht before-content-display-001.xht == reference/after-content-display-001-ref.xht @@ -3848,6 +3849,7 @@ invalid-decl-at-rule-001.xht == reference/filler-text-below-green.xht invalid-decl-at-rule-002.xht == reference/filler-text-below-green.xht keywords-000.xht == reference/ref-green-background.xht keywords-001.xht == reference/keywords-001-ref.xht +lang-selector-001.xht == reference/lang-selector-001-ref.xht lang-selector-002.xht == reference/no-red-filler-text-ref.xht lang-selector-003.xht == reference/filler-text-below-green.xht leading-001.xht == reference/leading-001-ref.xht diff --git a/tests/wpt/css-tests/css21_dev/xhtml1print/before-after-selector-001.xht b/tests/wpt/css-tests/css21_dev/xhtml1print/before-after-selector-001.xht index 6daa01fcbb4..4483cb18055 100644 --- a/tests/wpt/css-tests/css21_dev/xhtml1print/before-after-selector-001.xht +++ b/tests/wpt/css-tests/css21_dev/xhtml1print/before-after-selector-001.xht @@ -13,6 +13,7 @@ </style> <link rel="author" title="Microsoft" href="http://www.microsoft.com/" /> <link rel="help" href="http://www.w3.org/TR/CSS21/selector.html#before-and-after" /> + <link rel="match" href="reference/before-after-selector-001-ref.xht" /> <meta name="flags" content="" /> <meta name="assert" content="After and before pseudo-element allows inserted text after or before a given element." /> <style type="text/css"> diff --git a/tests/wpt/css-tests/css21_dev/xhtml1print/chapter-5.xht b/tests/wpt/css-tests/css21_dev/xhtml1print/chapter-5.xht index 886f36341b5..73a3077fecc 100644 --- a/tests/wpt/css-tests/css21_dev/xhtml1print/chapter-5.xht +++ b/tests/wpt/css-tests/css21_dev/xhtml1print/chapter-5.xht @@ -1768,7 +1768,7 @@ <tr id="lang-selector-001-5.11.4" class="primary"> <td><strong> <a href="lang-selector-001.xht">lang-selector-001</a></strong></td> - <td></td> + <td><a href="reference/lang-selector-001-ref.xht">=</a> </td> <td></td> <td>Selectors :lang pseudo-class <ul class="assert"> @@ -7535,7 +7535,7 @@ <tr id="before-after-selector-001-5.12.3" class="primary"> <td><strong> <a href="before-after-selector-001.xht">before-after-selector-001</a></strong></td> - <td></td> + <td><a href="reference/before-after-selector-001-ref.xht">=</a> </td> <td></td> <td>After and before pseudo-elements <ul class="assert"> diff --git a/tests/wpt/css-tests/css21_dev/xhtml1print/lang-selector-001.xht b/tests/wpt/css-tests/css21_dev/xhtml1print/lang-selector-001.xht index e90b2ec3347..87d9d32a1b2 100644 --- a/tests/wpt/css-tests/css21_dev/xhtml1print/lang-selector-001.xht +++ b/tests/wpt/css-tests/css21_dev/xhtml1print/lang-selector-001.xht @@ -13,6 +13,7 @@ </style> <link rel="author" title="Microsoft" href="http://www.microsoft.com/" /> <link rel="help" href="http://www.w3.org/TR/CSS21/selector.html#lang" /> + <link rel="match" href="reference/lang-selector-001-ref.xht" /> <meta name="flags" content="" /> <meta name="assert" content="The :lang pseudo-class selector matches any element with a matching lang attribute." /> <style type="text/css"> diff --git a/tests/wpt/css-tests/css21_dev/xhtml1print/reference/before-after-selector-001-ref.xht b/tests/wpt/css-tests/css21_dev/xhtml1print/reference/before-after-selector-001-ref.xht new file mode 100644 index 00000000000..ab871e330ef --- /dev/null +++ b/tests/wpt/css-tests/css21_dev/xhtml1print/reference/before-after-selector-001-ref.xht @@ -0,0 +1,25 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> +<head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> +<title>CSS Reftest Reference</title> + <style type="text/css"> + @page { font: italic 8pt sans-serif; color: gray; + margin: 7%; + counter-increment: page; + @top-left { content: "CSS 2.1 Conformance Test Suite"; } + @top-right { content: "Test before-after-selector-001-ref"; } + @bottom-right { content: counter(page); } + } +</style> +<link rel="author" title="Ms2ger" href="mailto:Ms2ger@gmail.com" /> +<style type="text/css"> +div { + color: green; +} +</style> +</head> +<body> +<p>Test passes if the "Filler Text" below is green.</p> +<div>Filler Text Filler Text</div> +</body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css21_dev/xhtml1print/reference/lang-selector-001-ref.xht b/tests/wpt/css-tests/css21_dev/xhtml1print/reference/lang-selector-001-ref.xht new file mode 100644 index 00000000000..d66f1edea44 --- /dev/null +++ b/tests/wpt/css-tests/css21_dev/xhtml1print/reference/lang-selector-001-ref.xht @@ -0,0 +1,27 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> +<head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> +<title>CSS Reftest Reference</title> + <style type="text/css"> + @page { font: italic 8pt sans-serif; color: gray; + margin: 7%; + counter-increment: page; + @top-left { content: "CSS 2.1 Conformance Test Suite"; } + @top-right { content: "Test lang-selector-001-ref"; } + @bottom-right { content: counter(page); } + } +</style> +<link rel="author" title="Ms2ger" href="mailto:Ms2ger@gmail.com" /> +<style type="text/css"> +.green { + color: green; +} +</style> +</head> +<body> +<p>Test passes if only the first line of "Filler Text" below is green.</p> +<p class="green">Filler Text</p> +<p>Filler Text</p> +<div>Filler Text</div> +</body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/css21_dev/xhtml1print/reftest-toc.xht b/tests/wpt/css-tests/css21_dev/xhtml1print/reftest-toc.xht index f5ef94eede8..d72e0c009c2 100644 --- a/tests/wpt/css-tests/css21_dev/xhtml1print/reftest-toc.xht +++ b/tests/wpt/css-tests/css21_dev/xhtml1print/reftest-toc.xht @@ -8480,6 +8480,14 @@ <td rowspan="1"></td> </tr> </tbody> + <tbody id="before-after-selector-001" class=""> + <tr> + <td rowspan="1" title="After and before pseudo-elements"> + <a href="before-after-selector-001.xht">before-after-selector-001</a></td> + <td><a href="reference/before-after-selector-001-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> <tbody id="before-after-table-parts-001" class=""> <tr> <td rowspan="1" title="generated content"> @@ -30724,6 +30732,14 @@ <td rowspan="1"></td> </tr> </tbody> + <tbody id="lang-selector-001" class=""> + <tr> + <td rowspan="1" title="Selectors :lang pseudo-class"> + <a href="lang-selector-001.xht">lang-selector-001</a></td> + <td><a href="reference/lang-selector-001-ref.xht">=</a> </td> + <td rowspan="1"></td> + </tr> + </tbody> <tbody id="lang-selector-002" class="invalid"> <tr> <td rowspan="1" title="Empty :lang selector"> diff --git a/tests/wpt/css-tests/css21_dev/xhtml1print/reftest.list b/tests/wpt/css-tests/css21_dev/xhtml1print/reftest.list index 134ba30bee7..544f0a7a9a8 100644 --- a/tests/wpt/css-tests/css21_dev/xhtml1print/reftest.list +++ b/tests/wpt/css-tests/css21_dev/xhtml1print/reftest.list @@ -1063,6 +1063,7 @@ before-after-dynamic-restyle-001.xht == reference/before-after-dynamic-restyle-0 before-after-floated-001.xht == reference/before-after-floated-001-ref.xht before-after-images-001.xht == reference/before-after-images-001-ref.xht before-after-positioned-001.xht == reference/before-after-positioned-001-ref.xht +before-after-selector-001.xht == reference/before-after-selector-001-ref.xht before-after-table-parts-001.xht == reference/before-after-table-parts-001-ref.xht before-after-table-whitespace-001.xht == reference/before-after-table-whitespace-001-ref.xht before-content-display-001.xht == reference/after-content-display-001-ref.xht @@ -3848,6 +3849,7 @@ invalid-decl-at-rule-001.xht == reference/filler-text-below-green.xht invalid-decl-at-rule-002.xht == reference/filler-text-below-green.xht keywords-000.xht == reference/ref-green-background.xht keywords-001.xht == reference/keywords-001-ref.xht +lang-selector-001.xht == reference/lang-selector-001-ref.xht lang-selector-002.xht == reference/no-red-filler-text-ref.xht lang-selector-003.xht == reference/filler-text-below-green.xht leading-001.xht == reference/leading-001-ref.xht diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/CaretPosition-001.htm b/tests/wpt/css-tests/cssom-view-1_dev/html/CaretPosition-001.htm new file mode 100644 index 00000000000..83dcb1c6f6d --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/CaretPosition-001.htm @@ -0,0 +1,43 @@ +<!DOCTYPE html> +<html><head> + <title>CSSOM View Module test:CaretPosition</title> + <link href="mailto:tidelgl@gmail.com" rel="author" title="unbug"> + <link href="http://www.w3.org/TR/cssom-view/#the-caretposition-interface" rel="help"> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> + <style type="text/css"> + .box{ + position: absolute; + top : 100px; + left : 400px; + width: 100px; + height: 100px; + background-color: #000; + } + </style> +</head> +<body> + <p>This case tests the Screen pixelDepth and colorDepth</p> + <p>The test passes if the value is Element "#box2"</p> + <div class="box" id="box"></div> + <div class="box"></div> + <div class="box"></div> + <div class="box"></div> + <div class="box"></div> + <div class="box"></div> + <div class="box" id="box2"></div> + <div style="left: 405px;background:red;" class="box" id="box3"></div> + <div id="log"></div> + <script> + test(function(){ + assert_equals(getBox('box2'), document.elementFromPoint(400,100), "Expected value for element id is 'box2'"); + },'getBox'); + test(function(){ + assert_equals(null, document.elementFromPoint(400,900), "Expected value for element id is 'box2'"); + },'getBox'); + function getBox(id){ + return document.getElementById(id); + } + </script> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/MediaQueryList-001.htm b/tests/wpt/css-tests/cssom-view-1_dev/html/MediaQueryList-001.htm new file mode 100644 index 00000000000..5c82d30f6ae --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/MediaQueryList-001.htm @@ -0,0 +1,21 @@ +<!DOCTYPE html> +<html><head> + <title>CSSOM View Module test:MediaQueryList</title> + <link href="mailto:tidelgl@gmail.com" rel="author" title="unbug"> + <link href="http://www.w3.org/TR/cssom-view/#the-mediaquerylist-interface" rel="help"> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> + <style type="text/css"> + </style> +</head> +<body> + <p>This case tests the MediaQueryList + </p><p>The test passes if the value is 1280/800</p> + <div id="log"></div> + <script> + test(function(){ + assert_equals(window.matchMedia('(device-aspect-ratio: 1280/800)').matches, true, "Expected value for device-aspect-ratio is 1280/800"); + },'matchMedia'); + </script> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/Screen-pixelDepth-Screen-colorDepth001.htm b/tests/wpt/css-tests/cssom-view-1_dev/html/Screen-pixelDepth-Screen-colorDepth001.htm new file mode 100644 index 00000000000..7b5b3854f3f --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/Screen-pixelDepth-Screen-colorDepth001.htm @@ -0,0 +1,32 @@ +<!DOCTYPE html> +<html><head> + <title>CSSOM View Module test:Screen-pixelDepth,Screen-colorDepth</title> + <link href="mailto:tidelgl@gmail.com" rel="author" title="unbug"> + <link href="http://www.w3.org/TR/cssom-view/#the-screen-interface" rel="help"> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> + <style type="text/css"> + </style> +</head> +<body> + <p>This case tests the Screen pixelDepth and colorDepth</p> + <p>The test passes if the value is 24</p> + <div id="log"></div> + <script> + test(function(){ + assert_equals(testColorDepth(), 24, "Expected value for colorDepth is 24"); + },'testColorDepth'); + test(function(){ + assert_equals(testPixelDepth(), 24, "Expected value for pixelDepth is 24"); + },'testPixelDepth'); + function testColorDepth(){ + var colorDepth = window.screen.colorDepth; + return colorDepth; + } + function testPixelDepth(){ + var pixelDepth = window.screen.pixelDepth; + return pixelDepth; + } + </script> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/chapter-1.htm b/tests/wpt/css-tests/cssom-view-1_dev/html/chapter-1.htm new file mode 100644 index 00000000000..eb6113d50f9 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/chapter-1.htm @@ -0,0 +1,39 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>Background - CSSOM View Module Level 1 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSSOM View Module Level 1 Test Suite</h1> + <h2>Background (0 tests)</h2> + <table width="100%"> + <col id="test-column"> + <col id="refs-column"> + <col id="flags-column"> + <col id="info-column"> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s1">+</a> + <a href="http://www.w3.org/TR/cssom-view/#background">1 Background</a></th></tr> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/chapter-10.htm b/tests/wpt/css-tests/cssom-view-1_dev/html/chapter-10.htm new file mode 100644 index 00000000000..1edf64444f6 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/chapter-10.htm @@ -0,0 +1,45 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>Extensions to the Range Interface - CSSOM View Module Level 1 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSSOM View Module Level 1 Test Suite</h1> + <h2>Extensions to the Range Interface (0 tests)</h2> + <table width="100%"> + <col id="test-column"> + <col id="refs-column"> + <col id="flags-column"> + <col id="info-column"> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s10"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s10">+</a> + <a href="http://www.w3.org/TR/cssom-view/#extensions-to-the-range-interface">10 Extensions to the Range Interface</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s10.#dom-range-getboundingclientrect"> + <!-- 0 tests --> + </tbody> + <tbody id="s10.#dom-range-getclientrects"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/chapter-11.htm b/tests/wpt/css-tests/cssom-view-1_dev/html/chapter-11.htm new file mode 100644 index 00000000000..9a9b82a6f5e --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/chapter-11.htm @@ -0,0 +1,69 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>Extensions to the MouseEvent Interface - CSSOM View Module Level 1 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSSOM View Module Level 1 Test Suite</h1> + <h2>Extensions to the MouseEvent Interface (0 tests)</h2> + <table width="100%"> + <col id="test-column"> + <col id="refs-column"> + <col id="flags-column"> + <col id="info-column"> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s11"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s11">+</a> + <a href="http://www.w3.org/TR/cssom-view/#extensions-to-the-mouseevent-interface">11 Extensions to the MouseEvent Interface</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s11.#dom-mouseevent-clientx"> + <!-- 0 tests --> + </tbody> + <tbody id="s11.#dom-mouseevent-clienty"> + <!-- 0 tests --> + </tbody> + <tbody id="s11.#dom-mouseevent-offsetx"> + <!-- 0 tests --> + </tbody> + <tbody id="s11.#dom-mouseevent-offsety"> + <!-- 0 tests --> + </tbody> + <tbody id="s11.#dom-mouseevent-pagex"> + <!-- 0 tests --> + </tbody> + <tbody id="s11.#dom-mouseevent-pagey"> + <!-- 0 tests --> + </tbody> + <tbody id="s11.#dom-mouseevent-screenx"> + <!-- 0 tests --> + </tbody> + <tbody id="s11.#dom-mouseevent-screeny"> + <!-- 0 tests --> + </tbody> + <tbody id="s11.#dom-mouseevent-x"> + <!-- 0 tests --> + </tbody> + <tbody id="s11.#dom-mouseevent-y"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/chapter-12.htm b/tests/wpt/css-tests/cssom-view-1_dev/html/chapter-12.htm new file mode 100644 index 00000000000..27069ec0248 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/chapter-12.htm @@ -0,0 +1,72 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>Geometry - CSSOM View Module Level 1 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSSOM View Module Level 1 Test Suite</h1> + <h2>Geometry (0 tests)</h2> + <table width="100%"> + <col id="test-column"> + <col id="refs-column"> + <col id="flags-column"> + <col id="info-column"> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s12"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s12">+</a> + <a href="http://www.w3.org/TR/cssom-view/#geometry">12 Geometry</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s12.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s12.1">+</a> + <a href="http://www.w3.org/TR/cssom-view/#the-geometryutils-interface">12.1 The GeometryUtils Interface</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s12.1.#boxquadoptions"> + <!-- 0 tests --> + </tbody> + <tbody id="s12.1.#convertcoordinateoptions"> + <!-- 0 tests --> + </tbody> + <tbody id="s12.1.#cssboxtype"> + <!-- 0 tests --> + </tbody> + <tbody id="s12.1.#dom-geometryutils-convertpointfromnode"> + <!-- 0 tests --> + </tbody> + <tbody id="s12.1.#dom-geometryutils-convertquadfromnode"> + <!-- 0 tests --> + </tbody> + <tbody id="s12.1.#dom-geometryutils-convertrectfromnode"> + <!-- 0 tests --> + </tbody> + <tbody id="s12.1.#dom-geometryutils-getboxquads"> + <!-- 0 tests --> + </tbody> + <tbody id="s12.1.#geometrynode"> + <!-- 0 tests --> + </tbody> + <tbody id="s12.1.#geometryutils"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/chapter-13.htm b/tests/wpt/css-tests/cssom-view-1_dev/html/chapter-13.htm new file mode 100644 index 00000000000..eb7c7e218a5 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/chapter-13.htm @@ -0,0 +1,51 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>Events - CSSOM View Module Level 1 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSSOM View Module Level 1 Test Suite</h1> + <h2>Events (0 tests)</h2> + <table width="100%"> + <col id="test-column"> + <col id="refs-column"> + <col id="flags-column"> + <col id="info-column"> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s13"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s13">+</a> + <a href="http://www.w3.org/TR/cssom-view/#events">13 Events</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s13.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s13.1">+</a> + <a href="http://www.w3.org/TR/cssom-view/#resizing-viewports">13.1 Resizing viewports</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s13.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s13.2">+</a> + <a href="http://www.w3.org/TR/cssom-view/#scrolling-0">13.2 Scrolling</a></th></tr> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/chapter-14.htm b/tests/wpt/css-tests/cssom-view-1_dev/html/chapter-14.htm new file mode 100644 index 00000000000..f4f2249c9f3 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/chapter-14.htm @@ -0,0 +1,108 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>CSS properties - CSSOM View Module Level 1 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSSOM View Module Level 1 Test Suite</h1> + <h2>CSS properties (0 tests)</h2> + <table width="100%"> + <col id="test-column"> + <col id="refs-column"> + <col id="flags-column"> + <col id="info-column"> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s14"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s14">+</a> + <a href="http://www.w3.org/TR/cssom-view/#css-properties">14 CSS properties</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s14.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s14.1">+</a> + <a href="http://www.w3.org/TR/cssom-view/#smooth-scrolling:-the-'scroll-behavior'-property">14.1 Smooth Scrolling: The 'scroll-behavior' Property</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s14.1.#scroll-behavior"> + <!-- 0 tests --> + </tbody> + <tbody id="s14.1.#scroll-behavior-instant"> + <!-- 0 tests --> + </tbody> + <tbody id="s14.1.#scroll-behavior-smooth"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#abstract"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#acknowledgments"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#anolis-references"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#references"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#refsCSSBOX"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#refsCSSDEVICEADAPT"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#refsCSSOM"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#refsCSSTRANSFORMS"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#refsCSSWRITINGMODES"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#refsDOM"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#refsGEOMETRY"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#refsHTML"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#refsRFC2119"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#refsSVG"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#refsWEBIDL"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#sotd"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#toc"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#w3c-doctype"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/chapter-2.htm b/tests/wpt/css-tests/cssom-view-1_dev/html/chapter-2.htm new file mode 100644 index 00000000000..adc33d25a27 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/chapter-2.htm @@ -0,0 +1,48 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>Conformance - CSSOM View Module Level 1 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSSOM View Module Level 1 Test Suite</h1> + <h2>Conformance (0 tests)</h2> + <table width="100%"> + <col id="test-column"> + <col id="refs-column"> + <col id="flags-column"> + <col id="info-column"> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2">+</a> + <a href="http://www.w3.org/TR/cssom-view/#conformance">2 Conformance</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s2.#hardwareLimitations"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.1">+</a> + <a href="http://www.w3.org/TR/cssom-view/#web-idl">2.1 Web IDL</a></th></tr> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/chapter-3.htm b/tests/wpt/css-tests/cssom-view-1_dev/html/chapter-3.htm new file mode 100644 index 00000000000..d17a641123c --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/chapter-3.htm @@ -0,0 +1,141 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>Terminology - CSSOM View Module Level 1 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSSOM View Module Level 1 Test Suite</h1> + <h2>Terminology (0 tests)</h2> + <table width="100%"> + <col id="test-column"> + <col id="refs-column"> + <col id="flags-column"> + <col id="info-column"> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3">+</a> + <a href="http://www.w3.org/TR/cssom-view/#terminology">3 Terminology</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#beginning-edges"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#block-flow-direction"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#border-edge"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#canvas"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#content-edge"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#css-layout-box"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#dompoint"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#dompointinit"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#dompointreadonly"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#domquad"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#domrect"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#domrectlist"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#domrectreadonly"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#ending-edges"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#initial-containing-block"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#inline-base-direction"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#layout-box"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#margin-edge"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#mouseevent"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#mouseeventinit"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#overflow-directions"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#padding-edge"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#scrolling-area"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#scrolling-box"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#svg-layout-box"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#the-html-body-element"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#transforms"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#viewport"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.1">+</a> + <a href="http://www.w3.org/TR/cssom-view/#css-pixels">3.1 CSS pixels</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.2">+</a> + <a href="http://www.w3.org/TR/cssom-view/#zooming">3.2 Zooming</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.2.#page-zoom"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.2.#pinch-zoom"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/chapter-4.htm b/tests/wpt/css-tests/cssom-view-1_dev/html/chapter-4.htm new file mode 100644 index 00000000000..ba56924ae0f --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/chapter-4.htm @@ -0,0 +1,63 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>Common Infrastructure - CSSOM View Module Level 1 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSSOM View Module Level 1 Test Suite</h1> + <h2>Common Infrastructure (0 tests)</h2> + <table width="100%"> + <col id="test-column"> + <col id="refs-column"> + <col id="flags-column"> + <col id="info-column"> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s4"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4">+</a> + <a href="http://www.w3.org/TR/cssom-view/#common-infrastructure">4 Common Infrastructure</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s4.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4.1">+</a> + <a href="http://www.w3.org/TR/cssom-view/#scrolling">4.1 Scrolling</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s4.1.#concept-instant-scroll"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.1.#concept-smooth-scroll"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.1.#concept-smooth-scroll-aborted"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.1.#concept-smooth-scroll-completed"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.1.#perform-a-scroll"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.1.#scroll-to-the-beginning-of-the-document"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/chapter-5.htm b/tests/wpt/css-tests/cssom-view-1_dev/html/chapter-5.htm new file mode 100644 index 00000000000..95b83a28634 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/chapter-5.htm @@ -0,0 +1,333 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>Extensions to the Window Interface - CSSOM View Module Level 1 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSSOM View Module Level 1 Test Suite</h1> + <h2>Extensions to the Window Interface (13 tests)</h2> + <table width="100%"> + <col id="test-column"> + <col id="refs-column"> + <col id="flags-column"> + <col id="info-column"> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s5"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s5">+</a> + <a href="http://www.w3.org/TR/cssom-view/#extensions-to-the-window-interface">5 Extensions to the Window Interface</a></th></tr> + <!-- 2 tests --> + <tr id="media-query-list-interface-5" class="primary dom script"> + <td><strong> + <a href="media-query-list-interface.htm">media-query-list-interface</a></strong></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>Properties and Functions + <ul class="assert"> + <li>All properties exist and are readonly. All functions exist and are instances of Function</li> + </ul> + </td> + </tr> + <tr id="window-interface-5" class="primary dom script"> + <td><strong> + <a href="window-interface.htm">window-interface</a></strong></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>Properties and Functions + <ul class="assert"> + <li>All properties exist and are readonly. All functions exist and are instances of Function</li> + </ul> + </td> + </tr> + </tbody> + <tbody id="s5.#allowed-to-resize-and-move"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#dom-window-devicepixelratio"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#dom-window-innerheight"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#dom-window-innerwidth"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#dom-window-matchmedia"> + <!-- 1 tests --> + <tr id="matchmedia-5.#dom-window-matchmedia" class="primary dom script"> + <td><strong> + <a href="matchMedia.htm">matchmedia</a></strong></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>CSSOM View matchMedia and MediaQueryList + </td> + </tr> + </tbody> + <tbody id="s5.#dom-window-moveby"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#dom-window-moveto"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#dom-window-outerheight"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#dom-window-outerwidth"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#dom-window-pagexoffset"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#dom-window-pageyoffset"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#dom-window-resizeby"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#dom-window-resizeto"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#dom-window-screen"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#dom-window-screenx"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#dom-window-screeny"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#dom-window-scroll"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#dom-window-scrollby"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#dom-window-scrollto"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#dom-window-scrollx"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#dom-window-scrolly"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#scrollbehavior"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#scrolloptions"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s5.1">+</a> + <a href="http://www.w3.org/TR/cssom-view/#the-features-argument-to-the-open()-method">5.1 The features argument to the open() method</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s5.1.#dom-open-features-height"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.1.#dom-open-features-left"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.1.#dom-open-features-top"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.1.#dom-open-features-width"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.1.#supported-open()-feature-name"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s5.2">+</a> + <a href="http://www.w3.org/TR/cssom-view/#the-mediaquerylist-interface">5.2 The MediaQueryList Interface</a></th></tr> + <!-- 4 tests --> + <tr id="matchmedia-5.2" class="dom script"> + <td> + <a href="matchMedia.htm">matchmedia</a></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>CSSOM View matchMedia and MediaQueryList + </td> + </tr> + <tr id="matchmediaaddlistener-5.2" class="primary dom script"> + <td><strong> + <a href="matchMediaAddListener.htm">matchmediaaddlistener</a></strong></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>CSSOM View matchMedia addListener + </td> + </tr> + <tr id="media-query-list-interface-5.2" class="dom script"> + <td> + <a href="media-query-list-interface.htm">media-query-list-interface</a></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>Properties and Functions + <ul class="assert"> + <li>All properties exist and are readonly. All functions exist and are instances of Function</li> + </ul> + </td> + </tr> + <tr id="mediaquerylist-001-5.2" class="primary script"> + <td><strong> + <a href="MediaQueryList-001.htm">mediaquerylist-001</a></strong></td> + <td></td> + <td><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>MediaQueryList + </td> + </tr> + </tbody> + <tbody id="s5.2.#dom-mediaquerylist-addlistener"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2.#dom-mediaquerylist-matches"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2.#dom-mediaquerylist-media"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2.#dom-mediaquerylist-removelistener"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2.#list-of-media-query-list-listeners"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2.#mediaquerylist"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2.#mediaquerylistlistener"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s5.3">+</a> + <a href="http://www.w3.org/TR/cssom-view/#the-screen-interface">5.3 The Screen Interface</a></th></tr> + <!-- 8 tests --> + <tr id="cssom-view-window-screen-interface-5.3" class="primary dom script"> + <td><strong> + <a href="cssom-view-window-screen-interface.htm">cssom-view-window-screen-interface</a></strong></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>cssom view window screen attribute + <ul class="assert"> + <li>window screen interface</li> + </ul> + </td> + </tr> + <tr id="screen-pixeldepth-screen-colordepth001-5.3" class="primary script"> + <td><strong> + <a href="Screen-pixelDepth-Screen-colorDepth001.htm">screen-pixeldepth-screen-colordepth001</a></strong></td> + <td></td> + <td><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>Screen-pixelDepth,Screen-colorDepth + </td> + </tr> + <tr id="window-screen-height-5.3" class="primary dom script"> + <td><strong> + <a href="window-screen-height.htm">window-screen-height</a></strong></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>CSSOM View - 4.2 - screen.height range tests + <ul class="assert"> + <li>window.screen.height has sensible values</li> + </ul> + </td> + </tr> + <tr id="window-screen-height-immutable-5.3" class="primary dom script"> + <td><strong> + <a href="window-screen-height-immutable.htm">window-screen-height-immutable</a></strong></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>CSSOM View - 4.2 - screen.height immutability + <ul class="assert"> + <li>screen.height is immutable</li> + </ul> + </td> + </tr> + <tr id="window-screen-height-mutation-throws-5.3" class="primary dom script"> + <td><strong> + <a href="window-screen-height-mutation-throws.htm">window-screen-height-mutation-throws</a></strong></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>CSSOM View - 4.2 - screen.height mutation throws exception + <ul class="assert"> + <li>screen.height mutation throws exception</li> + </ul> + </td> + </tr> + <tr id="window-screen-width-5.3" class="primary dom script"> + <td><strong> + <a href="window-screen-width.htm">window-screen-width</a></strong></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>CSSOM View - 4.2 - screen.width range tests + <ul class="assert"> + <li>window.screen.width has sensible values</li> + </ul> + </td> + </tr> + <tr id="window-screen-width-immutable-5.3" class="primary dom script"> + <td><strong> + <a href="window-screen-width-immutable.htm">window-screen-width-immutable</a></strong></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>CSSOM View - 4.2 - screen.width immutability + <ul class="assert"> + <li>screen.width is immutable</li> + </ul> + </td> + </tr> + <tr id="window-screen-width-mutation-throws-5.3" class="primary dom script"> + <td><strong> + <a href="window-screen-width-mutation-throws.htm">window-screen-width-mutation-throws</a></strong></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>CSSOM View - 4.2 - screen.width mutation throws exception + <ul class="assert"> + <li>screen.width mutation throws exception</li> + </ul> + </td> + </tr> + </tbody> + <tbody id="s5.3.#dom-screen-availheight"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.3.#dom-screen-availwidth"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.3.#dom-screen-colordepth"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.3.#dom-screen-height"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.3.#dom-screen-pixeldepth"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.3.#dom-screen-width"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.3.#screen"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/chapter-6.htm b/tests/wpt/css-tests/cssom-view-1_dev/html/chapter-6.htm new file mode 100644 index 00000000000..b4f8db90875 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/chapter-6.htm @@ -0,0 +1,105 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>Extensions to the Document Interface - CSSOM View Module Level 1 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSSOM View Module Level 1 Test Suite</h1> + <h2>Extensions to the Document Interface (3 tests)</h2> + <table width="100%"> + <col id="test-column"> + <col id="refs-column"> + <col id="flags-column"> + <col id="info-column"> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s6"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6">+</a> + <a href="http://www.w3.org/TR/cssom-view/#extensions-to-the-document-interface">6 Extensions to the Document Interface</a></th></tr> + <!-- 2 tests --> + <tr id="elementfrompoint-001-6" class="primary dom script"> + <td><strong> + <a href="elementFromPoint-001.htm">elementfrompoint-001</a></strong></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>CSSOM View - 5 - extensions to the Document interface + <ul class="assert"> + <li>elementFromPoint returns correct element</li> + </ul> + </td> + </tr> + <tr id="elementfromposition-6" class="primary dom script"> + <td><strong> + <a href="elementFromPosition.htm">elementfromposition</a></strong></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>CSSOM View elementFromPoint + </td> + </tr> + </tbody> + <tbody id="s6.#dom-document-caretpositionfrompoint"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.#dom-document-elementfrompoint"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.#dom-document-elementsfrompoint"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6.1">+</a> + <a href="http://www.w3.org/TR/cssom-view/#the-caretposition-interface">6.1 The CaretPosition Interface</a></th></tr> + <!-- 1 tests --> + <tr id="caretposition-001-6.1" class="primary script"> + <td><strong> + <a href="CaretPosition-001.htm">caretposition-001</a></strong></td> + <td></td> + <td><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>CaretPosition + </td> + </tr> + </tbody> + <tbody id="s6.1.#caret-node"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#caret-offset"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#caret-position"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#caret-range"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#caretposition"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#dom-caretposition-getclientrect"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#dom-caretposition-offset"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#dom-caretposition-offsetnode"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/chapter-7.htm b/tests/wpt/css-tests/cssom-view-1_dev/html/chapter-7.htm new file mode 100644 index 00000000000..b29a387dddd --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/chapter-7.htm @@ -0,0 +1,161 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>Extensions to the Element Interface - CSSOM View Module Level 1 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSSOM View Module Level 1 Test Suite</h1> + <h2>Extensions to the Element Interface (6 tests)</h2> + <table width="100%"> + <col id="test-column"> + <col id="refs-column"> + <col id="flags-column"> + <col id="info-column"> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s7"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s7">+</a> + <a href="http://www.w3.org/TR/cssom-view/#extensions-to-the-element-interface">7 Extensions to the Element Interface</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s7.#dom-element-clientheight"> + <!-- 0 tests --> + </tbody> + <tbody id="s7.#dom-element-clientleft"> + <!-- 0 tests --> + </tbody> + <tbody id="s7.#dom-element-clienttop"> + <!-- 0 tests --> + </tbody> + <tbody id="s7.#dom-element-clientwidth"> + <!-- 0 tests --> + </tbody> + <tbody id="s7.#dom-element-getboundingclientrect"> + <!-- 2 tests --> + <tr id="cssom-getboundingclientrect-001-7.#dom-element-getboundingclientrect" class="primary dom script"> + <td><strong> + <a href="cssom-getBoundingClientRect-001.htm">cssom-getboundingclientrect-001</a></strong></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>CSSOM View - 6.1 - getBoundingClientRect tests + </td> + </tr> + <tr id="cssom-getboundingclientrect-002-7.#dom-element-getboundingclientrect" class="dom script"> + <td> + <a href="cssom-getBoundingClientRect-002.htm">cssom-getboundingclientrect-002</a></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>getBoundingClientRect of element outside DOM + <ul class="assert"> + <li>Calling getBoundingClientRect on an element that is outside of the DOM (and therefore does not have an associated layout box) should result in an all-zeroes DOMRect and should definitely not throw an error.</li> + </ul> + </td> + </tr> + </tbody> + <tbody id="s7.#dom-element-getclientrects"> + <!-- 2 tests --> + <tr id="cssom-getboundingclientrect-002-7.#dom-element-getclientrects" class="primary dom script"> + <td><strong> + <a href="cssom-getBoundingClientRect-002.htm">cssom-getboundingclientrect-002</a></strong></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>getBoundingClientRect of element outside DOM + <ul class="assert"> + <li>Calling getBoundingClientRect on an element that is outside of the DOM (and therefore does not have an associated layout box) should result in an all-zeroes DOMRect and should definitely not throw an error.</li> + </ul> + </td> + </tr> + <tr id="cssom-getclientrects-7.#dom-element-getclientrects" class="primary dom script"> + <td><strong> + <a href="cssom-getClientRects.htm">cssom-getclientrects</a></strong></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>getClientRects of element outside DOM + <ul class="assert"> + <li>Calling getClientRects on an element that is outside of the DOM (and therefore does not have an associated layout box) should result in an empty DOMRectList and should definitely not throw an error.</li> + </ul> + </td> + </tr> + </tbody> + <tbody id="s7.#dom-element-scrollheight"> + <!-- 0 tests --> + </tbody> + <tbody id="s7.#dom-element-scrollintoview"> + <!-- 1 tests --> + <tr id="ttwf-scrollintoview-7.#dom-element-scrollintoview" class="primary dom script"> + <td><strong> + <a href="ttwf-scrollintoview.htm">ttwf-scrollintoview</a></strong></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>CSSOM View - 6 - scrollIntoView tests + </td> + </tr> + </tbody> + <tbody id="s7.#dom-element-scrollleft"> + <!-- 0 tests --> + </tbody> + <tbody id="s7.#dom-element-scrolltop"> + <!-- 0 tests --> + </tbody> + <tbody id="s7.#dom-element-scrollwidth"> + <!-- 2 tests --> + <tr id="scrollwidthheight-7.#dom-element-scrollwidth" class="primary dom script"> + <td><strong> + <a href="scrollWidthHeight.htm">scrollwidthheight</a></strong></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>CSSOM View scrollWidth and scrollHeight + </td> + </tr> + <tr id="scrollwidthheightwhennotscrollable-7.#dom-element-scrollwidth" class="primary dom script"> + <td><strong> + <a href="scrollWidthHeightWhenNotScrollable.htm">scrollwidthheightwhennotscrollable</a></strong></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>CSSOM View scrollWidth/scrollHeight (for nonscrollable elements) + </td> + </tr> + </tbody> + <tbody id="s7.#scrolloptionshorizontal"> + <!-- 0 tests --> + </tbody> + <tbody id="s7.#scrolloptionsvertical"> + <!-- 0 tests --> + </tbody> + <tbody id="s7.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s7.1">+</a> + <a href="http://www.w3.org/TR/cssom-view/#the-getclientrects()-and-getboundingclientrect()-methods">7.1 The getClientRects() and getBoundingClientRect() methods</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s7.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s7.2">+</a> + <a href="http://www.w3.org/TR/cssom-view/#element-scrolling-members">7.2 Element Scrolling Members</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s7.2.#scroll-an-element"> + <!-- 0 tests --> + </tbody> + <tbody id="s7.2.#scroll-an-element-into-view"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/chapter-8.htm b/tests/wpt/css-tests/cssom-view-1_dev/html/chapter-8.htm new file mode 100644 index 00000000000..d23aa36ff3a --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/chapter-8.htm @@ -0,0 +1,70 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>Extensions to the HTMLElement Interface - CSSOM View Module Level 1 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSSOM View Module Level 1 Test Suite</h1> + <h2>Extensions to the HTMLElement Interface (1 tests)</h2> + <table width="100%"> + <col id="test-column"> + <col id="refs-column"> + <col id="flags-column"> + <col id="info-column"> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s8"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s8">+</a> + <a href="http://www.w3.org/TR/cssom-view/#extensions-to-the-htmlelement-interface">8 Extensions to the HTMLElement Interface</a></th></tr> + <!-- 1 tests --> + <tr id="offsetparent_element_test-8" class="primary script"> + <td><strong> + <a href="offsetParent_element_test.htm">offsetparent_element_test</a></strong></td> + <td></td> + <td><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>CSSOM View &amp;#8212;&amp;#8212; offsetParent element test + </td> + </tr> + </tbody> + <tbody id="s8.#dom-htmlelement-offsetheight"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.#dom-htmlelement-offsetleft"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.#dom-htmlelement-offsetparent"> + <!-- 1 tests --> + <tr id="offsetparent_element_test-8.#dom-htmlelement-offsetparent" class="script"> + <td> + <a href="offsetParent_element_test.htm">offsetparent_element_test</a></td> + <td></td> + <td><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>CSSOM View &amp;#8212;&amp;#8212; offsetParent element test + </td> + </tr> + </tbody> + <tbody id="s8.#dom-htmlelement-offsettop"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.#dom-htmlelement-offsetwidth"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/chapter-9.htm b/tests/wpt/css-tests/cssom-view-1_dev/html/chapter-9.htm new file mode 100644 index 00000000000..ac7d28dc662 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/chapter-9.htm @@ -0,0 +1,45 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>Excensions to the HTMLImageElement Interface - CSSOM View Module Level 1 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSSOM View Module Level 1 Test Suite</h1> + <h2>Excensions to the HTMLImageElement Interface (0 tests)</h2> + <table width="100%"> + <col id="test-column"> + <col id="refs-column"> + <col id="flags-column"> + <col id="info-column"> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s9"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s9">+</a> + <a href="http://www.w3.org/TR/cssom-view/#excensions-to-the-htmlimageelement-interface">9 Excensions to the HTMLImageElement Interface</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s9.#dom-htmlimageelement-x"> + <!-- 0 tests --> + </tbody> + <tbody id="s9.#dom-htmlimageelement-y"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/cssom-getBoundingClientRect-001.htm b/tests/wpt/css-tests/cssom-view-1_dev/html/cssom-getBoundingClientRect-001.htm new file mode 100644 index 00000000000..f9572ab4db4 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/cssom-getBoundingClientRect-001.htm @@ -0,0 +1,31 @@ +<!DOCTYPE html> +<html><head> + <title>CSSOM View - 6.1 - getBoundingClientRect tests</title> + <meta charset="utf-8"> + <link href="mailto:pwx.frontend@gmail.com" rel="author" title="Chris Wu"> + <link href="http://www.w3.org/TR/cssom-view/#dom-element-getboundingclientrect" rel="help"> + <meta content="dom" name="flags"> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> + <style type="text/css"> + #testItem{width:279px;height: 188px;margin:100px 0 0 178px;background-color: purple;font-size: 26px;font-weight:bold;text-align: center;line-height: 188px;} + </style> +</head> +<body> + <div id="testItem">test item</div> + <div id="log"></div> + <script> + var titem = document.getElementById('testItem').getBoundingClientRect(); + test( + function(){ + assert_equals(titem.bottom - titem.top,titem.height,"They donot match") + },"check getBoundingClientRect().top,getBoundingClientRect.bottom()" + ); + test( + function(){ + assert_equals(titem.right - titem.left,titem.width,"They donot match") + },"check getBoundingClientRect().left,getBoundingClientRect.right()" + ) + </script> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/cssom-getBoundingClientRect-002.htm b/tests/wpt/css-tests/cssom-view-1_dev/html/cssom-getBoundingClientRect-002.htm new file mode 100644 index 00000000000..b23d010cb4f --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/cssom-getBoundingClientRect-002.htm @@ -0,0 +1,27 @@ +<!DOCTYPE html> +<html><head> + <meta charset="utf-8"> + <title>CSS Test (CSSOM View): getBoundingClientRect of element outside DOM</title> + <link href="http://chrisrebert.com" rel="author" title="Chris Rebert"> + <link href="http://www.w3.org/TR/cssom-view/#dom-element-getclientrects" rel="help"> + <link href="http://www.w3.org/TR/cssom-view/#dom-element-getboundingclientrect" rel="help"> + <meta content="dom" name="flags"> + <meta content="Calling getBoundingClientRect on an element that is outside of the DOM (and therefore does not have an associated layout box) should result in an all-zeroes DOMRect and should definitely not throw an error." name="assert"> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> + <script> + test( + function () { + var rect = document.createElement('div').getBoundingClientRect(); + assert_equals(rect.x, 0, "DOMRect's x should be zero"); + assert_equals(rect.y, 0, "DOMRect's y should be zero"); + assert_equals(rect.width, 0, "DOMRect's width should be zero"); + assert_equals(rect.height, 0, "DOMRect's height should be zero"); + }, + "getBoundingClientRect on a newly-created Element not yet inserted into the DOM should return an all-zeroes DOMRect" + ); + </script> +</head> +<body> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/cssom-getClientRects.htm b/tests/wpt/css-tests/cssom-view-1_dev/html/cssom-getClientRects.htm new file mode 100644 index 00000000000..7015c2a7541 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/cssom-getClientRects.htm @@ -0,0 +1,23 @@ +<!DOCTYPE html> +<html><head> + <meta charset="utf-8"> + <title>CSS Test (CSSOM View): getClientRects of element outside DOM</title> + <link href="http://chrisrebert.com" rel="author" title="Chris Rebert"> + <link href="http://www.w3.org/TR/cssom-view/#dom-element-getclientrects" rel="help"> + <meta content="dom" name="flags"> + <meta content="Calling getClientRects on an element that is outside of the DOM (and therefore does not have an associated layout box) should result in an empty DOMRectList and should definitely not throw an error." name="assert"> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> + <script> + test( + function () { + var rectList = document.createElement('div').getClientRects(); + assert_equals(rectList.length, 0, "DOMRectList should be empty"); + }, + "getClientRects on a newly-created Element not yet inserted into the DOM should return an empty DOMRectList" + ); + </script> +</head> +<body> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/cssom-view-window-screen-interface.htm b/tests/wpt/css-tests/cssom-view-1_dev/html/cssom-view-window-screen-interface.htm new file mode 100644 index 00000000000..ba5ce915606 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/cssom-view-window-screen-interface.htm @@ -0,0 +1,39 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Test: cssom view window screen attribute</title> + <link href="mailto:jingkewhu@gmail.com" rel="author" title="jingke"> + <link href="http://www.w3.org/TR/cssom-view/#the-screen-interface" rel="help"> + <meta content="dom" name="flags"> + <meta content="window screen interface" name="assert"> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> + </head> + <body> + <div id="myDiv"></div> + <div id="log"></div> + <script> + /*test readonly*/ + test(function(){assert_readonly(window.screen, "availWidth");}, "Screen.availWidth is readonly"); + test(function(){assert_readonly(window.screen, "availHeight");}, "Screen.availHeight is readonly"); + test(function(){assert_readonly(window.screen, "width");}, "Screen.width is readonly"); + test(function(){assert_readonly(window.screen, "height");}, "Screen.height is readonly"); + test(function(){assert_readonly(window.screen, "colorDepth");}, "Screen.colorDepth is readonly"); + test(function(){assert_readonly(window.screen, "pixelDepth");}, "Screen.pixelDepth is readonly"); + + + test(function(){assert_true(window.screen.width >= 0 && window.screen.width < 6000000);}, + "window.screen.width >= 0 && window.screen.width < 6000000"); + test(function(){assert_true(window.screen.height >= 0 && window.screen.height < 6000000);}, + "window.screen.height >= 0 && window.screen.height < 6000000"); + test(function(){assert_true(window.screen.availWidth >= 0 && window.screen.availWidth <= window.screen.width);}, + "window.screen.availWidth >= 0 && window.screen.availWidth <= window.screen.width"); + test(function(){assert_true(window.screen.availHeight >= 0 && window.screen.availHeight <= window.screen.height);}, + "window.screen.availHeight >= 0 && window.screen.availHeight <= window.screen.height"); + test(function(){assert_true(window.screen.colorDepth == 0 || window.screen.colorDepth == 16 || window.screen.colorDepth == 24 || window.screen.colorDepth == 32);}, + "window.screen.colorDepth == 0 || window.screen.colorDepth == 16 || window.screen.colorDepth == 24 || window.screen.colorDepth == 32"); + test(function(){assert_equals(window.screen.pixelDepth, window.screen.colorDepth);}, + "window.screen.pixelDepth must return the value returned by window.screen.colorDepth"); + </script> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/elementFromPoint-001.htm b/tests/wpt/css-tests/cssom-view-1_dev/html/elementFromPoint-001.htm new file mode 100644 index 00000000000..52e1749300d --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/elementFromPoint-001.htm @@ -0,0 +1,33 @@ +<!DOCTYPE html> +<html><head> + <title>CSSOM View - 5 - extensions to the Document interface</title> + <link href="mailto:neils.christoffersen@gmail.com" rel="author" title="Neils Christoffersen"> + <link href="http://www.w3.org/TR/cssom-view/#extensions-to-the-document-interface" rel="help"> + <meta content="dom" name="flags"> + <meta content="elementFromPoint returns correct element" name="assert"> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> + <style> + #targetDiv { + position: absolute; + top: 10; + left: 10; + height: 100px; + width: 100px; + } + </style> +</head> +<body> + <div id="myDiv"></div> + <div id="log"></div> + <div id="targetDiv"> + </div> + <script> + var element = document.elementFromPoint(15, 15); + + test ( function() { + assert_equals(element.id, "targetDiv", "elementFromPoint didn't return the correct element"); + }); + </script> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/elementFromPosition.htm b/tests/wpt/css-tests/cssom-view-1_dev/html/elementFromPosition.htm new file mode 100644 index 00000000000..11173d7e82e --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/elementFromPosition.htm @@ -0,0 +1,144 @@ +<!DOCTYPE html> +<html lang="en-US"><head> + <title>CSS Test: CSSOM View elementFromPoint</title> + <meta charset="UTF-8"> + <link href="mailto:pwx.frontend@gmail.com" rel="author" title="Chris"> + <link href="http://www.w3.org/TR/cssom-view/#extensions-to-the-document-interface" rel="help"> + <link href="http://www.w3.org/TR/cssom-view/#widl-Document-elementFromPoint-Element-float-x-float-y" rel="help"> + <meta content="dom" name="flags"> + <script src="/resources/testharness.js" type="text/javascript"></script> + <script src="/resources/testharnessreport.js" type="text/javascript"></script> + <script id="metadata_cache">/* +{ + "document.elementFromPoint": {}, + "document.elementFromPoint is a Function": {}, + "test some point of the element: top left corner": {}, + "test some point of the element: top line": {}, + "test some point of the element: top right corner": {}, + "test some point of the element: left line": {}, + "test some point of the element: inside": {}, + "test some point of the element: right line": {}, + "test some point of the element: bottom left corner": {}, + "test some point of the element: bottom line": {}, + "test some point of the element: botom right corner": {}, + "Point (0, 0), return root element(HTML)": {}, + " test negative x ": {}, + " test nagetive y ": {}, + "test outside of viewport": {}, + "test the top of layer": {} +} + */</script> +</head> +<body> + <noscript>Test not run - JavaScript required!</noscript> + <div id="log"></div> + <script type="text/javascript"> + + var body = document.getElementsByTagName( 'body' )[0]; + function createElement( id ) { + var elem = document.createElement( 'div' ); + if ( id && typeof id == 'string' ) { + elem.id = id; + } + body.appendChild( elem ); + return elem; + } + + function setPosition( config ) { + var target = config.target; + target.style.position = 'absolute'; + target.style.left = config.left + 'px'; + target.style.top = config.top + 'px'; + target.style.width = config.width + 'px'; + target.style.height = config.height + 'px'; + if ( config['z-index'] ) { + target.style.zIndex = config['z-index']; + } + } + + var target = createElement( 'dom-1' ); + setPosition( { + width: 100, + height: 100, + left: 10, + top: 10, + target: target + }); + + test( function () { + assert_inherits( document, 'elementFromPoint' ); + }, 'document.elementFromPoint'); + + test( function () { + assert_true( document.elementFromPoint instanceof Function ); + }, 'document.elementFromPoint is a Function'); + (function(){ + var wrap = [ + // ๅทฆไธŠ่ง’. + {x: 10, y: 10, r: 'top left corner'}, + // ไธŠ่พน็บฟ + {x: 50, y: 10, r: 'top line'}, + // ๅณไธŠ่ง’ + {x: 110, y: 10, r: 'top right corner'}, + // ๅทฆ่พน็บฟ + {x: 10, y: 50, r: 'left line'}, + // ๅ…ƒ็ด ่Œƒๅ›ดๅ†… + {x: 50, y: 50, r: 'inside'}, + // ๅณ่พน็บฟ + {x: 110, y: 10, r: 'right line'}, + // ๅทฆไธ‹่ง’ + {x: 10, y: 110, r: 'bottom left corner'}, + // ไธ‹่พน็บฟ + {x: 50, y: 110, r: 'bottom line'}, + // ๅณไธ‹่ง’ + {x: 110, y: 110, r: 'botom right corner'} + ]; + var i = 0, len = wrap.length, item; + for ( ; i < len; i++ ) { + item = wrap[ i ]; + test( function () { + assert_equals( document.elementFromPoint( item.x, item.y).id == 'dom-1', true ); + }, 'test some point of the element: ' + item.r); + } + })(); + test( function () { + var elem = document.elementFromPoint( 0, 0 ); + assert_true( elem.nodeName == 'HTML' ); + }, 'Point (0, 0), return root element(HTML)' ); + + test( function () { + var elem = document.elementFromPoint( -1000, 0 ); + assert_true( elem == null, 'negative x, return null' ); + }, ' test negative x '); + + test( function () { + var elem = document.elementFromPoint( 0, -1000 ); + assert_true( elem == null, 'negative y, return null' ); + }, ' test nagetive y '); + + test( function () { + var elem = document.elementFromPoint( 100000, 0 ); + assert_true( elem == null ); + }, 'test outside of viewport'); + + test( function () { + var config = { + width: 100, + height: 100, + left: 5, + top: 5 + }; + var target2 = createElement( 'dom-2' ); + config.target = target2; + setPosition( config ); + + var elem = document.elementFromPoint( 10, 10 ); + var elem2 = document.elementFromPoint( 10, 10 ); + assert_equals( elem.id, elem2.id ); + }, 'test the top of layer'); + </script> + + + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/matchMedia.htm b/tests/wpt/css-tests/cssom-view-1_dev/html/matchMedia.htm new file mode 100644 index 00000000000..ae2612e9f67 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/matchMedia.htm @@ -0,0 +1,186 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> +<html> + <head> + <title>CSS Test: CSSOM View matchMedia and MediaQueryList</title> + <link rel="author" title="Rune Lillesveen" href="mailto:rune@opera.com"> + <link rel="help" href="http://www.w3.org/TR/cssom-view/#dom-window-matchmedia"> + <link rel="help" href="http://www.w3.org/TR/cssom-view/#the-mediaquerylist-interface"> + <link rel="help" href="http://www.w3.org/TR/cssom/#serializing-media-queries"> + <meta name="flags" content="dom"> + <script src="/resources/testharness.js" type="text/javascript"></script> + <script src="/resources/testharnessreport.js" type="text/javascript"></script> + <style type="text/css"> + iframe { border: none; } + </style> + </head> + <body> + <noscript>Test not run - javascript required.</noscript> + <div id="log"></div> + <iframe width="200" height="100"></iframe> + <script type="text/javascript"> + function reflow(doc) { + doc.body.offsetWidth; + } + + var iframe = document.querySelector("iframe"); + var iframe_window = window.frames[0]; + + reflow(iframe_window.document); + + test(function(){ + assert_inherits(window, "matchMedia"); + }, "window.matchMedia exists"); + + test(function(){ + assert_true(window.matchMedia instanceof Function, "FATAL ERROR: The window.matchMedia function is not present. The rest of the testsuite will fail to run."); + }, "window.matchMedia is a Function"); + + var mql, mql1, mql2, mql3; + + test(function(){ + mql = window.matchMedia("all"); + assert_true(mql instanceof MediaQueryList, "matchMedia(\"all\") returned MediaQueryList object."); + }, "window.matchMedia(\"all\")"); + + test(function(){ + assert_idl_attribute(mql, "media", "Check that MediaQueryList.media exists."); + }, "MediaQueryList.media exists"); + + test(function(){ + assert_readonly(mql, "media", "Check that MediaQueryList.media is readonly."); + }, "MediaQueryList.media is readonly"); + + test(function(){ + assert_equals(mql.media, "all"); + }, "MediaQueryList.media for \"all\""); + + test(function(){ + assert_idl_attribute(mql, "matches", "Check that MediaQueryList.matches exists."); + }, "MediaQueryList.matches exists"); + + test(function(){ + assert_readonly(mql, "matches", "Check that MediaQueryList.matches is readonly."); + }, "MediaQueryList.matches is readonly"); + + test(function(){ + assert_true(mql.matches); + }, "MediaQueryList.matches for \"all\""); + + test(function(){ + assert_inherits(mql, "addListener"); + }, "MediaQueryList.addListener exists"); + + test(function(){ + assert_true(mql.addListener instanceof Function); + }, "MediaQueryList.addListener is a Function"); + + test(function(){ + assert_inherits(mql, "removeListener"); + }, "MediaQueryList.removeListener exists"); + + test(function(){ + assert_true(mql.removeListener instanceof Function); + }, "MediaQueryList.removeListener is a Function"); + + test(function(){ + mql = window.matchMedia("::"); + assert_true(mql instanceof MediaQueryList, "window.matchMedia(\"::\") returned MediaQueryList object."); + assert_equals(mql.media, "not all", "MediaQueryList.media serialized as \"not all\" from original string with syntax error."); + }, "MediaQueryList.media syntax error"); + + test(function(){ + assert_false(mql.matches); + }, "MediaQueryList.matches for \"not all\""); + + test(function(){ + mql = iframe_window.matchMedia("(max-width: 199px), all and (min-width: 200px)"); + assert_equals(mql.media, "(max-width: 199px), (min-width: 200px)"); + assert_true(mql.matches); + }, "MediaQueryList.matches for \"(max-width: 199px), all and (min-width: 200px)\"") + + test(function(){ + mql = iframe_window.matchMedia("(min-aspect-ratio: 1/1)"); + assert_true(mql.matches); + }, "MediaQueryList.matches for \"(min-aspect-ratio: 1/1)\""); + + test(function(){ + mql = iframe_window.matchMedia("(width: 200px)"); + assert_true(mql.matches); + }, "MediaQueryList.matches for \"(width: 200px)\""); + + test(function(){ + mql1 = iframe_window.matchMedia("(max-height: 50px)"); + assert_false(mql1.matches); + }, "MediaQueryList.matches for \"(max-height: 50px)\""); + + test(function(){ + mql2 = iframe_window.matchMedia("(min-width: 150px)"); + assert_true(mql2.matches); + }, "MediaQueryList.matches for \"(min-width: 150px)\""); + + var resizeTest = async_test("Resize iframe from 200x100 to 200x50, then to 100x50"); + var listenerOrderTest = async_test("Listeners are called in the order which they have been added"); + var duplicateListenerTest = async_test("Listener added twice is only called once."); + + window.onload = function(){ + + var rmListener = function(x){ + resizeTest.step(function(){ + assert_unreached("removeListener was not successful."); + }); + }; + + var dupListener = function(x){ + duplicateListenerTest.step(function(){ + assert_false(mql1.dupListenerCalled, "Check that this listener has not been called before."); + mql1.dupListenerCalled = true; + }); + }; + + mql1.firstListenerCalled = false; + mql1.dupListenerCalled = false; + // Add listener twice and remove it below. Should not be called. + mql1.addListener(rmListener); + mql1.addListener(rmListener); + // Add listener twice. Should only be called once. + mql1.addListener(dupListener); + mql1.addListener(dupListener); + + mql1.addListener(function(x){ + resizeTest.step(function(){ + assert_equals(x, mql1, "Check that the MediaQueryList passed to the handler is the same that addListener was invoked on."); + assert_true(x.matches, "(max-height: 50px) should now pass."); + assert_true(mql2.matches, "(min-width: 150px) should still pass."); + iframe.width = "100"; + }); + + listenerOrderTest.step(function(){ + assert_false(mql1.firstListenerCalled, "Check that this listener is only called once."); + mql1.firstListenerCalled = true; + }); + }); + + mql1.addListener(function(x){ + listenerOrderTest.step(function(){ + assert_true(mql1.firstListenerCalled, "Check that the listener added last is called last."); + }); + listenerOrderTest.done(); + }); + + mql1.removeListener(rmListener); + + mql2.addListener(function(x){ + duplicateListenerTest.done(); + resizeTest.step(function(){ + assert_equals(x, mql2, "Check that the MediaQueryList passed to the handler is the same that addListener was invoked on."); + assert_true(mql1.matches, "(max-height: 50px) should still pass."); + assert_false(x.matches, "(min-width: 150px) should now fail."); + }); + resizeTest.done(); + }); + + iframe.height = "50"; + }; + </script> + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/matchMediaAddListener.htm b/tests/wpt/css-tests/cssom-view-1_dev/html/matchMediaAddListener.htm new file mode 100644 index 00000000000..48ae719796e --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/matchMediaAddListener.htm @@ -0,0 +1,67 @@ +<!DOCTYPE html> +<html><head> + <title>CSS Test: CSSOM View matchMedia addListener</title> + <link href="mailto:pwx.frontend@gmail.com" rel="author" title="Chris Wu"> + <link href="http://www.w3.org/TR/cssom-view/#the-mediaquerylist-interface" rel="help"> + <meta content="dom" name="flags"> + <script src="/resources/testharness.js" type="text/javascript"> + <script src="/resources/testharnessreport.js" type="text/javascript" /> + <style type="text/css"> + iframe { border: none; } + </style> + </head> + <body> + <div id="log"></div> + <iframe width="200" height="100" id="iframe1" ></iframe> + <script> + function reflow(doc) { + doc.body.offsetWidth; + } + + var iframe = document.querySelector("iframe"); + var iframe_window = window.frames[0]; + var iframe1 = document.getElementById("iframe1"); + reflow(iframe_window.document); + + var i = 0; + var totalCount = 10; + var count = 0; + var divineCount = 10; + var width_list = [201,199]; + var mq1 = iframe_window.matchMedia("(max-width:200px)"); + mq1.addListener(function(mql){ + + count = count + 1; + + }); + + var equalAssert = async_test("Check for the correct number of event triggers"); + + var changeFrameWidth = function(iWidth) { + iframe1.style.width = iWidth + "px"; + i = (i === 0) ? 1 : 0; + totalCount = totalCount - 1; + if(totalCount > 0) + { + setTimeout(function(){ + changeFrameWidth(width_list[i]); + }, 100); + } + else + { + setTimeout(function(){ + equalAssert.step(function(){ + assert_equals(divineCount, count, "this will be 10 times of event triggers by change width"); + }); + equalAssert.done(); + }, 100); + } + }; + + changeFrameWidth(width_list[0]); + + + </script> + </head><body> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/media-query-list-interface.htm b/tests/wpt/css-tests/cssom-view-1_dev/html/media-query-list-interface.htm new file mode 100644 index 00000000000..e88acc6565b --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/media-query-list-interface.htm @@ -0,0 +1,69 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> +<html> + <head> + <title>CSSOM MediaQueryList Test: Properties and Functions</title> + <link rel="author" title="Joe Balancio" href="mailto:jlbalancio@gmail.com"> + <link rel="help" href="http://www.w3.org/TR/cssom-view/#extensions-to-the-window-interface"> + <link rel="help" href="http://www.w3.org/TR/cssom-view/#the-mediaquerylist-interface"> + <meta name="flags" content="dom"> + <meta name="assert" content="All properties exist and are readonly. All functions exist and are instances of Function"> + <script src="/resources/testharness.js" type="text/javascript"></script> + <script src="/resources/testharnessreport.js" type="text/javascript"></script> + </head> + <body> + <noscript>Test not run - javascript required.</noscript> + <div id="log"></div> + <script type="text/javascript"> + var mediaQueryList; + test( + function(){ + assert_inherits(window, "matchMedia"); + mediaQueryList = window.matchMedia('foo'); + }, 'window_inherits_matchmedia', { + assert: ['window.matchMedia is inherited. If this fails, the rest of the test fails.'] + } + ); + /* + MediaQueryList Functions + */ + test( + function(){ + assert_inherits(mediaQueryList, "addListener"); + assert_inherits(mediaQueryList, "removeListener"); + }, 'mediaquerylist_inherited_functions', { + assert: ['MediaQueryList functions are inherited'] + } + ); + + test( + function(){ + assert_true(mediaQueryList.addListener instanceof Function); + assert_true(mediaQueryList.removeListener instanceof Function); + }, 'mediaquerylist_functions', { + assert: ['MediaQueryList functions are instances of Function'] + } + ); + + /* + MediaQueryList Properties + */ + test( + function() { + assert_own_property(mediaQueryList, 'media'); + assert_own_property(mediaQueryList, 'matches'); + }, 'mediaquerylist_properties', { + assert: ['MediaQueryList properties are owned by window'] + } + ); + test( + function() { + assert_readonly(mediaQueryList, 'media'); + assert_readonly(mediaQueryList, 'matches'); + }, 'mediaquerylist_properties_readonly', { + assert: ['MediaQueryList properties are readonly'] + } + ); + + </script> + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/offsetParent_element_test.htm b/tests/wpt/css-tests/cssom-view-1_dev/html/offsetParent_element_test.htm new file mode 100644 index 00000000000..f3912c7f3e1 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/offsetParent_element_test.htm @@ -0,0 +1,137 @@ +๏ปฟ<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> +<title>CSSOM View โ€”โ€” offsetParent element test</title> +<link href="mailto:1988wangxiao@gmail.com" rel="author" title="neo_and_rayi"> +<link href="http://www.w3.org/TR/cssom-view/#extensions-to-the-htmlelement-interface" rel="help"> +<link href="http://www.w3.org/TR/cssom-view/#dom-htmlelement-offsetparent" rel="help"> +<script src="/resources/testharness.js"></script> +<script src="/resources/testharnessreport.js"></script> +<script id="metadata_cache">/* +{ + "Valid the algorithm rule of offsetParent check step 1": { "assert": "The offsetParent attribute algorithm rule checking passed!" }, + "Valid the algorithm rule of offsetParent check step 2": { "assert": "The offsetParent attribute algorithm rule checking passed!" } +} +*/</script> +<style> +#fixed { + position: fixed; +} + +#none-element { + display:none; +} + +#relative-element { + position: relative; +} + +#absolute-element { + position: absolute; +} +</style> + +</head> +<body> + +<div id="body-element-child"></div> + +<div id="relative-element"> + <div id="relative-element-child"></div> +</div> + +<div id="absolute-element"> + <div id="absolute-element-child"></div> +</div> + +<table id="table-element"> + <caption> + <div id="caption-element-child"></div> + </caption> + + <tbody> + <tr id="table-element-tr"> + <td id="table-element-td"> + <span id="table-element-child"></span> + </td> + </tr> + </tbody> +</table> + +<div id="none-element"> + <a href="#" id="none-element-child-a"></a> + <p id="none-element-child-p"></p> + <video id="none-element-child-video"></video> + <audio id="none-element-child-audio"></audio> + <canvas id="none-element-child-canvas"></canvas> + <svg id="none-element-child-svg"></svg> +</div> + +<div id="fixed"> +</div> + +<div id="log"></div> +<script type="text/javascript"> +var getStyle = window.getComputedStyle; +var html = document.documentElement; +var body = document.body; +var fixed_element = document.getElementById('fixed'); +var none_element = document.getElementById('none-element'); + +var none_element_child_a = document.getElementById('none-element-child-a'); +var none_element_child_p = document.getElementById('none-element-child-p'); +var none_element_child_video = document.getElementById('none-element-child-video'); +var none_element_child_audio = document.getElementById('none-element-child-audio'); +var none_element_child_canvas = document.getElementById('none-element-child-canvas'); +var none_element_child_svg = document.getElementById('none-element-child-svg'); + +var relative_element = document.getElementById('relative-element'); +var absolute_element = document.getElementById('absolute-element'); +var td_element = document.getElementsByTagName('td')[0]; + +var body_element_child = document.getElementById('body-element-child'); +var relative_element_child = document.getElementById('relative-element-child'); +var absolute_element_child = document.getElementById('absolute-element-child'); +var table_element_child = document.getElementById('table-element-child'); + +var caption_element_child = document.getElementById('caption-element-child'); +var table_element_tr = document.getElementById('table-element-tr'); +var table_element = document.getElementById('table-element'); + +test(function() { + assert_equals(html.offsetParent,null); + assert_equals(body.offsetParent,null); + assert_equals(fixed_element.offsetParent,null); + assert_equals(none_element.offsetParent,null); + assert_equals(none_element_child_a.offsetParent,null); + assert_equals(none_element_child_p.offsetParent,null); + assert_equals(none_element_child_video.offsetParent,null); + assert_equals(none_element_child_audio.offsetParent,null); + assert_equals(none_element_child_canvas.offsetParent,null); + assert_equals(none_element_child_svg.offsetParent,null); +}, "Valid the algorithm rule of offsetParent check step 1", +{ assert: "The offsetParent attribute algorithm rule checking passed!" } +); + +test(function() { + assert_equals(body_element_child.offsetParent,body); + assert_equals(window.getComputedStyle(relative_element).position,'relative'); + assert_equals(relative_element_child.offsetParent,relative_element); + assert_equals(window.getComputedStyle(absolute_element).position,'absolute'); + assert_equals(absolute_element_child.offsetParent,absolute_element); + assert_equals(window.getComputedStyle(td_element).position,'static'); + assert_equals(table_element_child.offsetParent,td_element); + assert_equals(window.getComputedStyle(table_element_tr).position,'static'); + assert_equals(table_element_tr.offsetParent,table_element); + assert_equals(window.getComputedStyle(caption_element_child).position,'static'); + assert_equals(caption_element_child.offsetParent,table_element); + assert_equals(window.getComputedStyle(td_element).position,'static'); + assert_equals(td_element.offsetParent,table_element); +}, "Valid the algorithm rule of offsetParent check step 2", +{ assert: "The offsetParent attribute algorithm rule checking passed!" } +); + +</script> + + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/reftest-toc.htm b/tests/wpt/css-tests/cssom-view-1_dev/html/reftest-toc.htm new file mode 100644 index 00000000000..b1c122c78ee --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/reftest-toc.htm @@ -0,0 +1,30 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>CSSOM View Module Level 1 Test Suite Reftest Index</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSSOM View Module Level 1 Test Suite Reftest Index</h1> + <table width="100%"> + <col id="test-column"> + <col id="ref-column"> + <col id="flags-column"> + <thead> + <tr> + <th>Test</th> + <th>Reference</th> + <th>Flags</th> + </tr> + </thead> + </table> + + </body> +</html> diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/reftest.list b/tests/wpt/css-tests/cssom-view-1_dev/html/reftest.list new file mode 100644 index 00000000000..8b137891791 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/reftest.list @@ -0,0 +1 @@ + diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/scrollWidthHeight.htm b/tests/wpt/css-tests/cssom-view-1_dev/html/scrollWidthHeight.htm new file mode 100644 index 00000000000..beeacdbfb22 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/scrollWidthHeight.htm @@ -0,0 +1,146 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> +<html> + <head> + <title>CSS Test: CSSOM View scrollWidth and scrollHeight</title> + <link rel="author" title="Robert O'Callahan" href="mailto:robert@ocallahan.org"> + <link rel="help" href="http://www.w3.org/TR/cssom-view/#dom-element-scrollwidth"> + <meta name="flags" content="dom"> + <script src="/resources/testharness.js" type="text/javascript"></script> + <script src="/resources/testharnessreport.js" type="text/javascript"></script> + <style type="text/css"> + #elemSimple, #elemOverflow, #elemNestedOverflow { + border:1px solid black; + overflow:hidden; + width:200px; + height:40px; + padding-bottom:50px; + padding-right:40px; + } + #elemSimple > div { + background:yellow; + width:60px; + height:30px; + } + #elemOverflow > div { + background:yellow; + width:250px; + height:150px; + } + #elemNestedOverflow > div { + background:yellow; + width:60px; + height:30px; + } + #elemNestedOverflow > div > div { + background:blue; + width:250px; + height:150px; + } + </style> + <script id="metadata_cache" type="text/javascript">/* +{ + "elemSimple.clientHeight is the height of the padding edge": {}, + "elemSimple.scrollHeight is its clientHeight": {}, + "elemSimple.clientWidth is the width of the padding edge": {}, + "elemSimple.scrollWidth is its clientWidth": {}, + "elemOverflow.clientHeight is the height of the padding edge": {}, + "elemOverflow.scrollHeight is the height of its scrolled contents (ignoring padding, since we overflowed)": {}, + "elemOverflow.clientWidth is the width of the padding edge": {}, + "elemOverflow.scrollHeight is the width of its scrolled contents (ignoring padding, since we overflowed)": {}, + "elemNestedOverflow.clientHeight is the height of the padding edge": {}, + "elemNestedOverflow.scrollHeight is the height of its scrolled contents (ignoring padding, since we overflowed)": {}, + "elemNestedOverflow.clientWidth is the height of the padding edge": {}, + "elemNestedOverflow.scrollWidth is the width of its scrolled contents (ignoring padding, since we overflowed)": {} +*/ </script> + </head> + <body> + <noscript>Test not run - javascript required.</noscript> + <div id="log"></div> + <div id="elemSimple"> + <div></div> + </div> + <div id="elemOverflow"> + <div></div> + </div> + <div id="elemNestedOverflow"> + <div> + <div></div> + </div> + </div> + <script type="text/javascript"> + var elemSimple = document.getElementById("elemSimple"); + var elemOverflow = document.getElementById("elemOverflow"); + var elemNestedOverflow = document.getElementById("elemNestedOverflow"); + + test(function(){ + assert_equals(elemSimple.clientHeight, 90); + }, "elemSimple.clientHeight is the height of the padding edge"); + + test(function(){ + assert_equals(elemSimple.scrollHeight, 90); + }, "elemSimple.scrollHeight is its clientHeight"); + + test(function(){ + assert_equals(elemSimple.clientWidth, 240); + }, "elemSimple.clientWidth is the width of the padding edge"); + + test(function(){ + assert_equals(elemSimple.scrollWidth, 240); + }, "elemSimple.scrollWidth is its clientWidth"); + + test(function(){ + assert_equals(elemOverflow.clientHeight, 90); + }, "elemOverflow.clientHeight is the height of the padding edge"); + + /* This test differs from the spec. Opera and Webkit meet the spec, IE9 and Firefox + give the result here. It seems that in this case Opera and Webkit place + the padding-bottom below elemOverflow's child (i.e. below elemOverflow's bottom border); + you can scroll to it. IE9 and Firefox do not. I believe this is a Webkit/Opera bug + (If you remove overflow:hidden then the padding-bottom moves back to be above the bottom + border, as expected.) + The underlying issue seems to be whether bottom padding on a scrollable element is + always placed at the element's bottom border and not scrolled, or else deemed to + belong to the scrolled content and placed below the scrolled element's children. + Commenting out for now, because this is not really a CSSOM issue, but an issue + over the layout of elements with 'overflow'. + + test(function(){ + assert_equals(elemOverflow.scrollHeight, 150); + }, "elemOverflow.scrollHeight is the height of its scrolled contents (ignoring padding, since we overflowed)"); + */ + + test(function(){ + assert_equals(elemOverflow.clientWidth, 240); + }, "elemOverflow.clientWidth is the width of the padding edge"); + + /* This test differs from the spec. All major browsers give the result here, ignoring + the right padding. + */ + test(function(){ + assert_equals(elemOverflow.scrollWidth, 250); + }, "elemOverflow.scrollHeight is the width of its scrolled contents (ignoring padding, since we overflowed)"); + + test(function(){ + assert_equals(elemNestedOverflow.clientHeight, 90); + }, "elemNestedOverflow.clientHeight is the height of the padding edge"); + + /* This test differs from the spec. All major browsers give the result here. + */ + test(function(){ + assert_equals(elemNestedOverflow.scrollHeight, 150); + }, "elemNestedOverflow.scrollHeight is the height of its scrolled contents (ignoring padding, since we overflowed)"); + + test(function(){ + assert_equals(elemNestedOverflow.clientWidth, 240); + }, "elemNestedOverflow.clientWidth is the height of the padding edge"); + + /* This test differs from the spec. All major browsers give the result here, ignoring + the right padding. + */ + test(function(){ + assert_equals(elemNestedOverflow.scrollWidth, 250); + }, "elemNestedOverflow.scrollWidth is the width of its scrolled contents (ignoring padding, since we overflowed)"); + + </script> + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/scrollWidthHeightWhenNotScrollable.htm b/tests/wpt/css-tests/cssom-view-1_dev/html/scrollWidthHeightWhenNotScrollable.htm new file mode 100644 index 00000000000..99fb96a4c19 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/scrollWidthHeightWhenNotScrollable.htm @@ -0,0 +1,136 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> +<html> + <head> + <title>CSS Test: CSSOM View scrollWidth/scrollHeight (for nonscrollable elements)</title> + <link rel="author" title="Robert O'Callahan" href="mailto:robert@ocallahan.org"> + <link rel="help" href="http://www.w3.org/TR/cssom-view/#dom-element-scrollwidth"> + <meta name="flags" content="dom"> + <script src="/resources/testharness.js" type="text/javascript"></script> + <script src="/resources/testharnessreport.js" type="text/javascript"></script> + <style type="text/css"> + #elemSimple, #elemOverflow, #elemNestedOverflow { + border:1px solid black; + width:200px; + height:40px; + padding-bottom:50px; + padding-right:40px; + } + #elemSimple > div { + background:yellow; + width:60px; + height:30px; + } + #elemOverflow > div { + background:yellow; + width:250px; + height:150px; + } + #elemNestedOverflow > div { + background:yellow; + width:60px; + height:30px; + } + #elemNestedOverflow > div > div { + background:blue; + width:250px; + height:150px; + } + </style> + <script id="metadata_cache" type="text/javascript">/* +{ + "elemSimple.clientHeight is the height of the padding edge": {}, + "elemSimple.scrollHeight is its clientHeight": {}, + "elemSimple.clientWidth is the width of the padding edge": {}, + "elemSimple.scrollWidth is its clientWidth": {}, + "elemOverflow.clientHeight is the height of the padding edge": {}, + "elemOverflow.scrollHeight is the height of its scrolled contents (ignoring padding, since we overflowed)": {}, + "elemOverflow.clientWidth is the width of the padding edge": {}, + "elemOverflow.scrollHeight is the width of its scrolled contents (ignoring padding, since we overflowed)": {}, + "elemNestedOverflow.clientHeight is the height of the padding edge": {}, + "elemNestedOverflow.scrollHeight is the height of its scrolled contents (ignoring padding, since we overflowed)": {}, + "elemNestedOverflow.clientWidth is the height of the padding edge": {}, + "elemNestedOverflow.scrollWidth is the width of its scrolled contents (ignoring padding, since we overflowed)": {} +*/ </script> + </head> + <body> + <noscript>Test not run - javascript required.</noscript> + <div id="log"></div> + <div id="elemSimple"> + <div></div> + </div> + <div id="elemOverflow"> + <div></div> + </div> + <div id="elemNestedOverflow"> + <div> + <div></div> + </div> + </div> + <script type="text/javascript"> + var elemSimple = document.getElementById("elemSimple"); + var elemOverflow = document.getElementById("elemOverflow"); + var elemNestedOverflow = document.getElementById("elemNestedOverflow"); + + test(function(){ + assert_equals(elemSimple.clientHeight, 90); + }, "elemSimple.clientHeight is the height of the padding edge"); + + test(function(){ + assert_equals(elemSimple.scrollHeight, 90); + }, "elemSimple.scrollHeight is its clientHeight"); + + test(function(){ + assert_equals(elemSimple.clientWidth, 240); + }, "elemSimple.clientWidth is the width of the padding edge"); + + test(function(){ + assert_equals(elemSimple.scrollWidth, 240); + }, "elemSimple.scrollWidth is its clientWidth"); + + test(function(){ + assert_equals(elemOverflow.clientHeight, 90); + }, "elemOverflow.clientHeight is the height of the padding edge"); + + /* This test differs from the spec. All major browsers give the result here, ignoring + the bottom padding. + */ + test(function(){ + assert_equals(elemOverflow.scrollHeight, 150); + }, "elemOverflow.scrollHeight is the height of its scrolled contents (ignoring padding, since we overflowed)"); + + test(function(){ + }, "elemOverflow.clientWidth is the width of the padding edge"); + assert_equals(elemOverflow.clientWidth, 240); + + /* This test differs from the spec. All major browsers give the result here, ignoring + the right padding. + */ + test(function(){ + assert_equals(elemOverflow.scrollWidth, 250); + }, "elemOverflow.scrollHeight is the width of its scrolled contents (ignoring padding, since we overflowed)"); + + test(function(){ + assert_equals(elemNestedOverflow.clientHeight, 90); + }, "elemNestedOverflow.clientHeight is the height of the padding edge"); + + /* This test differs from the spec. All major browsers give the result here, ignoring the + bottom padding. + */ + test(function(){ + assert_equals(elemNestedOverflow.scrollHeight, 150); + }, "elemNestedOverflow.scrollHeight is the height of its scrolled contents (ignoring padding, since we overflowed)"); + + test(function(){ + assert_equals(elemNestedOverflow.clientWidth, 240); + }, "elemNestedOverflow.clientWidth is the height of the padding edge"); + + /* This test differs from the spec. All major browsers give the result here, ignoring + the right padding. + */ + test(function(){ + assert_equals(elemNestedOverflow.scrollWidth, 250); + }, "elemNestedOverflow.scrollWidth is the width of its scrolled contents (ignoring padding, since we overflowed)"); + + </script> + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/support/1x1-green.png b/tests/wpt/css-tests/cssom-view-1_dev/html/support/1x1-green.png new file mode 100644 index 0000000000000000000000000000000000000000..b98ca0ba0a03c580ac339e4a3653539cfa8edc71 GIT binary patch literal 135 zcmeAS@N?(olHy`uVBq!ia0vp^j3CU&3?x-=hn)gaEa{HEjtmUzPnffIy#(@^1AIbU z85$Vo{9HN_$mQ~MaSW-rm7D-%GchneRloNK$dW8^jVKAuPb(=;EJ|f?Ovz75Rq)JB bOiv9;O-!jQJeg_(RK(!v>gTe~DWM4f4{;-! literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/support/1x1-lime.png b/tests/wpt/css-tests/cssom-view-1_dev/html/support/1x1-lime.png new file mode 100644 index 0000000000000000000000000000000000000000..cb397fb090e199c51e80e4243d1ede03a79aa8d9 GIT binary patch literal 135 zcmeAS@N?(olHy`uVBq!ia0vp^j3CU&3?x-=hn)gaEa{HEjtmUzPnffIy#(@^1AIbU z8U8bv#2r`x<Z^ksIEGZ*N=^W>nHU(Ks^9wqWJ#8|MwA5Sr<If^7Ns&crsOB3DtP85 brl$s_CZ<#to=mj?Dq`?-^>bP0l+XkK_<AEq literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/support/1x1-maroon.png b/tests/wpt/css-tests/cssom-view-1_dev/html/support/1x1-maroon.png new file mode 100644 index 0000000000000000000000000000000000000000..3f86b0721955eb4e0f014102c68c2a9764ef7593 GIT binary patch literal 109 zcmeAS@N?(olHy`uVBq!ia0vp^j3CUx1|;Q0k8}blwj^(N7lsBPi@{?l_gf&vS>O>_ v4B~>Z+sSM@AcNP_#W95AdU8fW!Vi81W){YV4{giyfD#Ozu6{1-oD!M<@rf3U literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/support/1x1-navy.png b/tests/wpt/css-tests/cssom-view-1_dev/html/support/1x1-navy.png new file mode 100644 index 0000000000000000000000000000000000000000..9b9a03955baea7abde9e056e8604e18694e49b66 GIT binary patch literal 109 zcmeAS@N?(olHy`uVBq!ia0vp^j3CUx1|;Q0k8}blwj^(N7a+~R&>-^LA|6O{7I;J! w18EO1b~~AE2W0Six;Tb#Tu)9&$oRp}z{JAX(7`d=3n;<h>FVdQ&MBb@0MNe`HUIzs literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/support/1x1-red.png b/tests/wpt/css-tests/cssom-view-1_dev/html/support/1x1-red.png new file mode 100644 index 0000000000000000000000000000000000000000..6bd73ac101874f306d007e9cea8fa3a1f62dce16 GIT binary patch literal 135 zcmeAS@N?(olHy`uVBq!ia0vp^j3CU&3?x-=hn)gaEa{HEjtmUzPnffIy#(@^1AIbU z|1&U1KH@Y7a=AQR978H@B_{ycObm=q)$jcQvLs7fBT9nv(@M${i&7aJQ}UBi6+Ckj b(^G>|6H_V+Po~-c6)||a`njxgN@xNA!@(kn literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/support/1x1-white.png b/tests/wpt/css-tests/cssom-view-1_dev/html/support/1x1-white.png new file mode 100644 index 0000000000000000000000000000000000000000..dd43faec54ae60a210f1eab6ff4e7c88b8e34c97 GIT binary patch literal 109 zcmeAS@N?(olHy`uVBq!ia0vp^j3CUx1|;Q0k8}blwj^(N7l!{JxM1({$v_d#0*}aI wAngIhZYQ(tfDB$w7sn8e>&ZX<|Nmdl!1<f`@5Sbx4?qb9Pgg&ebxsLQ020p~!2kdN literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/support/60x60-gg-rr.png b/tests/wpt/css-tests/cssom-view-1_dev/html/support/60x60-gg-rr.png new file mode 100644 index 0000000000000000000000000000000000000000..84f5b2a4f1d1865d763cac875bfa6a8c5c576c91 GIT binary patch literal 224 zcmeAS@N?(olHy`uVBq!ia0vp^HXzKw1SGf4^HT*<jKx9jP7LeL$-D$|I14-?iy0WW zg+Z8+Vb&Z8pdfpRr>`sfEmlzu3&R;K0lq*X$r9Iy66gHf+|;}h2Ir#G#FEq$h4Rdj z3<Y;j-+=H&K5?KTUr!gukc@k8FBtMN81S%c^q)Ar(pb!~&BKo6T4>(2QlSh?@M7jG eOI|GCZ+2WP<2UBa)$Kro89ZJ6T-G@yGywqpiaLV; literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/support/60x60-green.png b/tests/wpt/css-tests/cssom-view-1_dev/html/support/60x60-green.png new file mode 100644 index 0000000000000000000000000000000000000000..b3c8cf3eb4c89bd8f2d1ffde051856f375e3a3de GIT binary patch literal 218 zcmeAS@N?(olHy`uVBq!ia0vp^HXzKw1SGf4^HT*<jKx9jP7LeL$-D$|I14-?iy0WW zg+Z8+Vb&Z8pdfpRr>`sfEmlzu3yE9XPACF}BuiW)N}Tg^b5rw57@Uhz6H8K46v{J8 zG8EiBeFMT9`NV;W+&x_!Lo)8YJ?F^Fz`((>;PMkU^HzRy4~NuGe(INq1>ePjdKrGS TIXtNc8p+`4>gTe~DWM4fy9-d) literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/support/60x60-red.png b/tests/wpt/css-tests/cssom-view-1_dev/html/support/60x60-red.png new file mode 100644 index 0000000000000000000000000000000000000000..823f125b8e4a60f780f00443c9c9a10b9fa1f447 GIT binary patch literal 217 zcmeAS@N?(olHy`uVBq!ia0vp^HXzKw1SGf4^HT*<jKx9jP7LeL$-D$|I14-?iy0WW zg+Z8+Vb&Z8pdfpRr>`sfEmlzuQ<1cFzubXBk|nMYCC>S|xv6<249-QVi6yBi3gww4 z84B*6z5(HleBwYwZk{fVAsP4Ho@3->VBlchkp2JMEhm9(EUQo2%VrV@UNUpX$1;`+ Ty_~-WXd;8BtDnm{r-UW|v1>m& literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/support/README b/tests/wpt/css-tests/cssom-view-1_dev/html/support/README new file mode 100644 index 00000000000..69d1737bead --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/support/README @@ -0,0 +1,29 @@ +CSS Global Support Directory +============================ + +This directory contains common support files (such as images and external +style sheets). These are sync'ed into the support directories of all our +test suites. If you have test-suite-specific support files, please add +them to the appropriate test-suite-specific support/ directory. + +If you add to a support/ directory, please run the tools/supportprop.py +script from the top of the repository to cascade support files into the +lower-level support directories. + +Description of the Common Support File Collection +------------------------------------------------- + +The 1x1-* images are all exactly one pixel. + +The swatch-* images all use 15x15 cells. + +The square-* images all use 15x15 cells with one pixel borders. + +The pattern-* images use cells of various sizes: + + pattern-gg-gr.png 20x20 + pattern-grg-rgr-grg.png 20x20 + pattern-rgr-grg-rgr.png 20x20 + pattern-tr.png 15x15 + pattern-grg-rrg-rgg.png 15x15 + diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/support/a-green.css b/tests/wpt/css-tests/cssom-view-1_dev/html/support/a-green.css new file mode 100644 index 00000000000..b0dbb071d5b --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/support/a-green.css @@ -0,0 +1 @@ +.a { color: green; } diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/support/b-green.css b/tests/wpt/css-tests/cssom-view-1_dev/html/support/b-green.css new file mode 100644 index 00000000000..a0473f5ca26 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/support/b-green.css @@ -0,0 +1 @@ +.b { color: green; } \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/support/c-red.css b/tests/wpt/css-tests/cssom-view-1_dev/html/support/c-red.css new file mode 100644 index 00000000000..d4ba5c64e95 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/support/c-red.css @@ -0,0 +1 @@ +.c { color: red; } \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/support/cat.png b/tests/wpt/css-tests/cssom-view-1_dev/html/support/cat.png new file mode 100644 index 0000000000000000000000000000000000000000..85dd7324815b8f8ef1a1d0496224c1a0661db9d8 GIT binary patch literal 1883 zcmV-h2c-CkP)<h;3K|Lk000e1NJLTq003eD003hM0ssI3n4EHI0000LbVXQnLvm$d zbZKvHAXI5>WdH}z3>gRm8%$Aad;kCd2XskIMF-Ff83-yN8ye1400009a7bBm000id z000id0mpBsWB>pL*-1n}RCwC$Tnn<>HVmXZK1a^ho3&SK4-(g{9GN13#R7t8y*I%m zZ)BMw!6g9VLwR{T9*v;e^Z&9e>xbnR^*7(`)-M11{_j7xFNSfJ@$>S&(_i1@5GH@m zhpeXC{afFEKhVJCt^WWpLj3iQEg77_JYJnk79anUvL0gx`(AYZ27s0x;q_WRcJD`A zg+R7jBu}y@4l@kFdQJ7DGoh@H-xD(&>S?#kV5MJwAHN8ovs16uEnknmyyLJw3_Dz} z-2t_1y-WcyWmd+)eVZDoh>C$4rk3Oju)y$mQ#%^)+P>PB74gM`GN6$$a17nlNge7- z3RmB|dPjb|$p?mh6-(D?ThB@WuYf>+sj1twj=G%GFkj5O!mZqLtqotF8cC*N$ri;H z2HQ+$17ses$k7#RTbJz}gD2-`@wiB%W8DFRH7rLV$VR8C-{$0BU^7QA)6xcOPkeLG zIC+y8#pH<ZE4DkLuB$eJu=YD09p6saU_=3B*q=j^t+sjfsKzKVsF6<N*#6N`(<ECy zIXKz+z9s_>H3S(N>pr`5y87*;bv|b^HW*-n7#c-VH5l06wfM%K8tMv%QYu1VMJ&`q zXuT9g-DjG%ok+2IhK&G~#M;r0zu4sf-`3+KmoX<0eCv7>JZuYAQ4+JlXds3Yz$`iq zO!pQ9wr}Yor1)n9bJP~%@)tD+crwU7nJ%PeORd0)1m4F<)qG~XO2nT^iMivEf)z-D zBxjR-YQ3Q3>4*f>(%TkH;D#Ki*aVYot>nkyxLr9zV62-PtQAsVZ<)M&ROZ`q=r-yb zxV0FojhaWJa00$t-zE`xTYXArX#ra%P+dk^apt~h+vO{<A@@#@ZFd70kl?YRKP5&g zb`j&Qn9|8fN_S*$P|_f3a(aM4y>N9i$&>6i;Se`Xu#!Aka_7=8lY{bL`gE8-D*^)! zY7!?ohKiqcXDjd>0jZICXBl_KZ$6sC00LyW54V5*dj5-!>hm-t>Ht(52LoWuR*1xE z2G*{@twTZxdhmIo{825j6wMk`;$*SKGZc>R!t=-#&gkXa<yH8pw79M3dp_ikAFn&8 zlrN9ORLOJsca5=ic6o}b2pc1mIER3bjmUh7pG>kkRkQfHYSKVRo~#WuBph;XemDuD z6qUJ989evMeRwkDj)54kU$UA#IGU-IZHnWTVRA#9kA1APN3ZjwA2_hn2Ug_Nvo#=1 zvdA6|8~BUnoI@62w{|P|2@lwrchE#7bJ6Kq6kBhZllSFE87tja$&a^Vsv9DzjxZA* zQVOrQc2nyJWb8G&wn4GZFkUv;Z=ATnxIprXHN_9;9UHeyvrlY2*kxbFPXGYML&r3) zen%FSp5K}|`|V@N#w>xf>JHCqGnQ($o1mTz0Za^NSrBZ!onF6dnw<3&y(VH1bndXf z391*{FlywkRueb2`q*Y`c5i|#c-`R1y$R0#>_jShsA?F))d087sWd*L&RJQPVgO6z zuKDv)`2I=hc!ut73ss<T4Sc(1p2frAo70eTGSQX~W-TmJr(%YaR!iQ`4Ur=@=?jjU zfTygMe0q~vry0lFm|`8tJ+roq*(WDI6R9%w#!|-Y#%eR(ke!N@^4>>?(GbUMv>AFu zU<y*Z1YJ38rx1Sr_(M)_9Tc=-h}Yr*n2uA=E}I+loFj7auyHJrfHI|Po@I%y`4tj7 zZ|2XgMqBeQS(s^b?xD;O6`XX77pU2u-JQEex9#}uQe_K^?kYOxRi<VJVwG%9W16&C zB}3F3+z%GVHY()dth0|pcjvht>SWGaq^ijA)f<0KH8%k6{9y7l%|MvpgU?6jsh(M$ z5N*sz^783ghS!jcq!BDms81L*G}VLWyHB!u>=8qC&htH>PmP{A<v#~L#&MqpRv4yG zw4r_l@+VBe#^s0kwg9GF@{ms(MG=X;Z*q>HB})c5>>6kFjvP9zMaPHfq~YhEr7DrH zD;~lup<3-juf%_Prr9Z-V4nORxcT&~FF{{2Nk&bqG}pd>$n(1*n4sj(w0;RH6sT{j zbhUJqyjT6iN>h5jrHP`lGXxi;LI(=%bR`2^fsT95-&yGjH)}sb@TGCA(mUti&QX<4 z{U$^U=I18hwKL%pN^cWLwM6MtTI+-Up~5fcjt@Bxe*M77{d?${Py^67eTt4eFFZ)l zh8I~nmB}UQ_u%EtP`CsPA88ZuaO!(Y>9V^z>txmUh$SjH&7r>5XT86X<2m!DSg2-= z-<rS@<i5Y4N=-ro_(K1~{gF<l7M3R7QZPDFa>~W*e9lSUNASn#NOM-@)>-Im^e@d- V<q-+yJ<<RG002ovPDHLkV1mLWjBEe^ literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/support/import-green.css b/tests/wpt/css-tests/cssom-view-1_dev/html/support/import-green.css new file mode 100644 index 00000000000..537104e6633 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/support/import-green.css @@ -0,0 +1 @@ +.import { color: green; } diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/support/import-red.css b/tests/wpt/css-tests/cssom-view-1_dev/html/support/import-red.css new file mode 100644 index 00000000000..9945ef47114 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/support/import-red.css @@ -0,0 +1 @@ +.import { color: red; } diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/support/pattern-gg-gr.png b/tests/wpt/css-tests/cssom-view-1_dev/html/support/pattern-gg-gr.png new file mode 100644 index 0000000000000000000000000000000000000000..a6d65b0d4a1be23b323e984021344ca0b4b5461a GIT binary patch literal 148 zcmeAS@N?(olHy`uVBq!ia0vp^5+KaM#K6EPAvDVp$cgrJaSW-r^)}Fwi$Q^>`%?S& z=cNKi7CQ^*@}*6Bw#d{maAM=f)UGERf;1N-vv1m&p5B~X5^}Di`?-|n{be54CcfOe y>%rS5*MrA-!~*Nf*Suw)+i0M4x&F=aCazsi_#&SL`uqo4!{F)a=d#Wzp$P!0nm8o@ literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/support/pattern-grg-rgr-grg.png b/tests/wpt/css-tests/cssom-view-1_dev/html/support/pattern-grg-rgr-grg.png new file mode 100644 index 0000000000000000000000000000000000000000..9b88fbd81149891234185f54f8b4a0431759f181 GIT binary patch literal 222 zcmeAS@N?(olHy`uVBq!ia0vp^HXzKw1SGf4^HT*<jKx9jP7LeL$-D$|*pj^6T^Rm@ z;DWu&Cj&(|3p^r=85p>QL70(Y)*K0-AbW|YuPgg44gppHg^c>jqd=iJPZ!6KjC*fy z8gelx@Gu{^HvM;TY)zwU$c{IS(wnBFeYtT?qh#}i+>eP179zlX|30sumufTRE+B#Q jJePWx&kbz|5I0kznWOaej?gzin;1M@{an^LB{Ts59-mW( literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/support/pattern-grg-rrg-rgg.png b/tests/wpt/css-tests/cssom-view-1_dev/html/support/pattern-grg-rrg-rgg.png new file mode 100644 index 0000000000000000000000000000000000000000..fcf4f3fd7d95431b8cd1bc5f5129fcb724c5e40f GIT binary patch literal 231 zcmeAS@N?(olHy`uVBq!ia0vp^x**KK#K6FKsNOXi$XVy<;uunK>uuO>p#}vW?s@X} z?5{Vn@(E1fdg>#_p5-zBiX+1VA%+4b26mx2|7={&ovNQ>6SXtcysBl-)c><WmS!Y( zv7BNEzPH=%x{1!KjWd@lmbz(awP;VviDQ{7SW3K#guH|K-#!i8$dVG=UlQ?2Ho)uu z>9DyExiv#HMbsD$XX>p~Q&Z4f6DV?h!MD37E_}{<nz@wk)ekYNY^%>svR6Ky{&{h` fDhG(UQO-Q~pMsNotNvM_%Naaf{an^LB{Ts5h3Hy_ literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/support/pattern-rgr-grg-rgr.png b/tests/wpt/css-tests/cssom-view-1_dev/html/support/pattern-rgr-grg-rgr.png new file mode 100644 index 0000000000000000000000000000000000000000..d454e3a630cd98146c241537dbb3d4cef313f465 GIT binary patch literal 223 zcmeAS@N?(olHy`uVBq!ia0vp^HXzKw1SGf4^HT*<jKx9jP7LeL$-D$|*pj^6T^Rm@ z;DWu&Cj&(|3p^r=85p>QL70(Y)*K0-AbW|YuPgg44gppHg^c>jqd=i}PZ!6KjC*fy z8gelx@Gu{^HvM;TY>lI9$c{Iy(wkbIbyRJ-o`3vUZZ|(OF9Q6nGtzszXKw9ExeG`j k-E5KlqACYx1X%C$w4CD$N64zrK&u!$UHx3vIVCg!00%}%YybcN literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/support/pattern-tr.png b/tests/wpt/css-tests/cssom-view-1_dev/html/support/pattern-tr.png new file mode 100644 index 0000000000000000000000000000000000000000..8b4b25364e0ffbe09e563e13b567fa57330e48d5 GIT binary patch literal 137 zcmeAS@N?(olHy`uVBq!ia0vp^azM<_!N$PA*s|9jBoW~0;uunKD><d1=|2z8e@O`m zi5U_X7?eM1T?jqI(8f2(=fLXOHJ)xxeNNw5J?)fkN19wc<FT&3eZzeBMQLtcCc<9q mCdFSHSg)@*x>)QnGsEKzd}=q=PizO8&EV<k=d#Wzp$Pzi&n><H literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/support/ruler-h-50%.png b/tests/wpt/css-tests/cssom-view-1_dev/html/support/ruler-h-50%.png new file mode 100644 index 0000000000000000000000000000000000000000..cf2eea6b438a11503a89414cbb2f9f1fde55df0c GIT binary patch literal 691 zcmV;k0!;mhP)<h;3K|Lk000e1NJLTq0077U001%w0ssI3;WRTK0007dNkl<Zc-rlq zy{h6s7=~wbiC|&k#KzV}uoP2RSPBY)sHIn;ot@^CYHeD*0k6SU@&o=<wt~SzQP6LT z+1+9bIY?G>_PkGJCLw%0c_-t<Byu8R0TE%rfqnf#2=STCc!0-|BNJiWm+$+t+3XF+ zG01&|R6WZ2a%FMO8DoZFSe6xdSs{%)dLqg~Sttu-y|XONIp^Fk491wQ>y1Vu;JWBp zVzJoqc$A+V$Du&M;PW30)i^&u7Gwd)f-J~_EXabafA}Ss^LRYITrL@7hr_}5ea4uo zs-EXfr_-?8qSw;z_hYfxZnq<%d_G?&6l8n7UMHeNA~7D1DXd_+^X%M^b1Xhu#0egw zA!I?;mp#FUr6!IGxafwE1t1HuAPce}3$g%YK^9~|*6&HOysvn(*(i##-EJ9UsZ`3c zEZerjZtKO@{G-umsZ=7OWHL!ax~|LH&Qw+HcDr($*H`sP-cZ*0d?q4I(}+k2AsaiL zj;3j@>xNm@j~53yo6Tl2nfZLaSS%Dp@jOqqx7+P>I$bK2_WONkdm(-b!)ORuq3(u{ zuZ3eR);?H^UI=h{2M87b0ALRNMpGQFFcbm=3m{kkAXosw0tglW2o^xF0D=Vof&~yP zfM5aey@Mqmboq;Vy>6Q3^?Ef;v)OFQ#$+;S+qUC4@()R>)vA0j20RIU1AN~f3<kMe zPA*0wk^B8lM7P^58jZ@v;czH~5JH%ySu7Suqmd9o*Y(L{67t7~@KDnmXti3a)#`LQ z^?JQ>xhxxNwc21XxLhtDA0P5nd4E{1*Of{|zC6!y9M^SKRYkDydOv{gSOCES0Ko#G Z;3u}YJM}AuyWao+002ovPDHLkV1h`wI+p+d literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/support/ruler-h-50px.png b/tests/wpt/css-tests/cssom-view-1_dev/html/support/ruler-h-50px.png new file mode 100644 index 0000000000000000000000000000000000000000..9f46583665ca6471075227f9e2244f1ba1ffece0 GIT binary patch literal 671 zcmV;Q0$}}#P)<h;3K|Lk000e1NJLTq0074T001%w0ssI35I<<G0007JNkl<Zc-rlq zv8v)g6oyYUj*(OvJMF|<*xQPQHX;gQ=Q9YtMk4qIcD_Uk3p+s&EW|>6gP<0o<3OBS z1j1$6y@J=>jmiI2W)i~T^Pfp3CPtA`(u;`E>xkCAIOm38{A6Fs3%^GNnFzqX(&;o2 zDT)%hOaxRt$_h?dilXdxyZwIuAIl18<k1sR7Ro|dDC@73<(+Ub#)4IrH|Pr?i0E>; z;NbHP*$SvFj1Q0nSpc#i3$h>!vLNd#s;X8h6(Y)HGDMWkW{IfR>*e!#BI@`1L^K!- zq999sxJ98*&~=@N=JPpYY_r)A(Q>)W<#PTuuIolY7N$GT%2E_8{&5kbJC1`e1yhkZ z{QWZiAyepm0H$CHreF%DU<$w#Ou-aPy%*}kd9U|DN?9(KiD<D{L{ydh79vWeQmfTU zN_jXOj>n_dsO!3I+fqu~wx`pn*C<1c`p_d0X`044S5?*jCFXoSGsc7vhGD3xigAie z)6_I=x7!g>wOXy$>t1^zkyx+So-)UAqG0No%Wt8-X!kNxI7<M}X6pN1hP7CW{s%Cs z1EdN70HQYojOJV%M?e6ODu7f0qzV9}3LsSgsR9700!S4=ssK_208$0QoT}fxKB3)i zTb3n+uq><7>A-U2c*&C|r_;$a%~Gl4EyiN8`~5DZbX_+dkNXem%w{vr`D8LF7K>iv z?RKlxYUA;^)oKYL{4FJTXMQ?Xb-Uf|cFP#!ocsSC*Jw0`!=VsjG#WLVO@HH$j}Ibp z9OvtMgBWAUWb%5w;_jEw@bB(q!d+8H6#$q60;CFrn@_JUXnGtsT_OMg002ovPDHLk FV1h+lHID!Q literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/support/ruler-v-100px.png b/tests/wpt/css-tests/cssom-view-1_dev/html/support/ruler-v-100px.png new file mode 100644 index 0000000000000000000000000000000000000000..a837eca2225082917dc952efd5c689e1b51d7bbd GIT binary patch literal 760 zcmeAS@N?(olHy`uVBq!ia0vp^MnHU=gNcEGaWU)iTMP_L`#oJ8Ln>~)opsRfQGkd; ze)kq>afh25lNKiW9??&5?NHJA%O>=XS@{0}+4zG^EwY_?F_M#iv9}3z1aeiSUzA*K zu(aV(kHK?2k3BK|`KL4QXWugp33W=8Xj?T)Nc8vQ(%9`GT4(2eudkH7c2+NL?u$dR z-nKS2Z~j`Y^K+f^ZT|OzL59~vJ9g=>@?L(q?{UxZ$KUny^7DVzuDt!h?mmN?plfyf zmG|FWk8IKrjGUqMkB_(Yd8N`MAGQ3vyhA@<bgG)GyNbMZyBKBu{M65@X^X#_xz|N( zNI2NE)qRbRnzGW(oG=%g^U{3n2NQ}bDsH?iaanTtWy$WlscV`SSj{;6?RV|zP4C{l zb6FCjH+xxSZLO}-<dZ7%&v$p^-rjt(=cAyQ4#>1ywbzy(%Ux#+<}|T#gG9?_n$GnL zUK#SiePsyOw7;>}x9Vgku7B`~<KEgPU54g^2R_?``Yyk`>Xk*`s(JJ0KQFQj%{7r) zbt}iL)bq?nx5a@6yp{&7nsqXz>CffMm(RcYnakO|rl9#~(#I!HTteT!e?R%;lGnRd zMQMom`TO7h&1I+D{M{YwHHiH{KeA^3UX!~oKff$N`Q3$OHK!M>^?md}Ue5YP`;WJ` zoGPcdSKa}V$916$caR7I{lB!WCtmR1qOjFlqjc|ok6s(LH?H5a&h2Na;zQo04{aAN z%iOnj@5)!NUuP>#?C|XJSbx2`vNCh~ZFhHf$0DPdQ%*l!y?XWL&Bph?D}P^q>`h+m zFXb?;somY&_rL4w>#x3=<rC!6*Wd5@<m1PSg>$|yNsZi=Yj1B~pCFjW&0YS{yFmW8 z{%3D_dwKh-9vNpof7j<_ShMfbl=P&-N7}Xp$UV*Eei}Fr#*lj&2u6iKLAmWf*~0AY cw|+4$pP;3B^U*VLV7g}TboFyt=akR{0G}~+v;Y7A literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/support/ruler-v-50px.png b/tests/wpt/css-tests/cssom-view-1_dev/html/support/ruler-v-50px.png new file mode 100644 index 0000000000000000000000000000000000000000..84141028020b7e8cdf2412acbca3c799ba50a534 GIT binary patch literal 757 zcmeAS@N?(olHy`uVBq!ia0vp^MnHU=gNcEGaWU)iTMP_LdpunnLn>~)o#p7Q6)4em z{$d*2BG*@!Lc3jVdA+?Q+2PW(<&`<hUq0SH>~H^wHaWhIaoO!ruE(m{QKE2v_l)kA z-e(KKcYm$vKGDDac}?&6nKO$m!Y2I`xEAGUC@i-6WK{O=zyHpiJNNeO+xv#s?=j!Z zxcM?)V^6`#D~}&Pp5?A$`q-&{Ubpelh>!(auZC((&D%cv^wS>0zQ+>Dv(7%_|5v|q zao)lohkkPybSa7E=I2W%vo$wv-F7j<M5=efqK_3hJ(iZ1hR5E#eOo#2c)7cvt4QFM zmy258?Tg>%?^YeP{?keR*WWj6TXu)LZemGAMMlrg{rmeFE-(LJ<A3S&Y482_`L|4a zV$ruGZ1vX<9}HH``Sp4I^9xs8BD45(?Git7i|IscNI2NU%6%<AQFrUQr?(D+*uNsK z-AeFYem8ITy4x>H79F(9J8|Uk$H$M8Jv&{Tg0!YiDk&_S=(k)oHZIO<*REZcdS={{ zuBxt{yk+-pZOxfJY$vZ@zkcEDg32{MYQY*JDz>(^mVKA=wyUOYzPWhuV$b-4=Px{% z$%e2T?g|j&pZPVd@7osh<~-+>HNJ0@q3xBETkz(j;nVk5#ZE1@IrSJs=KbBV&8b#r zs@K)5tKa`-ZH>~KK0UlH?2I+Pa;AYqh}P8R=H>^<I%3lO$0yypfB*5vA5Q|#-o1Ob zz+%ny*S~-Nb}TZHdiwe2?Afz7Z#KUF-I?$98QU)7&slTl&$qX?-@VRShVSyrk_kFu z-9WGGdw)G^>*dRrJqy()8y@>owKqh|)N|Lm*OhSvei_W#^M7W~=v`a$@8~4GJx?va z-#4{oh}c&&{rS;0ap_x5l~b1MPI0e<Gk|OmIt~)N1C)g`AmVT`zVHuY?mGL;&f7B= Q0uwcZr>mdKI;Vst0OKlsf&c&j literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/support/square-purple.png b/tests/wpt/css-tests/cssom-view-1_dev/html/support/square-purple.png new file mode 100644 index 0000000000000000000000000000000000000000..0f522d78728417b0f74b694e2e47cd41c00359d1 GIT binary patch literal 92 zcmeAS@N?(olHy`uVBq!ia0vp^f*{Pu3?vyBU)>3$*aCb)TpJh~{xkePDssRFB<<<q n7*cU7`N#kLjg3MaSNIuL+z|fjF-g!1D9PaI>gTe~DWM4f*isp& literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/support/square-teal.png b/tests/wpt/css-tests/cssom-view-1_dev/html/support/square-teal.png new file mode 100644 index 0000000000000000000000000000000000000000..e567f51b91bbe40754cb0e0cae066201219cbb4a GIT binary patch literal 92 zcmeAS@N?(olHy`uVBq!ia0vp^f*{Pu3?vyBU)>3$*aCb)Tp1b~82<lv|F?D~NZQlI nF{I*F@{j-f8ykf<uJALgxFP)4W0Ig3P?EvZ)z4*}Q$iB}@>Uv7 literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/support/square-white.png b/tests/wpt/css-tests/cssom-view-1_dev/html/support/square-white.png new file mode 100644 index 0000000000000000000000000000000000000000..5853cbb238cb2d4aba3dd49af3f2ba64d6c7a2de GIT binary patch literal 78 zcmeAS@N?(olHy`uVBq!ia0vp^f*{NRBpBq_B-DVEsHcl#NX4yWiv~UkzCZ4)$}udm Z3=C_{1@!OB{@4Xl=;`X`vd$@?2>|f05A6T| literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/support/swatch-blue.png b/tests/wpt/css-tests/cssom-view-1_dev/html/support/swatch-blue.png new file mode 100644 index 0000000000000000000000000000000000000000..bf2759634d45dbe3df13868341eddb7e4bf24172 GIT binary patch literal 84 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K83?vyP*g1g|bAV5XD+9y-u8K?HKrWA`i(^Q| dt>gp+Mj%g@f$_JNuojTT;OXk;vd$@?2>>P$4{-nh literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/support/swatch-green.png b/tests/wpt/css-tests/cssom-view-1_dev/html/support/swatch-green.png new file mode 100644 index 0000000000000000000000000000000000000000..0aa79b0c86bd72c2220ecce39b9553e2cd3605b9 GIT binary patch literal 84 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K83?vyP*g1g|bAV5XD?<aroS#c40=Yb%E{-7; dw~`YS7=b)p2FBl7!dgHUgQu&X%Q~loCIBjB50U@? literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/support/swatch-lime.png b/tests/wpt/css-tests/cssom-view-1_dev/html/support/swatch-lime.png new file mode 100644 index 0000000000000000000000000000000000000000..55fd7fdaedfc1ed505b111f20fabbca568c68fa5 GIT binary patch literal 84 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K83?vyP*g1g|bAV5XE5m;VlehybfLtC=7srr_ dTgeFuj6j|)1LJQkVJ#qw!PC{xWt~$(6968w4?q9_ literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/support/swatch-orange.png b/tests/wpt/css-tests/cssom-view-1_dev/html/support/swatch-orange.png new file mode 100644 index 0000000000000000000000000000000000000000..d3cd498b52bd88ea6c991f050f1ecb1cfdd136bb GIT binary patch literal 84 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K83?vyP*g1g|bAV5X>;I(;rzSbh26A~kT^vIy dZY3uuFamkH42-|EgtdSy22WQ%mvv4FO#nq@5F-Ep literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/support/swatch-red.png b/tests/wpt/css-tests/cssom-view-1_dev/html/support/swatch-red.png new file mode 100644 index 0000000000000000000000000000000000000000..1caf25c992aa8e23483cddb3334b5f51ec967f4a GIT binary patch literal 84 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K83?vyP*g1g|bAV5X>wg9Y$w!>#KrWA`i(^Q| dt>gp+Mj%g@f$_JNuojTT;OXk;vd$@?2>=8a4uJpw literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/support/swatch-teal.png b/tests/wpt/css-tests/cssom-view-1_dev/html/support/swatch-teal.png new file mode 100644 index 0000000000000000000000000000000000000000..0293ce89dea5c9413e4c829cc83a4e39d8f23300 GIT binary patch literal 156 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K11|+SoP4xm&jKx9jP7LeL$-D$|*pj^6T^Rm@ z;DWu&Cj&(|3p^r=85p>QL70(Y)*K0-AbW|YuPgg4R#65`cCM1`H9#R5PZ!4!jq}MV s85uv$JE$cjEnw)$lDlfNN|Kv_A+(E0c5RvdE}%LFPgg&ebxsLQ0IVw~FaQ7m literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/support/swatch-white.png b/tests/wpt/css-tests/cssom-view-1_dev/html/support/swatch-white.png new file mode 100644 index 0000000000000000000000000000000000000000..1a7d4323d77287d8eb03a89c635b09d099d94869 GIT binary patch literal 85 zcmeAS@N?(olHy`uVBq!ia0vp^{2<H-Bp8I(u6Pcln3BBRT^Jbeb_p*5^7uSm978H@ gCI9%}-<ZL|Fh5TA$_Ah94}dZZp00i_>zopr0Qo5vZ~y=R literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/support/swatch-yellow.png b/tests/wpt/css-tests/cssom-view-1_dev/html/support/swatch-yellow.png new file mode 100644 index 0000000000000000000000000000000000000000..1591aa0e2e274854ed836cf582235ea0202f9c8e GIT binary patch literal 84 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K83?vyP*g1g|bAV5X>;L}@UB|w-0=Yb%E{-7; dw~`YS7=b)p2FBl7!dgHUgQu&X%Q~loCIDbL5Y7Mq literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/support/test-bl.png b/tests/wpt/css-tests/cssom-view-1_dev/html/support/test-bl.png new file mode 100644 index 0000000000000000000000000000000000000000..904e24e996a3e5da93bef89e10c49e24c07d0ed2 GIT binary patch literal 1368 zcmV-e1*iInP)<h;3K|Lk000e1NJLTq003kF003kJ0{{R3g3O3#0000aP)t-s005aY zGnr;)nE(LHGc(L)X3UwH%*@QpW@i7Hng7hp|NsC0s-1y@0000CbW%=J|NsC0|NsC0 z|Ns9065r0w00001VoOIv3m@0SzyJUQ%1J~)RCwC$mrHKsHV}qI#0OA$)CUNV+0PNC z5z>1FDgrZWOHO<59>534BKsDgp7p3B>I7zAF2$Eby&QX;;i_BGr>dV-tSTkfVYNIl zi$7l1mTrsB_C8C-i#4X^3LaLG>jn4e0?941+dy=QV9i9xkG(@4H;@(~ogt^a`43yj z^`**Zh^{Td#Pj%+Qr%fKN-5`g;nYOF+LzqmXhmO+m0gFk>gfe#F-NRAhUdXXT_P3& z5hZ>zhPowUE`a<#=%qb^0(KmTs?O^A;`TX0ocz1q{qO362uJ`J02e5qdmo1g`RwHP z!A7z7fk;yZJFK4j+J<J_!!kFwGv}DTl*m6N!y-fSp;zS$vG4R+^f3f3FkDp6`iZB@ z9Rq0{yOh5|GFgnv$G$b5jmSNW@=3{zpgZ``cV=57#LB;M$gx-;>{j+R-gEgot3{VQ zT_EJMJvHm{U-0*2vCJ(xH5>9<9E?yX{cn>?Cg7{`b(@FBIAj4b8LLlxUA}&DNX9v( z3NQA_a4!BS*5!`~%BqqjA5Y&4uFEHnEyD3&j#zU)o^f5S%cniIzr|OZ3i>ow5`DiR zKV-E(ZYQ3EdZkb6@<UeNeUB?iBFq`D*X2*MI!I#{X}9FZS$$Qmwt_`|Y{-wZnqKV6 z1blp+IyR9XXEjwg7bU<2vXH;?C)8Cq%49XyvL(Ou3A1w<`?`EvZGvCF2-_3drF_v3 zWsvc|O+gEO*$ta$@sA0cmcFE8)2I`NWRx;N{9|`#gBRBOOq5lHKJ|AG{lc-r?c}4) zL-$z5Md6GLEg?qSW3G#N#pKN%xTocLj)Y#BeKpr}_iC1cFHVHGREV^M$HW)&`;U1U zqa(S7SZ8*J-qhDnFUE@G8)EF3n+2Q$s`7)uute1_k<QgF7t5n>rGpW1SV4To*jSQh zlcG$a4=ps-GU>1C2_a&@$I%?>7`aa!VnfzdIeZ#?+sUD|PY~B%U0^7GO|Nu@sDsJ# z@KlWWEXlsO1AjC<{IhGw<M`A>1$M}i5N36xL4oHW;3LYQL{&USeE7rWXggil@q+qy zcqZ;IV<F)o1Yw4G7>JjWW`PLt<%)`T&`L8>V}>Oa<kn^+iI7n5LHubaqvh(*WJr7^ z)T>O$2em@zx|mEC771}cDVqgE!@z!yT>QYv82lFP(%@F<5;wl4TqknAA$72YTMI-# zh4f`KPMMiy>XyGdc~Of)_A<zfoj!JJF(=#0d7SY)+PJ~38KUdBOaRb$*jPKdJK=EV zrkm0Z8xVG(YE0}Yt@-e>+14L1KJ#R!khI&B)WtXi&X5b{lL3*@ZkLC@MvW|+A?7gN zW^9D0T;2*9*?`>~p)-$sKP@gC`DhvB0@0TW$+>vr68OLZ|AFHIA?8UIVp5VL8#iJF zp>x%gNY!OhEyLo1uORl+--}g*Wst2R?yDkOfv7^I8;JRK;rXg-$rj?i69C?WTvb<5 z-Ama!5K|d3=PQC<K{RE8uwP1VM##=LEUkC!&4^ZAZE86{8mYSe$D&=JS`K8398A-< zAkI6YxS&bnwNTEyqw<esfq5o26J~CRQnjl~iN@O75YIKX+q?rYE}CZZF2t>$$WP>d ai~I`(b4pM507-ZN0000<MNUMnLSTZUYM}!F literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/support/test-br.png b/tests/wpt/css-tests/cssom-view-1_dev/html/support/test-br.png new file mode 100644 index 0000000000000000000000000000000000000000..f413ff5c1a0f2ad9f9a345d3e07be57a59a82207 GIT binary patch literal 1045 zcmV+w1nT>VP)<h;3K|Lk000e1NJLTq003kF003kJ0{{R3g3O3#0000aP)t-s005aY zGnr;)nE(LHGc(L)X3UwH%*@QpW@i7Hng7hp|NsC0s-1y@0000CbW%=J|NsC0|NsC0 z|Ns9065r0w00001VoOIv3m@0SzyJUPhe<?1RCwC$ms@V5FcgLlnk;}*nH@}b&;=9; z`W^{0$~+gU<h>dx3m9n@P^7faO%<|&!sf>KZm^B!d3qut2z>beeU2{xp@)&j(02`` zTY^Y(yls!8j-g6{#iqXUOZZmq^{tQRnwIpYptOGKE#wg=geU|udB&pePc3cOueFKs zvzd?t6~fN!7xtH~ecHeFR|~mNE=(hU<zcj=XW{%Yp6UJ6N@ftUzmC!P5cbt`?6jy? zkn>j9-;D~v`nZNntt8~9LC7xNOec_RZz1(-9N|5dP=m0v9-_#(n4W^-V2~txiYhzj z!i$YK*$mpxEQDn<+Gk7q?5d2K>8gc&fN~c@-gEJg62@yGi)KdJFKsVL7OffK1s(gk zuDvn5Y{BU<F%-%e((qKG8u5Ul%idy$ct({KxR(KBlCq)lwQ%n=>I*USjd;i%YrdEb z{Sn*_^roe9hCXX0U8@*Tm5}W<;uM1)L8qv|EjeFw?$DQBbYc7Y_+{2Z;0_;OA3x6W z0PY|Sr^RF&+^N9lo^nJde+0T>e|Q%!CAxA~?GMkwJ^q*@L1D^DW{@@e8aZfW&HlL( zh^h58`-7ZbHV<zaS+W1w2>0aSI!6vcWNu~EzD%TLWzD`y<i?s$R_yCU8Y@az$o?{s ztJ8(Yy+rUffV?jfsir=p{xwOCNIQ`VxeF})mt`W=%)g=j#qveyLfcAweUa7TT2Y9% zj|Z80xYL7JBN#v$SuMm7!T-APcUV_RUG7#w6p(kTFo<b#?tbL$mc9)MbD|J81-xCa zu1iy(+!eIf8G_WOYv>wDV7Xr)zJ+r5pkj?+g<rb&*<VHdwnQ#%k*B`?n)b<=Z)r8M z*w%Y?pY@=}iIK&e%yly-p3Gaau$<qAqFp+%WF>S_u|SWDG`g}53&gW~H?kPATZn)^ z{pHpDF0f_Yc)Al>7VPVTai^XiPQR;MAxJ&d2ec|FrET5HXc}tCS~{7gaV(KcTp<oc zQD|B7>QZ^Z1TjZ~gu`3RQzOf}P2=}cU|fp)kR|{zS!z=9ML<>z3CM~dAz5JrL$V?W z4Q^@!)=5xS07+PK!ylVGm5`=3ktPvYvS1MHR5ItZK3>BJtE{TnlF}3mey44O;Kkq6 ztd@0Ivcj%UvClb}M#-r)(X{Qa==a|U(_!d)YlyiY`vK(N;tTmg{#)cPVxOudoeJ1E P00000NkvXXu0mjfoHYWE literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/support/test-inner-half-size.png b/tests/wpt/css-tests/cssom-view-1_dev/html/support/test-inner-half-size.png new file mode 100644 index 0000000000000000000000000000000000000000..e473bf80efc66766cb32ec2cc60244ed37dc1157 GIT binary patch literal 180 zcmV;l089UgP)<h;3K|Lk000e1NJLTq0015U001%w1^@s7JXu?L0001cNkl<Zc-rli z!4AM62t%pa|Nk<(E?zL=Fq+2^X)3e<nYr61nsxC@Ld$8rPiTZTB&ja&s6as%ZJL|M z=rOcU${2vp2YUvrojv1iz<}=oKePMm#BU3e)Gz&dnG;ue53v^M#Hf!LH5!*`jH~Z= iHN+4@%ynW{5626)ITymFxuX~W0000<MNUMnLSTZVu1667 literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/support/test-outer.png b/tests/wpt/css-tests/cssom-view-1_dev/html/support/test-outer.png new file mode 100644 index 0000000000000000000000000000000000000000..82eeace7fc0c4202f79610978ab423e62abf8939 GIT binary patch literal 2412 zcmZ{mdpOg78^=c{EOMMh4qF~6Bd3rFi9{I*a|(^Nvdq~?QjT*?4xw_Itd@FmT1%@; zkHai-Y6->Aa{4*!H%&eKiag(`-yhHQT+j9WT%Y^CzTeON{@nNL{(P?Mo9&Krl9f@D z0f9iW&L<o^0NV)yNkF9}fteqx$p(R>O`RQ%dM1nrDqQhOXQ7#ug?V#Sa2fmTSTTg# zq5n>b3YP6~G}vwrp{7((H(F%s9=vs(d(vdsw5S`*{!`K=^0e|Hs;%}@ZAe9;YhM#o z_ToaBZbi>ZoPth;c~{8~-g5bm@{$}EyaCQ}|KNtGC?`*cg`T-jp?`3qQTBgZTv?v{ zsdiqg_=L}TaeDHp)WEMH?m}9l;@m~8p=7pF>!36@MZO>-W1E4=+P#fwf=QndMcXv7 z8Z8-fF2Q7mdllSkqq$$v5O4Max@#iK>)>}|J2%opy`et}FlLkY$|k=MPb|h-F&GS# z`yPH&Q53dkQkZ<87kdVuoRE+pLOXW`h4H>u8uuqXC&Rob*li9oo;cl8K)zjxUvIBg z$)w}LH2k-=iDKc?$`Kh8{tr6}PB1uTuEZnV2}8sH8=6vc={^tU1@E=j4k~YXOGQ|X zkJ7bc);}A=x!>Q|ZjgqKn<q^%>txci{z1vOpT5iHp(Eo0q?hU&McH@xcJuaJ!&r=t z?vM4Ew=lmncbCv<w<by^%~!2EMkjjnd54&X#Od#j14r-;{%H*anvq+xT4z&^R~p5` z!xS#*RhyBq#-3+TSq9ZKkNp)WoXPH4H-m1)g6J1}?lL8tMqKR^6?)~97d2-4DhB+5 zUdGN1RJ+xB<5yKLk0NkP^&6b`?>%iQg%g%g!y>UhwjyyUTO+MrE;m#Qlfbq|*dc(4 zZC|6qC(sSHP6V-iNf|!edmH+^^*p7Z*`Fr|qZ;SsTT5vuq{VfH<xT}KU7pO%=gQ-v zpl}EV2Ej;R3K*TfdooFmy;Lk8A$M$3@V7ALWqa%n93N4h!H9%#CFmf!JRkt3OVQHb z4OBETnat*91Ne0G$7cc;8XW%MV(Eh}E-|2Hw!aen*h^t9zNtCIQK#4?o8<B4NzKA= zJ-KtNi74c~C_F{C-09RZX5o7;K}%g#V~>E_u(9E~{{7oy($sRI!r_#kERyw=)upx! zFkJKpcdtUCXezrquiN45{@FUmzL;55Wac?m%0{3=Y46O}udzZQvI2GYkbbEmgW{O# zB*tP_1EQvt8AEX}i1ucwo7Do-=J@@}d(C-#{nOcUixx3CVB}<e`Lw}_xWS0LbrOGg z-0$$Y+G<jqNui?4Zdoxsu$TaOYd=pOXKWEl=;Q$~#Yp}}11wlrY@mF@rT&tjQx2Kc z;EdG(+Qw=(0gQccTmb_LX#GO@-=ToE{*}o1S&Q<qR$oGG$H$7QsF?VyQgL%mGamZB zN8AN0>yfx&o9U9a{k9oC*L+CRvNc6NGmAaSr-%G%isWSVX*Ri;gJFYDY61-RZMJ9s z-`z?*?sVx<BY`>k?ebatm>?cmkvn8n>~gVoVD9PAWg?M?$DhQ9`wq>_JP04nEs0as zGCYyp$>C%Uz4Sbg-8nx$KQdBELKqs3JZpaXR0kdt6C;QpRUl$8ZN2BT1ay8+QeDwI zu62>#lKkWL24UmrHRFc%C7-=lR_WXembP{E_3D{)24gRLd3m`56V=JI3W>Gc@|ghD zM4FnK`Yo)lucxJLsZJ~`ENt|1#h-mVSROoe^Uf(EVVw0btkFTIuq)O|12?%MoRDpA z2yb%N3pEM(Fd#*y6-Dy|)=~4^T7Ra;qxZn6bJQv8eU-G*cUmx99|SwF1S^VO>?Mcy ziKu&}Y5&7fzUR%+PBa2D*ec=Nds+$#Hi85rKsnpQ4u~Tuc0eH#V&@ut(`oSm91zDY za+r0m+14Xz`N-u=du{O&XwC%ls)q~AieIs$nYA?j`i;>+?lE4qb*u__4g0>Wic&zo zR+V36^t{R_-%yv8wr}-_^1lgZWPfdu3O$yvqYW912-Zu#GoWhgovH3+iIzI{A=E)V zcQydV*I><E=u_da(q7DH+)<GXMo3AvA=y+6U6e})iPP3*DUDxWlG~X9WJt}Yx1=aW z9f9!2A{3*A+uM>n-slX6bO6zsU?5t4944(oUP5)GKA$4KLQ4haDC`}{Ps+Ey(|x}` zyBd9~%hyJlk{^d?Lo)0)dE5l)3+)ni{3Zg_i0Xi|wj6^6BU*ew>BPGjg>hpsG84#F zFtJR+%|k#s!XCqF_ng1k)XQe2ZTWsnZZ|ncg`BfZy2~e>2r%0X?)0(asHJc|7s;{V zAyLed^iYKNI1KWOw{~cQNG_eYN!$n`KQ1lw1ky25mK1-sOUN<}du0+Jm-|WOJ}UZk z;MD^*RM{7)%54F<f89d$AT43&eEZMXjD>{-bX|b)&Pma9Hxh~L<9I*zLO^8O^&sR* z+Z4@)s8v757MByxkbSog24S(-^4S*wgp`yZd~#%@yPop)OUea1c4?kMp-^sa!(oST zlOoZRWmaIl?bWsCD++LG;;LvBull2<z%AUo%!0tXV5Zh=aOTXJiC4)n)<ylZJ1#8> zTKN2P=4FEB_A-kIhbh4*)5)gT&@Gq#)33|s%4+1d`N2!(NL$;9utxEAWYvRMlM?)J zUGmy09Ze5xzD#Sp`sH(nNMyos$)$75^*zJVnHX>A58rdx9N!z~iBj0<W}FS}{WTSS zYe(Kh?$^;NgZyZ(TL-Pc;QQJ0!or2b!LYc9i2f%v0)ZgFaP|`7cK3seBhSK1u{4h_ z@XA$Y?)2*bv%CGWDk&;eV+0`iroein?E{ZT1m@$$KVz-tVqdPbjg5@~%n0G(y?uRF z>IU6@K0Y6KJQh(%2_L<F(zQbdtgfyO+|gmbe_i?OiRXdC>Z+=$Xf!%}G|=DQ-_LJ; z{R@v*PI@{ju&;VMdI8E|v)OrCwr%pJojwJ7oSpnX!a|OIC{+5t7cWF27_n5j0g~u3 VAD}`@1i=3k$k`F)P-h>U`X3Goc2EES literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/support/test-tl.png b/tests/wpt/css-tests/cssom-view-1_dev/html/support/test-tl.png new file mode 100644 index 0000000000000000000000000000000000000000..f6ac0ef7e8f6e192c9c26239884bf92b13cf67b8 GIT binary patch literal 1025 zcmV+c1pfPpP)<h;3K|Lk000e1NJLTq003kF003kJ0{{R3g3O3#0000aP)t-s005aY zGnr;)nE(LHGc(L)X3UwH%*@QpW@i7Hng7hp|NsC0s-1y@0000CbW%=J|NsC0|NsC0 z|Ns9065r0w00001VoOIv3m@0SzyJUPb4f%&RCwC$mQ8M}Fc5&T!~r@I9HIMngrJ)4 zQ(^kjbwEn?FN@yb9iWkt>{9_J2)W!F@R;Dg)Lp$zS!5CX;rV991JU){SM-DYAV0|e zM%uPHwukYjIUJ7B*Q=ZTu2z>QMR^bD+hKK83n7YJaQrDaUiXl8N2@a^ART^^rwFp> z9#IKgok0Td0KkTyXt?~yXZ<2qM=a7Vzey#Q*6RDnL2!78qHiE=Ex4QTA^lz~J%kTw zstmq|U|5-t@E~V@SRUkpVNEL-i@q);x>HzkHGJJLeJv;~hO4ub=d-q4IFZka!eTMc zu`{buHGh%+at79akO>1WhSi7Zh!q^12-bv5K>WppZFh6@Am?f!<BIe8<ZyJvwWFFq zUcMXE0yolD)G8oeTdi8;=!mNz`J_B*yPwI?M)m~}`KHs5imGL+R7;7ZWotYNJV;A* zWckKOJq2tdq{0$$(*LL3ZKU7Jv@p{|rJmVH#VIZ=UDrmLfQ3*?VqE$rdu3uFswG*f z%lCCbgf){JI*%YWuFdgL!bDU{f?kyVyi~}>KvZ5Be|6^zTf#t8UO;S(JZAKN+3ASN z3j@6)uNUz|&Al}d$_w_F78jlrimN;suUD0qIN$0jWDohucq6MjSV#Rh_J5@Pc!G3f z_wwM3t6xj|WYw9-AC(uqCDDE%<9fTAh~QL5JzvTmP~Jf3VT_w`oktbsK$-$vb-dY+ zEip&>4?ZIC^U;m)Hw&SbOn!F;BHM*_pCjsYrK_unjA?=AlYvYnPPY~!(~?^V6%rmz z<RXVlV(+q3UGZ)qa4U<3RPu9z8&h()Lr7;MvMclhIow%G<k?0tDQT)8vXJ#M5t59J znRmOBS}sb`n8kPXi@9Ww{-vOHwGp3wv!1nUm_EL5ha0)Qi>kimBF|Bjt{e!>7aIY` z$e-!kZF!dZ$<~h?Ekqu$Hyc?mW_>Y3_Tv~aU&L~krJRVP<{Xh@#O3lKU&e81AT)VW z+l8Kn<$pJj%%^`<NBnV^?sG(rO721gjrZ5ir7vt3{7A{<<H{~jA7`ID<MD7X!t_;S zAdaE>s>@+0W|%%6zicXInEvpcG8HpS|5i+Fr$GIwnD~MX)K@9PlerDlpNfeu>p=af vm<;kz{V6gHxvP)gcJytThUyO|QzGyW8di!g0nvTM00000NkvXXu0mjfqXF-V literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/support/test-tr.png b/tests/wpt/css-tests/cssom-view-1_dev/html/support/test-tr.png new file mode 100644 index 0000000000000000000000000000000000000000..59843ae54b64f6ce4f7e616d4be491c911ea84cf GIT binary patch literal 1235 zcmV;^1T6cBP)<h;3K|Lk000e1NJLTq003kF003kJ0{{R3g3O3#0000aP)t-s005aY zGnr;)nE(LHGc(L)X3UwH%*@QpW@i7Hng7hp|NsC0s-1y@0000CbW%=J|NsC0|NsC0 z|Ns9065r0w00001VoOIv3m@0SzyJUQMM*?KRCwC$mrYXRI26aFnjFBd+de=qdOt_N zRTBGjNv4=J5|!QqHQb;NfD32Vom9jLqFiod>%)>Qhp^}!Di#F%(|iB->7dhx5Bfwt zkx%50BC1n|tx|6vK%_mLQWqnX6K;;U`FDFEg`lc|)m4wlpBK4@05B8)B_V|J%_Vlw za4<$t6qwQ5?fVe&2b-UQ(B}DF=TLGmWzFWjfTsuoBj{dz2tgQl^A0mb5R|kzAGjHU zzt-QIvk5};13=E&LB-q-)byMklsg#6^|GA>1kTt&3kTTsQcmN$3rJ$UlvDpmfxi-B zs(OsZVotq*l2F1pfdVHvT}FC0ny!_MGKlO{^1lTH|7D!$)SEgOs2&9Y@Lbr2kd{<# zhySTga0aoQC4`TSr6hxqDd{GMq~)Oxf{zHUHg7p3EkeB)qa9pj)F50=N<;4i33kkV z+Zkfqoh0ngavtIa&CE4aHM11QcA(<ZnS*i}9_-kZ;*#IbkX(ZM7}U-VnO=(WZJ}O6 zN?{sklqJk*eYL?f(2HA43tsrLxw#P83GW(do-aa9$Cseyd*a!d^}6HVyqYAe5u#PP zW%Z*kP*_6LlYHvTg7zzOR0H&%9HKkXNYMzhoi|%+O@~02w{IClNzOR!w=8e?lQnb@ z%pq|-dqh2QW;SdM6#?$Yk>1_eQZqwfj_k!6`W4$RXtT;($sb=Vf=Ltr<fHQ=Orru; zUn;qEfp&3@JVRc|I^G&)9Ni4A9mSQOHEM$Fe1C)nz8+lD!g*#oEk#T?Ym^*pUDLa@ zP0fmiPIHK0vlU}q+Y5`}FTpe9;sq1LWPGS!Et$V!6C--}V}{^za7DM=t4WauJA@K$ zMP={GAs~J}TSO4+Obz2!!c-2PJ^BD}6(L7%qhFFWlm_w*{A_jB&gyf79BgCs?>w9n z=2B#u(Pr7sL0tWekex*^{dF&8!>RY)KGWH*ffTXTQc}}ioq82%jI{MEgls^5+h<%O z^>H1Z@tJtBVk*~XX#88aM!5hI=gDs?hBhOj+jXMvWV-~H?(^Z!I&l*r!fNriI&I;K z<Iv6+Vk^Q0%(qeN5a+0NAxn^9#sT%s+L9uce-sc;vjLIT_kg$%QSX=-v{o_lKqih2 zSFAju?}mC>UB`|wTQ4r~E*vl-*0C6Qu@PH2eTrR0Wf{T~%Xbknf3wf*S&<+a`6o9M zz*S7^KKgFY$UnJ0HVgZg8jXfF%*c<rs4-Jtxk{$Dr$zap4viTq<*Snt>L({(KZLbt zzRNL^s?W;zZP~w5L&>g+M15Ai**#&3n|Wb>4eGP<`;PGlMsC0muRbf^cs3p5##&fh zIr(FkMaZ}vrt)1Swj2@$kLqXgyORsRw`3xZBX}-f+RL=$<nPGNDtben%J*+U`~KZM xFqlMZdn&(j3r#(mcWQ87&CEBe=q+_3|9^_Lp+#u>Ntgft002ovPDHLkV1lbeOeO#T literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/toc.htm b/tests/wpt/css-tests/cssom-view-1_dev/html/toc.htm new file mode 100644 index 00000000000..efedf2faf16 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/toc.htm @@ -0,0 +1,94 @@ + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html> + <head> + <title>CSSOM View Module Level 1 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> +<body> + <h1>CSSOM View Module Level 1 Test Suite By Chapter</h1> + + <p>This index contains both + <a href="http://wiki.csswg.org/test/selftest">self-describing tests</a> + and reftests. + A separate <a href="reftest-toc.htm">alphabetical reftest index</a> + is provided for tests in <a href="http://wiki.csswg.org/test/reftest">reftest + format</a> along with the <a href="reftest.list">reftest manifest</a>.</p> + + <table> + <tbody id="s1"> + <tr><th><a href="chapter-1.htm">Chapter 1 - + Background</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s2"> + <tr><th><a href="chapter-2.htm">Chapter 2 - + Conformance</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s3"> + <tr><th><a href="chapter-3.htm">Chapter 3 - + Terminology</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s4"> + <tr><th><a href="chapter-4.htm">Chapter 4 - + Common Infrastructure</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s5"> + <tr><th><a href="chapter-5.htm">Chapter 5 - + Extensions to the Window Interface</a></th> + <td>(13 Tests)</td></tr> + </tbody> + <tbody id="s6"> + <tr><th><a href="chapter-6.htm">Chapter 6 - + Extensions to the Document Interface</a></th> + <td>(3 Tests)</td></tr> + </tbody> + <tbody id="s7"> + <tr><th><a href="chapter-7.htm">Chapter 7 - + Extensions to the Element Interface</a></th> + <td>(6 Tests)</td></tr> + </tbody> + <tbody id="s8"> + <tr><th><a href="chapter-8.htm">Chapter 8 - + Extensions to the HTMLElement Interface</a></th> + <td>(1 Tests)</td></tr> + </tbody> + <tbody id="s9"> + <tr><th><a href="chapter-9.htm">Chapter 9 - + Excensions to the HTMLImageElement Interface</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s10"> + <tr><th><a href="chapter-10.htm">Chapter 10 - + Extensions to the Range Interface</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s11"> + <tr><th><a href="chapter-11.htm">Chapter 11 - + Extensions to the MouseEvent Interface</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s12"> + <tr><th><a href="chapter-12.htm">Chapter 12 - + Geometry</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s13"> + <tr><th><a href="chapter-13.htm">Chapter 13 - + Events</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s14"> + <tr><th><a href="chapter-14.htm">Chapter 14 - + CSS properties</a></th> + <td>(0 Tests)</td></tr> + </tbody> + </table> +</body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/ttwf-scrollintoview.htm b/tests/wpt/css-tests/cssom-view-1_dev/html/ttwf-scrollintoview.htm new file mode 100644 index 00000000000..8a9880b98a9 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/ttwf-scrollintoview.htm @@ -0,0 +1,31 @@ +<!DOCTYPE html> +<html><head> + <title>CSSOM View - 6 - scrollIntoView tests</title> + <meta charset="utf-8"> + <link href="mailto:pwx.frontend@gmail.com" rel="author" title="Chris Wu"> + <link href="http://www.w3.org/TR/cssom-view/#dom-element-scrollintoview" rel="help"> + <meta content="dom" name="flags"> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> + <style type="text/css"> + #phitem{height: 2000px;} + #viewitem{width:300px;height:200px;margin:0 auto;background-color: lightgreen;} + </style> +</head> +<body> + <div id="myDiv"> + <div id="phitem"></div> + <div id="viewitem"></div> + </div> + <div id="log"></div> + <script> + var asytest = async_test('check scrollIntoView'); + asytest.step(function(){ + var viewitem = document.getElementById('viewitem'); + viewitem.scrollIntoView(); + assert_true(window.pageYOffset + window.innerHeight > viewitem.offsetTop, "The element isn't in the viewport") + }) + asytest.done() + </script> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/window-interface.htm b/tests/wpt/css-tests/cssom-view-1_dev/html/window-interface.htm new file mode 100644 index 00000000000..e1872955888 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/window-interface.htm @@ -0,0 +1,97 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> +<html> + <head> + <title>CSSOM Window Test: Properties and Functions</title> + <link rel="author" title="Joe Balancio" href="mailto:jlbalancio@gmail.com"> + <link rel="help" href="http://www.w3.org/TR/cssom-view/#extensions-to-the-window-interface"> + <meta name="flags" content="dom"> + <meta name="assert" content="All properties exist and are readonly. All functions exist and are instances of Function"> + <script src="/resources/testharness.js" type="text/javascript"></script> + <script src="/resources/testharnessreport.js" type="text/javascript"></script> + </head> + <body> + <noscript>Test not run - javascript required.</noscript> + <div id="log"></div> + <script id="metadata_cache">/* + { + "window_inherited_functions": { + "assert": ["window functions are inherited"] + }, + "window_functions": { + "assert": ["window functions are instances of Function"] + }, + "window_properties": { + "assert": ["window properties are owned by window"] + }, + "window_properties_readonly": { + "assert": ["window properties are readonly"] + } + } + */</script> + <script type="text/javascript"> + /* + Window Functions + */ + test( + function(){ + assert_inherits(window, "matchMedia"); + assert_inherits(window, "scroll"); + assert_inherits(window, "scrollTo"); + assert_inherits(window, "scrollBy"); + }, 'window_inherited_functions', { + assert: ['window functions are inherited'] + } + ); + + test( + function(){ + assert_true(window.matchMedia instanceof Function); + assert_true(window.scroll instanceof Function); + assert_true(window.scrollTo instanceof Function); + assert_true(window.scrollBy instanceof Function); + }, 'window_functions', { + assert: ['window functions are instances of Function'] + } + ); + + /* + Window Properties + */ + test( + function() { + assert_own_property(window, 'screen'); + assert_own_property(window, 'innerWidth'); + assert_own_property(window, 'innerHeight'); + assert_own_property(window, 'scrollX'); + assert_own_property(window, 'pageXOffset'); + assert_own_property(window, 'scrollY'); + assert_own_property(window, 'pageYOffset'); + assert_own_property(window, 'screenX'); + assert_own_property(window, 'screenY'); + assert_own_property(window, 'outerWidth'); + assert_own_property(window, 'outerHeight'); + }, 'window_properties', { + assert: ['window properties are owned by window'] + } + ); + test( + function() { + assert_readonly(window, 'screen'); + assert_readonly(window, 'innerWidth'); + assert_readonly(window, 'innerHeight'); + assert_readonly(window, 'scrollX'); + assert_readonly(window, 'pageXOffset'); + assert_readonly(window, 'scrollY'); + assert_readonly(window, 'pageYOffset'); + assert_readonly(window, 'screenX'); + assert_readonly(window, 'screenY'); + assert_readonly(window, 'outerWidth'); + assert_readonly(window, 'outerHeight'); + }, 'window_properties_readonly', { + assert: ['window properties are readonly'] + } + ); + + </script> + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/window-screen-height-immutable.htm b/tests/wpt/css-tests/cssom-view-1_dev/html/window-screen-height-immutable.htm new file mode 100644 index 00000000000..868707da49a --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/window-screen-height-immutable.htm @@ -0,0 +1,27 @@ +<!DOCTYPE html> +<html><head> + <title>CSSOM View - 4.2 - screen.height immutability</title> + <link href="mailto:neils.christoffersen@gmail.com" rel="author" title="Neils Christoffersen"> + <link href="http://www.w3.org/TR/cssom-view/#the-screen-interface" rel="help"> + <meta content="dom" name="flags"> + <meta content="screen.height is immutable" name="assert"> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> +</head> +<body> + <div id="myDiv"></div> + <div id="log"></div> + <script> + var originalVal = window.screen.height; + + // try to set window.screen.height + window.screen.height = 0; + + // verify window.screen.height didn't change + test(function() { + assert_equals(window.screen.height, originalVal, "window.screen.height should be immutable") + }, "immutability test"); + </script> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/window-screen-height-mutation-throws.htm b/tests/wpt/css-tests/cssom-view-1_dev/html/window-screen-height-mutation-throws.htm new file mode 100644 index 00000000000..83ff327f67c --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/window-screen-height-mutation-throws.htm @@ -0,0 +1,23 @@ +<!DOCTYPE html> +<html><head> + <title>CSSOM View - 4.2 - screen.height mutation throws exception</title> + <link href="mailto:neils.christoffersen@gmail.com" rel="author" title="Neils Christoffersen"> + <link href="http://www.w3.org/TR/cssom-view/#the-screen-interface" rel="help"> + <meta content="dom" name="flags"> + <meta content="screen.height mutation throws exception" name="assert"> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> +</head> +<body> + <div id="myDiv"></div> + <div id="log"></div> + <script> + test(function() { + assert_throws(null, function() { + window.screen.height = 0 + }), "chaning window.screen.height should throw exception" + }, "mutation exception test"); + </script> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/window-screen-height.htm b/tests/wpt/css-tests/cssom-view-1_dev/html/window-screen-height.htm new file mode 100644 index 00000000000..2db7e28fcdd --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/window-screen-height.htm @@ -0,0 +1,37 @@ +<!DOCTYPE html> +<html><head> + <title>CSSOM View - 4.2 - screen.height range tests</title> + <link href="mailto:neils.christoffersen@gmail.com" rel="author" title="Neils Christoffersen"> + <link href="http://www.w3.org/TR/cssom-view/#the-screen-interface" rel="help"> + <meta content="dom" name="flags"> + <meta content="window.screen.height has sensible values" name="assert"> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> +</head> +<body> + <div id="myDiv"></div> + <div id="log"></div> + <script> + var upperBound = 50000; + + test( + function() { + assert_not_equals(window.screen.height, 0, "window.screen.height is zero") + }, "zero check" + ); + + test( + function() { + assert_true(window.screen.height > 0, "window.screen.height shouldn't be negative") + }, "positive check" + ); + + test( + function() { + assert_true(window.screen.height < upperBound, "window.screen.height shouldn't be so large") + }, "upper bound check" + ); + </script> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/window-screen-width-immutable.htm b/tests/wpt/css-tests/cssom-view-1_dev/html/window-screen-width-immutable.htm new file mode 100644 index 00000000000..9f1580884c3 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/window-screen-width-immutable.htm @@ -0,0 +1,27 @@ +<!DOCTYPE html> +<html><head> + <title>CSSOM View - 4.2 - screen.width immutability</title> + <link href="mailto:neils.christoffersen@gmail.com" rel="author" title="Neils Christoffersen"> + <link href="http://www.w3.org/TR/cssom-view/#the-screen-interface" rel="help"> + <meta content="dom" name="flags"> + <meta content="screen.width is immutable" name="assert"> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> +</head> +<body> + <div id="myDiv"></div> + <div id="log"></div> + <script> + var originalVal = window.screen.width; + + // try to set window.screen.width + window.screen.width = 0; + + // verify window.screen.width didn't change + test(function() { + assert_equals(window.screen.width, originalVal, "window.screen.width should be immutable") + }, "immutability test"); + </script> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/window-screen-width-mutation-throws.htm b/tests/wpt/css-tests/cssom-view-1_dev/html/window-screen-width-mutation-throws.htm new file mode 100644 index 00000000000..28c26e67bad --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/window-screen-width-mutation-throws.htm @@ -0,0 +1,23 @@ +<!DOCTYPE html> +<html><head> + <title>CSSOM View - 4.2 - screen.width mutation throws exception</title> + <link href="mailto:neils.christoffersen@gmail.com" rel="author" title="Neils Christoffersen"> + <link href="http://www.w3.org/TR/cssom-view/#the-screen-interface" rel="help"> + <meta content="dom" name="flags"> + <meta content="screen.width mutation throws exception" name="assert"> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> +</head> +<body> + <div id="myDiv"></div> + <div id="log"></div> + <script> + test(function() { + assert_throws(null, function() { + window.screen.width = 0 + }), "chaning window.screen.width should throw exception" + }, "mutation exception test"); + </script> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/html/window-screen-width.htm b/tests/wpt/css-tests/cssom-view-1_dev/html/window-screen-width.htm new file mode 100644 index 00000000000..5533f95f5ce --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/html/window-screen-width.htm @@ -0,0 +1,37 @@ +<!DOCTYPE html> +<html><head> + <title>CSSOM View - 4.2 - screen.width range tests</title> + <link href="mailto:neils.christoffersen@gmail.com" rel="author" title="Neils Christoffersen"> + <link href="http://www.w3.org/TR/cssom-view/#the-screen-interface" rel="help"> + <meta content="dom" name="flags"> + <meta content="window.screen.width has sensible values" name="assert"> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> +</head> +<body> + <div id="myDiv"></div> + <div id="log"></div> + <script> + var upperBound = 50000; + + test( + function() { + assert_not_equals(window.screen.width, 0, "window.screen.width is zero") + }, "zero check" + ); + + test( + function() { + assert_true(window.screen.width > 0, "window.screen.width shouldn't be negative") + }, "positive check" + ); + + test( + function() { + assert_true(window.screen.width < upperBound, "window.screen.width shouldn't be so large") + }, "upper bound check" + ); + </script> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/implementation-report-TEMPLATE.data b/tests/wpt/css-tests/cssom-view-1_dev/implementation-report-TEMPLATE.data new file mode 100644 index 00000000000..e2735157a51 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/implementation-report-TEMPLATE.data @@ -0,0 +1,51 @@ +# UA version OS version +# UA string (if applicable) +# http://test.csswg.org/suites/cssom-view-1_dev/DATESTAMP/ +# See http://wiki.csswg.org/test/implementation-report for instructions +testname revision result comment +html/caretposition-001.htm ec2bdc9c730d65a0319935187debd4c6811d57b1 ? +xhtml1/caretposition-001.xht ec2bdc9c730d65a0319935187debd4c6811d57b1 ? +html/cssom-getboundingclientrect-001.htm 20226816a4a06d869e8c8d49428a8851a8ab9988 ? +xhtml1/cssom-getboundingclientrect-001.xht 20226816a4a06d869e8c8d49428a8851a8ab9988 ? +html/cssom-getboundingclientrect-002.htm 29a0bd1179d5cbf42b4cb21706022d3328b6b134 ? +xhtml1/cssom-getboundingclientrect-002.xht 29a0bd1179d5cbf42b4cb21706022d3328b6b134 ? +html/cssom-getclientrects.htm 2b2a3a320d19265eab4e6a5a05b20f43c0565e21 ? +xhtml1/cssom-getclientrects.xht 2b2a3a320d19265eab4e6a5a05b20f43c0565e21 ? +html/cssom-view-window-screen-interface.htm 4aaebe055d605dc7f915dac2039087fd7b018439 ? +xhtml1/cssom-view-window-screen-interface.xht 4aaebe055d605dc7f915dac2039087fd7b018439 ? +html/elementfrompoint-001.htm 52a4d67631063dcb64c8d1bba460430195f3877a ? +xhtml1/elementfrompoint-001.xht 52a4d67631063dcb64c8d1bba460430195f3877a ? +html/elementfromposition.htm 78b980b1011fb13154d1ddf81eaf962f59bfa0d7 ? +xhtml1/elementfromposition.xht 78b980b1011fb13154d1ddf81eaf962f59bfa0d7 ? +html/matchmedia.htm 968cc094c6258392a6d1f8dd5eb814f43ed6692f ? +xhtml1/matchmedia.xht 968cc094c6258392a6d1f8dd5eb814f43ed6692f ? +html/matchmediaaddlistener.htm ff9c78237902cf841131fcc2a30344dd737e1f55 ? +xhtml1/matchmediaaddlistener.xht ff9c78237902cf841131fcc2a30344dd737e1f55 ? +html/media-query-list-interface.htm bf107020b2904718b522b5b57fad03c51c059a1e ? +xhtml1/media-query-list-interface.xht bf107020b2904718b522b5b57fad03c51c059a1e ? +html/mediaquerylist-001.htm 5e0c1c5758733b0f2887620db9ce20a6aa00a00c ? +xhtml1/mediaquerylist-001.xht 5e0c1c5758733b0f2887620db9ce20a6aa00a00c ? +html/offsetparent_element_test.htm 42948177cf68f659f7e9dd5147032169558760b1 ? +xhtml1/offsetparent_element_test.xht 42948177cf68f659f7e9dd5147032169558760b1 ? +html/screen-pixeldepth-screen-colordepth001.htm 6747335ed4736a1e6d2dcd446c9c28a0923b2396 ? +xhtml1/screen-pixeldepth-screen-colordepth001.xht 6747335ed4736a1e6d2dcd446c9c28a0923b2396 ? +html/scrollwidthheight.htm dc82a1c1dfddec949ed64ab7ffb8c30625b911b2 ? +xhtml1/scrollwidthheight.xht dc82a1c1dfddec949ed64ab7ffb8c30625b911b2 ? +html/scrollwidthheightwhennotscrollable.htm 5d33a8bab0ff6b187dd544afaefce6b7662128b5 ? +xhtml1/scrollwidthheightwhennotscrollable.xht 5d33a8bab0ff6b187dd544afaefce6b7662128b5 ? +html/ttwf-scrollintoview.htm 3b360b57241e529014b011aec1fd93640f08ffd5 ? +xhtml1/ttwf-scrollintoview.xht 3b360b57241e529014b011aec1fd93640f08ffd5 ? +html/window-interface.htm 40732ddf8d7cd2185d6a6cb9d57d9dcbd2d73c42 ? +xhtml1/window-interface.xht 40732ddf8d7cd2185d6a6cb9d57d9dcbd2d73c42 ? +html/window-screen-height-immutable.htm a5a7e61d3e4844b0e4f6ed83277fda329652e9b6 ? +xhtml1/window-screen-height-immutable.xht a5a7e61d3e4844b0e4f6ed83277fda329652e9b6 ? +html/window-screen-height-mutation-throws.htm 6846cf8927a3214496b4996c95bde1eb3e657552 ? +xhtml1/window-screen-height-mutation-throws.xht 6846cf8927a3214496b4996c95bde1eb3e657552 ? +html/window-screen-height.htm b591d259abd635443575d699dfa1c774968b4746 ? +xhtml1/window-screen-height.xht b591d259abd635443575d699dfa1c774968b4746 ? +html/window-screen-width-immutable.htm 5cb01db5fb1eb56842952d75a921f77e26650cab ? +xhtml1/window-screen-width-immutable.xht 5cb01db5fb1eb56842952d75a921f77e26650cab ? +html/window-screen-width-mutation-throws.htm 7960afc871c5c4cd1fb33681adbc31674af2bbba ? +xhtml1/window-screen-width-mutation-throws.xht 7960afc871c5c4cd1fb33681adbc31674af2bbba ? +html/window-screen-width.htm 43d6fd44dd0ce57fa93c5a2f93fefbf70028fd7a ? +xhtml1/window-screen-width.xht 43d6fd44dd0ce57fa93c5a2f93fefbf70028fd7a ? diff --git a/tests/wpt/css-tests/cssom-view-1_dev/index.htm b/tests/wpt/css-tests/cssom-view-1_dev/index.htm new file mode 100644 index 00000000000..3d0db1b11c9 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/index.htm @@ -0,0 +1,140 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> +<html lang="en"> + <head> + <title>CSSOM View Module Level 1 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "indices.css"; + </style> + </head> + <body> + + + <h1>CSSOM View Module Level 1 Test Suite</h1> + <dt>Test Coordinator:</dt> + <dd>None Yet</dd> + + <p>This is a <strong>Development</strong> + version of the CSSOM View Module Level 1 Test Suite.</p> + + <p>You can provide test data or review the testing results for this test suite:</p> + <dt><a href="http://test.csswg.org/harness/suite/cssom-view-1_dev">Enter Data</a></dt> + <dt><a href="http://test.csswg.org/harness/review/cssom-view-1_dev">Review Results</a></dt> + + + <p>Some tests in the test suite may contain errors. + Please check the latest version of the + <a href="http://www.w3.org/TR/cssom-view/">CSSOM View Module 1 specification</a> + <strong>and its errata</strong> + before assuming a failure is due to an implementation bug and + not a test suite bug.</p> + + + <p> + In time we hope to correct all errors and extend this test suite to + cover all of CSSOM View Module 1. Your help is welcome in this effort. + The appropriate mailing list for submitting tests and bug reports is + <a href="http://lists.w3.org/Archives/Public/public-css-testsuite/">public-css-testsuite@w3.org</a>. + More information on the contribution process and test guidelines is + available on the <a href="http://wiki.csswg.org/test">wiki + page</a>.</p> + + <p>Tests are currently available in these formats:</p> + + <dl> + <dt><a href="html/toc.htm">HTML 5</a></dt> + <dd>HTML 5 tests sent as <code>text/html</code></dd> + <dt><a href="xhtml1/toc.xht">XHTML 1.1</a></dt> + <dd>XHTML 1.1 tests sent as <code>application/xhtml+xml</code></dd> + + + <p>Unless the test instructions explicitly indicate otherwise, + any occurrence of red in a test indicates test failure.</p> + +<h2 id="implement">Implementation Reports</h2> + <p>An <a href="implementation-report-TEMPLATE.data">implementation report template</a> + is available to help with creating implementation reports. See also the + <a href="http://lists.w3.org/Archives/Public/public-css-testsuite/2010Aug/0020.html">explanation</a> + of its format.</p> + +<h2 id="common">Common Assumptions</h2> + + <p>Most of the test suite makes the following assumptions:</p> + <ul> + <li>The X/HTML <code>div</code> element is assigned <code>display: block;</code> + and no other property declaration.</li> + <li>The X/HTML <code>span</code> element is assigned <code>display: inline;</code> + and no other property declaration.</li> + <li>The X/HTML <code>p</code> element is assigned <code>display: block;</code></li> + <li>The X/HTML <code>li</code> element is assigned <code>display: list-item;</code></li> + <li>The X/HTML table elements <code>table</code>, <code>tbody</code>, + <code>tr</code>, and <code>td</code> are assigned the <code>display</code> + values <code>table</code>, <code>table-row-group</code>, + <code>table-row</code>, and <code>table-cell</code>, respectively.</li> + <li>The device can display the sixteen color values associated with the color + keywords <code>black</code>, <code>white</code>, <code>gray</code>, + <code>silver</code>, <code>red</code>, <code>green</code>, <code>blue</code>, + <code>purple</code>, <code>yellow</code>, <code>orange</code>, <code>teal</code>, + <code>fuchsia</code>, <code>maroon</code>, <code>navy</code>, <code>aqua</code>, + and <code>lime</code> as distinct colors.</li> + <li>The UA is set to print background colors and, if it supports graphics, + background images.</li> + <li>The UA implements reasonable page-breaking behavior; e.g., it is assumed + that UAs will not break at every opportunity, but only near the end of + a page unless a page break is forced.</li> + <li>The UA implements reasonable line-breaking behavior; e.g., it is assumed + that spaces between alphanumeric characters provide line breaking + opportunities and that UAs will not break at every opportunity, but only + near the end of a line unless a line break is forced.</li> + </ul> + +<h2 id="uncommon">Uncommon Assumptions</h2> + + <p>In addition, some of the tests make one or more of the following + assumptions:</p> + + <ul> + <li>The device is a full-color device.</li> + <li>The device has a viewport width of at least 640px (approx).</li> + <li>The resolution of the device is 96 CSS pixels per inch.</li> + <li>The UA imposes no minimum font size.</li> + <li>The 'medium' font-size computes to 16px.</li> + <li>The initial value of 'color' is black.</li> + <li>The canvas background is white.</li> + <li>The user stylesheet is empty (except where indicated by the tests).</li> + <li>The device is interactive and uses scroll bars.</li> + </ul> + + <p>The tests that need these assumptions to be true have not yet been + marked, but it is likely that we will add a way to identify these + tests in due course. Tests should avoid relying on these assumptions + unless necessary.</p> + +<h2>License</h2> + + <p>This test suite is licensed under both the + <a href="http://www.w3.org/Consortium/Legal/2008/04-testsuite-license">W3C + Test Suite License</a> and the <a href="http://www.w3.org/Consortium/Legal/2008/03-bsd-license">W3C + 3-clause BSD License</a>. See W3C Legal's <a href="http://www.w3.org/Consortium/Legal/2008/04-testsuite-copyright">explanation + of the licenses</a>.</p> + +<h2>Acknowledgements</h2> + + <p>Many thanks to the following for their contributions:</p> + <ul> + <li>Chris</li> + <li>Chris Rebert</li> + <li>Chris Wu</li> + <li>jingke</li> + <li>Joe Balancio</li> + <li>Neils Christoffersen</li> + <li>neo_and_rayi</li> + <li>Robert O'Callahan</li> + <li>Rune Lillesveen</li> + <li>unbug</li> + </ul> + +</body> +</html> diff --git a/tests/wpt/css-tests/cssom-view-1_dev/index.xht b/tests/wpt/css-tests/cssom-view-1_dev/index.xht new file mode 100644 index 00000000000..7aa35609ed1 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/index.xht @@ -0,0 +1,140 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> + <head> + <title>CSSOM View Module Level 1 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "indices.css"; + </style> + </head> + <body> + + + <h1>CSSOM View Module Level 1 Test Suite</h1> + <dt>Test Coordinator:</dt> + <dd>None Yet</dd> + + <p>This is a <strong>Development</strong> + version of the CSSOM View Module Level 1 Test Suite.</p> + + <p>You can provide test data or review the testing results for this test suite:</p> + <dt><a href="http://test.csswg.org/harness/suite/cssom-view-1_dev">Enter Data</a></dt> + <dt><a href="http://test.csswg.org/harness/review/cssom-view-1_dev">Review Results</a></dt> + + + <p>Some tests in the test suite may contain errors. + Please check the latest version of the + <a href="http://www.w3.org/TR/cssom-view/">CSSOM View Module 1 specification</a> + <strong>and its errata</strong> + before assuming a failure is due to an implementation bug and + not a test suite bug.</p> + + + <p> + In time we hope to correct all errors and extend this test suite to + cover all of CSSOM View Module 1. Your help is welcome in this effort. + The appropriate mailing list for submitting tests and bug reports is + <a href="http://lists.w3.org/Archives/Public/public-css-testsuite/">public-css-testsuite@w3.org</a>. + More information on the contribution process and test guidelines is + available on the <a href="http://wiki.csswg.org/test">wiki + page</a>.</p> + + <p>Tests are currently available in these formats:</p> + + <dl> + <dt><a href="html/toc.htm">HTML 5</a></dt> + <dd>HTML 5 tests sent as <code>text/html</code></dd> + <dt><a href="xhtml1/toc.xht">XHTML 1.1</a></dt> + <dd>XHTML 1.1 tests sent as <code>application/xhtml+xml</code></dd> + + + <p>Unless the test instructions explicitly indicate otherwise, + any occurrence of red in a test indicates test failure.</p> + +<h2 id="implement">Implementation Reports</h2> + <p>An <a href="implementation-report-TEMPLATE.data">implementation report template</a> + is available to help with creating implementation reports. See also the + <a href="http://lists.w3.org/Archives/Public/public-css-testsuite/2010Aug/0020.html">explanation</a> + of its format.</p> + +<h2 id="common">Common Assumptions</h2> + + <p>Most of the test suite makes the following assumptions:</p> + <ul> + <li>The X/HTML <code>div</code> element is assigned <code>display: block;</code> + and no other property declaration.</li> + <li>The X/HTML <code>span</code> element is assigned <code>display: inline;</code> + and no other property declaration.</li> + <li>The X/HTML <code>p</code> element is assigned <code>display: block;</code></li> + <li>The X/HTML <code>li</code> element is assigned <code>display: list-item;</code></li> + <li>The X/HTML table elements <code>table</code>, <code>tbody</code>, + <code>tr</code>, and <code>td</code> are assigned the <code>display</code> + values <code>table</code>, <code>table-row-group</code>, + <code>table-row</code>, and <code>table-cell</code>, respectively.</li> + <li>The device can display the sixteen color values associated with the color + keywords <code>black</code>, <code>white</code>, <code>gray</code>, + <code>silver</code>, <code>red</code>, <code>green</code>, <code>blue</code>, + <code>purple</code>, <code>yellow</code>, <code>orange</code>, <code>teal</code>, + <code>fuchsia</code>, <code>maroon</code>, <code>navy</code>, <code>aqua</code>, + and <code>lime</code> as distinct colors.</li> + <li>The UA is set to print background colors and, if it supports graphics, + background images.</li> + <li>The UA implements reasonable page-breaking behavior; e.g., it is assumed + that UAs will not break at every opportunity, but only near the end of + a page unless a page break is forced.</li> + <li>The UA implements reasonable line-breaking behavior; e.g., it is assumed + that spaces between alphanumeric characters provide line breaking + opportunities and that UAs will not break at every opportunity, but only + near the end of a line unless a line break is forced.</li> + </ul> + +<h2 id="uncommon">Uncommon Assumptions</h2> + + <p>In addition, some of the tests make one or more of the following + assumptions:</p> + + <ul> + <li>The device is a full-color device.</li> + <li>The device has a viewport width of at least 640px (approx).</li> + <li>The resolution of the device is 96 CSS pixels per inch.</li> + <li>The UA imposes no minimum font size.</li> + <li>The 'medium' font-size computes to 16px.</li> + <li>The initial value of 'color' is black.</li> + <li>The canvas background is white.</li> + <li>The user stylesheet is empty (except where indicated by the tests).</li> + <li>The device is interactive and uses scroll bars.</li> + </ul> + + <p>The tests that need these assumptions to be true have not yet been + marked, but it is likely that we will add a way to identify these + tests in due course. Tests should avoid relying on these assumptions + unless necessary.</p> + +<h2>License</h2> + + <p>This test suite is licensed under both the + <a href="http://www.w3.org/Consortium/Legal/2008/04-testsuite-license">W3C + Test Suite License</a> and the <a href="http://www.w3.org/Consortium/Legal/2008/03-bsd-license">W3C + 3-clause BSD License</a>. See W3C Legal's <a href="http://www.w3.org/Consortium/Legal/2008/04-testsuite-copyright">explanation + of the licenses</a>.</p> + +<h2>Acknowledgements</h2> + + <p>Many thanks to the following for their contributions:</p> + <ul> + <li>Chris</li> + <li>Chris Rebert</li> + <li>Chris Wu</li> + <li>jingke</li> + <li>Joe Balancio</li> + <li>Neils Christoffersen</li> + <li>neo_and_rayi</li> + <li>Robert O'Callahan</li> + <li>Rune Lillesveen</li> + <li>unbug</li> + </ul> + +</body> +</html> diff --git a/tests/wpt/css-tests/cssom-view-1_dev/indices.css b/tests/wpt/css-tests/cssom-view-1_dev/indices.css new file mode 100644 index 00000000000..7bc70eeef94 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/indices.css @@ -0,0 +1,96 @@ +/* CSS for CSS Conformance Test Indices */ +/* Written by fantasai */ + +/* Test Tables */ + + table { + border-collapse: collapse; + } + + thead { + border-bottom: 0.2em solid; + } + + tbody { + border: thin solid; + border-style: solid none; + } + + tbody.ch { + border-top: 0.2em solid; + } + tbody.ch th { + font-weight: bold; + } + + tbody th { + border-bottom: silver dotted thin; + background: #EEE; + color: black; + font-weight: normal; + font-style: italic; + } + tbody th :link { + color: gray; + background: transparent; + } + tbody th :visited { + color: #333; + background: transparent; + } + + th, td { + padding: 0.2em; + text-align: left; + vertical-align: baseline; + } + + td { + font-size: 0.9em; + } + + /* flags */ + td abbr { + border: solid thin gray; + padding: 0 0.1em; + cursor: help; + } + td abbr:hover { + background: #ffa; + color: black; + } + + + tr:hover { + background: #F9F9F9; + color: navy; + } + + th a, + td a { + text-decoration: none; + } + th a:hover, + td a:hover, + th a:focus, + td a:focus { + text-decoration: underline; + } + + td a { + display: block; + padding-left: 2em; + text-indent: -1em; + } + .refs { + font-weight: bold; + font-size: larger; + } + .assert, .assert > li { + list-style-type: none; + font-style: italic; + color: gray; + margin: 0; + padding: 0; + text-indent: 0; + } diff --git a/tests/wpt/css-tests/cssom-view-1_dev/testinfo.data b/tests/wpt/css-tests/cssom-view-1_dev/testinfo.data new file mode 100644 index 00000000000..ff32f785edd --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/testinfo.data @@ -0,0 +1,24 @@ +id references title flags links revision credits assertion +CaretPosition-001 CaretPosition script http://www.w3.org/TR/cssom-view/#the-caretposition-interface ec2bdc9c730d65a0319935187debd4c6811d57b1 `unbug`<mailto:tidelgl@gmail.com> +cssom-getBoundingClientRect-001 CSSOM View - 6.1 - getBoundingClientRect tests dom,script http://www.w3.org/TR/cssom-view/#dom-element-getboundingclientrect 20226816a4a06d869e8c8d49428a8851a8ab9988 `Chris Wu`<mailto:pwx.frontend@gmail.com> +cssom-getBoundingClientRect-002 getBoundingClientRect of element outside DOM dom,script http://www.w3.org/TR/cssom-view/#dom-element-getclientrects,http://www.w3.org/TR/cssom-view/#dom-element-getboundingclientrect 29a0bd1179d5cbf42b4cb21706022d3328b6b134 `Chris Rebert`<http://chrisrebert.com> Calling getBoundingClientRect on an element that is outside of the DOM (and therefore does not have an associated layout box) should result in an all-zeroes DOMRect and should definitely not throw an error. +cssom-getClientRects getClientRects of element outside DOM dom,script http://www.w3.org/TR/cssom-view/#dom-element-getclientrects 2b2a3a320d19265eab4e6a5a05b20f43c0565e21 `Chris Rebert`<http://chrisrebert.com> Calling getClientRects on an element that is outside of the DOM (and therefore does not have an associated layout box) should result in an empty DOMRectList and should definitely not throw an error. +cssom-view-window-screen-interface cssom view window screen attribute dom,script http://www.w3.org/TR/cssom-view/#the-screen-interface 4aaebe055d605dc7f915dac2039087fd7b018439 `jingke`<mailto:jingkewhu@gmail.com> window screen interface +elementFromPoint-001 CSSOM View - 5 - extensions to the Document interface dom,script http://www.w3.org/TR/cssom-view/#extensions-to-the-document-interface 52a4d67631063dcb64c8d1bba460430195f3877a `Neils Christoffersen`<mailto:neils.christoffersen@gmail.com> elementFromPoint returns correct element +elementFromPosition CSSOM View elementFromPoint dom,script http://www.w3.org/TR/cssom-view/#extensions-to-the-document-interface,http://www.w3.org/TR/cssom-view/#widl-Document-elementFromPoint-Element-float-x-float-y 78b980b1011fb13154d1ddf81eaf962f59bfa0d7 `Chris`<mailto:pwx.frontend@gmail.com> +matchMedia CSSOM View matchMedia and MediaQueryList dom,script http://www.w3.org/TR/cssom-view/#dom-window-matchmedia,http://www.w3.org/TR/cssom-view/#the-mediaquerylist-interface,http://www.w3.org/TR/cssom/#serializing-media-queries 968cc094c6258392a6d1f8dd5eb814f43ed6692f `Rune Lillesveen`<mailto:rune@opera.com> +matchMediaAddListener CSSOM View matchMedia addListener dom,script http://www.w3.org/TR/cssom-view/#the-mediaquerylist-interface ff9c78237902cf841131fcc2a30344dd737e1f55 `Chris Wu`<mailto:pwx.frontend@gmail.com> +media-query-list-interface Properties and Functions dom,script http://www.w3.org/TR/cssom-view/#extensions-to-the-window-interface,http://www.w3.org/TR/cssom-view/#the-mediaquerylist-interface bf107020b2904718b522b5b57fad03c51c059a1e `Joe Balancio`<mailto:jlbalancio@gmail.com> All properties exist and are readonly. All functions exist and are instances of Function +MediaQueryList-001 MediaQueryList script http://www.w3.org/TR/cssom-view/#the-mediaquerylist-interface 5e0c1c5758733b0f2887620db9ce20a6aa00a00c `unbug`<mailto:tidelgl@gmail.com> +offsetParent_element_test CSSOM View &#8212;&#8212; offsetParent element test script http://www.w3.org/TR/cssom-view/#extensions-to-the-htmlelement-interface,http://www.w3.org/TR/cssom-view/#dom-htmlelement-offsetparent 42948177cf68f659f7e9dd5147032169558760b1 `neo_and_rayi`<mailto:1988wangxiao@gmail.com> +Screen-pixelDepth-Screen-colorDepth001 Screen-pixelDepth,Screen-colorDepth script http://www.w3.org/TR/cssom-view/#the-screen-interface 6747335ed4736a1e6d2dcd446c9c28a0923b2396 `unbug`<mailto:tidelgl@gmail.com> +scrollWidthHeight CSSOM View scrollWidth and scrollHeight dom,script http://www.w3.org/TR/cssom-view/#dom-element-scrollwidth dc82a1c1dfddec949ed64ab7ffb8c30625b911b2 `Robert O'Callahan`<mailto:robert@ocallahan.org> +scrollWidthHeightWhenNotScrollable CSSOM View scrollWidth/scrollHeight (for nonscrollable elements) dom,script http://www.w3.org/TR/cssom-view/#dom-element-scrollwidth 5d33a8bab0ff6b187dd544afaefce6b7662128b5 `Robert O'Callahan`<mailto:robert@ocallahan.org> +ttwf-scrollintoview CSSOM View - 6 - scrollIntoView tests dom,script http://www.w3.org/TR/cssom-view/#dom-element-scrollintoview 3b360b57241e529014b011aec1fd93640f08ffd5 `Chris Wu`<mailto:pwx.frontend@gmail.com> +window-interface Properties and Functions dom,script http://www.w3.org/TR/cssom-view/#extensions-to-the-window-interface 40732ddf8d7cd2185d6a6cb9d57d9dcbd2d73c42 `Joe Balancio`<mailto:jlbalancio@gmail.com> All properties exist and are readonly. All functions exist and are instances of Function +window-screen-height CSSOM View - 4.2 - screen.height range tests dom,script http://www.w3.org/TR/cssom-view/#the-screen-interface b591d259abd635443575d699dfa1c774968b4746 `Neils Christoffersen`<mailto:neils.christoffersen@gmail.com> window.screen.height has sensible values +window-screen-height-immutable CSSOM View - 4.2 - screen.height immutability dom,script http://www.w3.org/TR/cssom-view/#the-screen-interface a5a7e61d3e4844b0e4f6ed83277fda329652e9b6 `Neils Christoffersen`<mailto:neils.christoffersen@gmail.com> screen.height is immutable +window-screen-height-mutation-throws CSSOM View - 4.2 - screen.height mutation throws exception dom,script http://www.w3.org/TR/cssom-view/#the-screen-interface 6846cf8927a3214496b4996c95bde1eb3e657552 `Neils Christoffersen`<mailto:neils.christoffersen@gmail.com> screen.height mutation throws exception +window-screen-width CSSOM View - 4.2 - screen.width range tests dom,script http://www.w3.org/TR/cssom-view/#the-screen-interface 43d6fd44dd0ce57fa93c5a2f93fefbf70028fd7a `Neils Christoffersen`<mailto:neils.christoffersen@gmail.com> window.screen.width has sensible values +window-screen-width-immutable CSSOM View - 4.2 - screen.width immutability dom,script http://www.w3.org/TR/cssom-view/#the-screen-interface 5cb01db5fb1eb56842952d75a921f77e26650cab `Neils Christoffersen`<mailto:neils.christoffersen@gmail.com> screen.width is immutable +window-screen-width-mutation-throws CSSOM View - 4.2 - screen.width mutation throws exception dom,script http://www.w3.org/TR/cssom-view/#the-screen-interface 7960afc871c5c4cd1fb33681adbc31674af2bbba `Neils Christoffersen`<mailto:neils.christoffersen@gmail.com> screen.width mutation throws exception diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/CaretPosition-001.xht b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/CaretPosition-001.xht new file mode 100644 index 00000000000..f530bce9350 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/CaretPosition-001.xht @@ -0,0 +1,43 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSSOM View Module test:CaretPosition</title> + <link href="mailto:tidelgl@gmail.com" rel="author" title="unbug" /> + <link href="http://www.w3.org/TR/cssom-view/#the-caretposition-interface" rel="help" /> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> + <style type="text/css"> + .box{ + position: absolute; + top : 100px; + left : 400px; + width: 100px; + height: 100px; + background-color: #000; + } + </style> +</head> +<body> + <p>This case tests the Screen pixelDepth and colorDepth</p> + <p>The test passes if the value is Element "#box2"</p> + <div class="box" id="box"></div> + <div class="box"></div> + <div class="box"></div> + <div class="box"></div> + <div class="box"></div> + <div class="box"></div> + <div class="box" id="box2"></div> + <div style="left: 405px;background:red;" class="box" id="box3"></div> + <div id="log"></div> + <script> + test(function(){ + assert_equals(getBox('box2'), document.elementFromPoint(400,100), "Expected value for element id is 'box2'"); + },'getBox'); + test(function(){ + assert_equals(null, document.elementFromPoint(400,900), "Expected value for element id is 'box2'"); + },'getBox'); + function getBox(id){ + return document.getElementById(id); + } + </script> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/MediaQueryList-001.xht b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/MediaQueryList-001.xht new file mode 100644 index 00000000000..0b6ce5d33f8 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/MediaQueryList-001.xht @@ -0,0 +1,21 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSSOM View Module test:MediaQueryList</title> + <link href="mailto:tidelgl@gmail.com" rel="author" title="unbug" /> + <link href="http://www.w3.org/TR/cssom-view/#the-mediaquerylist-interface" rel="help" /> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> + <style type="text/css"> + </style> +</head> +<body> + <p>This case tests the MediaQueryList + </p><p>The test passes if the value is 1280/800</p> + <div id="log"></div> + <script> + test(function(){ + assert_equals(window.matchMedia('(device-aspect-ratio: 1280/800)').matches, true, "Expected value for device-aspect-ratio is 1280/800"); + },'matchMedia'); + </script> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/Screen-pixelDepth-Screen-colorDepth001.xht b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/Screen-pixelDepth-Screen-colorDepth001.xht new file mode 100644 index 00000000000..0432d27a57d --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/Screen-pixelDepth-Screen-colorDepth001.xht @@ -0,0 +1,32 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSSOM View Module test:Screen-pixelDepth,Screen-colorDepth</title> + <link href="mailto:tidelgl@gmail.com" rel="author" title="unbug" /> + <link href="http://www.w3.org/TR/cssom-view/#the-screen-interface" rel="help" /> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> + <style type="text/css"> + </style> +</head> +<body> + <p>This case tests the Screen pixelDepth and colorDepth</p> + <p>The test passes if the value is 24</p> + <div id="log"></div> + <script> + test(function(){ + assert_equals(testColorDepth(), 24, "Expected value for colorDepth is 24"); + },'testColorDepth'); + test(function(){ + assert_equals(testPixelDepth(), 24, "Expected value for pixelDepth is 24"); + },'testPixelDepth'); + function testColorDepth(){ + var colorDepth = window.screen.colorDepth; + return colorDepth; + } + function testPixelDepth(){ + var pixelDepth = window.screen.pixelDepth; + return pixelDepth; + } + </script> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-1.xht b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-1.xht new file mode 100644 index 00000000000..89eb7b6156f --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-1.xht @@ -0,0 +1,39 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Background - CSSOM View Module Level 1 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSSOM View Module Level 1 Test Suite</h1> + <h2>Background (0 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s1">+</a> + <a href="http://www.w3.org/TR/cssom-view/#background">1 Background</a></th></tr> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-10.xht b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-10.xht new file mode 100644 index 00000000000..5773f9a6f51 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-10.xht @@ -0,0 +1,45 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Extensions to the Range Interface - CSSOM View Module Level 1 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSSOM View Module Level 1 Test Suite</h1> + <h2>Extensions to the Range Interface (0 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s10"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s10">+</a> + <a href="http://www.w3.org/TR/cssom-view/#extensions-to-the-range-interface">10 Extensions to the Range Interface</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s10.#dom-range-getboundingclientrect"> + <!-- 0 tests --> + </tbody> + <tbody id="s10.#dom-range-getclientrects"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-11.xht b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-11.xht new file mode 100644 index 00000000000..74c202e4b9c --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-11.xht @@ -0,0 +1,69 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Extensions to the MouseEvent Interface - CSSOM View Module Level 1 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSSOM View Module Level 1 Test Suite</h1> + <h2>Extensions to the MouseEvent Interface (0 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s11"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s11">+</a> + <a href="http://www.w3.org/TR/cssom-view/#extensions-to-the-mouseevent-interface">11 Extensions to the MouseEvent Interface</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s11.#dom-mouseevent-clientx"> + <!-- 0 tests --> + </tbody> + <tbody id="s11.#dom-mouseevent-clienty"> + <!-- 0 tests --> + </tbody> + <tbody id="s11.#dom-mouseevent-offsetx"> + <!-- 0 tests --> + </tbody> + <tbody id="s11.#dom-mouseevent-offsety"> + <!-- 0 tests --> + </tbody> + <tbody id="s11.#dom-mouseevent-pagex"> + <!-- 0 tests --> + </tbody> + <tbody id="s11.#dom-mouseevent-pagey"> + <!-- 0 tests --> + </tbody> + <tbody id="s11.#dom-mouseevent-screenx"> + <!-- 0 tests --> + </tbody> + <tbody id="s11.#dom-mouseevent-screeny"> + <!-- 0 tests --> + </tbody> + <tbody id="s11.#dom-mouseevent-x"> + <!-- 0 tests --> + </tbody> + <tbody id="s11.#dom-mouseevent-y"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-12.xht b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-12.xht new file mode 100644 index 00000000000..51dc4b8ff20 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-12.xht @@ -0,0 +1,72 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Geometry - CSSOM View Module Level 1 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSSOM View Module Level 1 Test Suite</h1> + <h2>Geometry (0 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s12"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s12">+</a> + <a href="http://www.w3.org/TR/cssom-view/#geometry">12 Geometry</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s12.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s12.1">+</a> + <a href="http://www.w3.org/TR/cssom-view/#the-geometryutils-interface">12.1 The GeometryUtils Interface</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s12.1.#boxquadoptions"> + <!-- 0 tests --> + </tbody> + <tbody id="s12.1.#convertcoordinateoptions"> + <!-- 0 tests --> + </tbody> + <tbody id="s12.1.#cssboxtype"> + <!-- 0 tests --> + </tbody> + <tbody id="s12.1.#dom-geometryutils-convertpointfromnode"> + <!-- 0 tests --> + </tbody> + <tbody id="s12.1.#dom-geometryutils-convertquadfromnode"> + <!-- 0 tests --> + </tbody> + <tbody id="s12.1.#dom-geometryutils-convertrectfromnode"> + <!-- 0 tests --> + </tbody> + <tbody id="s12.1.#dom-geometryutils-getboxquads"> + <!-- 0 tests --> + </tbody> + <tbody id="s12.1.#geometrynode"> + <!-- 0 tests --> + </tbody> + <tbody id="s12.1.#geometryutils"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-13.xht b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-13.xht new file mode 100644 index 00000000000..0ae5b0b4357 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-13.xht @@ -0,0 +1,51 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Events - CSSOM View Module Level 1 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSSOM View Module Level 1 Test Suite</h1> + <h2>Events (0 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s13"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s13">+</a> + <a href="http://www.w3.org/TR/cssom-view/#events">13 Events</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s13.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s13.1">+</a> + <a href="http://www.w3.org/TR/cssom-view/#resizing-viewports">13.1 Resizing viewports</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s13.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s13.2">+</a> + <a href="http://www.w3.org/TR/cssom-view/#scrolling-0">13.2 Scrolling</a></th></tr> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-14.xht b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-14.xht new file mode 100644 index 00000000000..a2cdd05c912 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-14.xht @@ -0,0 +1,108 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>CSS properties - CSSOM View Module Level 1 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSSOM View Module Level 1 Test Suite</h1> + <h2>CSS properties (0 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s14"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s14">+</a> + <a href="http://www.w3.org/TR/cssom-view/#css-properties">14 CSS properties</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s14.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s14.1">+</a> + <a href="http://www.w3.org/TR/cssom-view/#smooth-scrolling:-the-'scroll-behavior'-property">14.1 Smooth Scrolling: The 'scroll-behavior' Property</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s14.1.#scroll-behavior"> + <!-- 0 tests --> + </tbody> + <tbody id="s14.1.#scroll-behavior-instant"> + <!-- 0 tests --> + </tbody> + <tbody id="s14.1.#scroll-behavior-smooth"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#abstract"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#acknowledgments"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#anolis-references"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#references"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#refsCSSBOX"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#refsCSSDEVICEADAPT"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#refsCSSOM"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#refsCSSTRANSFORMS"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#refsCSSWRITINGMODES"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#refsDOM"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#refsGEOMETRY"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#refsHTML"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#refsRFC2119"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#refsSVG"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#refsWEBIDL"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#sotd"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#toc"> + <!-- 0 tests --> + </tbody> + <tbody id="s.#w3c-doctype"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-2.xht b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-2.xht new file mode 100644 index 00000000000..1aae732997f --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-2.xht @@ -0,0 +1,48 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Conformance - CSSOM View Module Level 1 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSSOM View Module Level 1 Test Suite</h1> + <h2>Conformance (0 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2">+</a> + <a href="http://www.w3.org/TR/cssom-view/#conformance">2 Conformance</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s2.#hardwareLimitations"> + <!-- 0 tests --> + </tbody> + <tbody id="s2.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s2.1">+</a> + <a href="http://www.w3.org/TR/cssom-view/#web-idl">2.1 Web IDL</a></th></tr> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-3.xht b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-3.xht new file mode 100644 index 00000000000..d748003ca2d --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-3.xht @@ -0,0 +1,141 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Terminology - CSSOM View Module Level 1 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSSOM View Module Level 1 Test Suite</h1> + <h2>Terminology (0 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3">+</a> + <a href="http://www.w3.org/TR/cssom-view/#terminology">3 Terminology</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#beginning-edges"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#block-flow-direction"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#border-edge"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#canvas"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#content-edge"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#css-layout-box"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#dompoint"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#dompointinit"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#dompointreadonly"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#domquad"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#domrect"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#domrectlist"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#domrectreadonly"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#ending-edges"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#initial-containing-block"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#inline-base-direction"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#layout-box"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#margin-edge"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#mouseevent"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#mouseeventinit"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#overflow-directions"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#padding-edge"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#scrolling-area"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#scrolling-box"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#svg-layout-box"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#the-html-body-element"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#transforms"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.#viewport"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.1">+</a> + <a href="http://www.w3.org/TR/cssom-view/#css-pixels">3.1 CSS pixels</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s3.2">+</a> + <a href="http://www.w3.org/TR/cssom-view/#zooming">3.2 Zooming</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s3.2.#page-zoom"> + <!-- 0 tests --> + </tbody> + <tbody id="s3.2.#pinch-zoom"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-4.xht b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-4.xht new file mode 100644 index 00000000000..2048bea24d6 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-4.xht @@ -0,0 +1,63 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Common Infrastructure - CSSOM View Module Level 1 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSSOM View Module Level 1 Test Suite</h1> + <h2>Common Infrastructure (0 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s4"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4">+</a> + <a href="http://www.w3.org/TR/cssom-view/#common-infrastructure">4 Common Infrastructure</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s4.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s4.1">+</a> + <a href="http://www.w3.org/TR/cssom-view/#scrolling">4.1 Scrolling</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s4.1.#concept-instant-scroll"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.1.#concept-smooth-scroll"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.1.#concept-smooth-scroll-aborted"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.1.#concept-smooth-scroll-completed"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.1.#perform-a-scroll"> + <!-- 0 tests --> + </tbody> + <tbody id="s4.1.#scroll-to-the-beginning-of-the-document"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-5.xht b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-5.xht new file mode 100644 index 00000000000..1b83223fdbd --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-5.xht @@ -0,0 +1,333 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Extensions to the Window Interface - CSSOM View Module Level 1 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSSOM View Module Level 1 Test Suite</h1> + <h2>Extensions to the Window Interface (13 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s5"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s5">+</a> + <a href="http://www.w3.org/TR/cssom-view/#extensions-to-the-window-interface">5 Extensions to the Window Interface</a></th></tr> + <!-- 2 tests --> + <tr id="media-query-list-interface-5" class="primary dom script"> + <td><strong> + <a href="media-query-list-interface.xht">media-query-list-interface</a></strong></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>Properties and Functions + <ul class="assert"> + <li>All properties exist and are readonly. All functions exist and are instances of Function</li> + </ul> + </td> + </tr> + <tr id="window-interface-5" class="primary dom script"> + <td><strong> + <a href="window-interface.xht">window-interface</a></strong></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>Properties and Functions + <ul class="assert"> + <li>All properties exist and are readonly. All functions exist and are instances of Function</li> + </ul> + </td> + </tr> + </tbody> + <tbody id="s5.#allowed-to-resize-and-move"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#dom-window-devicepixelratio"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#dom-window-innerheight"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#dom-window-innerwidth"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#dom-window-matchmedia"> + <!-- 1 tests --> + <tr id="matchmedia-5.#dom-window-matchmedia" class="primary dom script"> + <td><strong> + <a href="matchMedia.xht">matchmedia</a></strong></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>CSSOM View matchMedia and MediaQueryList + </td> + </tr> + </tbody> + <tbody id="s5.#dom-window-moveby"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#dom-window-moveto"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#dom-window-outerheight"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#dom-window-outerwidth"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#dom-window-pagexoffset"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#dom-window-pageyoffset"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#dom-window-resizeby"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#dom-window-resizeto"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#dom-window-screen"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#dom-window-screenx"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#dom-window-screeny"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#dom-window-scroll"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#dom-window-scrollby"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#dom-window-scrollto"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#dom-window-scrollx"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#dom-window-scrolly"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#scrollbehavior"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.#scrolloptions"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s5.1">+</a> + <a href="http://www.w3.org/TR/cssom-view/#the-features-argument-to-the-open()-method">5.1 The features argument to the open() method</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s5.1.#dom-open-features-height"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.1.#dom-open-features-left"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.1.#dom-open-features-top"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.1.#dom-open-features-width"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.1.#supported-open()-feature-name"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s5.2">+</a> + <a href="http://www.w3.org/TR/cssom-view/#the-mediaquerylist-interface">5.2 The MediaQueryList Interface</a></th></tr> + <!-- 4 tests --> + <tr id="matchmedia-5.2" class="dom script"> + <td> + <a href="matchMedia.xht">matchmedia</a></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>CSSOM View matchMedia and MediaQueryList + </td> + </tr> + <tr id="matchmediaaddlistener-5.2" class="primary dom script"> + <td><strong> + <a href="matchMediaAddListener.xht">matchmediaaddlistener</a></strong></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>CSSOM View matchMedia addListener + </td> + </tr> + <tr id="media-query-list-interface-5.2" class="dom script"> + <td> + <a href="media-query-list-interface.xht">media-query-list-interface</a></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>Properties and Functions + <ul class="assert"> + <li>All properties exist and are readonly. All functions exist and are instances of Function</li> + </ul> + </td> + </tr> + <tr id="mediaquerylist-001-5.2" class="primary script"> + <td><strong> + <a href="MediaQueryList-001.xht">mediaquerylist-001</a></strong></td> + <td></td> + <td><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>MediaQueryList + </td> + </tr> + </tbody> + <tbody id="s5.2.#dom-mediaquerylist-addlistener"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2.#dom-mediaquerylist-matches"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2.#dom-mediaquerylist-media"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2.#dom-mediaquerylist-removelistener"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2.#list-of-media-query-list-listeners"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2.#mediaquerylist"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.2.#mediaquerylistlistener"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.3"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s5.3">+</a> + <a href="http://www.w3.org/TR/cssom-view/#the-screen-interface">5.3 The Screen Interface</a></th></tr> + <!-- 8 tests --> + <tr id="cssom-view-window-screen-interface-5.3" class="primary dom script"> + <td><strong> + <a href="cssom-view-window-screen-interface.xht">cssom-view-window-screen-interface</a></strong></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>cssom view window screen attribute + <ul class="assert"> + <li>window screen interface</li> + </ul> + </td> + </tr> + <tr id="screen-pixeldepth-screen-colordepth001-5.3" class="primary script"> + <td><strong> + <a href="Screen-pixelDepth-Screen-colorDepth001.xht">screen-pixeldepth-screen-colordepth001</a></strong></td> + <td></td> + <td><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>Screen-pixelDepth,Screen-colorDepth + </td> + </tr> + <tr id="window-screen-height-5.3" class="primary dom script"> + <td><strong> + <a href="window-screen-height.xht">window-screen-height</a></strong></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>CSSOM View - 4.2 - screen.height range tests + <ul class="assert"> + <li>window.screen.height has sensible values</li> + </ul> + </td> + </tr> + <tr id="window-screen-height-immutable-5.3" class="primary dom script"> + <td><strong> + <a href="window-screen-height-immutable.xht">window-screen-height-immutable</a></strong></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>CSSOM View - 4.2 - screen.height immutability + <ul class="assert"> + <li>screen.height is immutable</li> + </ul> + </td> + </tr> + <tr id="window-screen-height-mutation-throws-5.3" class="primary dom script"> + <td><strong> + <a href="window-screen-height-mutation-throws.xht">window-screen-height-mutation-throws</a></strong></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>CSSOM View - 4.2 - screen.height mutation throws exception + <ul class="assert"> + <li>screen.height mutation throws exception</li> + </ul> + </td> + </tr> + <tr id="window-screen-width-5.3" class="primary dom script"> + <td><strong> + <a href="window-screen-width.xht">window-screen-width</a></strong></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>CSSOM View - 4.2 - screen.width range tests + <ul class="assert"> + <li>window.screen.width has sensible values</li> + </ul> + </td> + </tr> + <tr id="window-screen-width-immutable-5.3" class="primary dom script"> + <td><strong> + <a href="window-screen-width-immutable.xht">window-screen-width-immutable</a></strong></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>CSSOM View - 4.2 - screen.width immutability + <ul class="assert"> + <li>screen.width is immutable</li> + </ul> + </td> + </tr> + <tr id="window-screen-width-mutation-throws-5.3" class="primary dom script"> + <td><strong> + <a href="window-screen-width-mutation-throws.xht">window-screen-width-mutation-throws</a></strong></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>CSSOM View - 4.2 - screen.width mutation throws exception + <ul class="assert"> + <li>screen.width mutation throws exception</li> + </ul> + </td> + </tr> + </tbody> + <tbody id="s5.3.#dom-screen-availheight"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.3.#dom-screen-availwidth"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.3.#dom-screen-colordepth"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.3.#dom-screen-height"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.3.#dom-screen-pixeldepth"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.3.#dom-screen-width"> + <!-- 0 tests --> + </tbody> + <tbody id="s5.3.#screen"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-6.xht b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-6.xht new file mode 100644 index 00000000000..f79262b9c11 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-6.xht @@ -0,0 +1,105 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Extensions to the Document Interface - CSSOM View Module Level 1 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSSOM View Module Level 1 Test Suite</h1> + <h2>Extensions to the Document Interface (3 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s6"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6">+</a> + <a href="http://www.w3.org/TR/cssom-view/#extensions-to-the-document-interface">6 Extensions to the Document Interface</a></th></tr> + <!-- 2 tests --> + <tr id="elementfrompoint-001-6" class="primary dom script"> + <td><strong> + <a href="elementFromPoint-001.xht">elementfrompoint-001</a></strong></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>CSSOM View - 5 - extensions to the Document interface + <ul class="assert"> + <li>elementFromPoint returns correct element</li> + </ul> + </td> + </tr> + <tr id="elementfromposition-6" class="primary dom script"> + <td><strong> + <a href="elementFromPosition.xht">elementfromposition</a></strong></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>CSSOM View elementFromPoint + </td> + </tr> + </tbody> + <tbody id="s6.#dom-document-caretpositionfrompoint"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.#dom-document-elementfrompoint"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.#dom-document-elementsfrompoint"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s6.1">+</a> + <a href="http://www.w3.org/TR/cssom-view/#the-caretposition-interface">6.1 The CaretPosition Interface</a></th></tr> + <!-- 1 tests --> + <tr id="caretposition-001-6.1" class="primary script"> + <td><strong> + <a href="CaretPosition-001.xht">caretposition-001</a></strong></td> + <td></td> + <td><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>CaretPosition + </td> + </tr> + </tbody> + <tbody id="s6.1.#caret-node"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#caret-offset"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#caret-position"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#caret-range"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#caretposition"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#dom-caretposition-getclientrect"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#dom-caretposition-offset"> + <!-- 0 tests --> + </tbody> + <tbody id="s6.1.#dom-caretposition-offsetnode"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-7.xht b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-7.xht new file mode 100644 index 00000000000..228285fb4c3 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-7.xht @@ -0,0 +1,161 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Extensions to the Element Interface - CSSOM View Module Level 1 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSSOM View Module Level 1 Test Suite</h1> + <h2>Extensions to the Element Interface (6 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s7"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s7">+</a> + <a href="http://www.w3.org/TR/cssom-view/#extensions-to-the-element-interface">7 Extensions to the Element Interface</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s7.#dom-element-clientheight"> + <!-- 0 tests --> + </tbody> + <tbody id="s7.#dom-element-clientleft"> + <!-- 0 tests --> + </tbody> + <tbody id="s7.#dom-element-clienttop"> + <!-- 0 tests --> + </tbody> + <tbody id="s7.#dom-element-clientwidth"> + <!-- 0 tests --> + </tbody> + <tbody id="s7.#dom-element-getboundingclientrect"> + <!-- 2 tests --> + <tr id="cssom-getboundingclientrect-001-7.#dom-element-getboundingclientrect" class="primary dom script"> + <td><strong> + <a href="cssom-getBoundingClientRect-001.xht">cssom-getboundingclientrect-001</a></strong></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>CSSOM View - 6.1 - getBoundingClientRect tests + </td> + </tr> + <tr id="cssom-getboundingclientrect-002-7.#dom-element-getboundingclientrect" class="dom script"> + <td> + <a href="cssom-getBoundingClientRect-002.xht">cssom-getboundingclientrect-002</a></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>getBoundingClientRect of element outside DOM + <ul class="assert"> + <li>Calling getBoundingClientRect on an element that is outside of the DOM (and therefore does not have an associated layout box) should result in an all-zeroes DOMRect and should definitely not throw an error.</li> + </ul> + </td> + </tr> + </tbody> + <tbody id="s7.#dom-element-getclientrects"> + <!-- 2 tests --> + <tr id="cssom-getboundingclientrect-002-7.#dom-element-getclientrects" class="primary dom script"> + <td><strong> + <a href="cssom-getBoundingClientRect-002.xht">cssom-getboundingclientrect-002</a></strong></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>getBoundingClientRect of element outside DOM + <ul class="assert"> + <li>Calling getBoundingClientRect on an element that is outside of the DOM (and therefore does not have an associated layout box) should result in an all-zeroes DOMRect and should definitely not throw an error.</li> + </ul> + </td> + </tr> + <tr id="cssom-getclientrects-7.#dom-element-getclientrects" class="primary dom script"> + <td><strong> + <a href="cssom-getClientRects.xht">cssom-getclientrects</a></strong></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>getClientRects of element outside DOM + <ul class="assert"> + <li>Calling getClientRects on an element that is outside of the DOM (and therefore does not have an associated layout box) should result in an empty DOMRectList and should definitely not throw an error.</li> + </ul> + </td> + </tr> + </tbody> + <tbody id="s7.#dom-element-scrollheight"> + <!-- 0 tests --> + </tbody> + <tbody id="s7.#dom-element-scrollintoview"> + <!-- 1 tests --> + <tr id="ttwf-scrollintoview-7.#dom-element-scrollintoview" class="primary dom script"> + <td><strong> + <a href="ttwf-scrollintoview.xht">ttwf-scrollintoview</a></strong></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>CSSOM View - 6 - scrollIntoView tests + </td> + </tr> + </tbody> + <tbody id="s7.#dom-element-scrollleft"> + <!-- 0 tests --> + </tbody> + <tbody id="s7.#dom-element-scrolltop"> + <!-- 0 tests --> + </tbody> + <tbody id="s7.#dom-element-scrollwidth"> + <!-- 2 tests --> + <tr id="scrollwidthheight-7.#dom-element-scrollwidth" class="primary dom script"> + <td><strong> + <a href="scrollWidthHeight.xht">scrollwidthheight</a></strong></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>CSSOM View scrollWidth and scrollHeight + </td> + </tr> + <tr id="scrollwidthheightwhennotscrollable-7.#dom-element-scrollwidth" class="primary dom script"> + <td><strong> + <a href="scrollWidthHeightWhenNotScrollable.xht">scrollwidthheightwhennotscrollable</a></strong></td> + <td></td> + <td><abbr class="dom" title="Requires Document Object Model support">DOM/JS</abbr><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>CSSOM View scrollWidth/scrollHeight (for nonscrollable elements) + </td> + </tr> + </tbody> + <tbody id="s7.#scrolloptionshorizontal"> + <!-- 0 tests --> + </tbody> + <tbody id="s7.#scrolloptionsvertical"> + <!-- 0 tests --> + </tbody> + <tbody id="s7.1"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s7.1">+</a> + <a href="http://www.w3.org/TR/cssom-view/#the-getclientrects()-and-getboundingclientrect()-methods">7.1 The getClientRects() and getBoundingClientRect() methods</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s7.2"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s7.2">+</a> + <a href="http://www.w3.org/TR/cssom-view/#element-scrolling-members">7.2 Element Scrolling Members</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s7.2.#scroll-an-element"> + <!-- 0 tests --> + </tbody> + <tbody id="s7.2.#scroll-an-element-into-view"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-8.xht b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-8.xht new file mode 100644 index 00000000000..7e706cb6810 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-8.xht @@ -0,0 +1,70 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Extensions to the HTMLElement Interface - CSSOM View Module Level 1 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSSOM View Module Level 1 Test Suite</h1> + <h2>Extensions to the HTMLElement Interface (1 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s8"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s8">+</a> + <a href="http://www.w3.org/TR/cssom-view/#extensions-to-the-htmlelement-interface">8 Extensions to the HTMLElement Interface</a></th></tr> + <!-- 1 tests --> + <tr id="offsetparent_element_test-8" class="primary script"> + <td><strong> + <a href="offsetParent_element_test.xht">offsetparent_element_test</a></strong></td> + <td></td> + <td><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>CSSOM View &amp;#8212;&amp;#8212; offsetParent element test + </td> + </tr> + </tbody> + <tbody id="s8.#dom-htmlelement-offsetheight"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.#dom-htmlelement-offsetleft"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.#dom-htmlelement-offsetparent"> + <!-- 1 tests --> + <tr id="offsetparent_element_test-8.#dom-htmlelement-offsetparent" class="script"> + <td> + <a href="offsetParent_element_test.xht">offsetparent_element_test</a></td> + <td></td> + <td><abbr class="script" title="Executes tests in script">Script</abbr></td> + <td>CSSOM View &amp;#8212;&amp;#8212; offsetParent element test + </td> + </tr> + </tbody> + <tbody id="s8.#dom-htmlelement-offsettop"> + <!-- 0 tests --> + </tbody> + <tbody id="s8.#dom-htmlelement-offsetwidth"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-9.xht b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-9.xht new file mode 100644 index 00000000000..8003b99493f --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/chapter-9.xht @@ -0,0 +1,45 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>Excensions to the HTMLImageElement Interface - CSSOM View Module Level 1 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSSOM View Module Level 1 Test Suite</h1> + <h2>Excensions to the HTMLImageElement Interface (0 tests)</h2> + <table width="100%"> + <col id="test-column"></col> + <col id="refs-column"></col> + <col id="flags-column"></col> + <col id="info-column"></col> + <thead> + <tr> + <th>Test</th> + <th><abbr title="Rendering References">Refs</abbr></th> + <th>Flags</th> + <th>Info</th> + </tr> + </thead> + <tbody id="s9"> + <tr><th colspan="4" scope="rowgroup"> + <a href="#s9">+</a> + <a href="http://www.w3.org/TR/cssom-view/#excensions-to-the-htmlimageelement-interface">9 Excensions to the HTMLImageElement Interface</a></th></tr> + <!-- 0 tests --> + </tbody> + <tbody id="s9.#dom-htmlimageelement-x"> + <!-- 0 tests --> + </tbody> + <tbody id="s9.#dom-htmlimageelement-y"> + <!-- 0 tests --> + </tbody> + </table> + + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/cssom-getBoundingClientRect-001.xht b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/cssom-getBoundingClientRect-001.xht new file mode 100644 index 00000000000..20a917d58af --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/cssom-getBoundingClientRect-001.xht @@ -0,0 +1,31 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSSOM View - 6.1 - getBoundingClientRect tests</title> + <meta charset="utf-8" /> + <link href="mailto:pwx.frontend@gmail.com" rel="author" title="Chris Wu" /> + <link href="http://www.w3.org/TR/cssom-view/#dom-element-getboundingclientrect" rel="help" /> + <meta content="dom" name="flags" /> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> + <style type="text/css"> + #testItem{width:279px;height: 188px;margin:100px 0 0 178px;background-color: purple;font-size: 26px;font-weight:bold;text-align: center;line-height: 188px;} + </style> +</head> +<body> + <div id="testItem">test item</div> + <div id="log"></div> + <script> + var titem = document.getElementById('testItem').getBoundingClientRect(); + test( + function(){ + assert_equals(titem.bottom - titem.top,titem.height,"They donot match") + },"check getBoundingClientRect().top,getBoundingClientRect.bottom()" + ); + test( + function(){ + assert_equals(titem.right - titem.left,titem.width,"They donot match") + },"check getBoundingClientRect().left,getBoundingClientRect.right()" + ) + </script> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/cssom-getBoundingClientRect-002.xht b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/cssom-getBoundingClientRect-002.xht new file mode 100644 index 00000000000..eb04c632c74 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/cssom-getBoundingClientRect-002.xht @@ -0,0 +1,27 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <meta charset="utf-8" /> + <title>CSS Test (CSSOM View): getBoundingClientRect of element outside DOM</title> + <link href="http://chrisrebert.com" rel="author" title="Chris Rebert" /> + <link href="http://www.w3.org/TR/cssom-view/#dom-element-getclientrects" rel="help" /> + <link href="http://www.w3.org/TR/cssom-view/#dom-element-getboundingclientrect" rel="help" /> + <meta content="dom" name="flags" /> + <meta content="Calling getBoundingClientRect on an element that is outside of the DOM (and therefore does not have an associated layout box) should result in an all-zeroes DOMRect and should definitely not throw an error." name="assert" /> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> + <script> + test( + function () { + var rect = document.createElement('div').getBoundingClientRect(); + assert_equals(rect.x, 0, "DOMRect's x should be zero"); + assert_equals(rect.y, 0, "DOMRect's y should be zero"); + assert_equals(rect.width, 0, "DOMRect's width should be zero"); + assert_equals(rect.height, 0, "DOMRect's height should be zero"); + }, + "getBoundingClientRect on a newly-created Element not yet inserted into the DOM should return an all-zeroes DOMRect" + ); + </script> +</head> +<body> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/cssom-getClientRects.xht b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/cssom-getClientRects.xht new file mode 100644 index 00000000000..113645d8f60 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/cssom-getClientRects.xht @@ -0,0 +1,23 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <meta charset="utf-8" /> + <title>CSS Test (CSSOM View): getClientRects of element outside DOM</title> + <link href="http://chrisrebert.com" rel="author" title="Chris Rebert" /> + <link href="http://www.w3.org/TR/cssom-view/#dom-element-getclientrects" rel="help" /> + <meta content="dom" name="flags" /> + <meta content="Calling getClientRects on an element that is outside of the DOM (and therefore does not have an associated layout box) should result in an empty DOMRectList and should definitely not throw an error." name="assert" /> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> + <script> + test( + function () { + var rectList = document.createElement('div').getClientRects(); + assert_equals(rectList.length, 0, "DOMRectList should be empty"); + }, + "getClientRects on a newly-created Element not yet inserted into the DOM should return an empty DOMRectList" + ); + </script> +</head> +<body> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/cssom-view-window-screen-interface.xht b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/cssom-view-window-screen-interface.xht new file mode 100644 index 00000000000..3c835f8dedd --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/cssom-view-window-screen-interface.xht @@ -0,0 +1,39 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Test: cssom view window screen attribute</title> + <link href="mailto:jingkewhu@gmail.com" rel="author" title="jingke" /> + <link href="http://www.w3.org/TR/cssom-view/#the-screen-interface" rel="help" /> + <meta content="dom" name="flags" /> + <meta content="window screen interface" name="assert" /> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> + </head> + <body> + <div id="myDiv"></div> + <div id="log"></div> + <script> + /*test readonly*/ + test(function(){assert_readonly(window.screen, "availWidth");}, "Screen.availWidth is readonly"); + test(function(){assert_readonly(window.screen, "availHeight");}, "Screen.availHeight is readonly"); + test(function(){assert_readonly(window.screen, "width");}, "Screen.width is readonly"); + test(function(){assert_readonly(window.screen, "height");}, "Screen.height is readonly"); + test(function(){assert_readonly(window.screen, "colorDepth");}, "Screen.colorDepth is readonly"); + test(function(){assert_readonly(window.screen, "pixelDepth");}, "Screen.pixelDepth is readonly"); + + + test(function(){assert_true(window.screen.width &gt;= 0 &amp;&amp; window.screen.width &lt; 6000000);}, + "window.screen.width &gt;= 0 &amp;&amp; window.screen.width &lt; 6000000"); + test(function(){assert_true(window.screen.height &gt;= 0 &amp;&amp; window.screen.height &lt; 6000000);}, + "window.screen.height &gt;= 0 &amp;&amp; window.screen.height &lt; 6000000"); + test(function(){assert_true(window.screen.availWidth &gt;= 0 &amp;&amp; window.screen.availWidth &lt;= window.screen.width);}, + "window.screen.availWidth &gt;= 0 &amp;&amp; window.screen.availWidth &lt;= window.screen.width"); + test(function(){assert_true(window.screen.availHeight &gt;= 0 &amp;&amp; window.screen.availHeight &lt;= window.screen.height);}, + "window.screen.availHeight &gt;= 0 &amp;&amp; window.screen.availHeight &lt;= window.screen.height"); + test(function(){assert_true(window.screen.colorDepth == 0 || window.screen.colorDepth == 16 || window.screen.colorDepth == 24 || window.screen.colorDepth == 32);}, + "window.screen.colorDepth == 0 || window.screen.colorDepth == 16 || window.screen.colorDepth == 24 || window.screen.colorDepth == 32"); + test(function(){assert_equals(window.screen.pixelDepth, window.screen.colorDepth);}, + "window.screen.pixelDepth must return the value returned by window.screen.colorDepth"); + </script> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/elementFromPoint-001.xht b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/elementFromPoint-001.xht new file mode 100644 index 00000000000..8eee98e62e2 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/elementFromPoint-001.xht @@ -0,0 +1,33 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSSOM View - 5 - extensions to the Document interface</title> + <link href="mailto:neils.christoffersen@gmail.com" rel="author" title="Neils Christoffersen" /> + <link href="http://www.w3.org/TR/cssom-view/#extensions-to-the-document-interface" rel="help" /> + <meta content="dom" name="flags" /> + <meta content="elementFromPoint returns correct element" name="assert" /> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> + <style> + #targetDiv { + position: absolute; + top: 10; + left: 10; + height: 100px; + width: 100px; + } + </style> +</head> +<body> + <div id="myDiv"></div> + <div id="log"></div> + <div id="targetDiv"> + </div> + <script> + var element = document.elementFromPoint(15, 15); + + test ( function() { + assert_equals(element.id, "targetDiv", "elementFromPoint didn't return the correct element"); + }); + </script> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/elementFromPosition.xht b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/elementFromPosition.xht new file mode 100644 index 00000000000..3efe7b0d38c --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/elementFromPosition.xht @@ -0,0 +1,144 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html lang="en-US" xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Test: CSSOM View elementFromPoint</title> + <meta charset="UTF-8" /> + <link href="mailto:pwx.frontend@gmail.com" rel="author" title="Chris" /> + <link href="http://www.w3.org/TR/cssom-view/#extensions-to-the-document-interface" rel="help" /> + <link href="http://www.w3.org/TR/cssom-view/#widl-Document-elementFromPoint-Element-float-x-float-y" rel="help" /> + <meta content="dom" name="flags" /> + <script src="/resources/testharness.js" type="text/javascript"></script> + <script src="/resources/testharnessreport.js" type="text/javascript"></script> + <script id="metadata_cache">/* +{ + "document.elementFromPoint": {}, + "document.elementFromPoint is a Function": {}, + "test some point of the element: top left corner": {}, + "test some point of the element: top line": {}, + "test some point of the element: top right corner": {}, + "test some point of the element: left line": {}, + "test some point of the element: inside": {}, + "test some point of the element: right line": {}, + "test some point of the element: bottom left corner": {}, + "test some point of the element: bottom line": {}, + "test some point of the element: botom right corner": {}, + "Point (0, 0), return root element(HTML)": {}, + " test negative x ": {}, + " test nagetive y ": {}, + "test outside of viewport": {}, + "test the top of layer": {} +} + */</script> +</head> +<body> + <noscript>Test not run - JavaScript required!</noscript> + <div id="log"></div> + <script type="text/javascript"> + + var body = document.getElementsByTagName( 'body' )[0]; + function createElement( id ) { + var elem = document.createElement( 'div' ); + if ( id &amp;&amp; typeof id == 'string' ) { + elem.id = id; + } + body.appendChild( elem ); + return elem; + } + + function setPosition( config ) { + var target = config.target; + target.style.position = 'absolute'; + target.style.left = config.left + 'px'; + target.style.top = config.top + 'px'; + target.style.width = config.width + 'px'; + target.style.height = config.height + 'px'; + if ( config['z-index'] ) { + target.style.zIndex = config['z-index']; + } + } + + var target = createElement( 'dom-1' ); + setPosition( { + width: 100, + height: 100, + left: 10, + top: 10, + target: target + }); + + test( function () { + assert_inherits( document, 'elementFromPoint' ); + }, 'document.elementFromPoint'); + + test( function () { + assert_true( document.elementFromPoint instanceof Function ); + }, 'document.elementFromPoint is a Function'); + (function(){ + var wrap = [ + // ๅทฆไธŠ่ง’. + {x: 10, y: 10, r: 'top left corner'}, + // ไธŠ่พน็บฟ + {x: 50, y: 10, r: 'top line'}, + // ๅณไธŠ่ง’ + {x: 110, y: 10, r: 'top right corner'}, + // ๅทฆ่พน็บฟ + {x: 10, y: 50, r: 'left line'}, + // ๅ…ƒ็ด ่Œƒๅ›ดๅ†… + {x: 50, y: 50, r: 'inside'}, + // ๅณ่พน็บฟ + {x: 110, y: 10, r: 'right line'}, + // ๅทฆไธ‹่ง’ + {x: 10, y: 110, r: 'bottom left corner'}, + // ไธ‹่พน็บฟ + {x: 50, y: 110, r: 'bottom line'}, + // ๅณไธ‹่ง’ + {x: 110, y: 110, r: 'botom right corner'} + ]; + var i = 0, len = wrap.length, item; + for ( ; i &amp;lt; len; i++ ) { + item = wrap[ i ]; + test( function () { + assert_equals( document.elementFromPoint( item.x, item.y).id == 'dom-1', true ); + }, 'test some point of the element: ' + item.r); + } + })(); + test( function () { + var elem = document.elementFromPoint( 0, 0 ); + assert_true( elem.nodeName == 'HTML' ); + }, 'Point (0, 0), return root element(HTML)' ); + + test( function () { + var elem = document.elementFromPoint( -1000, 0 ); + assert_true( elem == null, 'negative x, return null' ); + }, ' test negative x '); + + test( function () { + var elem = document.elementFromPoint( 0, -1000 ); + assert_true( elem == null, 'negative y, return null' ); + }, ' test nagetive y '); + + test( function () { + var elem = document.elementFromPoint( 100000, 0 ); + assert_true( elem == null ); + }, 'test outside of viewport'); + + test( function () { + var config = { + width: 100, + height: 100, + left: 5, + top: 5 + }; + var target2 = createElement( 'dom-2' ); + config.target = target2; + setPosition( config ); + + var elem = document.elementFromPoint( 10, 10 ); + var elem2 = document.elementFromPoint( 10, 10 ); + assert_equals( elem.id, elem2.id ); + }, 'test the top of layer'); + </script> + + + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/matchMedia.xht b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/matchMedia.xht new file mode 100644 index 00000000000..2b75b4af764 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/matchMedia.xht @@ -0,0 +1,186 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> + <title>CSS Test: CSSOM View matchMedia and MediaQueryList</title> + <link rel="author" title="Rune Lillesveen" href="mailto:rune@opera.com" /> + <link rel="help" href="http://www.w3.org/TR/cssom-view/#dom-window-matchmedia" /> + <link rel="help" href="http://www.w3.org/TR/cssom-view/#the-mediaquerylist-interface" /> + <link rel="help" href="http://www.w3.org/TR/cssom/#serializing-media-queries" /> + <meta name="flags" content="dom" /> + <script src="/resources/testharness.js" type="text/javascript"></script> + <script src="/resources/testharnessreport.js" type="text/javascript"></script> + <style type="text/css"><![CDATA[ + iframe { border: none; } + ]]></style> + </head> + <body> + <noscript>Test not run - javascript required.</noscript> + <div id="log"></div> + <iframe width="200" height="100"></iframe> + <script type="text/javascript"><![CDATA[ + function reflow(doc) { + doc.body.offsetWidth; + } + + var iframe = document.querySelector("iframe"); + var iframe_window = window.frames[0]; + + reflow(iframe_window.document); + + test(function(){ + assert_inherits(window, "matchMedia"); + }, "window.matchMedia exists"); + + test(function(){ + assert_true(window.matchMedia instanceof Function, "FATAL ERROR: The window.matchMedia function is not present. The rest of the testsuite will fail to run."); + }, "window.matchMedia is a Function"); + + var mql, mql1, mql2, mql3; + + test(function(){ + mql = window.matchMedia("all"); + assert_true(mql instanceof MediaQueryList, "matchMedia(\"all\") returned MediaQueryList object."); + }, "window.matchMedia(\"all\")"); + + test(function(){ + assert_idl_attribute(mql, "media", "Check that MediaQueryList.media exists."); + }, "MediaQueryList.media exists"); + + test(function(){ + assert_readonly(mql, "media", "Check that MediaQueryList.media is readonly."); + }, "MediaQueryList.media is readonly"); + + test(function(){ + assert_equals(mql.media, "all"); + }, "MediaQueryList.media for \"all\""); + + test(function(){ + assert_idl_attribute(mql, "matches", "Check that MediaQueryList.matches exists."); + }, "MediaQueryList.matches exists"); + + test(function(){ + assert_readonly(mql, "matches", "Check that MediaQueryList.matches is readonly."); + }, "MediaQueryList.matches is readonly"); + + test(function(){ + assert_true(mql.matches); + }, "MediaQueryList.matches for \"all\""); + + test(function(){ + assert_inherits(mql, "addListener"); + }, "MediaQueryList.addListener exists"); + + test(function(){ + assert_true(mql.addListener instanceof Function); + }, "MediaQueryList.addListener is a Function"); + + test(function(){ + assert_inherits(mql, "removeListener"); + }, "MediaQueryList.removeListener exists"); + + test(function(){ + assert_true(mql.removeListener instanceof Function); + }, "MediaQueryList.removeListener is a Function"); + + test(function(){ + mql = window.matchMedia("::"); + assert_true(mql instanceof MediaQueryList, "window.matchMedia(\"::\") returned MediaQueryList object."); + assert_equals(mql.media, "not all", "MediaQueryList.media serialized as \"not all\" from original string with syntax error."); + }, "MediaQueryList.media syntax error"); + + test(function(){ + assert_false(mql.matches); + }, "MediaQueryList.matches for \"not all\""); + + test(function(){ + mql = iframe_window.matchMedia("(max-width: 199px), all and (min-width: 200px)"); + assert_equals(mql.media, "(max-width: 199px), (min-width: 200px)"); + assert_true(mql.matches); + }, "MediaQueryList.matches for \"(max-width: 199px), all and (min-width: 200px)\"") + + test(function(){ + mql = iframe_window.matchMedia("(min-aspect-ratio: 1/1)"); + assert_true(mql.matches); + }, "MediaQueryList.matches for \"(min-aspect-ratio: 1/1)\""); + + test(function(){ + mql = iframe_window.matchMedia("(width: 200px)"); + assert_true(mql.matches); + }, "MediaQueryList.matches for \"(width: 200px)\""); + + test(function(){ + mql1 = iframe_window.matchMedia("(max-height: 50px)"); + assert_false(mql1.matches); + }, "MediaQueryList.matches for \"(max-height: 50px)\""); + + test(function(){ + mql2 = iframe_window.matchMedia("(min-width: 150px)"); + assert_true(mql2.matches); + }, "MediaQueryList.matches for \"(min-width: 150px)\""); + + var resizeTest = async_test("Resize iframe from 200x100 to 200x50, then to 100x50"); + var listenerOrderTest = async_test("Listeners are called in the order which they have been added"); + var duplicateListenerTest = async_test("Listener added twice is only called once."); + + window.onload = function(){ + + var rmListener = function(x){ + resizeTest.step(function(){ + assert_unreached("removeListener was not successful."); + }); + }; + + var dupListener = function(x){ + duplicateListenerTest.step(function(){ + assert_false(mql1.dupListenerCalled, "Check that this listener has not been called before."); + mql1.dupListenerCalled = true; + }); + }; + + mql1.firstListenerCalled = false; + mql1.dupListenerCalled = false; + // Add listener twice and remove it below. Should not be called. + mql1.addListener(rmListener); + mql1.addListener(rmListener); + // Add listener twice. Should only be called once. + mql1.addListener(dupListener); + mql1.addListener(dupListener); + + mql1.addListener(function(x){ + resizeTest.step(function(){ + assert_equals(x, mql1, "Check that the MediaQueryList passed to the handler is the same that addListener was invoked on."); + assert_true(x.matches, "(max-height: 50px) should now pass."); + assert_true(mql2.matches, "(min-width: 150px) should still pass."); + iframe.width = "100"; + }); + + listenerOrderTest.step(function(){ + assert_false(mql1.firstListenerCalled, "Check that this listener is only called once."); + mql1.firstListenerCalled = true; + }); + }); + + mql1.addListener(function(x){ + listenerOrderTest.step(function(){ + assert_true(mql1.firstListenerCalled, "Check that the listener added last is called last."); + }); + listenerOrderTest.done(); + }); + + mql1.removeListener(rmListener); + + mql2.addListener(function(x){ + duplicateListenerTest.done(); + resizeTest.step(function(){ + assert_equals(x, mql2, "Check that the MediaQueryList passed to the handler is the same that addListener was invoked on."); + assert_true(mql1.matches, "(max-height: 50px) should still pass."); + assert_false(x.matches, "(min-width: 150px) should now fail."); + }); + resizeTest.done(); + }); + + iframe.height = "50"; + };]]> + </script> + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/matchMediaAddListener.xht b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/matchMediaAddListener.xht new file mode 100644 index 00000000000..b5ef6bcbea4 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/matchMediaAddListener.xht @@ -0,0 +1,67 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSS Test: CSSOM View matchMedia addListener</title> + <link href="mailto:pwx.frontend@gmail.com" rel="author" title="Chris Wu" /> + <link href="http://www.w3.org/TR/cssom-view/#the-mediaquerylist-interface" rel="help" /> + <meta content="dom" name="flags" /> + <script src="/resources/testharness.js" type="text/javascript"> + &lt;script src="/resources/testharnessreport.js" type="text/javascript" /&gt; + &lt;style type="text/css"&gt; + iframe { border: none; } + &lt;/style&gt; + &lt;/head&gt; + &lt;body&gt; + &lt;div id="log"&gt;&lt;/div&gt; + &lt;iframe width="200" height="100" id="iframe1" &gt;&lt;/iframe&gt; + &lt;script&gt; + function reflow(doc) { + doc.body.offsetWidth; + } + + var iframe = document.querySelector("iframe"); + var iframe_window = window.frames[0]; + var iframe1 = document.getElementById("iframe1"); + reflow(iframe_window.document); + + var i = 0; + var totalCount = 10; + var count = 0; + var divineCount = 10; + var width_list = [201,199]; + var mq1 = iframe_window.matchMedia("(max-width:200px)"); + mq1.addListener(function(mql){ + + count = count + 1; + + }); + + var equalAssert = async_test("Check for the correct number of event triggers"); + + var changeFrameWidth = function(iWidth) { + iframe1.style.width = iWidth + "px"; + i = (i === 0) ? 1 : 0; + totalCount = totalCount - 1; + if(totalCount &gt; 0) + { + setTimeout(function(){ + changeFrameWidth(width_list[i]); + }, 100); + } + else + { + setTimeout(function(){ + equalAssert.step(function(){ + assert_equals(divineCount, count, "this will be 10 times of event triggers by change width"); + }); + equalAssert.done(); + }, 100); + } + }; + + changeFrameWidth(width_list[0]); + + + </script> + </head><body> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/media-query-list-interface.xht b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/media-query-list-interface.xht new file mode 100644 index 00000000000..569618ad065 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/media-query-list-interface.xht @@ -0,0 +1,69 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> + <title>CSSOM MediaQueryList Test: Properties and Functions</title> + <link rel="author" title="Joe Balancio" href="mailto:jlbalancio@gmail.com" /> + <link rel="help" href="http://www.w3.org/TR/cssom-view/#extensions-to-the-window-interface" /> + <link rel="help" href="http://www.w3.org/TR/cssom-view/#the-mediaquerylist-interface" /> + <meta name="flags" content="dom" /> + <meta name="assert" content="All properties exist and are readonly. All functions exist and are instances of Function" /> + <script src="/resources/testharness.js" type="text/javascript"></script> + <script src="/resources/testharnessreport.js" type="text/javascript"></script> + </head> + <body> + <noscript>Test not run - javascript required.</noscript> + <div id="log"></div> + <script type="text/javascript"><![CDATA[ + var mediaQueryList; + test( + function(){ + assert_inherits(window, "matchMedia"); + mediaQueryList = window.matchMedia('foo'); + }, 'window_inherits_matchmedia', { + assert: ['window.matchMedia is inherited. If this fails, the rest of the test fails.'] + } + ); + /* + MediaQueryList Functions + */ + test( + function(){ + assert_inherits(mediaQueryList, "addListener"); + assert_inherits(mediaQueryList, "removeListener"); + }, 'mediaquerylist_inherited_functions', { + assert: ['MediaQueryList functions are inherited'] + } + ); + + test( + function(){ + assert_true(mediaQueryList.addListener instanceof Function); + assert_true(mediaQueryList.removeListener instanceof Function); + }, 'mediaquerylist_functions', { + assert: ['MediaQueryList functions are instances of Function'] + } + ); + + /* + MediaQueryList Properties + */ + test( + function() { + assert_own_property(mediaQueryList, 'media'); + assert_own_property(mediaQueryList, 'matches'); + }, 'mediaquerylist_properties', { + assert: ['MediaQueryList properties are owned by window'] + } + ); + test( + function() { + assert_readonly(mediaQueryList, 'media'); + assert_readonly(mediaQueryList, 'matches'); + }, 'mediaquerylist_properties_readonly', { + assert: ['MediaQueryList properties are readonly'] + } + ); + ]]> + </script> + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/offsetParent_element_test.xht b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/offsetParent_element_test.xht new file mode 100644 index 00000000000..18dcf6e9abf --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/offsetParent_element_test.xht @@ -0,0 +1,137 @@ +๏ปฟ<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> +<title>CSSOM View โ€”โ€” offsetParent element test</title> +<link href="mailto:1988wangxiao@gmail.com" rel="author" title="neo_and_rayi" /> +<link href="http://www.w3.org/TR/cssom-view/#extensions-to-the-htmlelement-interface" rel="help" /> +<link href="http://www.w3.org/TR/cssom-view/#dom-htmlelement-offsetparent" rel="help" /> +<script src="/resources/testharness.js"></script> +<script src="/resources/testharnessreport.js"></script> +<script id="metadata_cache">/* +{ + "Valid the algorithm rule of offsetParent check step 1": { "assert": "The offsetParent attribute algorithm rule checking passed!" }, + "Valid the algorithm rule of offsetParent check step 2": { "assert": "The offsetParent attribute algorithm rule checking passed!" } +} +*/</script> +<style> +#fixed { + position: fixed; +} + +#none-element { + display:none; +} + +#relative-element { + position: relative; +} + +#absolute-element { + position: absolute; +} +</style> + +</head> +<body> + +<div id="body-element-child"></div> + +<div id="relative-element"> + <div id="relative-element-child"></div> +</div> + +<div id="absolute-element"> + <div id="absolute-element-child"></div> +</div> + +<table id="table-element"> + <caption> + <div id="caption-element-child"></div> + </caption> + + <tbody> + <tr id="table-element-tr"> + <td id="table-element-td"> + <span id="table-element-child"></span> + </td> + </tr> + </tbody> +</table> + +<div id="none-element"> + <a href="#" id="none-element-child-a"></a> + <p id="none-element-child-p"></p> + <video id="none-element-child-video"></video> + <audio id="none-element-child-audio"></audio> + <canvas id="none-element-child-canvas"></canvas> + <svg id="none-element-child-svg" xmlns="http://www.w3.org/2000/svg"></svg> +</div> + +<div id="fixed"> +</div> + +<div id="log"></div> +<script type="text/javascript"> +var getStyle = window.getComputedStyle; +var html = document.documentElement; +var body = document.body; +var fixed_element = document.getElementById('fixed'); +var none_element = document.getElementById('none-element'); + +var none_element_child_a = document.getElementById('none-element-child-a'); +var none_element_child_p = document.getElementById('none-element-child-p'); +var none_element_child_video = document.getElementById('none-element-child-video'); +var none_element_child_audio = document.getElementById('none-element-child-audio'); +var none_element_child_canvas = document.getElementById('none-element-child-canvas'); +var none_element_child_svg = document.getElementById('none-element-child-svg'); + +var relative_element = document.getElementById('relative-element'); +var absolute_element = document.getElementById('absolute-element'); +var td_element = document.getElementsByTagName('td')[0]; + +var body_element_child = document.getElementById('body-element-child'); +var relative_element_child = document.getElementById('relative-element-child'); +var absolute_element_child = document.getElementById('absolute-element-child'); +var table_element_child = document.getElementById('table-element-child'); + +var caption_element_child = document.getElementById('caption-element-child'); +var table_element_tr = document.getElementById('table-element-tr'); +var table_element = document.getElementById('table-element'); + +test(function() { + assert_equals(html.offsetParent,null); + assert_equals(body.offsetParent,null); + assert_equals(fixed_element.offsetParent,null); + assert_equals(none_element.offsetParent,null); + assert_equals(none_element_child_a.offsetParent,null); + assert_equals(none_element_child_p.offsetParent,null); + assert_equals(none_element_child_video.offsetParent,null); + assert_equals(none_element_child_audio.offsetParent,null); + assert_equals(none_element_child_canvas.offsetParent,null); + assert_equals(none_element_child_svg.offsetParent,null); +}, "Valid the algorithm rule of offsetParent check step 1", +{ assert: "The offsetParent attribute algorithm rule checking passed!" } +); + +test(function() { + assert_equals(body_element_child.offsetParent,body); + assert_equals(window.getComputedStyle(relative_element).position,'relative'); + assert_equals(relative_element_child.offsetParent,relative_element); + assert_equals(window.getComputedStyle(absolute_element).position,'absolute'); + assert_equals(absolute_element_child.offsetParent,absolute_element); + assert_equals(window.getComputedStyle(td_element).position,'static'); + assert_equals(table_element_child.offsetParent,td_element); + assert_equals(window.getComputedStyle(table_element_tr).position,'static'); + assert_equals(table_element_tr.offsetParent,table_element); + assert_equals(window.getComputedStyle(caption_element_child).position,'static'); + assert_equals(caption_element_child.offsetParent,table_element); + assert_equals(window.getComputedStyle(td_element).position,'static'); + assert_equals(td_element.offsetParent,table_element); +}, "Valid the algorithm rule of offsetParent check step 2", +{ assert: "The offsetParent attribute algorithm rule checking passed!" } +); + +</script> + + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/reftest-toc.xht b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/reftest-toc.xht new file mode 100644 index 00000000000..8ca75a140e8 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/reftest-toc.xht @@ -0,0 +1,30 @@ + + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>CSSOM View Module Level 1 Test Suite Reftest Index</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> + + <body> + + <h1>CSSOM View Module Level 1 Test Suite Reftest Index</h1> + <table width="100%"> + <col id="test-column"></col> + <col id="ref-column"></col> + <col id="flags-column"></col> + <thead> + <tr> + <th>Test</th> + <th>Reference</th> + <th>Flags</th> + </tr> + </thead> + </table> + + </body> +</html> diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/reftest.list b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/reftest.list new file mode 100644 index 00000000000..8b137891791 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/reftest.list @@ -0,0 +1 @@ + diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/scrollWidthHeight.xht b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/scrollWidthHeight.xht new file mode 100644 index 00000000000..0098553f125 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/scrollWidthHeight.xht @@ -0,0 +1,146 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> + <title>CSS Test: CSSOM View scrollWidth and scrollHeight</title> + <link rel="author" title="Robert O'Callahan" href="mailto:robert@ocallahan.org" /> + <link rel="help" href="http://www.w3.org/TR/cssom-view/#dom-element-scrollwidth" /> + <meta name="flags" content="dom" /> + <script src="/resources/testharness.js" type="text/javascript"></script> + <script src="/resources/testharnessreport.js" type="text/javascript"></script> + <style type="text/css"><![CDATA[ + #elemSimple, #elemOverflow, #elemNestedOverflow { + border:1px solid black; + overflow:hidden; + width:200px; + height:40px; + padding-bottom:50px; + padding-right:40px; + } + #elemSimple > div { + background:yellow; + width:60px; + height:30px; + } + #elemOverflow > div { + background:yellow; + width:250px; + height:150px; + } + #elemNestedOverflow > div { + background:yellow; + width:60px; + height:30px; + } + #elemNestedOverflow > div > div { + background:blue; + width:250px; + height:150px; + } + ]]></style> + <script id="metadata_cache" type="text/javascript"><![CDATA[/* +{ + "elemSimple.clientHeight is the height of the padding edge": {}, + "elemSimple.scrollHeight is its clientHeight": {}, + "elemSimple.clientWidth is the width of the padding edge": {}, + "elemSimple.scrollWidth is its clientWidth": {}, + "elemOverflow.clientHeight is the height of the padding edge": {}, + "elemOverflow.scrollHeight is the height of its scrolled contents (ignoring padding, since we overflowed)": {}, + "elemOverflow.clientWidth is the width of the padding edge": {}, + "elemOverflow.scrollHeight is the width of its scrolled contents (ignoring padding, since we overflowed)": {}, + "elemNestedOverflow.clientHeight is the height of the padding edge": {}, + "elemNestedOverflow.scrollHeight is the height of its scrolled contents (ignoring padding, since we overflowed)": {}, + "elemNestedOverflow.clientWidth is the height of the padding edge": {}, + "elemNestedOverflow.scrollWidth is the width of its scrolled contents (ignoring padding, since we overflowed)": {} +*/ ]]></script> + </head> + <body> + <noscript>Test not run - javascript required.</noscript> + <div id="log"></div> + <div id="elemSimple"> + <div></div> + </div> + <div id="elemOverflow"> + <div></div> + </div> + <div id="elemNestedOverflow"> + <div> + <div></div> + </div> + </div> + <script type="text/javascript"><![CDATA[ + var elemSimple = document.getElementById("elemSimple"); + var elemOverflow = document.getElementById("elemOverflow"); + var elemNestedOverflow = document.getElementById("elemNestedOverflow"); + + test(function(){ + assert_equals(elemSimple.clientHeight, 90); + }, "elemSimple.clientHeight is the height of the padding edge"); + + test(function(){ + assert_equals(elemSimple.scrollHeight, 90); + }, "elemSimple.scrollHeight is its clientHeight"); + + test(function(){ + assert_equals(elemSimple.clientWidth, 240); + }, "elemSimple.clientWidth is the width of the padding edge"); + + test(function(){ + assert_equals(elemSimple.scrollWidth, 240); + }, "elemSimple.scrollWidth is its clientWidth"); + + test(function(){ + assert_equals(elemOverflow.clientHeight, 90); + }, "elemOverflow.clientHeight is the height of the padding edge"); + + /* This test differs from the spec. Opera and Webkit meet the spec, IE9 and Firefox + give the result here. It seems that in this case Opera and Webkit place + the padding-bottom below elemOverflow's child (i.e. below elemOverflow's bottom border); + you can scroll to it. IE9 and Firefox do not. I believe this is a Webkit/Opera bug + (If you remove overflow:hidden then the padding-bottom moves back to be above the bottom + border, as expected.) + The underlying issue seems to be whether bottom padding on a scrollable element is + always placed at the element's bottom border and not scrolled, or else deemed to + belong to the scrolled content and placed below the scrolled element's children. + Commenting out for now, because this is not really a CSSOM issue, but an issue + over the layout of elements with 'overflow'. + + test(function(){ + assert_equals(elemOverflow.scrollHeight, 150); + }, "elemOverflow.scrollHeight is the height of its scrolled contents (ignoring padding, since we overflowed)"); + */ + + test(function(){ + assert_equals(elemOverflow.clientWidth, 240); + }, "elemOverflow.clientWidth is the width of the padding edge"); + + /* This test differs from the spec. All major browsers give the result here, ignoring + the right padding. + */ + test(function(){ + assert_equals(elemOverflow.scrollWidth, 250); + }, "elemOverflow.scrollHeight is the width of its scrolled contents (ignoring padding, since we overflowed)"); + + test(function(){ + assert_equals(elemNestedOverflow.clientHeight, 90); + }, "elemNestedOverflow.clientHeight is the height of the padding edge"); + + /* This test differs from the spec. All major browsers give the result here. + */ + test(function(){ + assert_equals(elemNestedOverflow.scrollHeight, 150); + }, "elemNestedOverflow.scrollHeight is the height of its scrolled contents (ignoring padding, since we overflowed)"); + + test(function(){ + assert_equals(elemNestedOverflow.clientWidth, 240); + }, "elemNestedOverflow.clientWidth is the height of the padding edge"); + + /* This test differs from the spec. All major browsers give the result here, ignoring + the right padding. + */ + test(function(){ + assert_equals(elemNestedOverflow.scrollWidth, 250); + }, "elemNestedOverflow.scrollWidth is the width of its scrolled contents (ignoring padding, since we overflowed)"); + + ]]></script> + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/scrollWidthHeightWhenNotScrollable.xht b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/scrollWidthHeightWhenNotScrollable.xht new file mode 100644 index 00000000000..0ff1a600107 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/scrollWidthHeightWhenNotScrollable.xht @@ -0,0 +1,136 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> + <title>CSS Test: CSSOM View scrollWidth/scrollHeight (for nonscrollable elements)</title> + <link rel="author" title="Robert O'Callahan" href="mailto:robert@ocallahan.org" /> + <link rel="help" href="http://www.w3.org/TR/cssom-view/#dom-element-scrollwidth" /> + <meta name="flags" content="dom" /> + <script src="/resources/testharness.js" type="text/javascript"></script> + <script src="/resources/testharnessreport.js" type="text/javascript"></script> + <style type="text/css"><![CDATA[ + #elemSimple, #elemOverflow, #elemNestedOverflow { + border:1px solid black; + width:200px; + height:40px; + padding-bottom:50px; + padding-right:40px; + } + #elemSimple > div { + background:yellow; + width:60px; + height:30px; + } + #elemOverflow > div { + background:yellow; + width:250px; + height:150px; + } + #elemNestedOverflow > div { + background:yellow; + width:60px; + height:30px; + } + #elemNestedOverflow > div > div { + background:blue; + width:250px; + height:150px; + } + ]]></style> + <script id="metadata_cache" type="text/javascript"><![CDATA[/* +{ + "elemSimple.clientHeight is the height of the padding edge": {}, + "elemSimple.scrollHeight is its clientHeight": {}, + "elemSimple.clientWidth is the width of the padding edge": {}, + "elemSimple.scrollWidth is its clientWidth": {}, + "elemOverflow.clientHeight is the height of the padding edge": {}, + "elemOverflow.scrollHeight is the height of its scrolled contents (ignoring padding, since we overflowed)": {}, + "elemOverflow.clientWidth is the width of the padding edge": {}, + "elemOverflow.scrollHeight is the width of its scrolled contents (ignoring padding, since we overflowed)": {}, + "elemNestedOverflow.clientHeight is the height of the padding edge": {}, + "elemNestedOverflow.scrollHeight is the height of its scrolled contents (ignoring padding, since we overflowed)": {}, + "elemNestedOverflow.clientWidth is the height of the padding edge": {}, + "elemNestedOverflow.scrollWidth is the width of its scrolled contents (ignoring padding, since we overflowed)": {} +*/ ]]></script> + </head> + <body> + <noscript>Test not run - javascript required.</noscript> + <div id="log"></div> + <div id="elemSimple"> + <div></div> + </div> + <div id="elemOverflow"> + <div></div> + </div> + <div id="elemNestedOverflow"> + <div> + <div></div> + </div> + </div> + <script type="text/javascript"><![CDATA[ + var elemSimple = document.getElementById("elemSimple"); + var elemOverflow = document.getElementById("elemOverflow"); + var elemNestedOverflow = document.getElementById("elemNestedOverflow"); + + test(function(){ + assert_equals(elemSimple.clientHeight, 90); + }, "elemSimple.clientHeight is the height of the padding edge"); + + test(function(){ + assert_equals(elemSimple.scrollHeight, 90); + }, "elemSimple.scrollHeight is its clientHeight"); + + test(function(){ + assert_equals(elemSimple.clientWidth, 240); + }, "elemSimple.clientWidth is the width of the padding edge"); + + test(function(){ + assert_equals(elemSimple.scrollWidth, 240); + }, "elemSimple.scrollWidth is its clientWidth"); + + test(function(){ + assert_equals(elemOverflow.clientHeight, 90); + }, "elemOverflow.clientHeight is the height of the padding edge"); + + /* This test differs from the spec. All major browsers give the result here, ignoring + the bottom padding. + */ + test(function(){ + assert_equals(elemOverflow.scrollHeight, 150); + }, "elemOverflow.scrollHeight is the height of its scrolled contents (ignoring padding, since we overflowed)"); + + test(function(){ + }, "elemOverflow.clientWidth is the width of the padding edge"); + assert_equals(elemOverflow.clientWidth, 240); + + /* This test differs from the spec. All major browsers give the result here, ignoring + the right padding. + */ + test(function(){ + assert_equals(elemOverflow.scrollWidth, 250); + }, "elemOverflow.scrollHeight is the width of its scrolled contents (ignoring padding, since we overflowed)"); + + test(function(){ + assert_equals(elemNestedOverflow.clientHeight, 90); + }, "elemNestedOverflow.clientHeight is the height of the padding edge"); + + /* This test differs from the spec. All major browsers give the result here, ignoring the + bottom padding. + */ + test(function(){ + assert_equals(elemNestedOverflow.scrollHeight, 150); + }, "elemNestedOverflow.scrollHeight is the height of its scrolled contents (ignoring padding, since we overflowed)"); + + test(function(){ + assert_equals(elemNestedOverflow.clientWidth, 240); + }, "elemNestedOverflow.clientWidth is the height of the padding edge"); + + /* This test differs from the spec. All major browsers give the result here, ignoring + the right padding. + */ + test(function(){ + assert_equals(elemNestedOverflow.scrollWidth, 250); + }, "elemNestedOverflow.scrollWidth is the width of its scrolled contents (ignoring padding, since we overflowed)"); + + ]]></script> + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/1x1-green.png b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/1x1-green.png new file mode 100644 index 0000000000000000000000000000000000000000..b98ca0ba0a03c580ac339e4a3653539cfa8edc71 GIT binary patch literal 135 zcmeAS@N?(olHy`uVBq!ia0vp^j3CU&3?x-=hn)gaEa{HEjtmUzPnffIy#(@^1AIbU z85$Vo{9HN_$mQ~MaSW-rm7D-%GchneRloNK$dW8^jVKAuPb(=;EJ|f?Ovz75Rq)JB bOiv9;O-!jQJeg_(RK(!v>gTe~DWM4f4{;-! literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/1x1-lime.png b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/1x1-lime.png new file mode 100644 index 0000000000000000000000000000000000000000..cb397fb090e199c51e80e4243d1ede03a79aa8d9 GIT binary patch literal 135 zcmeAS@N?(olHy`uVBq!ia0vp^j3CU&3?x-=hn)gaEa{HEjtmUzPnffIy#(@^1AIbU z8U8bv#2r`x<Z^ksIEGZ*N=^W>nHU(Ks^9wqWJ#8|MwA5Sr<If^7Ns&crsOB3DtP85 brl$s_CZ<#to=mj?Dq`?-^>bP0l+XkK_<AEq literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/1x1-maroon.png b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/1x1-maroon.png new file mode 100644 index 0000000000000000000000000000000000000000..3f86b0721955eb4e0f014102c68c2a9764ef7593 GIT binary patch literal 109 zcmeAS@N?(olHy`uVBq!ia0vp^j3CUx1|;Q0k8}blwj^(N7lsBPi@{?l_gf&vS>O>_ v4B~>Z+sSM@AcNP_#W95AdU8fW!Vi81W){YV4{giyfD#Ozu6{1-oD!M<@rf3U literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/1x1-navy.png b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/1x1-navy.png new file mode 100644 index 0000000000000000000000000000000000000000..9b9a03955baea7abde9e056e8604e18694e49b66 GIT binary patch literal 109 zcmeAS@N?(olHy`uVBq!ia0vp^j3CUx1|;Q0k8}blwj^(N7a+~R&>-^LA|6O{7I;J! w18EO1b~~AE2W0Six;Tb#Tu)9&$oRp}z{JAX(7`d=3n;<h>FVdQ&MBb@0MNe`HUIzs literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/1x1-red.png b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/1x1-red.png new file mode 100644 index 0000000000000000000000000000000000000000..6bd73ac101874f306d007e9cea8fa3a1f62dce16 GIT binary patch literal 135 zcmeAS@N?(olHy`uVBq!ia0vp^j3CU&3?x-=hn)gaEa{HEjtmUzPnffIy#(@^1AIbU z|1&U1KH@Y7a=AQR978H@B_{ycObm=q)$jcQvLs7fBT9nv(@M${i&7aJQ}UBi6+Ckj b(^G>|6H_V+Po~-c6)||a`njxgN@xNA!@(kn literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/1x1-white.png b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/1x1-white.png new file mode 100644 index 0000000000000000000000000000000000000000..dd43faec54ae60a210f1eab6ff4e7c88b8e34c97 GIT binary patch literal 109 zcmeAS@N?(olHy`uVBq!ia0vp^j3CUx1|;Q0k8}blwj^(N7l!{JxM1({$v_d#0*}aI wAngIhZYQ(tfDB$w7sn8e>&ZX<|Nmdl!1<f`@5Sbx4?qb9Pgg&ebxsLQ020p~!2kdN literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/60x60-gg-rr.png b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/60x60-gg-rr.png new file mode 100644 index 0000000000000000000000000000000000000000..84f5b2a4f1d1865d763cac875bfa6a8c5c576c91 GIT binary patch literal 224 zcmeAS@N?(olHy`uVBq!ia0vp^HXzKw1SGf4^HT*<jKx9jP7LeL$-D$|I14-?iy0WW zg+Z8+Vb&Z8pdfpRr>`sfEmlzu3&R;K0lq*X$r9Iy66gHf+|;}h2Ir#G#FEq$h4Rdj z3<Y;j-+=H&K5?KTUr!gukc@k8FBtMN81S%c^q)Ar(pb!~&BKo6T4>(2QlSh?@M7jG eOI|GCZ+2WP<2UBa)$Kro89ZJ6T-G@yGywqpiaLV; literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/60x60-green.png b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/60x60-green.png new file mode 100644 index 0000000000000000000000000000000000000000..b3c8cf3eb4c89bd8f2d1ffde051856f375e3a3de GIT binary patch literal 218 zcmeAS@N?(olHy`uVBq!ia0vp^HXzKw1SGf4^HT*<jKx9jP7LeL$-D$|I14-?iy0WW zg+Z8+Vb&Z8pdfpRr>`sfEmlzu3yE9XPACF}BuiW)N}Tg^b5rw57@Uhz6H8K46v{J8 zG8EiBeFMT9`NV;W+&x_!Lo)8YJ?F^Fz`((>;PMkU^HzRy4~NuGe(INq1>ePjdKrGS TIXtNc8p+`4>gTe~DWM4fy9-d) literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/60x60-red.png b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/60x60-red.png new file mode 100644 index 0000000000000000000000000000000000000000..823f125b8e4a60f780f00443c9c9a10b9fa1f447 GIT binary patch literal 217 zcmeAS@N?(olHy`uVBq!ia0vp^HXzKw1SGf4^HT*<jKx9jP7LeL$-D$|I14-?iy0WW zg+Z8+Vb&Z8pdfpRr>`sfEmlzuQ<1cFzubXBk|nMYCC>S|xv6<249-QVi6yBi3gww4 z84B*6z5(HleBwYwZk{fVAsP4Ho@3->VBlchkp2JMEhm9(EUQo2%VrV@UNUpX$1;`+ Ty_~-WXd;8BtDnm{r-UW|v1>m& literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/README b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/README new file mode 100644 index 00000000000..69d1737bead --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/README @@ -0,0 +1,29 @@ +CSS Global Support Directory +============================ + +This directory contains common support files (such as images and external +style sheets). These are sync'ed into the support directories of all our +test suites. If you have test-suite-specific support files, please add +them to the appropriate test-suite-specific support/ directory. + +If you add to a support/ directory, please run the tools/supportprop.py +script from the top of the repository to cascade support files into the +lower-level support directories. + +Description of the Common Support File Collection +------------------------------------------------- + +The 1x1-* images are all exactly one pixel. + +The swatch-* images all use 15x15 cells. + +The square-* images all use 15x15 cells with one pixel borders. + +The pattern-* images use cells of various sizes: + + pattern-gg-gr.png 20x20 + pattern-grg-rgr-grg.png 20x20 + pattern-rgr-grg-rgr.png 20x20 + pattern-tr.png 15x15 + pattern-grg-rrg-rgg.png 15x15 + diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/a-green.css b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/a-green.css new file mode 100644 index 00000000000..b0dbb071d5b --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/a-green.css @@ -0,0 +1 @@ +.a { color: green; } diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/b-green.css b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/b-green.css new file mode 100644 index 00000000000..a0473f5ca26 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/b-green.css @@ -0,0 +1 @@ +.b { color: green; } \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/c-red.css b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/c-red.css new file mode 100644 index 00000000000..d4ba5c64e95 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/c-red.css @@ -0,0 +1 @@ +.c { color: red; } \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/cat.png b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/cat.png new file mode 100644 index 0000000000000000000000000000000000000000..85dd7324815b8f8ef1a1d0496224c1a0661db9d8 GIT binary patch literal 1883 zcmV-h2c-CkP)<h;3K|Lk000e1NJLTq003eD003hM0ssI3n4EHI0000LbVXQnLvm$d zbZKvHAXI5>WdH}z3>gRm8%$Aad;kCd2XskIMF-Ff83-yN8ye1400009a7bBm000id z000id0mpBsWB>pL*-1n}RCwC$Tnn<>HVmXZK1a^ho3&SK4-(g{9GN13#R7t8y*I%m zZ)BMw!6g9VLwR{T9*v;e^Z&9e>xbnR^*7(`)-M11{_j7xFNSfJ@$>S&(_i1@5GH@m zhpeXC{afFEKhVJCt^WWpLj3iQEg77_JYJnk79anUvL0gx`(AYZ27s0x;q_WRcJD`A zg+R7jBu}y@4l@kFdQJ7DGoh@H-xD(&>S?#kV5MJwAHN8ovs16uEnknmyyLJw3_Dz} z-2t_1y-WcyWmd+)eVZDoh>C$4rk3Oju)y$mQ#%^)+P>PB74gM`GN6$$a17nlNge7- z3RmB|dPjb|$p?mh6-(D?ThB@WuYf>+sj1twj=G%GFkj5O!mZqLtqotF8cC*N$ri;H z2HQ+$17ses$k7#RTbJz}gD2-`@wiB%W8DFRH7rLV$VR8C-{$0BU^7QA)6xcOPkeLG zIC+y8#pH<ZE4DkLuB$eJu=YD09p6saU_=3B*q=j^t+sjfsKzKVsF6<N*#6N`(<ECy zIXKz+z9s_>H3S(N>pr`5y87*;bv|b^HW*-n7#c-VH5l06wfM%K8tMv%QYu1VMJ&`q zXuT9g-DjG%ok+2IhK&G~#M;r0zu4sf-`3+KmoX<0eCv7>JZuYAQ4+JlXds3Yz$`iq zO!pQ9wr}Yor1)n9bJP~%@)tD+crwU7nJ%PeORd0)1m4F<)qG~XO2nT^iMivEf)z-D zBxjR-YQ3Q3>4*f>(%TkH;D#Ki*aVYot>nkyxLr9zV62-PtQAsVZ<)M&ROZ`q=r-yb zxV0FojhaWJa00$t-zE`xTYXArX#ra%P+dk^apt~h+vO{<A@@#@ZFd70kl?YRKP5&g zb`j&Qn9|8fN_S*$P|_f3a(aM4y>N9i$&>6i;Se`Xu#!Aka_7=8lY{bL`gE8-D*^)! zY7!?ohKiqcXDjd>0jZICXBl_KZ$6sC00LyW54V5*dj5-!>hm-t>Ht(52LoWuR*1xE z2G*{@twTZxdhmIo{825j6wMk`;$*SKGZc>R!t=-#&gkXa<yH8pw79M3dp_ikAFn&8 zlrN9ORLOJsca5=ic6o}b2pc1mIER3bjmUh7pG>kkRkQfHYSKVRo~#WuBph;XemDuD z6qUJ989evMeRwkDj)54kU$UA#IGU-IZHnWTVRA#9kA1APN3ZjwA2_hn2Ug_Nvo#=1 zvdA6|8~BUnoI@62w{|P|2@lwrchE#7bJ6Kq6kBhZllSFE87tja$&a^Vsv9DzjxZA* zQVOrQc2nyJWb8G&wn4GZFkUv;Z=ATnxIprXHN_9;9UHeyvrlY2*kxbFPXGYML&r3) zen%FSp5K}|`|V@N#w>xf>JHCqGnQ($o1mTz0Za^NSrBZ!onF6dnw<3&y(VH1bndXf z391*{FlywkRueb2`q*Y`c5i|#c-`R1y$R0#>_jShsA?F))d087sWd*L&RJQPVgO6z zuKDv)`2I=hc!ut73ss<T4Sc(1p2frAo70eTGSQX~W-TmJr(%YaR!iQ`4Ur=@=?jjU zfTygMe0q~vry0lFm|`8tJ+roq*(WDI6R9%w#!|-Y#%eR(ke!N@^4>>?(GbUMv>AFu zU<y*Z1YJ38rx1Sr_(M)_9Tc=-h}Yr*n2uA=E}I+loFj7auyHJrfHI|Po@I%y`4tj7 zZ|2XgMqBeQS(s^b?xD;O6`XX77pU2u-JQEex9#}uQe_K^?kYOxRi<VJVwG%9W16&C zB}3F3+z%GVHY()dth0|pcjvht>SWGaq^ijA)f<0KH8%k6{9y7l%|MvpgU?6jsh(M$ z5N*sz^783ghS!jcq!BDms81L*G}VLWyHB!u>=8qC&htH>PmP{A<v#~L#&MqpRv4yG zw4r_l@+VBe#^s0kwg9GF@{ms(MG=X;Z*q>HB})c5>>6kFjvP9zMaPHfq~YhEr7DrH zD;~lup<3-juf%_Prr9Z-V4nORxcT&~FF{{2Nk&bqG}pd>$n(1*n4sj(w0;RH6sT{j zbhUJqyjT6iN>h5jrHP`lGXxi;LI(=%bR`2^fsT95-&yGjH)}sb@TGCA(mUti&QX<4 z{U$^U=I18hwKL%pN^cWLwM6MtTI+-Up~5fcjt@Bxe*M77{d?${Py^67eTt4eFFZ)l zh8I~nmB}UQ_u%EtP`CsPA88ZuaO!(Y>9V^z>txmUh$SjH&7r>5XT86X<2m!DSg2-= z-<rS@<i5Y4N=-ro_(K1~{gF<l7M3R7QZPDFa>~W*e9lSUNASn#NOM-@)>-Im^e@d- V<q-+yJ<<RG002ovPDHLkV1mLWjBEe^ literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/import-green.css b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/import-green.css new file mode 100644 index 00000000000..537104e6633 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/import-green.css @@ -0,0 +1 @@ +.import { color: green; } diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/import-red.css b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/import-red.css new file mode 100644 index 00000000000..9945ef47114 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/import-red.css @@ -0,0 +1 @@ +.import { color: red; } diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/pattern-gg-gr.png b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/pattern-gg-gr.png new file mode 100644 index 0000000000000000000000000000000000000000..a6d65b0d4a1be23b323e984021344ca0b4b5461a GIT binary patch literal 148 zcmeAS@N?(olHy`uVBq!ia0vp^5+KaM#K6EPAvDVp$cgrJaSW-r^)}Fwi$Q^>`%?S& z=cNKi7CQ^*@}*6Bw#d{maAM=f)UGERf;1N-vv1m&p5B~X5^}Di`?-|n{be54CcfOe y>%rS5*MrA-!~*Nf*Suw)+i0M4x&F=aCazsi_#&SL`uqo4!{F)a=d#Wzp$P!0nm8o@ literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/pattern-grg-rgr-grg.png b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/pattern-grg-rgr-grg.png new file mode 100644 index 0000000000000000000000000000000000000000..9b88fbd81149891234185f54f8b4a0431759f181 GIT binary patch literal 222 zcmeAS@N?(olHy`uVBq!ia0vp^HXzKw1SGf4^HT*<jKx9jP7LeL$-D$|*pj^6T^Rm@ z;DWu&Cj&(|3p^r=85p>QL70(Y)*K0-AbW|YuPgg44gppHg^c>jqd=iJPZ!6KjC*fy z8gelx@Gu{^HvM;TY)zwU$c{IS(wnBFeYtT?qh#}i+>eP179zlX|30sumufTRE+B#Q jJePWx&kbz|5I0kznWOaej?gzin;1M@{an^LB{Ts59-mW( literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/pattern-grg-rrg-rgg.png b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/pattern-grg-rrg-rgg.png new file mode 100644 index 0000000000000000000000000000000000000000..fcf4f3fd7d95431b8cd1bc5f5129fcb724c5e40f GIT binary patch literal 231 zcmeAS@N?(olHy`uVBq!ia0vp^x**KK#K6FKsNOXi$XVy<;uunK>uuO>p#}vW?s@X} z?5{Vn@(E1fdg>#_p5-zBiX+1VA%+4b26mx2|7={&ovNQ>6SXtcysBl-)c><WmS!Y( zv7BNEzPH=%x{1!KjWd@lmbz(awP;VviDQ{7SW3K#guH|K-#!i8$dVG=UlQ?2Ho)uu z>9DyExiv#HMbsD$XX>p~Q&Z4f6DV?h!MD37E_}{<nz@wk)ekYNY^%>svR6Ky{&{h` fDhG(UQO-Q~pMsNotNvM_%Naaf{an^LB{Ts5h3Hy_ literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/pattern-rgr-grg-rgr.png b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/pattern-rgr-grg-rgr.png new file mode 100644 index 0000000000000000000000000000000000000000..d454e3a630cd98146c241537dbb3d4cef313f465 GIT binary patch literal 223 zcmeAS@N?(olHy`uVBq!ia0vp^HXzKw1SGf4^HT*<jKx9jP7LeL$-D$|*pj^6T^Rm@ z;DWu&Cj&(|3p^r=85p>QL70(Y)*K0-AbW|YuPgg44gppHg^c>jqd=i}PZ!6KjC*fy z8gelx@Gu{^HvM;TY>lI9$c{Iy(wkbIbyRJ-o`3vUZZ|(OF9Q6nGtzszXKw9ExeG`j k-E5KlqACYx1X%C$w4CD$N64zrK&u!$UHx3vIVCg!00%}%YybcN literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/pattern-tr.png b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/pattern-tr.png new file mode 100644 index 0000000000000000000000000000000000000000..8b4b25364e0ffbe09e563e13b567fa57330e48d5 GIT binary patch literal 137 zcmeAS@N?(olHy`uVBq!ia0vp^azM<_!N$PA*s|9jBoW~0;uunKD><d1=|2z8e@O`m zi5U_X7?eM1T?jqI(8f2(=fLXOHJ)xxeNNw5J?)fkN19wc<FT&3eZzeBMQLtcCc<9q mCdFSHSg)@*x>)QnGsEKzd}=q=PizO8&EV<k=d#Wzp$Pzi&n><H literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/ruler-h-50%.png b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/ruler-h-50%.png new file mode 100644 index 0000000000000000000000000000000000000000..cf2eea6b438a11503a89414cbb2f9f1fde55df0c GIT binary patch literal 691 zcmV;k0!;mhP)<h;3K|Lk000e1NJLTq0077U001%w0ssI3;WRTK0007dNkl<Zc-rlq zy{h6s7=~wbiC|&k#KzV}uoP2RSPBY)sHIn;ot@^CYHeD*0k6SU@&o=<wt~SzQP6LT z+1+9bIY?G>_PkGJCLw%0c_-t<Byu8R0TE%rfqnf#2=STCc!0-|BNJiWm+$+t+3XF+ zG01&|R6WZ2a%FMO8DoZFSe6xdSs{%)dLqg~Sttu-y|XONIp^Fk491wQ>y1Vu;JWBp zVzJoqc$A+V$Du&M;PW30)i^&u7Gwd)f-J~_EXabafA}Ss^LRYITrL@7hr_}5ea4uo zs-EXfr_-?8qSw;z_hYfxZnq<%d_G?&6l8n7UMHeNA~7D1DXd_+^X%M^b1Xhu#0egw zA!I?;mp#FUr6!IGxafwE1t1HuAPce}3$g%YK^9~|*6&HOysvn(*(i##-EJ9UsZ`3c zEZerjZtKO@{G-umsZ=7OWHL!ax~|LH&Qw+HcDr($*H`sP-cZ*0d?q4I(}+k2AsaiL zj;3j@>xNm@j~53yo6Tl2nfZLaSS%Dp@jOqqx7+P>I$bK2_WONkdm(-b!)ORuq3(u{ zuZ3eR);?H^UI=h{2M87b0ALRNMpGQFFcbm=3m{kkAXosw0tglW2o^xF0D=Vof&~yP zfM5aey@Mqmboq;Vy>6Q3^?Ef;v)OFQ#$+;S+qUC4@()R>)vA0j20RIU1AN~f3<kMe zPA*0wk^B8lM7P^58jZ@v;czH~5JH%ySu7Suqmd9o*Y(L{67t7~@KDnmXti3a)#`LQ z^?JQ>xhxxNwc21XxLhtDA0P5nd4E{1*Of{|zC6!y9M^SKRYkDydOv{gSOCES0Ko#G Z;3u}YJM}AuyWao+002ovPDHLkV1h`wI+p+d literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/ruler-h-50px.png b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/ruler-h-50px.png new file mode 100644 index 0000000000000000000000000000000000000000..9f46583665ca6471075227f9e2244f1ba1ffece0 GIT binary patch literal 671 zcmV;Q0$}}#P)<h;3K|Lk000e1NJLTq0074T001%w0ssI35I<<G0007JNkl<Zc-rlq zv8v)g6oyYUj*(OvJMF|<*xQPQHX;gQ=Q9YtMk4qIcD_Uk3p+s&EW|>6gP<0o<3OBS z1j1$6y@J=>jmiI2W)i~T^Pfp3CPtA`(u;`E>xkCAIOm38{A6Fs3%^GNnFzqX(&;o2 zDT)%hOaxRt$_h?dilXdxyZwIuAIl18<k1sR7Ro|dDC@73<(+Ub#)4IrH|Pr?i0E>; z;NbHP*$SvFj1Q0nSpc#i3$h>!vLNd#s;X8h6(Y)HGDMWkW{IfR>*e!#BI@`1L^K!- zq999sxJ98*&~=@N=JPpYY_r)A(Q>)W<#PTuuIolY7N$GT%2E_8{&5kbJC1`e1yhkZ z{QWZiAyepm0H$CHreF%DU<$w#Ou-aPy%*}kd9U|DN?9(KiD<D{L{ydh79vWeQmfTU zN_jXOj>n_dsO!3I+fqu~wx`pn*C<1c`p_d0X`044S5?*jCFXoSGsc7vhGD3xigAie z)6_I=x7!g>wOXy$>t1^zkyx+So-)UAqG0No%Wt8-X!kNxI7<M}X6pN1hP7CW{s%Cs z1EdN70HQYojOJV%M?e6ODu7f0qzV9}3LsSgsR9700!S4=ssK_208$0QoT}fxKB3)i zTb3n+uq><7>A-U2c*&C|r_;$a%~Gl4EyiN8`~5DZbX_+dkNXem%w{vr`D8LF7K>iv z?RKlxYUA;^)oKYL{4FJTXMQ?Xb-Uf|cFP#!ocsSC*Jw0`!=VsjG#WLVO@HH$j}Ibp z9OvtMgBWAUWb%5w;_jEw@bB(q!d+8H6#$q60;CFrn@_JUXnGtsT_OMg002ovPDHLk FV1h+lHID!Q literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/ruler-v-100px.png b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/ruler-v-100px.png new file mode 100644 index 0000000000000000000000000000000000000000..a837eca2225082917dc952efd5c689e1b51d7bbd GIT binary patch literal 760 zcmeAS@N?(olHy`uVBq!ia0vp^MnHU=gNcEGaWU)iTMP_L`#oJ8Ln>~)opsRfQGkd; ze)kq>afh25lNKiW9??&5?NHJA%O>=XS@{0}+4zG^EwY_?F_M#iv9}3z1aeiSUzA*K zu(aV(kHK?2k3BK|`KL4QXWugp33W=8Xj?T)Nc8vQ(%9`GT4(2eudkH7c2+NL?u$dR z-nKS2Z~j`Y^K+f^ZT|OzL59~vJ9g=>@?L(q?{UxZ$KUny^7DVzuDt!h?mmN?plfyf zmG|FWk8IKrjGUqMkB_(Yd8N`MAGQ3vyhA@<bgG)GyNbMZyBKBu{M65@X^X#_xz|N( zNI2NE)qRbRnzGW(oG=%g^U{3n2NQ}bDsH?iaanTtWy$WlscV`SSj{;6?RV|zP4C{l zb6FCjH+xxSZLO}-<dZ7%&v$p^-rjt(=cAyQ4#>1ywbzy(%Ux#+<}|T#gG9?_n$GnL zUK#SiePsyOw7;>}x9Vgku7B`~<KEgPU54g^2R_?``Yyk`>Xk*`s(JJ0KQFQj%{7r) zbt}iL)bq?nx5a@6yp{&7nsqXz>CffMm(RcYnakO|rl9#~(#I!HTteT!e?R%;lGnRd zMQMom`TO7h&1I+D{M{YwHHiH{KeA^3UX!~oKff$N`Q3$OHK!M>^?md}Ue5YP`;WJ` zoGPcdSKa}V$916$caR7I{lB!WCtmR1qOjFlqjc|ok6s(LH?H5a&h2Na;zQo04{aAN z%iOnj@5)!NUuP>#?C|XJSbx2`vNCh~ZFhHf$0DPdQ%*l!y?XWL&Bph?D}P^q>`h+m zFXb?;somY&_rL4w>#x3=<rC!6*Wd5@<m1PSg>$|yNsZi=Yj1B~pCFjW&0YS{yFmW8 z{%3D_dwKh-9vNpof7j<_ShMfbl=P&-N7}Xp$UV*Eei}Fr#*lj&2u6iKLAmWf*~0AY cw|+4$pP;3B^U*VLV7g}TboFyt=akR{0G}~+v;Y7A literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/ruler-v-50px.png b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/ruler-v-50px.png new file mode 100644 index 0000000000000000000000000000000000000000..84141028020b7e8cdf2412acbca3c799ba50a534 GIT binary patch literal 757 zcmeAS@N?(olHy`uVBq!ia0vp^MnHU=gNcEGaWU)iTMP_LdpunnLn>~)o#p7Q6)4em z{$d*2BG*@!Lc3jVdA+?Q+2PW(<&`<hUq0SH>~H^wHaWhIaoO!ruE(m{QKE2v_l)kA z-e(KKcYm$vKGDDac}?&6nKO$m!Y2I`xEAGUC@i-6WK{O=zyHpiJNNeO+xv#s?=j!Z zxcM?)V^6`#D~}&Pp5?A$`q-&{Ubpelh>!(auZC((&D%cv^wS>0zQ+>Dv(7%_|5v|q zao)lohkkPybSa7E=I2W%vo$wv-F7j<M5=efqK_3hJ(iZ1hR5E#eOo#2c)7cvt4QFM zmy258?Tg>%?^YeP{?keR*WWj6TXu)LZemGAMMlrg{rmeFE-(LJ<A3S&Y482_`L|4a zV$ruGZ1vX<9}HH``Sp4I^9xs8BD45(?Git7i|IscNI2NU%6%<AQFrUQr?(D+*uNsK z-AeFYem8ITy4x>H79F(9J8|Uk$H$M8Jv&{Tg0!YiDk&_S=(k)oHZIO<*REZcdS={{ zuBxt{yk+-pZOxfJY$vZ@zkcEDg32{MYQY*JDz>(^mVKA=wyUOYzPWhuV$b-4=Px{% z$%e2T?g|j&pZPVd@7osh<~-+>HNJ0@q3xBETkz(j;nVk5#ZE1@IrSJs=KbBV&8b#r zs@K)5tKa`-ZH>~KK0UlH?2I+Pa;AYqh}P8R=H>^<I%3lO$0yypfB*5vA5Q|#-o1Ob zz+%ny*S~-Nb}TZHdiwe2?Afz7Z#KUF-I?$98QU)7&slTl&$qX?-@VRShVSyrk_kFu z-9WGGdw)G^>*dRrJqy()8y@>owKqh|)N|Lm*OhSvei_W#^M7W~=v`a$@8~4GJx?va z-#4{oh}c&&{rS;0ap_x5l~b1MPI0e<Gk|OmIt~)N1C)g`AmVT`zVHuY?mGL;&f7B= Q0uwcZr>mdKI;Vst0OKlsf&c&j literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/square-purple.png b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/square-purple.png new file mode 100644 index 0000000000000000000000000000000000000000..0f522d78728417b0f74b694e2e47cd41c00359d1 GIT binary patch literal 92 zcmeAS@N?(olHy`uVBq!ia0vp^f*{Pu3?vyBU)>3$*aCb)TpJh~{xkePDssRFB<<<q n7*cU7`N#kLjg3MaSNIuL+z|fjF-g!1D9PaI>gTe~DWM4f*isp& literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/square-teal.png b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/square-teal.png new file mode 100644 index 0000000000000000000000000000000000000000..e567f51b91bbe40754cb0e0cae066201219cbb4a GIT binary patch literal 92 zcmeAS@N?(olHy`uVBq!ia0vp^f*{Pu3?vyBU)>3$*aCb)Tp1b~82<lv|F?D~NZQlI nF{I*F@{j-f8ykf<uJALgxFP)4W0Ig3P?EvZ)z4*}Q$iB}@>Uv7 literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/square-white.png b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/square-white.png new file mode 100644 index 0000000000000000000000000000000000000000..5853cbb238cb2d4aba3dd49af3f2ba64d6c7a2de GIT binary patch literal 78 zcmeAS@N?(olHy`uVBq!ia0vp^f*{NRBpBq_B-DVEsHcl#NX4yWiv~UkzCZ4)$}udm Z3=C_{1@!OB{@4Xl=;`X`vd$@?2>|f05A6T| literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/swatch-blue.png b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/swatch-blue.png new file mode 100644 index 0000000000000000000000000000000000000000..bf2759634d45dbe3df13868341eddb7e4bf24172 GIT binary patch literal 84 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K83?vyP*g1g|bAV5XD+9y-u8K?HKrWA`i(^Q| dt>gp+Mj%g@f$_JNuojTT;OXk;vd$@?2>>P$4{-nh literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/swatch-green.png b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/swatch-green.png new file mode 100644 index 0000000000000000000000000000000000000000..0aa79b0c86bd72c2220ecce39b9553e2cd3605b9 GIT binary patch literal 84 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K83?vyP*g1g|bAV5XD?<aroS#c40=Yb%E{-7; dw~`YS7=b)p2FBl7!dgHUgQu&X%Q~loCIBjB50U@? literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/swatch-lime.png b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/swatch-lime.png new file mode 100644 index 0000000000000000000000000000000000000000..55fd7fdaedfc1ed505b111f20fabbca568c68fa5 GIT binary patch literal 84 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K83?vyP*g1g|bAV5XE5m;VlehybfLtC=7srr_ dTgeFuj6j|)1LJQkVJ#qw!PC{xWt~$(6968w4?q9_ literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/swatch-orange.png b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/swatch-orange.png new file mode 100644 index 0000000000000000000000000000000000000000..d3cd498b52bd88ea6c991f050f1ecb1cfdd136bb GIT binary patch literal 84 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K83?vyP*g1g|bAV5X>;I(;rzSbh26A~kT^vIy dZY3uuFamkH42-|EgtdSy22WQ%mvv4FO#nq@5F-Ep literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/swatch-red.png b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/swatch-red.png new file mode 100644 index 0000000000000000000000000000000000000000..1caf25c992aa8e23483cddb3334b5f51ec967f4a GIT binary patch literal 84 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K83?vyP*g1g|bAV5X>wg9Y$w!>#KrWA`i(^Q| dt>gp+Mj%g@f$_JNuojTT;OXk;vd$@?2>=8a4uJpw literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/swatch-teal.png b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/swatch-teal.png new file mode 100644 index 0000000000000000000000000000000000000000..0293ce89dea5c9413e4c829cc83a4e39d8f23300 GIT binary patch literal 156 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K11|+SoP4xm&jKx9jP7LeL$-D$|*pj^6T^Rm@ z;DWu&Cj&(|3p^r=85p>QL70(Y)*K0-AbW|YuPgg4R#65`cCM1`H9#R5PZ!4!jq}MV s85uv$JE$cjEnw)$lDlfNN|Kv_A+(E0c5RvdE}%LFPgg&ebxsLQ0IVw~FaQ7m literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/swatch-white.png b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/swatch-white.png new file mode 100644 index 0000000000000000000000000000000000000000..1a7d4323d77287d8eb03a89c635b09d099d94869 GIT binary patch literal 85 zcmeAS@N?(olHy`uVBq!ia0vp^{2<H-Bp8I(u6Pcln3BBRT^Jbeb_p*5^7uSm978H@ gCI9%}-<ZL|Fh5TA$_Ah94}dZZp00i_>zopr0Qo5vZ~y=R literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/swatch-yellow.png b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/swatch-yellow.png new file mode 100644 index 0000000000000000000000000000000000000000..1591aa0e2e274854ed836cf582235ea0202f9c8e GIT binary patch literal 84 zcmeAS@N?(olHy`uVBq!ia0vp^{2<K83?vyP*g1g|bAV5X>;L}@UB|w-0=Yb%E{-7; dw~`YS7=b)p2FBl7!dgHUgQu&X%Q~loCIDbL5Y7Mq literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/test-bl.png b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/test-bl.png new file mode 100644 index 0000000000000000000000000000000000000000..904e24e996a3e5da93bef89e10c49e24c07d0ed2 GIT binary patch literal 1368 zcmV-e1*iInP)<h;3K|Lk000e1NJLTq003kF003kJ0{{R3g3O3#0000aP)t-s005aY zGnr;)nE(LHGc(L)X3UwH%*@QpW@i7Hng7hp|NsC0s-1y@0000CbW%=J|NsC0|NsC0 z|Ns9065r0w00001VoOIv3m@0SzyJUQ%1J~)RCwC$mrHKsHV}qI#0OA$)CUNV+0PNC z5z>1FDgrZWOHO<59>534BKsDgp7p3B>I7zAF2$Eby&QX;;i_BGr>dV-tSTkfVYNIl zi$7l1mTrsB_C8C-i#4X^3LaLG>jn4e0?941+dy=QV9i9xkG(@4H;@(~ogt^a`43yj z^`**Zh^{Td#Pj%+Qr%fKN-5`g;nYOF+LzqmXhmO+m0gFk>gfe#F-NRAhUdXXT_P3& z5hZ>zhPowUE`a<#=%qb^0(KmTs?O^A;`TX0ocz1q{qO362uJ`J02e5qdmo1g`RwHP z!A7z7fk;yZJFK4j+J<J_!!kFwGv}DTl*m6N!y-fSp;zS$vG4R+^f3f3FkDp6`iZB@ z9Rq0{yOh5|GFgnv$G$b5jmSNW@=3{zpgZ``cV=57#LB;M$gx-;>{j+R-gEgot3{VQ zT_EJMJvHm{U-0*2vCJ(xH5>9<9E?yX{cn>?Cg7{`b(@FBIAj4b8LLlxUA}&DNX9v( z3NQA_a4!BS*5!`~%BqqjA5Y&4uFEHnEyD3&j#zU)o^f5S%cniIzr|OZ3i>ow5`DiR zKV-E(ZYQ3EdZkb6@<UeNeUB?iBFq`D*X2*MI!I#{X}9FZS$$Qmwt_`|Y{-wZnqKV6 z1blp+IyR9XXEjwg7bU<2vXH;?C)8Cq%49XyvL(Ou3A1w<`?`EvZGvCF2-_3drF_v3 zWsvc|O+gEO*$ta$@sA0cmcFE8)2I`NWRx;N{9|`#gBRBOOq5lHKJ|AG{lc-r?c}4) zL-$z5Md6GLEg?qSW3G#N#pKN%xTocLj)Y#BeKpr}_iC1cFHVHGREV^M$HW)&`;U1U zqa(S7SZ8*J-qhDnFUE@G8)EF3n+2Q$s`7)uute1_k<QgF7t5n>rGpW1SV4To*jSQh zlcG$a4=ps-GU>1C2_a&@$I%?>7`aa!VnfzdIeZ#?+sUD|PY~B%U0^7GO|Nu@sDsJ# z@KlWWEXlsO1AjC<{IhGw<M`A>1$M}i5N36xL4oHW;3LYQL{&USeE7rWXggil@q+qy zcqZ;IV<F)o1Yw4G7>JjWW`PLt<%)`T&`L8>V}>Oa<kn^+iI7n5LHubaqvh(*WJr7^ z)T>O$2em@zx|mEC771}cDVqgE!@z!yT>QYv82lFP(%@F<5;wl4TqknAA$72YTMI-# zh4f`KPMMiy>XyGdc~Of)_A<zfoj!JJF(=#0d7SY)+PJ~38KUdBOaRb$*jPKdJK=EV zrkm0Z8xVG(YE0}Yt@-e>+14L1KJ#R!khI&B)WtXi&X5b{lL3*@ZkLC@MvW|+A?7gN zW^9D0T;2*9*?`>~p)-$sKP@gC`DhvB0@0TW$+>vr68OLZ|AFHIA?8UIVp5VL8#iJF zp>x%gNY!OhEyLo1uORl+--}g*Wst2R?yDkOfv7^I8;JRK;rXg-$rj?i69C?WTvb<5 z-Ama!5K|d3=PQC<K{RE8uwP1VM##=LEUkC!&4^ZAZE86{8mYSe$D&=JS`K8398A-< zAkI6YxS&bnwNTEyqw<esfq5o26J~CRQnjl~iN@O75YIKX+q?rYE}CZZF2t>$$WP>d ai~I`(b4pM507-ZN0000<MNUMnLSTZUYM}!F literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/test-br.png b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/test-br.png new file mode 100644 index 0000000000000000000000000000000000000000..f413ff5c1a0f2ad9f9a345d3e07be57a59a82207 GIT binary patch literal 1045 zcmV+w1nT>VP)<h;3K|Lk000e1NJLTq003kF003kJ0{{R3g3O3#0000aP)t-s005aY zGnr;)nE(LHGc(L)X3UwH%*@QpW@i7Hng7hp|NsC0s-1y@0000CbW%=J|NsC0|NsC0 z|Ns9065r0w00001VoOIv3m@0SzyJUPhe<?1RCwC$ms@V5FcgLlnk;}*nH@}b&;=9; z`W^{0$~+gU<h>dx3m9n@P^7faO%<|&!sf>KZm^B!d3qut2z>beeU2{xp@)&j(02`` zTY^Y(yls!8j-g6{#iqXUOZZmq^{tQRnwIpYptOGKE#wg=geU|udB&pePc3cOueFKs zvzd?t6~fN!7xtH~ecHeFR|~mNE=(hU<zcj=XW{%Yp6UJ6N@ftUzmC!P5cbt`?6jy? zkn>j9-;D~v`nZNntt8~9LC7xNOec_RZz1(-9N|5dP=m0v9-_#(n4W^-V2~txiYhzj z!i$YK*$mpxEQDn<+Gk7q?5d2K>8gc&fN~c@-gEJg62@yGi)KdJFKsVL7OffK1s(gk zuDvn5Y{BU<F%-%e((qKG8u5Ul%idy$ct({KxR(KBlCq)lwQ%n=>I*USjd;i%YrdEb z{Sn*_^roe9hCXX0U8@*Tm5}W<;uM1)L8qv|EjeFw?$DQBbYc7Y_+{2Z;0_;OA3x6W z0PY|Sr^RF&+^N9lo^nJde+0T>e|Q%!CAxA~?GMkwJ^q*@L1D^DW{@@e8aZfW&HlL( zh^h58`-7ZbHV<zaS+W1w2>0aSI!6vcWNu~EzD%TLWzD`y<i?s$R_yCU8Y@az$o?{s ztJ8(Yy+rUffV?jfsir=p{xwOCNIQ`VxeF})mt`W=%)g=j#qveyLfcAweUa7TT2Y9% zj|Z80xYL7JBN#v$SuMm7!T-APcUV_RUG7#w6p(kTFo<b#?tbL$mc9)MbD|J81-xCa zu1iy(+!eIf8G_WOYv>wDV7Xr)zJ+r5pkj?+g<rb&*<VHdwnQ#%k*B`?n)b<=Z)r8M z*w%Y?pY@=}iIK&e%yly-p3Gaau$<qAqFp+%WF>S_u|SWDG`g}53&gW~H?kPATZn)^ z{pHpDF0f_Yc)Al>7VPVTai^XiPQR;MAxJ&d2ec|FrET5HXc}tCS~{7gaV(KcTp<oc zQD|B7>QZ^Z1TjZ~gu`3RQzOf}P2=}cU|fp)kR|{zS!z=9ML<>z3CM~dAz5JrL$V?W z4Q^@!)=5xS07+PK!ylVGm5`=3ktPvYvS1MHR5ItZK3>BJtE{TnlF}3mey44O;Kkq6 ztd@0Ivcj%UvClb}M#-r)(X{Qa==a|U(_!d)YlyiY`vK(N;tTmg{#)cPVxOudoeJ1E P00000NkvXXu0mjfoHYWE literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/test-inner-half-size.png b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/test-inner-half-size.png new file mode 100644 index 0000000000000000000000000000000000000000..e473bf80efc66766cb32ec2cc60244ed37dc1157 GIT binary patch literal 180 zcmV;l089UgP)<h;3K|Lk000e1NJLTq0015U001%w1^@s7JXu?L0001cNkl<Zc-rli z!4AM62t%pa|Nk<(E?zL=Fq+2^X)3e<nYr61nsxC@Ld$8rPiTZTB&ja&s6as%ZJL|M z=rOcU${2vp2YUvrojv1iz<}=oKePMm#BU3e)Gz&dnG;ue53v^M#Hf!LH5!*`jH~Z= iHN+4@%ynW{5626)ITymFxuX~W0000<MNUMnLSTZVu1667 literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/test-outer.png b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/test-outer.png new file mode 100644 index 0000000000000000000000000000000000000000..82eeace7fc0c4202f79610978ab423e62abf8939 GIT binary patch literal 2412 zcmZ{mdpOg78^=c{EOMMh4qF~6Bd3rFi9{I*a|(^Nvdq~?QjT*?4xw_Itd@FmT1%@; zkHai-Y6->Aa{4*!H%&eKiag(`-yhHQT+j9WT%Y^CzTeON{@nNL{(P?Mo9&Krl9f@D z0f9iW&L<o^0NV)yNkF9}fteqx$p(R>O`RQ%dM1nrDqQhOXQ7#ug?V#Sa2fmTSTTg# zq5n>b3YP6~G}vwrp{7((H(F%s9=vs(d(vdsw5S`*{!`K=^0e|Hs;%}@ZAe9;YhM#o z_ToaBZbi>ZoPth;c~{8~-g5bm@{$}EyaCQ}|KNtGC?`*cg`T-jp?`3qQTBgZTv?v{ zsdiqg_=L}TaeDHp)WEMH?m}9l;@m~8p=7pF>!36@MZO>-W1E4=+P#fwf=QndMcXv7 z8Z8-fF2Q7mdllSkqq$$v5O4Max@#iK>)>}|J2%opy`et}FlLkY$|k=MPb|h-F&GS# z`yPH&Q53dkQkZ<87kdVuoRE+pLOXW`h4H>u8uuqXC&Rob*li9oo;cl8K)zjxUvIBg z$)w}LH2k-=iDKc?$`Kh8{tr6}PB1uTuEZnV2}8sH8=6vc={^tU1@E=j4k~YXOGQ|X zkJ7bc);}A=x!>Q|ZjgqKn<q^%>txci{z1vOpT5iHp(Eo0q?hU&McH@xcJuaJ!&r=t z?vM4Ew=lmncbCv<w<by^%~!2EMkjjnd54&X#Od#j14r-;{%H*anvq+xT4z&^R~p5` z!xS#*RhyBq#-3+TSq9ZKkNp)WoXPH4H-m1)g6J1}?lL8tMqKR^6?)~97d2-4DhB+5 zUdGN1RJ+xB<5yKLk0NkP^&6b`?>%iQg%g%g!y>UhwjyyUTO+MrE;m#Qlfbq|*dc(4 zZC|6qC(sSHP6V-iNf|!edmH+^^*p7Z*`Fr|qZ;SsTT5vuq{VfH<xT}KU7pO%=gQ-v zpl}EV2Ej;R3K*TfdooFmy;Lk8A$M$3@V7ALWqa%n93N4h!H9%#CFmf!JRkt3OVQHb z4OBETnat*91Ne0G$7cc;8XW%MV(Eh}E-|2Hw!aen*h^t9zNtCIQK#4?o8<B4NzKA= zJ-KtNi74c~C_F{C-09RZX5o7;K}%g#V~>E_u(9E~{{7oy($sRI!r_#kERyw=)upx! zFkJKpcdtUCXezrquiN45{@FUmzL;55Wac?m%0{3=Y46O}udzZQvI2GYkbbEmgW{O# zB*tP_1EQvt8AEX}i1ucwo7Do-=J@@}d(C-#{nOcUixx3CVB}<e`Lw}_xWS0LbrOGg z-0$$Y+G<jqNui?4Zdoxsu$TaOYd=pOXKWEl=;Q$~#Yp}}11wlrY@mF@rT&tjQx2Kc z;EdG(+Qw=(0gQccTmb_LX#GO@-=ToE{*}o1S&Q<qR$oGG$H$7QsF?VyQgL%mGamZB zN8AN0>yfx&o9U9a{k9oC*L+CRvNc6NGmAaSr-%G%isWSVX*Ri;gJFYDY61-RZMJ9s z-`z?*?sVx<BY`>k?ebatm>?cmkvn8n>~gVoVD9PAWg?M?$DhQ9`wq>_JP04nEs0as zGCYyp$>C%Uz4Sbg-8nx$KQdBELKqs3JZpaXR0kdt6C;QpRUl$8ZN2BT1ay8+QeDwI zu62>#lKkWL24UmrHRFc%C7-=lR_WXembP{E_3D{)24gRLd3m`56V=JI3W>Gc@|ghD zM4FnK`Yo)lucxJLsZJ~`ENt|1#h-mVSROoe^Uf(EVVw0btkFTIuq)O|12?%MoRDpA z2yb%N3pEM(Fd#*y6-Dy|)=~4^T7Ra;qxZn6bJQv8eU-G*cUmx99|SwF1S^VO>?Mcy ziKu&}Y5&7fzUR%+PBa2D*ec=Nds+$#Hi85rKsnpQ4u~Tuc0eH#V&@ut(`oSm91zDY za+r0m+14Xz`N-u=du{O&XwC%ls)q~AieIs$nYA?j`i;>+?lE4qb*u__4g0>Wic&zo zR+V36^t{R_-%yv8wr}-_^1lgZWPfdu3O$yvqYW912-Zu#GoWhgovH3+iIzI{A=E)V zcQydV*I><E=u_da(q7DH+)<GXMo3AvA=y+6U6e})iPP3*DUDxWlG~X9WJt}Yx1=aW z9f9!2A{3*A+uM>n-slX6bO6zsU?5t4944(oUP5)GKA$4KLQ4haDC`}{Ps+Ey(|x}` zyBd9~%hyJlk{^d?Lo)0)dE5l)3+)ni{3Zg_i0Xi|wj6^6BU*ew>BPGjg>hpsG84#F zFtJR+%|k#s!XCqF_ng1k)XQe2ZTWsnZZ|ncg`BfZy2~e>2r%0X?)0(asHJc|7s;{V zAyLed^iYKNI1KWOw{~cQNG_eYN!$n`KQ1lw1ky25mK1-sOUN<}du0+Jm-|WOJ}UZk z;MD^*RM{7)%54F<f89d$AT43&eEZMXjD>{-bX|b)&Pma9Hxh~L<9I*zLO^8O^&sR* z+Z4@)s8v757MByxkbSog24S(-^4S*wgp`yZd~#%@yPop)OUea1c4?kMp-^sa!(oST zlOoZRWmaIl?bWsCD++LG;;LvBull2<z%AUo%!0tXV5Zh=aOTXJiC4)n)<ylZJ1#8> zTKN2P=4FEB_A-kIhbh4*)5)gT&@Gq#)33|s%4+1d`N2!(NL$;9utxEAWYvRMlM?)J zUGmy09Ze5xzD#Sp`sH(nNMyos$)$75^*zJVnHX>A58rdx9N!z~iBj0<W}FS}{WTSS zYe(Kh?$^;NgZyZ(TL-Pc;QQJ0!or2b!LYc9i2f%v0)ZgFaP|`7cK3seBhSK1u{4h_ z@XA$Y?)2*bv%CGWDk&;eV+0`iroein?E{ZT1m@$$KVz-tVqdPbjg5@~%n0G(y?uRF z>IU6@K0Y6KJQh(%2_L<F(zQbdtgfyO+|gmbe_i?OiRXdC>Z+=$Xf!%}G|=DQ-_LJ; z{R@v*PI@{ju&;VMdI8E|v)OrCwr%pJojwJ7oSpnX!a|OIC{+5t7cWF27_n5j0g~u3 VAD}`@1i=3k$k`F)P-h>U`X3Goc2EES literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/test-tl.png b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/test-tl.png new file mode 100644 index 0000000000000000000000000000000000000000..f6ac0ef7e8f6e192c9c26239884bf92b13cf67b8 GIT binary patch literal 1025 zcmV+c1pfPpP)<h;3K|Lk000e1NJLTq003kF003kJ0{{R3g3O3#0000aP)t-s005aY zGnr;)nE(LHGc(L)X3UwH%*@QpW@i7Hng7hp|NsC0s-1y@0000CbW%=J|NsC0|NsC0 z|Ns9065r0w00001VoOIv3m@0SzyJUPb4f%&RCwC$mQ8M}Fc5&T!~r@I9HIMngrJ)4 zQ(^kjbwEn?FN@yb9iWkt>{9_J2)W!F@R;Dg)Lp$zS!5CX;rV991JU){SM-DYAV0|e zM%uPHwukYjIUJ7B*Q=ZTu2z>QMR^bD+hKK83n7YJaQrDaUiXl8N2@a^ART^^rwFp> z9#IKgok0Td0KkTyXt?~yXZ<2qM=a7Vzey#Q*6RDnL2!78qHiE=Ex4QTA^lz~J%kTw zstmq|U|5-t@E~V@SRUkpVNEL-i@q);x>HzkHGJJLeJv;~hO4ub=d-q4IFZka!eTMc zu`{buHGh%+at79akO>1WhSi7Zh!q^12-bv5K>WppZFh6@Am?f!<BIe8<ZyJvwWFFq zUcMXE0yolD)G8oeTdi8;=!mNz`J_B*yPwI?M)m~}`KHs5imGL+R7;7ZWotYNJV;A* zWckKOJq2tdq{0$$(*LL3ZKU7Jv@p{|rJmVH#VIZ=UDrmLfQ3*?VqE$rdu3uFswG*f z%lCCbgf){JI*%YWuFdgL!bDU{f?kyVyi~}>KvZ5Be|6^zTf#t8UO;S(JZAKN+3ASN z3j@6)uNUz|&Al}d$_w_F78jlrimN;suUD0qIN$0jWDohucq6MjSV#Rh_J5@Pc!G3f z_wwM3t6xj|WYw9-AC(uqCDDE%<9fTAh~QL5JzvTmP~Jf3VT_w`oktbsK$-$vb-dY+ zEip&>4?ZIC^U;m)Hw&SbOn!F;BHM*_pCjsYrK_unjA?=AlYvYnPPY~!(~?^V6%rmz z<RXVlV(+q3UGZ)qa4U<3RPu9z8&h()Lr7;MvMclhIow%G<k?0tDQT)8vXJ#M5t59J znRmOBS}sb`n8kPXi@9Ww{-vOHwGp3wv!1nUm_EL5ha0)Qi>kimBF|Bjt{e!>7aIY` z$e-!kZF!dZ$<~h?Ekqu$Hyc?mW_>Y3_Tv~aU&L~krJRVP<{Xh@#O3lKU&e81AT)VW z+l8Kn<$pJj%%^`<NBnV^?sG(rO721gjrZ5ir7vt3{7A{<<H{~jA7`ID<MD7X!t_;S zAdaE>s>@+0W|%%6zicXInEvpcG8HpS|5i+Fr$GIwnD~MX)K@9PlerDlpNfeu>p=af vm<;kz{V6gHxvP)gcJytThUyO|QzGyW8di!g0nvTM00000NkvXXu0mjfqXF-V literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/test-tr.png b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/support/test-tr.png new file mode 100644 index 0000000000000000000000000000000000000000..59843ae54b64f6ce4f7e616d4be491c911ea84cf GIT binary patch literal 1235 zcmV;^1T6cBP)<h;3K|Lk000e1NJLTq003kF003kJ0{{R3g3O3#0000aP)t-s005aY zGnr;)nE(LHGc(L)X3UwH%*@QpW@i7Hng7hp|NsC0s-1y@0000CbW%=J|NsC0|NsC0 z|Ns9065r0w00001VoOIv3m@0SzyJUQMM*?KRCwC$mrYXRI26aFnjFBd+de=qdOt_N zRTBGjNv4=J5|!QqHQb;NfD32Vom9jLqFiod>%)>Qhp^}!Di#F%(|iB->7dhx5Bfwt zkx%50BC1n|tx|6vK%_mLQWqnX6K;;U`FDFEg`lc|)m4wlpBK4@05B8)B_V|J%_Vlw za4<$t6qwQ5?fVe&2b-UQ(B}DF=TLGmWzFWjfTsuoBj{dz2tgQl^A0mb5R|kzAGjHU zzt-QIvk5};13=E&LB-q-)byMklsg#6^|GA>1kTt&3kTTsQcmN$3rJ$UlvDpmfxi-B zs(OsZVotq*l2F1pfdVHvT}FC0ny!_MGKlO{^1lTH|7D!$)SEgOs2&9Y@Lbr2kd{<# zhySTga0aoQC4`TSr6hxqDd{GMq~)Oxf{zHUHg7p3EkeB)qa9pj)F50=N<;4i33kkV z+Zkfqoh0ngavtIa&CE4aHM11QcA(<ZnS*i}9_-kZ;*#IbkX(ZM7}U-VnO=(WZJ}O6 zN?{sklqJk*eYL?f(2HA43tsrLxw#P83GW(do-aa9$Cseyd*a!d^}6HVyqYAe5u#PP zW%Z*kP*_6LlYHvTg7zzOR0H&%9HKkXNYMzhoi|%+O@~02w{IClNzOR!w=8e?lQnb@ z%pq|-dqh2QW;SdM6#?$Yk>1_eQZqwfj_k!6`W4$RXtT;($sb=Vf=Ltr<fHQ=Orru; zUn;qEfp&3@JVRc|I^G&)9Ni4A9mSQOHEM$Fe1C)nz8+lD!g*#oEk#T?Ym^*pUDLa@ zP0fmiPIHK0vlU}q+Y5`}FTpe9;sq1LWPGS!Et$V!6C--}V}{^za7DM=t4WauJA@K$ zMP={GAs~J}TSO4+Obz2!!c-2PJ^BD}6(L7%qhFFWlm_w*{A_jB&gyf79BgCs?>w9n z=2B#u(Pr7sL0tWekex*^{dF&8!>RY)KGWH*ffTXTQc}}ioq82%jI{MEgls^5+h<%O z^>H1Z@tJtBVk*~XX#88aM!5hI=gDs?hBhOj+jXMvWV-~H?(^Z!I&l*r!fNriI&I;K z<Iv6+Vk^Q0%(qeN5a+0NAxn^9#sT%s+L9uce-sc;vjLIT_kg$%QSX=-v{o_lKqih2 zSFAju?}mC>UB`|wTQ4r~E*vl-*0C6Qu@PH2eTrR0Wf{T~%Xbknf3wf*S&<+a`6o9M zz*S7^KKgFY$UnJ0HVgZg8jXfF%*c<rs4-Jtxk{$Dr$zap4viTq<*Snt>L({(KZLbt zzRNL^s?W;zZP~w5L&>g+M15Ai**#&3n|Wb>4eGP<`;PGlMsC0muRbf^cs3p5##&fh zIr(FkMaZ}vrt)1Swj2@$kLqXgyORsRw`3xZBX}-f+RL=$<nPGNDtben%J*+U`~KZM xFqlMZdn&(j3r#(mcWQ87&CEBe=q+_3|9^_Lp+#u>Ntgft002ovPDHLkV1lbeOeO#T literal 0 HcmV?d00001 diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/toc.xht b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/toc.xht new file mode 100644 index 00000000000..14f2ece28e7 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/toc.xht @@ -0,0 +1,94 @@ + +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head> + <title>CSSOM View Module Level 1 Test Suite</title> + <style type="text/css"> + @import "http://www.w3.org/StyleSheets/TR/base.css"; + @import "../indices.css"; + </style> + </head> +<body> + <h1>CSSOM View Module Level 1 Test Suite By Chapter</h1> + + <p>This index contains both + <a href="http://wiki.csswg.org/test/selftest">self-describing tests</a> + and reftests. + A separate <a href="reftest-toc.xht">alphabetical reftest index</a> + is provided for tests in <a href="http://wiki.csswg.org/test/reftest">reftest + format</a> along with the <a href="reftest.list">reftest manifest</a>.</p> + + <table> + <tbody id="s1"> + <tr><th><a href="chapter-1.xht">Chapter 1 - + Background</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s2"> + <tr><th><a href="chapter-2.xht">Chapter 2 - + Conformance</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s3"> + <tr><th><a href="chapter-3.xht">Chapter 3 - + Terminology</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s4"> + <tr><th><a href="chapter-4.xht">Chapter 4 - + Common Infrastructure</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s5"> + <tr><th><a href="chapter-5.xht">Chapter 5 - + Extensions to the Window Interface</a></th> + <td>(13 Tests)</td></tr> + </tbody> + <tbody id="s6"> + <tr><th><a href="chapter-6.xht">Chapter 6 - + Extensions to the Document Interface</a></th> + <td>(3 Tests)</td></tr> + </tbody> + <tbody id="s7"> + <tr><th><a href="chapter-7.xht">Chapter 7 - + Extensions to the Element Interface</a></th> + <td>(6 Tests)</td></tr> + </tbody> + <tbody id="s8"> + <tr><th><a href="chapter-8.xht">Chapter 8 - + Extensions to the HTMLElement Interface</a></th> + <td>(1 Tests)</td></tr> + </tbody> + <tbody id="s9"> + <tr><th><a href="chapter-9.xht">Chapter 9 - + Excensions to the HTMLImageElement Interface</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s10"> + <tr><th><a href="chapter-10.xht">Chapter 10 - + Extensions to the Range Interface</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s11"> + <tr><th><a href="chapter-11.xht">Chapter 11 - + Extensions to the MouseEvent Interface</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s12"> + <tr><th><a href="chapter-12.xht">Chapter 12 - + Geometry</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s13"> + <tr><th><a href="chapter-13.xht">Chapter 13 - + Events</a></th> + <td>(0 Tests)</td></tr> + </tbody> + <tbody id="s14"> + <tr><th><a href="chapter-14.xht">Chapter 14 - + CSS properties</a></th> + <td>(0 Tests)</td></tr> + </tbody> + </table> +</body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/ttwf-scrollintoview.xht b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/ttwf-scrollintoview.xht new file mode 100644 index 00000000000..fcd0dcde920 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/ttwf-scrollintoview.xht @@ -0,0 +1,31 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSSOM View - 6 - scrollIntoView tests</title> + <meta charset="utf-8" /> + <link href="mailto:pwx.frontend@gmail.com" rel="author" title="Chris Wu" /> + <link href="http://www.w3.org/TR/cssom-view/#dom-element-scrollintoview" rel="help" /> + <meta content="dom" name="flags" /> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> + <style type="text/css"> + #phitem{height: 2000px;} + #viewitem{width:300px;height:200px;margin:0 auto;background-color: lightgreen;} + </style> +</head> +<body> + <div id="myDiv"> + <div id="phitem"></div> + <div id="viewitem"></div> + </div> + <div id="log"></div> + <script> + var asytest = async_test('check scrollIntoView'); + asytest.step(function(){ + var viewitem = document.getElementById('viewitem'); + viewitem.scrollIntoView(); + assert_true(window.pageYOffset + window.innerHeight &gt; viewitem.offsetTop, "The element isn't in the viewport") + }) + asytest.done() + </script> + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/window-interface.xht b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/window-interface.xht new file mode 100644 index 00000000000..a0e16101344 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/window-interface.xht @@ -0,0 +1,97 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> + <head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> + <title>CSSOM Window Test: Properties and Functions</title> + <link rel="author" title="Joe Balancio" href="mailto:jlbalancio@gmail.com" /> + <link rel="help" href="http://www.w3.org/TR/cssom-view/#extensions-to-the-window-interface" /> + <meta name="flags" content="dom" /> + <meta name="assert" content="All properties exist and are readonly. All functions exist and are instances of Function" /> + <script src="/resources/testharness.js" type="text/javascript"></script> + <script src="/resources/testharnessreport.js" type="text/javascript"></script> + </head> + <body> + <noscript>Test not run - javascript required.</noscript> + <div id="log"></div> + <script id="metadata_cache">/* + { + "window_inherited_functions": { + "assert": ["window functions are inherited"] + }, + "window_functions": { + "assert": ["window functions are instances of Function"] + }, + "window_properties": { + "assert": ["window properties are owned by window"] + }, + "window_properties_readonly": { + "assert": ["window properties are readonly"] + } + } + */</script> + <script type="text/javascript"><![CDATA[ + /* + Window Functions + */ + test( + function(){ + assert_inherits(window, "matchMedia"); + assert_inherits(window, "scroll"); + assert_inherits(window, "scrollTo"); + assert_inherits(window, "scrollBy"); + }, 'window_inherited_functions', { + assert: ['window functions are inherited'] + } + ); + + test( + function(){ + assert_true(window.matchMedia instanceof Function); + assert_true(window.scroll instanceof Function); + assert_true(window.scrollTo instanceof Function); + assert_true(window.scrollBy instanceof Function); + }, 'window_functions', { + assert: ['window functions are instances of Function'] + } + ); + + /* + Window Properties + */ + test( + function() { + assert_own_property(window, 'screen'); + assert_own_property(window, 'innerWidth'); + assert_own_property(window, 'innerHeight'); + assert_own_property(window, 'scrollX'); + assert_own_property(window, 'pageXOffset'); + assert_own_property(window, 'scrollY'); + assert_own_property(window, 'pageYOffset'); + assert_own_property(window, 'screenX'); + assert_own_property(window, 'screenY'); + assert_own_property(window, 'outerWidth'); + assert_own_property(window, 'outerHeight'); + }, 'window_properties', { + assert: ['window properties are owned by window'] + } + ); + test( + function() { + assert_readonly(window, 'screen'); + assert_readonly(window, 'innerWidth'); + assert_readonly(window, 'innerHeight'); + assert_readonly(window, 'scrollX'); + assert_readonly(window, 'pageXOffset'); + assert_readonly(window, 'scrollY'); + assert_readonly(window, 'pageYOffset'); + assert_readonly(window, 'screenX'); + assert_readonly(window, 'screenY'); + assert_readonly(window, 'outerWidth'); + assert_readonly(window, 'outerHeight'); + }, 'window_properties_readonly', { + assert: ['window properties are readonly'] + } + ); + ]]> + </script> + </body> +</html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/window-screen-height-immutable.xht b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/window-screen-height-immutable.xht new file mode 100644 index 00000000000..a631db520c0 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/window-screen-height-immutable.xht @@ -0,0 +1,27 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSSOM View - 4.2 - screen.height immutability</title> + <link href="mailto:neils.christoffersen@gmail.com" rel="author" title="Neils Christoffersen" /> + <link href="http://www.w3.org/TR/cssom-view/#the-screen-interface" rel="help" /> + <meta content="dom" name="flags" /> + <meta content="screen.height is immutable" name="assert" /> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> +</head> +<body> + <div id="myDiv"></div> + <div id="log"></div> + <script> + var originalVal = window.screen.height; + + // try to set window.screen.height + window.screen.height = 0; + + // verify window.screen.height didn't change + test(function() { + assert_equals(window.screen.height, originalVal, "window.screen.height should be immutable") + }, "immutability test"); + </script> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/window-screen-height-mutation-throws.xht b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/window-screen-height-mutation-throws.xht new file mode 100644 index 00000000000..4f40b1eb8a5 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/window-screen-height-mutation-throws.xht @@ -0,0 +1,23 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSSOM View - 4.2 - screen.height mutation throws exception</title> + <link href="mailto:neils.christoffersen@gmail.com" rel="author" title="Neils Christoffersen" /> + <link href="http://www.w3.org/TR/cssom-view/#the-screen-interface" rel="help" /> + <meta content="dom" name="flags" /> + <meta content="screen.height mutation throws exception" name="assert" /> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> +</head> +<body> + <div id="myDiv"></div> + <div id="log"></div> + <script> + test(function() { + assert_throws(null, function() { + window.screen.height = 0 + }), "chaning window.screen.height should throw exception" + }, "mutation exception test"); + </script> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/window-screen-height.xht b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/window-screen-height.xht new file mode 100644 index 00000000000..7515dfdf48b --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/window-screen-height.xht @@ -0,0 +1,37 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSSOM View - 4.2 - screen.height range tests</title> + <link href="mailto:neils.christoffersen@gmail.com" rel="author" title="Neils Christoffersen" /> + <link href="http://www.w3.org/TR/cssom-view/#the-screen-interface" rel="help" /> + <meta content="dom" name="flags" /> + <meta content="window.screen.height has sensible values" name="assert" /> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> +</head> +<body> + <div id="myDiv"></div> + <div id="log"></div> + <script> + var upperBound = 50000; + + test( + function() { + assert_not_equals(window.screen.height, 0, "window.screen.height is zero") + }, "zero check" + ); + + test( + function() { + assert_true(window.screen.height &gt; 0, "window.screen.height shouldn't be negative") + }, "positive check" + ); + + test( + function() { + assert_true(window.screen.height &lt; upperBound, "window.screen.height shouldn't be so large") + }, "upper bound check" + ); + </script> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/window-screen-width-immutable.xht b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/window-screen-width-immutable.xht new file mode 100644 index 00000000000..e2381d940ea --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/window-screen-width-immutable.xht @@ -0,0 +1,27 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSSOM View - 4.2 - screen.width immutability</title> + <link href="mailto:neils.christoffersen@gmail.com" rel="author" title="Neils Christoffersen" /> + <link href="http://www.w3.org/TR/cssom-view/#the-screen-interface" rel="help" /> + <meta content="dom" name="flags" /> + <meta content="screen.width is immutable" name="assert" /> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> +</head> +<body> + <div id="myDiv"></div> + <div id="log"></div> + <script> + var originalVal = window.screen.width; + + // try to set window.screen.width + window.screen.width = 0; + + // verify window.screen.width didn't change + test(function() { + assert_equals(window.screen.width, originalVal, "window.screen.width should be immutable") + }, "immutability test"); + </script> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/window-screen-width-mutation-throws.xht b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/window-screen-width-mutation-throws.xht new file mode 100644 index 00000000000..e7fbbf065ef --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/window-screen-width-mutation-throws.xht @@ -0,0 +1,23 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSSOM View - 4.2 - screen.width mutation throws exception</title> + <link href="mailto:neils.christoffersen@gmail.com" rel="author" title="Neils Christoffersen" /> + <link href="http://www.w3.org/TR/cssom-view/#the-screen-interface" rel="help" /> + <meta content="dom" name="flags" /> + <meta content="screen.width mutation throws exception" name="assert" /> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> +</head> +<body> + <div id="myDiv"></div> + <div id="log"></div> + <script> + test(function() { + assert_throws(null, function() { + window.screen.width = 0 + }), "chaning window.screen.width should throw exception" + }, "mutation exception test"); + </script> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/window-screen-width.xht b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/window-screen-width.xht new file mode 100644 index 00000000000..77921547f47 --- /dev/null +++ b/tests/wpt/css-tests/cssom-view-1_dev/xhtml1/window-screen-width.xht @@ -0,0 +1,37 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> + <title>CSSOM View - 4.2 - screen.width range tests</title> + <link href="mailto:neils.christoffersen@gmail.com" rel="author" title="Neils Christoffersen" /> + <link href="http://www.w3.org/TR/cssom-view/#the-screen-interface" rel="help" /> + <meta content="dom" name="flags" /> + <meta content="window.screen.width has sensible values" name="assert" /> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> +</head> +<body> + <div id="myDiv"></div> + <div id="log"></div> + <script> + var upperBound = 50000; + + test( + function() { + assert_not_equals(window.screen.width, 0, "window.screen.width is zero") + }, "zero check" + ); + + test( + function() { + assert_true(window.screen.width &gt; 0, "window.screen.width shouldn't be negative") + }, "positive check" + ); + + test( + function() { + assert_true(window.screen.width &lt; upperBound, "window.screen.width shouldn't be so large") + }, "upper bound check" + ); + </script> + + +</body></html> \ No newline at end of file diff --git a/tests/wpt/css-tests/source_rev b/tests/wpt/css-tests/source_rev index 1543909de7b..2b14b155931 100644 --- a/tests/wpt/css-tests/source_rev +++ b/tests/wpt/css-tests/source_rev @@ -1 +1 @@ -9918dac28080edc77c2e43f939540ab286635d96 \ No newline at end of file +ae96f96b203c2a8f712756c1a9bb3f2b13f7f82b \ No newline at end of file diff --git a/tests/wpt/metadata-css/MANIFEST.json b/tests/wpt/metadata-css/MANIFEST.json index f7bd997408f..65d7e15d0ab 100644 --- a/tests/wpt/metadata-css/MANIFEST.json +++ b/tests/wpt/metadata-css/MANIFEST.json @@ -7361,6 +7361,348 @@ ], "url": "/css-backgrounds-3_dev/xhtml1print/ttwf-reftest-borderRadius.xht" }, + { + "path": "css-break-3_dev/html/floats-clear-breaks-002.htm", + "references": [ + [ + "/css-break-3_dev/html/reference/floats-clear-breaks-002-ref.htm", + "==" + ] + ], + "url": "/css-break-3_dev/html/floats-clear-breaks-002.htm" + }, + { + "path": "css-break-3_dev/html/floats-in-named-flow-012.htm", + "references": [ + [ + "/css-break-3_dev/html/reference/floats-in-named-flow-012-ref.htm", + "==" + ] + ], + "url": "/css-break-3_dev/html/floats-in-named-flow-012.htm" + }, + { + "path": "css-break-3_dev/html/floats-in-named-flow-029.htm", + "references": [ + [ + "/css-break-3_dev/html/reference/floats-in-named-flow-029-ref.htm", + "==" + ] + ], + "url": "/css-break-3_dev/html/floats-in-named-flow-029.htm" + }, + { + "path": "css-break-3_dev/html/floats-in-named-flow-030.htm", + "references": [ + [ + "/css-break-3_dev/html/reference/floats-in-named-flow-030-ref.htm", + "==" + ] + ], + "url": "/css-break-3_dev/html/floats-in-named-flow-030.htm" + }, + { + "path": "css-break-3_dev/html/position-relative-001.htm", + "references": [ + [ + "/css-break-3_dev/html/reference/position-relative-001-ref.htm", + "==" + ] + ], + "url": "/css-break-3_dev/html/position-relative-001.htm" + }, + { + "path": "css-break-3_dev/html/regions-transforms-008.htm", + "references": [ + [ + "/css-break-3_dev/html/reference/regions-transforms-008-ref.htm", + "==" + ] + ], + "url": "/css-break-3_dev/html/regions-transforms-008.htm" + }, + { + "path": "css-break-3_dev/html/regions-transforms-009.htm", + "references": [ + [ + "/css-break-3_dev/html/reference/regions-transforms-008-ref.htm", + "==" + ] + ], + "url": "/css-break-3_dev/html/regions-transforms-009.htm" + }, + { + "path": "css-break-3_dev/html/regions-transforms-013.htm", + "references": [ + [ + "/css-break-3_dev/html/reference/regions-transforms-013-ref.htm", + "==" + ], + [ + "/css-break-3_dev/html/reference/regions-transforms-013-alt-ref.htm", + "==" + ] + ], + "url": "/css-break-3_dev/html/regions-transforms-013.htm" + }, + { + "path": "css-break-3_dev/html/regions-transforms-020.htm", + "references": [ + [ + "/css-break-3_dev/html/reference/regions-transforms-020-ref.htm", + "==" + ] + ], + "url": "/css-break-3_dev/html/regions-transforms-020.htm" + }, + { + "path": "css-break-3_dev/html/regions-transforms-021.htm", + "references": [ + [ + "/css-break-3_dev/html/reference/regions-transforms-020-ref.htm", + "==" + ] + ], + "url": "/css-break-3_dev/html/regions-transforms-021.htm" + }, + { + "path": "css-break-3_dev/html/regions-transforms-022.htm", + "references": [ + [ + "/css-break-3_dev/html/reference/regions-transforms-020-ref.htm", + "==" + ] + ], + "url": "/css-break-3_dev/html/regions-transforms-022.htm" + }, + { + "path": "css-break-3_dev/xhtml1/floats-clear-breaks-002.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1/reference/floats-clear-breaks-002-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1/floats-clear-breaks-002.xht" + }, + { + "path": "css-break-3_dev/xhtml1/floats-in-named-flow-012.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1/reference/floats-in-named-flow-012-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1/floats-in-named-flow-012.xht" + }, + { + "path": "css-break-3_dev/xhtml1/floats-in-named-flow-029.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1/reference/floats-in-named-flow-029-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1/floats-in-named-flow-029.xht" + }, + { + "path": "css-break-3_dev/xhtml1/floats-in-named-flow-030.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1/reference/floats-in-named-flow-030-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1/floats-in-named-flow-030.xht" + }, + { + "path": "css-break-3_dev/xhtml1/position-relative-001.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1/reference/position-relative-001-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1/position-relative-001.xht" + }, + { + "path": "css-break-3_dev/xhtml1/regions-transforms-008.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1/reference/regions-transforms-008-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1/regions-transforms-008.xht" + }, + { + "path": "css-break-3_dev/xhtml1/regions-transforms-009.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1/reference/regions-transforms-008-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1/regions-transforms-009.xht" + }, + { + "path": "css-break-3_dev/xhtml1/regions-transforms-013.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1/reference/regions-transforms-013-ref.xht", + "==" + ], + [ + "/css-break-3_dev/xhtml1/reference/regions-transforms-013-alt-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1/regions-transforms-013.xht" + }, + { + "path": "css-break-3_dev/xhtml1/regions-transforms-020.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1/reference/regions-transforms-020-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1/regions-transforms-020.xht" + }, + { + "path": "css-break-3_dev/xhtml1/regions-transforms-021.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1/reference/regions-transforms-020-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1/regions-transforms-021.xht" + }, + { + "path": "css-break-3_dev/xhtml1/regions-transforms-022.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1/reference/regions-transforms-020-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1/regions-transforms-022.xht" + }, + { + "path": "css-break-3_dev/xhtml1print/floats-clear-breaks-002.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1print/reference/floats-clear-breaks-002-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1print/floats-clear-breaks-002.xht" + }, + { + "path": "css-break-3_dev/xhtml1print/floats-in-named-flow-012.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1print/reference/floats-in-named-flow-012-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1print/floats-in-named-flow-012.xht" + }, + { + "path": "css-break-3_dev/xhtml1print/floats-in-named-flow-029.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1print/reference/floats-in-named-flow-029-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1print/floats-in-named-flow-029.xht" + }, + { + "path": "css-break-3_dev/xhtml1print/floats-in-named-flow-030.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1print/reference/floats-in-named-flow-030-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1print/floats-in-named-flow-030.xht" + }, + { + "path": "css-break-3_dev/xhtml1print/position-relative-001.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1print/reference/position-relative-001-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1print/position-relative-001.xht" + }, + { + "path": "css-break-3_dev/xhtml1print/regions-transforms-008.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1print/reference/regions-transforms-008-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1print/regions-transforms-008.xht" + }, + { + "path": "css-break-3_dev/xhtml1print/regions-transforms-009.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1print/reference/regions-transforms-008-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1print/regions-transforms-009.xht" + }, + { + "path": "css-break-3_dev/xhtml1print/regions-transforms-013.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1print/reference/regions-transforms-013-ref.xht", + "==" + ], + [ + "/css-break-3_dev/xhtml1print/reference/regions-transforms-013-alt-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1print/regions-transforms-013.xht" + }, + { + "path": "css-break-3_dev/xhtml1print/regions-transforms-020.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1print/reference/regions-transforms-020-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1print/regions-transforms-020.xht" + }, + { + "path": "css-break-3_dev/xhtml1print/regions-transforms-021.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1print/reference/regions-transforms-020-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1print/regions-transforms-021.xht" + }, + { + "path": "css-break-3_dev/xhtml1print/regions-transforms-022.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1print/reference/regions-transforms-020-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1print/regions-transforms-022.xht" + }, { "path": "css-color-3_dev/html4/t31-color-currentColor-b.htm", "references": [ @@ -46751,6 +47093,96 @@ ], "url": "/css-multicol-1_dev/xhtml1print/regions-multicol-029.xht" }, + { + "path": "css-pseudo-4_dev/html/first-letter-001.htm", + "references": [ + [ + "/css-pseudo-4_dev/html/reference/first-letter-001-ref.htm", + "==" + ] + ], + "url": "/css-pseudo-4_dev/html/first-letter-001.htm" + }, + { + "path": "css-pseudo-4_dev/html/first-letter-002.htm", + "references": [ + [ + "/css-pseudo-4_dev/html/reference/first-letter-001-ref.htm", + "==" + ] + ], + "url": "/css-pseudo-4_dev/html/first-letter-002.htm" + }, + { + "path": "css-pseudo-4_dev/html/first-letter-003.htm", + "references": [ + [ + "/css-pseudo-4_dev/html/reference/first-letter-001-ref.htm", + "==" + ] + ], + "url": "/css-pseudo-4_dev/html/first-letter-003.htm" + }, + { + "path": "css-pseudo-4_dev/xhtml1/first-letter-001.xht", + "references": [ + [ + "/css-pseudo-4_dev/xhtml1/reference/first-letter-001-ref.xht", + "==" + ] + ], + "url": "/css-pseudo-4_dev/xhtml1/first-letter-001.xht" + }, + { + "path": "css-pseudo-4_dev/xhtml1/first-letter-002.xht", + "references": [ + [ + "/css-pseudo-4_dev/xhtml1/reference/first-letter-001-ref.xht", + "==" + ] + ], + "url": "/css-pseudo-4_dev/xhtml1/first-letter-002.xht" + }, + { + "path": "css-pseudo-4_dev/xhtml1/first-letter-003.xht", + "references": [ + [ + "/css-pseudo-4_dev/xhtml1/reference/first-letter-001-ref.xht", + "==" + ] + ], + "url": "/css-pseudo-4_dev/xhtml1/first-letter-003.xht" + }, + { + "path": "css-pseudo-4_dev/xhtml1print/first-letter-001.xht", + "references": [ + [ + "/css-pseudo-4_dev/xhtml1print/reference/first-letter-001-ref.xht", + "==" + ] + ], + "url": "/css-pseudo-4_dev/xhtml1print/first-letter-001.xht" + }, + { + "path": "css-pseudo-4_dev/xhtml1print/first-letter-002.xht", + "references": [ + [ + "/css-pseudo-4_dev/xhtml1print/reference/first-letter-001-ref.xht", + "==" + ] + ], + "url": "/css-pseudo-4_dev/xhtml1print/first-letter-002.xht" + }, + { + "path": "css-pseudo-4_dev/xhtml1print/first-letter-003.xht", + "references": [ + [ + "/css-pseudo-4_dev/xhtml1print/reference/first-letter-001-ref.xht", + "==" + ] + ], + "url": "/css-pseudo-4_dev/xhtml1print/first-letter-003.xht" + }, { "path": "css-regions-1_dev/html/animations-001.htm", "references": [ @@ -108129,6 +108561,1076 @@ ], "url": "/css-ui-3_dev/xhtml1print/text-overflow.xht" }, + { + "path": "css-values-3_dev/html/calc-background-image-gradient-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-background-image-gradient-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-background-image-gradient-1.htm" + }, + { + "path": "css-values-3_dev/html/calc-background-linear-gradient-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-background-linear-gradient-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-background-linear-gradient-1.htm" + }, + { + "path": "css-values-3_dev/html/calc-background-position-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-background-position-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-background-position-1.htm" + }, + { + "path": "css-values-3_dev/html/calc-background-size-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-background-size-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-background-size-1.htm" + }, + { + "path": "css-values-3_dev/html/calc-border-radius-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-border-radius-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-border-radius-1.htm" + }, + { + "path": "css-values-3_dev/html/calc-height-block-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-height-block-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-height-block-1.htm" + }, + { + "path": "css-values-3_dev/html/calc-height-table-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-height-table-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-height-table-1.htm" + }, + { + "path": "css-values-3_dev/html/calc-margin-block-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-margin-block-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-margin-block-1.htm" + }, + { + "path": "css-values-3_dev/html/calc-max-height-block-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-max-height-block-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-max-height-block-1.htm" + }, + { + "path": "css-values-3_dev/html/calc-max-width-block-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-width-block-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-max-width-block-1.htm" + }, + { + "path": "css-values-3_dev/html/calc-max-width-block-intrinsic-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-max-width-block-intrinsic-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-max-width-block-intrinsic-1.htm" + }, + { + "path": "css-values-3_dev/html/calc-min-height-block-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-height-block-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-min-height-block-1.htm" + }, + { + "path": "css-values-3_dev/html/calc-min-width-block-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-width-block-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-min-width-block-1.htm" + }, + { + "path": "css-values-3_dev/html/calc-min-width-block-intrinsic-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-min-width-block-intrinsic-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-min-width-block-intrinsic-1.htm" + }, + { + "path": "css-values-3_dev/html/calc-offsets-absolute-bottom-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-offsets-absolute-top-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-offsets-absolute-bottom-1.htm" + }, + { + "path": "css-values-3_dev/html/calc-offsets-absolute-left-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-offsets-relative-left-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-offsets-absolute-left-1.htm" + }, + { + "path": "css-values-3_dev/html/calc-offsets-absolute-right-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-offsets-relative-left-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-offsets-absolute-right-1.htm" + }, + { + "path": "css-values-3_dev/html/calc-offsets-absolute-top-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-offsets-absolute-top-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-offsets-absolute-top-1.htm" + }, + { + "path": "css-values-3_dev/html/calc-offsets-relative-bottom-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-offsets-relative-top-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-offsets-relative-bottom-1.htm" + }, + { + "path": "css-values-3_dev/html/calc-offsets-relative-left-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-offsets-relative-left-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-offsets-relative-left-1.htm" + }, + { + "path": "css-values-3_dev/html/calc-offsets-relative-right-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-offsets-relative-left-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-offsets-relative-right-1.htm" + }, + { + "path": "css-values-3_dev/html/calc-offsets-relative-top-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-offsets-relative-top-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-offsets-relative-top-1.htm" + }, + { + "path": "css-values-3_dev/html/calc-padding-block-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-padding-block-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-padding-block-1.htm" + }, + { + "path": "css-values-3_dev/html/calc-text-indent-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-text-indent-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-text-indent-1.htm" + }, + { + "path": "css-values-3_dev/html/calc-text-indent-intrinsic-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-text-indent-intrinsic-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-text-indent-intrinsic-1.htm" + }, + { + "path": "css-values-3_dev/html/calc-transform-origin-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-transform-origin-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-transform-origin-1.htm" + }, + { + "path": "css-values-3_dev/html/calc-vertical-align-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-vertical-align-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-vertical-align-1.htm" + }, + { + "path": "css-values-3_dev/html/calc-width-block-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-width-block-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-width-block-1.htm" + }, + { + "path": "css-values-3_dev/html/calc-width-block-intrinsic-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-width-block-intrinsic-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-width-block-intrinsic-1.htm" + }, + { + "path": "css-values-3_dev/html/calc-width-table-auto-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-width-table-auto-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-width-table-auto-1.htm" + }, + { + "path": "css-values-3_dev/html/calc-width-table-fixed-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-width-table-fixed-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-width-table-fixed-1.htm" + }, + { + "path": "css-values-3_dev/html/ch-unit-001.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/ch-unit-001-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/ch-unit-001.htm" + }, + { + "path": "css-values-3_dev/html/min-width-001.htm", + "references": [ + [ + "/css-values-3_dev/html/ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/min-width-001.htm" + }, + { + "path": "css-values-3_dev/html/multicol-count-non-integer-001.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/multicol-columns-invalid-001-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/multicol-count-non-integer-001.htm" + }, + { + "path": "css-values-3_dev/html/multicol-count-non-integer-002.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/multicol-columns-invalid-001-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/multicol-count-non-integer-002.htm" + }, + { + "path": "css-values-3_dev/html/multicol-count-non-integer-003.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/multicol-columns-invalid-001-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/multicol-count-non-integer-003.htm" + }, + { + "path": "css-values-3_dev/html/multicol-inherit-002.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/multicol-inherit-002-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/multicol-inherit-002.htm" + }, + { + "path": "css-values-3_dev/html/multicol-rule-color-inherit-001.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/multicol-rule-color-inherit-001-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/multicol-rule-color-inherit-001.htm" + }, + { + "path": "css-values-3_dev/html/multicol-rule-color-inherit-002.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/multicol-rule-color-inherit-001-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/multicol-rule-color-inherit-002.htm" + }, + { + "path": "css-values-3_dev/html/regions-resizing-003.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/regions-resizing-001-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/regions-resizing-003.htm" + }, + { + "path": "css-values-3_dev/html/regions-resizing-007.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/regions-resizing-001-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/regions-resizing-007.htm" + }, + { + "path": "css-values-3_dev/html/regions-resizing-009.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/regions-resizing-001-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/regions-resizing-009.htm" + }, + { + "path": "css-values-3_dev/html/vh-calc-support-pct.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/all-green.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/vh-calc-support-pct.htm" + }, + { + "path": "css-values-3_dev/html/vh-calc-support.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/all-green.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/vh-calc-support.htm" + }, + { + "path": "css-values-3_dev/html/vh-em-inherit.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/all-green.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/vh-em-inherit.htm" + }, + { + "path": "css-values-3_dev/html/vh-inherit.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/all-green.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/vh-inherit.htm" + }, + { + "path": "css-values-3_dev/html/vh-interpolate-pct.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/all-green.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/vh-interpolate-pct.htm" + }, + { + "path": "css-values-3_dev/html/vh-interpolate-px.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/all-green.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/vh-interpolate-px.htm" + }, + { + "path": "css-values-3_dev/html/vh-interpolate-vh.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/all-green.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/vh-interpolate-vh.htm" + }, + { + "path": "css-values-3_dev/html/vh-support-atviewport.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/all-green.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/vh-support-atviewport.htm" + }, + { + "path": "css-values-3_dev/html/vh-support-margin.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/all-green.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/vh-support-margin.htm" + }, + { + "path": "css-values-3_dev/html/vh-support-transform-origin.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/all-green.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/vh-support-transform-origin.htm" + }, + { + "path": "css-values-3_dev/html/vh-support-transform-translate.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/all-green.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/vh-support-transform-translate.htm" + }, + { + "path": "css-values-3_dev/html/vh-support.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/all-green.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/vh-support.htm" + }, + { + "path": "css-values-3_dev/html/vh-zero-support.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/all-green.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/vh-zero-support.htm" + }, + { + "path": "css-values-3_dev/html/vh_not_refreshing_on_chrome.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/vh_not_refreshing_on_chrome-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/vh_not_refreshing_on_chrome.htm" + }, + { + "path": "css-values-3_dev/html/vh_not_refreshing_on_chrome_iframe.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/vh_not_refreshing_on_chrome-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/vh_not_refreshing_on_chrome_iframe.htm" + }, + { + "path": "css-values-3_dev/xhtml1/calc-background-image-gradient-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-background-image-gradient-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-background-image-gradient-1.xht" + }, + { + "path": "css-values-3_dev/xhtml1/calc-background-linear-gradient-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-background-linear-gradient-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-background-linear-gradient-1.xht" + }, + { + "path": "css-values-3_dev/xhtml1/calc-background-position-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-background-position-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-background-position-1.xht" + }, + { + "path": "css-values-3_dev/xhtml1/calc-background-size-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-background-size-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-background-size-1.xht" + }, + { + "path": "css-values-3_dev/xhtml1/calc-border-radius-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-border-radius-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-border-radius-1.xht" + }, + { + "path": "css-values-3_dev/xhtml1/calc-height-block-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-height-block-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-height-block-1.xht" + }, + { + "path": "css-values-3_dev/xhtml1/calc-height-table-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-height-table-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-height-table-1.xht" + }, + { + "path": "css-values-3_dev/xhtml1/calc-margin-block-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-margin-block-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-margin-block-1.xht" + }, + { + "path": "css-values-3_dev/xhtml1/calc-max-height-block-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-max-height-block-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-max-height-block-1.xht" + }, + { + "path": "css-values-3_dev/xhtml1/calc-max-width-block-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-width-block-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-max-width-block-1.xht" + }, + { + "path": "css-values-3_dev/xhtml1/calc-max-width-block-intrinsic-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-max-width-block-intrinsic-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-max-width-block-intrinsic-1.xht" + }, + { + "path": "css-values-3_dev/xhtml1/calc-min-height-block-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-height-block-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-min-height-block-1.xht" + }, + { + "path": "css-values-3_dev/xhtml1/calc-min-width-block-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-width-block-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-min-width-block-1.xht" + }, + { + "path": "css-values-3_dev/xhtml1/calc-min-width-block-intrinsic-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-min-width-block-intrinsic-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-min-width-block-intrinsic-1.xht" + }, + { + "path": "css-values-3_dev/xhtml1/calc-offsets-absolute-bottom-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-offsets-absolute-top-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-offsets-absolute-bottom-1.xht" + }, + { + "path": "css-values-3_dev/xhtml1/calc-offsets-absolute-left-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-offsets-relative-left-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-offsets-absolute-left-1.xht" + }, + { + "path": "css-values-3_dev/xhtml1/calc-offsets-absolute-right-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-offsets-relative-left-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-offsets-absolute-right-1.xht" + }, + { + "path": "css-values-3_dev/xhtml1/calc-offsets-absolute-top-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-offsets-absolute-top-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-offsets-absolute-top-1.xht" + }, + { + "path": "css-values-3_dev/xhtml1/calc-offsets-relative-bottom-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-offsets-relative-top-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-offsets-relative-bottom-1.xht" + }, + { + "path": "css-values-3_dev/xhtml1/calc-offsets-relative-left-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-offsets-relative-left-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-offsets-relative-left-1.xht" + }, + { + "path": "css-values-3_dev/xhtml1/calc-offsets-relative-right-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-offsets-relative-left-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-offsets-relative-right-1.xht" + }, + { + "path": "css-values-3_dev/xhtml1/calc-offsets-relative-top-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-offsets-relative-top-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-offsets-relative-top-1.xht" + }, + { + "path": "css-values-3_dev/xhtml1/calc-padding-block-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-padding-block-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-padding-block-1.xht" + }, + { + "path": "css-values-3_dev/xhtml1/calc-text-indent-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-text-indent-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-text-indent-1.xht" + }, + { + "path": "css-values-3_dev/xhtml1/calc-text-indent-intrinsic-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-text-indent-intrinsic-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-text-indent-intrinsic-1.xht" + }, + { + "path": "css-values-3_dev/xhtml1/calc-transform-origin-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-transform-origin-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-transform-origin-1.xht" + }, + { + "path": "css-values-3_dev/xhtml1/calc-vertical-align-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-vertical-align-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-vertical-align-1.xht" + }, + { + "path": "css-values-3_dev/xhtml1/calc-width-block-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-width-block-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-width-block-1.xht" + }, + { + "path": "css-values-3_dev/xhtml1/calc-width-block-intrinsic-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-width-block-intrinsic-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-width-block-intrinsic-1.xht" + }, + { + "path": "css-values-3_dev/xhtml1/calc-width-table-auto-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-width-table-auto-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-width-table-auto-1.xht" + }, + { + "path": "css-values-3_dev/xhtml1/calc-width-table-fixed-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-width-table-fixed-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-width-table-fixed-1.xht" + }, + { + "path": "css-values-3_dev/xhtml1/ch-unit-001.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/ch-unit-001-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/ch-unit-001.xht" + }, + { + "path": "css-values-3_dev/xhtml1/min-width-001.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/min-width-001.xht" + }, + { + "path": "css-values-3_dev/xhtml1/multicol-count-non-integer-001.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/multicol-columns-invalid-001-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/multicol-count-non-integer-001.xht" + }, + { + "path": "css-values-3_dev/xhtml1/multicol-count-non-integer-002.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/multicol-columns-invalid-001-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/multicol-count-non-integer-002.xht" + }, + { + "path": "css-values-3_dev/xhtml1/multicol-count-non-integer-003.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/multicol-columns-invalid-001-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/multicol-count-non-integer-003.xht" + }, + { + "path": "css-values-3_dev/xhtml1/multicol-inherit-002.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/multicol-inherit-002-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/multicol-inherit-002.xht" + }, + { + "path": "css-values-3_dev/xhtml1/regions-resizing-003.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/regions-resizing-001-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/regions-resizing-003.xht" + }, + { + "path": "css-values-3_dev/xhtml1/regions-resizing-007.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/regions-resizing-001-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/regions-resizing-007.xht" + }, + { + "path": "css-values-3_dev/xhtml1/regions-resizing-009.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/regions-resizing-001-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/regions-resizing-009.xht" + }, + { + "path": "css-values-3_dev/xhtml1/vh-em-inherit.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/all-green.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/vh-em-inherit.xht" + }, + { + "path": "css-values-3_dev/xhtml1/vh-inherit.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/all-green.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/vh-inherit.xht" + }, + { + "path": "css-values-3_dev/xhtml1/vh-interpolate-pct.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/all-green.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/vh-interpolate-pct.xht" + }, + { + "path": "css-values-3_dev/xhtml1/vh-interpolate-px.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/all-green.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/vh-interpolate-px.xht" + }, + { + "path": "css-values-3_dev/xhtml1/vh-interpolate-vh.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/all-green.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/vh-interpolate-vh.xht" + }, + { + "path": "css-values-3_dev/xhtml1/vh-support-margin.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/all-green.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/vh-support-margin.xht" + }, + { + "path": "css-values-3_dev/xhtml1/vh-support.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/all-green.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/vh-support.xht" + }, + { + "path": "css-values-3_dev/xhtml1/vh-zero-support.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/all-green.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/vh-zero-support.xht" + }, + { + "path": "css-values-3_dev/xhtml1/vh_not_refreshing_on_chrome.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/vh_not_refreshing_on_chrome-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/vh_not_refreshing_on_chrome.xht" + }, + { + "path": "css-values-3_dev/xhtml1/vh_not_refreshing_on_chrome_iframe.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/vh_not_refreshing_on_chrome-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/vh_not_refreshing_on_chrome_iframe.xht" + }, { "path": "css-variables-1_dev/html/css-vars-custom-property-case-sensitive-001.htm", "references": [ @@ -144515,6 +146017,16 @@ ], "url": "/css21_dev/html4/before-after-positioned-001.htm" }, + { + "path": "css21_dev/html4/before-after-selector-001.htm", + "references": [ + [ + "/css21_dev/html4/reference/before-after-selector-001-ref.htm", + "==" + ] + ], + "url": "/css21_dev/html4/before-after-selector-001.htm" + }, { "path": "css21_dev/html4/before-after-table-parts-001.htm", "references": [ @@ -172179,6 +173691,16 @@ ], "url": "/css21_dev/html4/keywords-001.htm" }, + { + "path": "css21_dev/html4/lang-selector-001.htm", + "references": [ + [ + "/css21_dev/html4/reference/lang-selector-001-ref.htm", + "==" + ] + ], + "url": "/css21_dev/html4/lang-selector-001.htm" + }, { "path": "css21_dev/html4/lang-selector-002.htm", "references": [ @@ -203689,6 +205211,16 @@ ], "url": "/css21_dev/xhtml1/before-after-positioned-001.xht" }, + { + "path": "css21_dev/xhtml1/before-after-selector-001.xht", + "references": [ + [ + "/css21_dev/xhtml1/reference/before-after-selector-001-ref.xht", + "==" + ] + ], + "url": "/css21_dev/xhtml1/before-after-selector-001.xht" + }, { "path": "css21_dev/xhtml1/before-after-table-parts-001.xht", "references": [ @@ -231043,6 +232575,16 @@ ], "url": "/css21_dev/xhtml1/keywords-001.xht" }, + { + "path": "css21_dev/xhtml1/lang-selector-001.xht", + "references": [ + [ + "/css21_dev/xhtml1/reference/lang-selector-001-ref.xht", + "==" + ] + ], + "url": "/css21_dev/xhtml1/lang-selector-001.xht" + }, { "path": "css21_dev/xhtml1/lang-selector-002.xht", "references": [ @@ -262303,6 +263845,16 @@ ], "url": "/css21_dev/xhtml1print/before-after-positioned-001.xht" }, + { + "path": "css21_dev/xhtml1print/before-after-selector-001.xht", + "references": [ + [ + "/css21_dev/xhtml1print/reference/before-after-selector-001-ref.xht", + "==" + ] + ], + "url": "/css21_dev/xhtml1print/before-after-selector-001.xht" + }, { "path": "css21_dev/xhtml1print/before-after-table-parts-001.xht", "references": [ @@ -289657,6 +291209,16 @@ ], "url": "/css21_dev/xhtml1print/keywords-001.xht" }, + { + "path": "css21_dev/xhtml1print/lang-selector-001.xht", + "references": [ + [ + "/css21_dev/xhtml1print/reference/lang-selector-001-ref.xht", + "==" + ] + ], + "url": "/css21_dev/xhtml1print/lang-selector-001.xht" + }, { "path": "css21_dev/xhtml1print/lang-selector-002.xht", "references": [ @@ -315382,6 +316944,94 @@ "path": "css-transitions-1_dev/xhtml1/transitions-animatable-properties-01.xht", "url": "/css-transitions-1_dev/xhtml1/transitions-animatable-properties-01.xht" }, + { + "path": "css-values-3_dev/html/calc-unit-analysis.htm", + "url": "/css-values-3_dev/html/calc-unit-analysis.htm" + }, + { + "path": "css-values-3_dev/html/shape-outside-circle-002.htm", + "url": "/css-values-3_dev/html/shape-outside-circle-002.htm" + }, + { + "path": "css-values-3_dev/html/shape-outside-circle-004.htm", + "url": "/css-values-3_dev/html/shape-outside-circle-004.htm" + }, + { + "path": "css-values-3_dev/html/shape-outside-ellipse-002.htm", + "url": "/css-values-3_dev/html/shape-outside-ellipse-002.htm" + }, + { + "path": "css-values-3_dev/html/shape-outside-ellipse-004.htm", + "url": "/css-values-3_dev/html/shape-outside-ellipse-004.htm" + }, + { + "path": "css-values-3_dev/html/shape-outside-inset-003.htm", + "url": "/css-values-3_dev/html/shape-outside-inset-003.htm" + }, + { + "path": "css-values-3_dev/html/shape-outside-polygon-004.htm", + "url": "/css-values-3_dev/html/shape-outside-polygon-004.htm" + }, + { + "path": "css-values-3_dev/html/transition-delay-001.htm", + "url": "/css-values-3_dev/html/transition-delay-001.htm" + }, + { + "path": "css-values-3_dev/html/transition-duration-001.htm", + "url": "/css-values-3_dev/html/transition-duration-001.htm" + }, + { + "path": "css-values-3_dev/html/viewport-relative-lengths-scaled-viewport.htm", + "url": "/css-values-3_dev/html/viewport-relative-lengths-scaled-viewport.htm" + }, + { + "path": "css-values-3_dev/html/viewport-units-css2-001.htm", + "url": "/css-values-3_dev/html/viewport-units-css2-001.htm" + }, + { + "path": "css-values-3_dev/xhtml1/calc-unit-analysis.xht", + "url": "/css-values-3_dev/xhtml1/calc-unit-analysis.xht" + }, + { + "path": "css-values-3_dev/xhtml1/shape-outside-circle-002.xht", + "url": "/css-values-3_dev/xhtml1/shape-outside-circle-002.xht" + }, + { + "path": "css-values-3_dev/xhtml1/shape-outside-circle-004.xht", + "url": "/css-values-3_dev/xhtml1/shape-outside-circle-004.xht" + }, + { + "path": "css-values-3_dev/xhtml1/shape-outside-ellipse-002.xht", + "url": "/css-values-3_dev/xhtml1/shape-outside-ellipse-002.xht" + }, + { + "path": "css-values-3_dev/xhtml1/shape-outside-ellipse-004.xht", + "url": "/css-values-3_dev/xhtml1/shape-outside-ellipse-004.xht" + }, + { + "path": "css-values-3_dev/xhtml1/shape-outside-inset-003.xht", + "url": "/css-values-3_dev/xhtml1/shape-outside-inset-003.xht" + }, + { + "path": "css-values-3_dev/xhtml1/shape-outside-polygon-004.xht", + "url": "/css-values-3_dev/xhtml1/shape-outside-polygon-004.xht" + }, + { + "path": "css-values-3_dev/xhtml1/transition-delay-001.xht", + "url": "/css-values-3_dev/xhtml1/transition-delay-001.xht" + }, + { + "path": "css-values-3_dev/xhtml1/transition-duration-001.xht", + "url": "/css-values-3_dev/xhtml1/transition-duration-001.xht" + }, + { + "path": "css-values-3_dev/xhtml1/viewport-relative-lengths-scaled-viewport.xht", + "url": "/css-values-3_dev/xhtml1/viewport-relative-lengths-scaled-viewport.xht" + }, + { + "path": "css-values-3_dev/xhtml1/viewport-units-css2-001.xht", + "url": "/css-values-3_dev/xhtml1/viewport-units-css2-001.xht" + }, { "path": "css-variables-1_dev/html/test_variable_legal_values.htm", "url": "/css-variables-1_dev/html/test_variable_legal_values.htm" @@ -316426,6 +318076,190 @@ "path": "cssom-1_dev/xhtml1print/ttwf-cssom-document-extension.xht", "url": "/cssom-1_dev/xhtml1print/ttwf-cssom-document-extension.xht" }, + { + "path": "cssom-view-1_dev/html/CaretPosition-001.htm", + "url": "/cssom-view-1_dev/html/CaretPosition-001.htm" + }, + { + "path": "cssom-view-1_dev/html/MediaQueryList-001.htm", + "url": "/cssom-view-1_dev/html/MediaQueryList-001.htm" + }, + { + "path": "cssom-view-1_dev/html/Screen-pixelDepth-Screen-colorDepth001.htm", + "url": "/cssom-view-1_dev/html/Screen-pixelDepth-Screen-colorDepth001.htm" + }, + { + "path": "cssom-view-1_dev/html/cssom-getBoundingClientRect-001.htm", + "url": "/cssom-view-1_dev/html/cssom-getBoundingClientRect-001.htm" + }, + { + "path": "cssom-view-1_dev/html/cssom-getBoundingClientRect-002.htm", + "url": "/cssom-view-1_dev/html/cssom-getBoundingClientRect-002.htm" + }, + { + "path": "cssom-view-1_dev/html/cssom-getClientRects.htm", + "url": "/cssom-view-1_dev/html/cssom-getClientRects.htm" + }, + { + "path": "cssom-view-1_dev/html/cssom-view-window-screen-interface.htm", + "url": "/cssom-view-1_dev/html/cssom-view-window-screen-interface.htm" + }, + { + "path": "cssom-view-1_dev/html/elementFromPoint-001.htm", + "url": "/cssom-view-1_dev/html/elementFromPoint-001.htm" + }, + { + "path": "cssom-view-1_dev/html/elementFromPosition.htm", + "url": "/cssom-view-1_dev/html/elementFromPosition.htm" + }, + { + "path": "cssom-view-1_dev/html/matchMedia.htm", + "url": "/cssom-view-1_dev/html/matchMedia.htm" + }, + { + "path": "cssom-view-1_dev/html/matchMediaAddListener.htm", + "url": "/cssom-view-1_dev/html/matchMediaAddListener.htm" + }, + { + "path": "cssom-view-1_dev/html/media-query-list-interface.htm", + "url": "/cssom-view-1_dev/html/media-query-list-interface.htm" + }, + { + "path": "cssom-view-1_dev/html/offsetParent_element_test.htm", + "url": "/cssom-view-1_dev/html/offsetParent_element_test.htm" + }, + { + "path": "cssom-view-1_dev/html/scrollWidthHeight.htm", + "url": "/cssom-view-1_dev/html/scrollWidthHeight.htm" + }, + { + "path": "cssom-view-1_dev/html/scrollWidthHeightWhenNotScrollable.htm", + "url": "/cssom-view-1_dev/html/scrollWidthHeightWhenNotScrollable.htm" + }, + { + "path": "cssom-view-1_dev/html/ttwf-scrollintoview.htm", + "url": "/cssom-view-1_dev/html/ttwf-scrollintoview.htm" + }, + { + "path": "cssom-view-1_dev/html/window-interface.htm", + "url": "/cssom-view-1_dev/html/window-interface.htm" + }, + { + "path": "cssom-view-1_dev/html/window-screen-height-immutable.htm", + "url": "/cssom-view-1_dev/html/window-screen-height-immutable.htm" + }, + { + "path": "cssom-view-1_dev/html/window-screen-height-mutation-throws.htm", + "url": "/cssom-view-1_dev/html/window-screen-height-mutation-throws.htm" + }, + { + "path": "cssom-view-1_dev/html/window-screen-height.htm", + "url": "/cssom-view-1_dev/html/window-screen-height.htm" + }, + { + "path": "cssom-view-1_dev/html/window-screen-width-immutable.htm", + "url": "/cssom-view-1_dev/html/window-screen-width-immutable.htm" + }, + { + "path": "cssom-view-1_dev/html/window-screen-width-mutation-throws.htm", + "url": "/cssom-view-1_dev/html/window-screen-width-mutation-throws.htm" + }, + { + "path": "cssom-view-1_dev/html/window-screen-width.htm", + "url": "/cssom-view-1_dev/html/window-screen-width.htm" + }, + { + "path": "cssom-view-1_dev/xhtml1/CaretPosition-001.xht", + "url": "/cssom-view-1_dev/xhtml1/CaretPosition-001.xht" + }, + { + "path": "cssom-view-1_dev/xhtml1/MediaQueryList-001.xht", + "url": "/cssom-view-1_dev/xhtml1/MediaQueryList-001.xht" + }, + { + "path": "cssom-view-1_dev/xhtml1/Screen-pixelDepth-Screen-colorDepth001.xht", + "url": "/cssom-view-1_dev/xhtml1/Screen-pixelDepth-Screen-colorDepth001.xht" + }, + { + "path": "cssom-view-1_dev/xhtml1/cssom-getBoundingClientRect-001.xht", + "url": "/cssom-view-1_dev/xhtml1/cssom-getBoundingClientRect-001.xht" + }, + { + "path": "cssom-view-1_dev/xhtml1/cssom-getBoundingClientRect-002.xht", + "url": "/cssom-view-1_dev/xhtml1/cssom-getBoundingClientRect-002.xht" + }, + { + "path": "cssom-view-1_dev/xhtml1/cssom-getClientRects.xht", + "url": "/cssom-view-1_dev/xhtml1/cssom-getClientRects.xht" + }, + { + "path": "cssom-view-1_dev/xhtml1/cssom-view-window-screen-interface.xht", + "url": "/cssom-view-1_dev/xhtml1/cssom-view-window-screen-interface.xht" + }, + { + "path": "cssom-view-1_dev/xhtml1/elementFromPoint-001.xht", + "url": "/cssom-view-1_dev/xhtml1/elementFromPoint-001.xht" + }, + { + "path": "cssom-view-1_dev/xhtml1/elementFromPosition.xht", + "url": "/cssom-view-1_dev/xhtml1/elementFromPosition.xht" + }, + { + "path": "cssom-view-1_dev/xhtml1/matchMedia.xht", + "url": "/cssom-view-1_dev/xhtml1/matchMedia.xht" + }, + { + "path": "cssom-view-1_dev/xhtml1/matchMediaAddListener.xht", + "url": "/cssom-view-1_dev/xhtml1/matchMediaAddListener.xht" + }, + { + "path": "cssom-view-1_dev/xhtml1/media-query-list-interface.xht", + "url": "/cssom-view-1_dev/xhtml1/media-query-list-interface.xht" + }, + { + "path": "cssom-view-1_dev/xhtml1/offsetParent_element_test.xht", + "url": "/cssom-view-1_dev/xhtml1/offsetParent_element_test.xht" + }, + { + "path": "cssom-view-1_dev/xhtml1/scrollWidthHeight.xht", + "url": "/cssom-view-1_dev/xhtml1/scrollWidthHeight.xht" + }, + { + "path": "cssom-view-1_dev/xhtml1/scrollWidthHeightWhenNotScrollable.xht", + "url": "/cssom-view-1_dev/xhtml1/scrollWidthHeightWhenNotScrollable.xht" + }, + { + "path": "cssom-view-1_dev/xhtml1/ttwf-scrollintoview.xht", + "url": "/cssom-view-1_dev/xhtml1/ttwf-scrollintoview.xht" + }, + { + "path": "cssom-view-1_dev/xhtml1/window-interface.xht", + "url": "/cssom-view-1_dev/xhtml1/window-interface.xht" + }, + { + "path": "cssom-view-1_dev/xhtml1/window-screen-height-immutable.xht", + "url": "/cssom-view-1_dev/xhtml1/window-screen-height-immutable.xht" + }, + { + "path": "cssom-view-1_dev/xhtml1/window-screen-height-mutation-throws.xht", + "url": "/cssom-view-1_dev/xhtml1/window-screen-height-mutation-throws.xht" + }, + { + "path": "cssom-view-1_dev/xhtml1/window-screen-height.xht", + "url": "/cssom-view-1_dev/xhtml1/window-screen-height.xht" + }, + { + "path": "cssom-view-1_dev/xhtml1/window-screen-width-immutable.xht", + "url": "/cssom-view-1_dev/xhtml1/window-screen-width-immutable.xht" + }, + { + "path": "cssom-view-1_dev/xhtml1/window-screen-width-mutation-throws.xht", + "url": "/cssom-view-1_dev/xhtml1/window-screen-width-mutation-throws.xht" + }, + { + "path": "cssom-view-1_dev/xhtml1/window-screen-width.xht", + "url": "/cssom-view-1_dev/xhtml1/window-screen-width.xht" + }, { "path": "geometry-1_dev/html/DOMMatrix-001.htm", "url": "/geometry-1_dev/html/DOMMatrix-001.htm" @@ -325313,6 +327147,414 @@ "url": "/css-backgrounds-3_dev/xhtml1print/ttwf-reftest-borderRadius.xht" } ], + "css-break-3_dev/html/floats-clear-breaks-002.htm": [ + { + "path": "css-break-3_dev/html/floats-clear-breaks-002.htm", + "references": [ + [ + "/css-break-3_dev/html/reference/floats-clear-breaks-002-ref.htm", + "==" + ] + ], + "url": "/css-break-3_dev/html/floats-clear-breaks-002.htm" + } + ], + "css-break-3_dev/html/floats-in-named-flow-012.htm": [ + { + "path": "css-break-3_dev/html/floats-in-named-flow-012.htm", + "references": [ + [ + "/css-break-3_dev/html/reference/floats-in-named-flow-012-ref.htm", + "==" + ] + ], + "url": "/css-break-3_dev/html/floats-in-named-flow-012.htm" + } + ], + "css-break-3_dev/html/floats-in-named-flow-029.htm": [ + { + "path": "css-break-3_dev/html/floats-in-named-flow-029.htm", + "references": [ + [ + "/css-break-3_dev/html/reference/floats-in-named-flow-029-ref.htm", + "==" + ] + ], + "url": "/css-break-3_dev/html/floats-in-named-flow-029.htm" + } + ], + "css-break-3_dev/html/floats-in-named-flow-030.htm": [ + { + "path": "css-break-3_dev/html/floats-in-named-flow-030.htm", + "references": [ + [ + "/css-break-3_dev/html/reference/floats-in-named-flow-030-ref.htm", + "==" + ] + ], + "url": "/css-break-3_dev/html/floats-in-named-flow-030.htm" + } + ], + "css-break-3_dev/html/position-relative-001.htm": [ + { + "path": "css-break-3_dev/html/position-relative-001.htm", + "references": [ + [ + "/css-break-3_dev/html/reference/position-relative-001-ref.htm", + "==" + ] + ], + "url": "/css-break-3_dev/html/position-relative-001.htm" + } + ], + "css-break-3_dev/html/regions-transforms-008.htm": [ + { + "path": "css-break-3_dev/html/regions-transforms-008.htm", + "references": [ + [ + "/css-break-3_dev/html/reference/regions-transforms-008-ref.htm", + "==" + ] + ], + "url": "/css-break-3_dev/html/regions-transforms-008.htm" + } + ], + "css-break-3_dev/html/regions-transforms-009.htm": [ + { + "path": "css-break-3_dev/html/regions-transforms-009.htm", + "references": [ + [ + "/css-break-3_dev/html/reference/regions-transforms-008-ref.htm", + "==" + ] + ], + "url": "/css-break-3_dev/html/regions-transforms-009.htm" + } + ], + "css-break-3_dev/html/regions-transforms-013.htm": [ + { + "path": "css-break-3_dev/html/regions-transforms-013.htm", + "references": [ + [ + "/css-break-3_dev/html/reference/regions-transforms-013-ref.htm", + "==" + ], + [ + "/css-break-3_dev/html/reference/regions-transforms-013-alt-ref.htm", + "==" + ] + ], + "url": "/css-break-3_dev/html/regions-transforms-013.htm" + } + ], + "css-break-3_dev/html/regions-transforms-020.htm": [ + { + "path": "css-break-3_dev/html/regions-transforms-020.htm", + "references": [ + [ + "/css-break-3_dev/html/reference/regions-transforms-020-ref.htm", + "==" + ] + ], + "url": "/css-break-3_dev/html/regions-transforms-020.htm" + } + ], + "css-break-3_dev/html/regions-transforms-021.htm": [ + { + "path": "css-break-3_dev/html/regions-transforms-021.htm", + "references": [ + [ + "/css-break-3_dev/html/reference/regions-transforms-020-ref.htm", + "==" + ] + ], + "url": "/css-break-3_dev/html/regions-transforms-021.htm" + } + ], + "css-break-3_dev/html/regions-transforms-022.htm": [ + { + "path": "css-break-3_dev/html/regions-transforms-022.htm", + "references": [ + [ + "/css-break-3_dev/html/reference/regions-transforms-020-ref.htm", + "==" + ] + ], + "url": "/css-break-3_dev/html/regions-transforms-022.htm" + } + ], + "css-break-3_dev/xhtml1/floats-clear-breaks-002.xht": [ + { + "path": "css-break-3_dev/xhtml1/floats-clear-breaks-002.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1/reference/floats-clear-breaks-002-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1/floats-clear-breaks-002.xht" + } + ], + "css-break-3_dev/xhtml1/floats-in-named-flow-012.xht": [ + { + "path": "css-break-3_dev/xhtml1/floats-in-named-flow-012.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1/reference/floats-in-named-flow-012-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1/floats-in-named-flow-012.xht" + } + ], + "css-break-3_dev/xhtml1/floats-in-named-flow-029.xht": [ + { + "path": "css-break-3_dev/xhtml1/floats-in-named-flow-029.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1/reference/floats-in-named-flow-029-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1/floats-in-named-flow-029.xht" + } + ], + "css-break-3_dev/xhtml1/floats-in-named-flow-030.xht": [ + { + "path": "css-break-3_dev/xhtml1/floats-in-named-flow-030.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1/reference/floats-in-named-flow-030-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1/floats-in-named-flow-030.xht" + } + ], + "css-break-3_dev/xhtml1/position-relative-001.xht": [ + { + "path": "css-break-3_dev/xhtml1/position-relative-001.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1/reference/position-relative-001-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1/position-relative-001.xht" + } + ], + "css-break-3_dev/xhtml1/regions-transforms-008.xht": [ + { + "path": "css-break-3_dev/xhtml1/regions-transforms-008.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1/reference/regions-transforms-008-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1/regions-transforms-008.xht" + } + ], + "css-break-3_dev/xhtml1/regions-transforms-009.xht": [ + { + "path": "css-break-3_dev/xhtml1/regions-transforms-009.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1/reference/regions-transforms-008-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1/regions-transforms-009.xht" + } + ], + "css-break-3_dev/xhtml1/regions-transforms-013.xht": [ + { + "path": "css-break-3_dev/xhtml1/regions-transforms-013.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1/reference/regions-transforms-013-ref.xht", + "==" + ], + [ + "/css-break-3_dev/xhtml1/reference/regions-transforms-013-alt-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1/regions-transforms-013.xht" + } + ], + "css-break-3_dev/xhtml1/regions-transforms-020.xht": [ + { + "path": "css-break-3_dev/xhtml1/regions-transforms-020.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1/reference/regions-transforms-020-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1/regions-transforms-020.xht" + } + ], + "css-break-3_dev/xhtml1/regions-transforms-021.xht": [ + { + "path": "css-break-3_dev/xhtml1/regions-transforms-021.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1/reference/regions-transforms-020-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1/regions-transforms-021.xht" + } + ], + "css-break-3_dev/xhtml1/regions-transforms-022.xht": [ + { + "path": "css-break-3_dev/xhtml1/regions-transforms-022.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1/reference/regions-transforms-020-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1/regions-transforms-022.xht" + } + ], + "css-break-3_dev/xhtml1print/floats-clear-breaks-002.xht": [ + { + "path": "css-break-3_dev/xhtml1print/floats-clear-breaks-002.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1print/reference/floats-clear-breaks-002-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1print/floats-clear-breaks-002.xht" + } + ], + "css-break-3_dev/xhtml1print/floats-in-named-flow-012.xht": [ + { + "path": "css-break-3_dev/xhtml1print/floats-in-named-flow-012.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1print/reference/floats-in-named-flow-012-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1print/floats-in-named-flow-012.xht" + } + ], + "css-break-3_dev/xhtml1print/floats-in-named-flow-029.xht": [ + { + "path": "css-break-3_dev/xhtml1print/floats-in-named-flow-029.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1print/reference/floats-in-named-flow-029-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1print/floats-in-named-flow-029.xht" + } + ], + "css-break-3_dev/xhtml1print/floats-in-named-flow-030.xht": [ + { + "path": "css-break-3_dev/xhtml1print/floats-in-named-flow-030.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1print/reference/floats-in-named-flow-030-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1print/floats-in-named-flow-030.xht" + } + ], + "css-break-3_dev/xhtml1print/position-relative-001.xht": [ + { + "path": "css-break-3_dev/xhtml1print/position-relative-001.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1print/reference/position-relative-001-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1print/position-relative-001.xht" + } + ], + "css-break-3_dev/xhtml1print/regions-transforms-008.xht": [ + { + "path": "css-break-3_dev/xhtml1print/regions-transforms-008.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1print/reference/regions-transforms-008-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1print/regions-transforms-008.xht" + } + ], + "css-break-3_dev/xhtml1print/regions-transforms-009.xht": [ + { + "path": "css-break-3_dev/xhtml1print/regions-transforms-009.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1print/reference/regions-transforms-008-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1print/regions-transforms-009.xht" + } + ], + "css-break-3_dev/xhtml1print/regions-transforms-013.xht": [ + { + "path": "css-break-3_dev/xhtml1print/regions-transforms-013.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1print/reference/regions-transforms-013-ref.xht", + "==" + ], + [ + "/css-break-3_dev/xhtml1print/reference/regions-transforms-013-alt-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1print/regions-transforms-013.xht" + } + ], + "css-break-3_dev/xhtml1print/regions-transforms-020.xht": [ + { + "path": "css-break-3_dev/xhtml1print/regions-transforms-020.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1print/reference/regions-transforms-020-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1print/regions-transforms-020.xht" + } + ], + "css-break-3_dev/xhtml1print/regions-transforms-021.xht": [ + { + "path": "css-break-3_dev/xhtml1print/regions-transforms-021.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1print/reference/regions-transforms-020-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1print/regions-transforms-021.xht" + } + ], + "css-break-3_dev/xhtml1print/regions-transforms-022.xht": [ + { + "path": "css-break-3_dev/xhtml1print/regions-transforms-022.xht", + "references": [ + [ + "/css-break-3_dev/xhtml1print/reference/regions-transforms-020-ref.xht", + "==" + ] + ], + "url": "/css-break-3_dev/xhtml1print/regions-transforms-022.xht" + } + ], "css-color-3_dev/html4/t31-color-currentColor-b.htm": [ { "path": "css-color-3_dev/html4/t31-color-currentColor-b.htm", @@ -372581,6 +374823,114 @@ "url": "/css-multicol-1_dev/xhtml1print/regions-multicol-029.xht" } ], + "css-pseudo-4_dev/html/first-letter-001.htm": [ + { + "path": "css-pseudo-4_dev/html/first-letter-001.htm", + "references": [ + [ + "/css-pseudo-4_dev/html/reference/first-letter-001-ref.htm", + "==" + ] + ], + "url": "/css-pseudo-4_dev/html/first-letter-001.htm" + } + ], + "css-pseudo-4_dev/html/first-letter-002.htm": [ + { + "path": "css-pseudo-4_dev/html/first-letter-002.htm", + "references": [ + [ + "/css-pseudo-4_dev/html/reference/first-letter-001-ref.htm", + "==" + ] + ], + "url": "/css-pseudo-4_dev/html/first-letter-002.htm" + } + ], + "css-pseudo-4_dev/html/first-letter-003.htm": [ + { + "path": "css-pseudo-4_dev/html/first-letter-003.htm", + "references": [ + [ + "/css-pseudo-4_dev/html/reference/first-letter-001-ref.htm", + "==" + ] + ], + "url": "/css-pseudo-4_dev/html/first-letter-003.htm" + } + ], + "css-pseudo-4_dev/xhtml1/first-letter-001.xht": [ + { + "path": "css-pseudo-4_dev/xhtml1/first-letter-001.xht", + "references": [ + [ + "/css-pseudo-4_dev/xhtml1/reference/first-letter-001-ref.xht", + "==" + ] + ], + "url": "/css-pseudo-4_dev/xhtml1/first-letter-001.xht" + } + ], + "css-pseudo-4_dev/xhtml1/first-letter-002.xht": [ + { + "path": "css-pseudo-4_dev/xhtml1/first-letter-002.xht", + "references": [ + [ + "/css-pseudo-4_dev/xhtml1/reference/first-letter-001-ref.xht", + "==" + ] + ], + "url": "/css-pseudo-4_dev/xhtml1/first-letter-002.xht" + } + ], + "css-pseudo-4_dev/xhtml1/first-letter-003.xht": [ + { + "path": "css-pseudo-4_dev/xhtml1/first-letter-003.xht", + "references": [ + [ + "/css-pseudo-4_dev/xhtml1/reference/first-letter-001-ref.xht", + "==" + ] + ], + "url": "/css-pseudo-4_dev/xhtml1/first-letter-003.xht" + } + ], + "css-pseudo-4_dev/xhtml1print/first-letter-001.xht": [ + { + "path": "css-pseudo-4_dev/xhtml1print/first-letter-001.xht", + "references": [ + [ + "/css-pseudo-4_dev/xhtml1print/reference/first-letter-001-ref.xht", + "==" + ] + ], + "url": "/css-pseudo-4_dev/xhtml1print/first-letter-001.xht" + } + ], + "css-pseudo-4_dev/xhtml1print/first-letter-002.xht": [ + { + "path": "css-pseudo-4_dev/xhtml1print/first-letter-002.xht", + "references": [ + [ + "/css-pseudo-4_dev/xhtml1print/reference/first-letter-001-ref.xht", + "==" + ] + ], + "url": "/css-pseudo-4_dev/xhtml1print/first-letter-002.xht" + } + ], + "css-pseudo-4_dev/xhtml1print/first-letter-003.xht": [ + { + "path": "css-pseudo-4_dev/xhtml1print/first-letter-003.xht", + "references": [ + [ + "/css-pseudo-4_dev/xhtml1print/reference/first-letter-001-ref.xht", + "==" + ] + ], + "url": "/css-pseudo-4_dev/xhtml1print/first-letter-003.xht" + } + ], "css-regions-1_dev/html/animations-001.htm": [ { "path": "css-regions-1_dev/html/animations-001.htm", @@ -446069,6 +448419,1290 @@ "url": "/css-ui-3_dev/xhtml1print/text-overflow.xht" } ], + "css-values-3_dev/html/calc-background-image-gradient-1.htm": [ + { + "path": "css-values-3_dev/html/calc-background-image-gradient-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-background-image-gradient-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-background-image-gradient-1.htm" + } + ], + "css-values-3_dev/html/calc-background-linear-gradient-1.htm": [ + { + "path": "css-values-3_dev/html/calc-background-linear-gradient-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-background-linear-gradient-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-background-linear-gradient-1.htm" + } + ], + "css-values-3_dev/html/calc-background-position-1.htm": [ + { + "path": "css-values-3_dev/html/calc-background-position-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-background-position-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-background-position-1.htm" + } + ], + "css-values-3_dev/html/calc-background-size-1.htm": [ + { + "path": "css-values-3_dev/html/calc-background-size-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-background-size-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-background-size-1.htm" + } + ], + "css-values-3_dev/html/calc-border-radius-1.htm": [ + { + "path": "css-values-3_dev/html/calc-border-radius-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-border-radius-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-border-radius-1.htm" + } + ], + "css-values-3_dev/html/calc-height-block-1.htm": [ + { + "path": "css-values-3_dev/html/calc-height-block-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-height-block-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-height-block-1.htm" + } + ], + "css-values-3_dev/html/calc-height-table-1.htm": [ + { + "path": "css-values-3_dev/html/calc-height-table-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-height-table-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-height-table-1.htm" + } + ], + "css-values-3_dev/html/calc-margin-block-1.htm": [ + { + "path": "css-values-3_dev/html/calc-margin-block-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-margin-block-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-margin-block-1.htm" + } + ], + "css-values-3_dev/html/calc-max-height-block-1.htm": [ + { + "path": "css-values-3_dev/html/calc-max-height-block-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-max-height-block-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-max-height-block-1.htm" + } + ], + "css-values-3_dev/html/calc-max-width-block-1.htm": [ + { + "path": "css-values-3_dev/html/calc-max-width-block-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-width-block-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-max-width-block-1.htm" + } + ], + "css-values-3_dev/html/calc-max-width-block-intrinsic-1.htm": [ + { + "path": "css-values-3_dev/html/calc-max-width-block-intrinsic-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-max-width-block-intrinsic-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-max-width-block-intrinsic-1.htm" + } + ], + "css-values-3_dev/html/calc-min-height-block-1.htm": [ + { + "path": "css-values-3_dev/html/calc-min-height-block-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-height-block-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-min-height-block-1.htm" + } + ], + "css-values-3_dev/html/calc-min-width-block-1.htm": [ + { + "path": "css-values-3_dev/html/calc-min-width-block-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-width-block-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-min-width-block-1.htm" + } + ], + "css-values-3_dev/html/calc-min-width-block-intrinsic-1.htm": [ + { + "path": "css-values-3_dev/html/calc-min-width-block-intrinsic-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-min-width-block-intrinsic-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-min-width-block-intrinsic-1.htm" + } + ], + "css-values-3_dev/html/calc-offsets-absolute-bottom-1.htm": [ + { + "path": "css-values-3_dev/html/calc-offsets-absolute-bottom-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-offsets-absolute-top-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-offsets-absolute-bottom-1.htm" + } + ], + "css-values-3_dev/html/calc-offsets-absolute-left-1.htm": [ + { + "path": "css-values-3_dev/html/calc-offsets-absolute-left-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-offsets-relative-left-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-offsets-absolute-left-1.htm" + } + ], + "css-values-3_dev/html/calc-offsets-absolute-right-1.htm": [ + { + "path": "css-values-3_dev/html/calc-offsets-absolute-right-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-offsets-relative-left-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-offsets-absolute-right-1.htm" + } + ], + "css-values-3_dev/html/calc-offsets-absolute-top-1.htm": [ + { + "path": "css-values-3_dev/html/calc-offsets-absolute-top-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-offsets-absolute-top-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-offsets-absolute-top-1.htm" + } + ], + "css-values-3_dev/html/calc-offsets-relative-bottom-1.htm": [ + { + "path": "css-values-3_dev/html/calc-offsets-relative-bottom-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-offsets-relative-top-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-offsets-relative-bottom-1.htm" + } + ], + "css-values-3_dev/html/calc-offsets-relative-left-1.htm": [ + { + "path": "css-values-3_dev/html/calc-offsets-relative-left-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-offsets-relative-left-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-offsets-relative-left-1.htm" + } + ], + "css-values-3_dev/html/calc-offsets-relative-right-1.htm": [ + { + "path": "css-values-3_dev/html/calc-offsets-relative-right-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-offsets-relative-left-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-offsets-relative-right-1.htm" + } + ], + "css-values-3_dev/html/calc-offsets-relative-top-1.htm": [ + { + "path": "css-values-3_dev/html/calc-offsets-relative-top-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-offsets-relative-top-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-offsets-relative-top-1.htm" + } + ], + "css-values-3_dev/html/calc-padding-block-1.htm": [ + { + "path": "css-values-3_dev/html/calc-padding-block-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-padding-block-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-padding-block-1.htm" + } + ], + "css-values-3_dev/html/calc-text-indent-1.htm": [ + { + "path": "css-values-3_dev/html/calc-text-indent-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-text-indent-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-text-indent-1.htm" + } + ], + "css-values-3_dev/html/calc-text-indent-intrinsic-1.htm": [ + { + "path": "css-values-3_dev/html/calc-text-indent-intrinsic-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-text-indent-intrinsic-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-text-indent-intrinsic-1.htm" + } + ], + "css-values-3_dev/html/calc-transform-origin-1.htm": [ + { + "path": "css-values-3_dev/html/calc-transform-origin-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-transform-origin-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-transform-origin-1.htm" + } + ], + "css-values-3_dev/html/calc-vertical-align-1.htm": [ + { + "path": "css-values-3_dev/html/calc-vertical-align-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-vertical-align-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-vertical-align-1.htm" + } + ], + "css-values-3_dev/html/calc-width-block-1.htm": [ + { + "path": "css-values-3_dev/html/calc-width-block-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-width-block-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-width-block-1.htm" + } + ], + "css-values-3_dev/html/calc-width-block-intrinsic-1.htm": [ + { + "path": "css-values-3_dev/html/calc-width-block-intrinsic-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-width-block-intrinsic-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-width-block-intrinsic-1.htm" + } + ], + "css-values-3_dev/html/calc-width-table-auto-1.htm": [ + { + "path": "css-values-3_dev/html/calc-width-table-auto-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-width-table-auto-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-width-table-auto-1.htm" + } + ], + "css-values-3_dev/html/calc-width-table-fixed-1.htm": [ + { + "path": "css-values-3_dev/html/calc-width-table-fixed-1.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/calc-width-table-fixed-1-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/calc-width-table-fixed-1.htm" + } + ], + "css-values-3_dev/html/ch-unit-001.htm": [ + { + "path": "css-values-3_dev/html/ch-unit-001.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/ch-unit-001-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/ch-unit-001.htm" + } + ], + "css-values-3_dev/html/min-width-001.htm": [ + { + "path": "css-values-3_dev/html/min-width-001.htm", + "references": [ + [ + "/css-values-3_dev/html/ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/min-width-001.htm" + } + ], + "css-values-3_dev/html/multicol-count-non-integer-001.htm": [ + { + "path": "css-values-3_dev/html/multicol-count-non-integer-001.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/multicol-columns-invalid-001-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/multicol-count-non-integer-001.htm" + } + ], + "css-values-3_dev/html/multicol-count-non-integer-002.htm": [ + { + "path": "css-values-3_dev/html/multicol-count-non-integer-002.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/multicol-columns-invalid-001-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/multicol-count-non-integer-002.htm" + } + ], + "css-values-3_dev/html/multicol-count-non-integer-003.htm": [ + { + "path": "css-values-3_dev/html/multicol-count-non-integer-003.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/multicol-columns-invalid-001-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/multicol-count-non-integer-003.htm" + } + ], + "css-values-3_dev/html/multicol-inherit-002.htm": [ + { + "path": "css-values-3_dev/html/multicol-inherit-002.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/multicol-inherit-002-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/multicol-inherit-002.htm" + } + ], + "css-values-3_dev/html/multicol-rule-color-inherit-001.htm": [ + { + "path": "css-values-3_dev/html/multicol-rule-color-inherit-001.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/multicol-rule-color-inherit-001-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/multicol-rule-color-inherit-001.htm" + } + ], + "css-values-3_dev/html/multicol-rule-color-inherit-002.htm": [ + { + "path": "css-values-3_dev/html/multicol-rule-color-inherit-002.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/multicol-rule-color-inherit-001-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/multicol-rule-color-inherit-002.htm" + } + ], + "css-values-3_dev/html/regions-resizing-003.htm": [ + { + "path": "css-values-3_dev/html/regions-resizing-003.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/regions-resizing-001-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/regions-resizing-003.htm" + } + ], + "css-values-3_dev/html/regions-resizing-007.htm": [ + { + "path": "css-values-3_dev/html/regions-resizing-007.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/regions-resizing-001-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/regions-resizing-007.htm" + } + ], + "css-values-3_dev/html/regions-resizing-009.htm": [ + { + "path": "css-values-3_dev/html/regions-resizing-009.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/regions-resizing-001-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/regions-resizing-009.htm" + } + ], + "css-values-3_dev/html/vh-calc-support-pct.htm": [ + { + "path": "css-values-3_dev/html/vh-calc-support-pct.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/all-green.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/vh-calc-support-pct.htm" + } + ], + "css-values-3_dev/html/vh-calc-support.htm": [ + { + "path": "css-values-3_dev/html/vh-calc-support.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/all-green.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/vh-calc-support.htm" + } + ], + "css-values-3_dev/html/vh-em-inherit.htm": [ + { + "path": "css-values-3_dev/html/vh-em-inherit.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/all-green.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/vh-em-inherit.htm" + } + ], + "css-values-3_dev/html/vh-inherit.htm": [ + { + "path": "css-values-3_dev/html/vh-inherit.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/all-green.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/vh-inherit.htm" + } + ], + "css-values-3_dev/html/vh-interpolate-pct.htm": [ + { + "path": "css-values-3_dev/html/vh-interpolate-pct.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/all-green.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/vh-interpolate-pct.htm" + } + ], + "css-values-3_dev/html/vh-interpolate-px.htm": [ + { + "path": "css-values-3_dev/html/vh-interpolate-px.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/all-green.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/vh-interpolate-px.htm" + } + ], + "css-values-3_dev/html/vh-interpolate-vh.htm": [ + { + "path": "css-values-3_dev/html/vh-interpolate-vh.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/all-green.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/vh-interpolate-vh.htm" + } + ], + "css-values-3_dev/html/vh-support-atviewport.htm": [ + { + "path": "css-values-3_dev/html/vh-support-atviewport.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/all-green.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/vh-support-atviewport.htm" + } + ], + "css-values-3_dev/html/vh-support-margin.htm": [ + { + "path": "css-values-3_dev/html/vh-support-margin.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/all-green.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/vh-support-margin.htm" + } + ], + "css-values-3_dev/html/vh-support-transform-origin.htm": [ + { + "path": "css-values-3_dev/html/vh-support-transform-origin.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/all-green.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/vh-support-transform-origin.htm" + } + ], + "css-values-3_dev/html/vh-support-transform-translate.htm": [ + { + "path": "css-values-3_dev/html/vh-support-transform-translate.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/all-green.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/vh-support-transform-translate.htm" + } + ], + "css-values-3_dev/html/vh-support.htm": [ + { + "path": "css-values-3_dev/html/vh-support.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/all-green.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/vh-support.htm" + } + ], + "css-values-3_dev/html/vh-zero-support.htm": [ + { + "path": "css-values-3_dev/html/vh-zero-support.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/all-green.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/vh-zero-support.htm" + } + ], + "css-values-3_dev/html/vh_not_refreshing_on_chrome.htm": [ + { + "path": "css-values-3_dev/html/vh_not_refreshing_on_chrome.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/vh_not_refreshing_on_chrome-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/vh_not_refreshing_on_chrome.htm" + } + ], + "css-values-3_dev/html/vh_not_refreshing_on_chrome_iframe.htm": [ + { + "path": "css-values-3_dev/html/vh_not_refreshing_on_chrome_iframe.htm", + "references": [ + [ + "/css-values-3_dev/html/reference/vh_not_refreshing_on_chrome-ref.htm", + "==" + ] + ], + "url": "/css-values-3_dev/html/vh_not_refreshing_on_chrome_iframe.htm" + } + ], + "css-values-3_dev/xhtml1/calc-background-image-gradient-1.xht": [ + { + "path": "css-values-3_dev/xhtml1/calc-background-image-gradient-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-background-image-gradient-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-background-image-gradient-1.xht" + } + ], + "css-values-3_dev/xhtml1/calc-background-linear-gradient-1.xht": [ + { + "path": "css-values-3_dev/xhtml1/calc-background-linear-gradient-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-background-linear-gradient-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-background-linear-gradient-1.xht" + } + ], + "css-values-3_dev/xhtml1/calc-background-position-1.xht": [ + { + "path": "css-values-3_dev/xhtml1/calc-background-position-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-background-position-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-background-position-1.xht" + } + ], + "css-values-3_dev/xhtml1/calc-background-size-1.xht": [ + { + "path": "css-values-3_dev/xhtml1/calc-background-size-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-background-size-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-background-size-1.xht" + } + ], + "css-values-3_dev/xhtml1/calc-border-radius-1.xht": [ + { + "path": "css-values-3_dev/xhtml1/calc-border-radius-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-border-radius-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-border-radius-1.xht" + } + ], + "css-values-3_dev/xhtml1/calc-height-block-1.xht": [ + { + "path": "css-values-3_dev/xhtml1/calc-height-block-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-height-block-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-height-block-1.xht" + } + ], + "css-values-3_dev/xhtml1/calc-height-table-1.xht": [ + { + "path": "css-values-3_dev/xhtml1/calc-height-table-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-height-table-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-height-table-1.xht" + } + ], + "css-values-3_dev/xhtml1/calc-margin-block-1.xht": [ + { + "path": "css-values-3_dev/xhtml1/calc-margin-block-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-margin-block-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-margin-block-1.xht" + } + ], + "css-values-3_dev/xhtml1/calc-max-height-block-1.xht": [ + { + "path": "css-values-3_dev/xhtml1/calc-max-height-block-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-max-height-block-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-max-height-block-1.xht" + } + ], + "css-values-3_dev/xhtml1/calc-max-width-block-1.xht": [ + { + "path": "css-values-3_dev/xhtml1/calc-max-width-block-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-width-block-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-max-width-block-1.xht" + } + ], + "css-values-3_dev/xhtml1/calc-max-width-block-intrinsic-1.xht": [ + { + "path": "css-values-3_dev/xhtml1/calc-max-width-block-intrinsic-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-max-width-block-intrinsic-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-max-width-block-intrinsic-1.xht" + } + ], + "css-values-3_dev/xhtml1/calc-min-height-block-1.xht": [ + { + "path": "css-values-3_dev/xhtml1/calc-min-height-block-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-height-block-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-min-height-block-1.xht" + } + ], + "css-values-3_dev/xhtml1/calc-min-width-block-1.xht": [ + { + "path": "css-values-3_dev/xhtml1/calc-min-width-block-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-width-block-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-min-width-block-1.xht" + } + ], + "css-values-3_dev/xhtml1/calc-min-width-block-intrinsic-1.xht": [ + { + "path": "css-values-3_dev/xhtml1/calc-min-width-block-intrinsic-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-min-width-block-intrinsic-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-min-width-block-intrinsic-1.xht" + } + ], + "css-values-3_dev/xhtml1/calc-offsets-absolute-bottom-1.xht": [ + { + "path": "css-values-3_dev/xhtml1/calc-offsets-absolute-bottom-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-offsets-absolute-top-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-offsets-absolute-bottom-1.xht" + } + ], + "css-values-3_dev/xhtml1/calc-offsets-absolute-left-1.xht": [ + { + "path": "css-values-3_dev/xhtml1/calc-offsets-absolute-left-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-offsets-relative-left-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-offsets-absolute-left-1.xht" + } + ], + "css-values-3_dev/xhtml1/calc-offsets-absolute-right-1.xht": [ + { + "path": "css-values-3_dev/xhtml1/calc-offsets-absolute-right-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-offsets-relative-left-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-offsets-absolute-right-1.xht" + } + ], + "css-values-3_dev/xhtml1/calc-offsets-absolute-top-1.xht": [ + { + "path": "css-values-3_dev/xhtml1/calc-offsets-absolute-top-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-offsets-absolute-top-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-offsets-absolute-top-1.xht" + } + ], + "css-values-3_dev/xhtml1/calc-offsets-relative-bottom-1.xht": [ + { + "path": "css-values-3_dev/xhtml1/calc-offsets-relative-bottom-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-offsets-relative-top-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-offsets-relative-bottom-1.xht" + } + ], + "css-values-3_dev/xhtml1/calc-offsets-relative-left-1.xht": [ + { + "path": "css-values-3_dev/xhtml1/calc-offsets-relative-left-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-offsets-relative-left-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-offsets-relative-left-1.xht" + } + ], + "css-values-3_dev/xhtml1/calc-offsets-relative-right-1.xht": [ + { + "path": "css-values-3_dev/xhtml1/calc-offsets-relative-right-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-offsets-relative-left-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-offsets-relative-right-1.xht" + } + ], + "css-values-3_dev/xhtml1/calc-offsets-relative-top-1.xht": [ + { + "path": "css-values-3_dev/xhtml1/calc-offsets-relative-top-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-offsets-relative-top-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-offsets-relative-top-1.xht" + } + ], + "css-values-3_dev/xhtml1/calc-padding-block-1.xht": [ + { + "path": "css-values-3_dev/xhtml1/calc-padding-block-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-padding-block-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-padding-block-1.xht" + } + ], + "css-values-3_dev/xhtml1/calc-text-indent-1.xht": [ + { + "path": "css-values-3_dev/xhtml1/calc-text-indent-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-text-indent-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-text-indent-1.xht" + } + ], + "css-values-3_dev/xhtml1/calc-text-indent-intrinsic-1.xht": [ + { + "path": "css-values-3_dev/xhtml1/calc-text-indent-intrinsic-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-text-indent-intrinsic-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-text-indent-intrinsic-1.xht" + } + ], + "css-values-3_dev/xhtml1/calc-transform-origin-1.xht": [ + { + "path": "css-values-3_dev/xhtml1/calc-transform-origin-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-transform-origin-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-transform-origin-1.xht" + } + ], + "css-values-3_dev/xhtml1/calc-vertical-align-1.xht": [ + { + "path": "css-values-3_dev/xhtml1/calc-vertical-align-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-vertical-align-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-vertical-align-1.xht" + } + ], + "css-values-3_dev/xhtml1/calc-width-block-1.xht": [ + { + "path": "css-values-3_dev/xhtml1/calc-width-block-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-width-block-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-width-block-1.xht" + } + ], + "css-values-3_dev/xhtml1/calc-width-block-intrinsic-1.xht": [ + { + "path": "css-values-3_dev/xhtml1/calc-width-block-intrinsic-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-width-block-intrinsic-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-width-block-intrinsic-1.xht" + } + ], + "css-values-3_dev/xhtml1/calc-width-table-auto-1.xht": [ + { + "path": "css-values-3_dev/xhtml1/calc-width-table-auto-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-width-table-auto-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-width-table-auto-1.xht" + } + ], + "css-values-3_dev/xhtml1/calc-width-table-fixed-1.xht": [ + { + "path": "css-values-3_dev/xhtml1/calc-width-table-fixed-1.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/calc-width-table-fixed-1-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/calc-width-table-fixed-1.xht" + } + ], + "css-values-3_dev/xhtml1/ch-unit-001.xht": [ + { + "path": "css-values-3_dev/xhtml1/ch-unit-001.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/ch-unit-001-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/ch-unit-001.xht" + } + ], + "css-values-3_dev/xhtml1/min-width-001.xht": [ + { + "path": "css-values-3_dev/xhtml1/min-width-001.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/min-width-001.xht" + } + ], + "css-values-3_dev/xhtml1/multicol-count-non-integer-001.xht": [ + { + "path": "css-values-3_dev/xhtml1/multicol-count-non-integer-001.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/multicol-columns-invalid-001-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/multicol-count-non-integer-001.xht" + } + ], + "css-values-3_dev/xhtml1/multicol-count-non-integer-002.xht": [ + { + "path": "css-values-3_dev/xhtml1/multicol-count-non-integer-002.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/multicol-columns-invalid-001-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/multicol-count-non-integer-002.xht" + } + ], + "css-values-3_dev/xhtml1/multicol-count-non-integer-003.xht": [ + { + "path": "css-values-3_dev/xhtml1/multicol-count-non-integer-003.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/multicol-columns-invalid-001-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/multicol-count-non-integer-003.xht" + } + ], + "css-values-3_dev/xhtml1/multicol-inherit-002.xht": [ + { + "path": "css-values-3_dev/xhtml1/multicol-inherit-002.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/multicol-inherit-002-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/multicol-inherit-002.xht" + } + ], + "css-values-3_dev/xhtml1/regions-resizing-003.xht": [ + { + "path": "css-values-3_dev/xhtml1/regions-resizing-003.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/regions-resizing-001-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/regions-resizing-003.xht" + } + ], + "css-values-3_dev/xhtml1/regions-resizing-007.xht": [ + { + "path": "css-values-3_dev/xhtml1/regions-resizing-007.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/regions-resizing-001-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/regions-resizing-007.xht" + } + ], + "css-values-3_dev/xhtml1/regions-resizing-009.xht": [ + { + "path": "css-values-3_dev/xhtml1/regions-resizing-009.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/regions-resizing-001-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/regions-resizing-009.xht" + } + ], + "css-values-3_dev/xhtml1/vh-em-inherit.xht": [ + { + "path": "css-values-3_dev/xhtml1/vh-em-inherit.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/all-green.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/vh-em-inherit.xht" + } + ], + "css-values-3_dev/xhtml1/vh-inherit.xht": [ + { + "path": "css-values-3_dev/xhtml1/vh-inherit.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/all-green.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/vh-inherit.xht" + } + ], + "css-values-3_dev/xhtml1/vh-interpolate-pct.xht": [ + { + "path": "css-values-3_dev/xhtml1/vh-interpolate-pct.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/all-green.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/vh-interpolate-pct.xht" + } + ], + "css-values-3_dev/xhtml1/vh-interpolate-px.xht": [ + { + "path": "css-values-3_dev/xhtml1/vh-interpolate-px.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/all-green.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/vh-interpolate-px.xht" + } + ], + "css-values-3_dev/xhtml1/vh-interpolate-vh.xht": [ + { + "path": "css-values-3_dev/xhtml1/vh-interpolate-vh.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/all-green.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/vh-interpolate-vh.xht" + } + ], + "css-values-3_dev/xhtml1/vh-support-margin.xht": [ + { + "path": "css-values-3_dev/xhtml1/vh-support-margin.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/all-green.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/vh-support-margin.xht" + } + ], + "css-values-3_dev/xhtml1/vh-support.xht": [ + { + "path": "css-values-3_dev/xhtml1/vh-support.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/all-green.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/vh-support.xht" + } + ], + "css-values-3_dev/xhtml1/vh-zero-support.xht": [ + { + "path": "css-values-3_dev/xhtml1/vh-zero-support.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/all-green.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/vh-zero-support.xht" + } + ], + "css-values-3_dev/xhtml1/vh_not_refreshing_on_chrome.xht": [ + { + "path": "css-values-3_dev/xhtml1/vh_not_refreshing_on_chrome.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/vh_not_refreshing_on_chrome-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/vh_not_refreshing_on_chrome.xht" + } + ], + "css-values-3_dev/xhtml1/vh_not_refreshing_on_chrome_iframe.xht": [ + { + "path": "css-values-3_dev/xhtml1/vh_not_refreshing_on_chrome_iframe.xht", + "references": [ + [ + "/css-values-3_dev/xhtml1/reference/vh_not_refreshing_on_chrome-ref.xht", + "==" + ] + ], + "url": "/css-values-3_dev/xhtml1/vh_not_refreshing_on_chrome_iframe.xht" + } + ], "css-variables-1_dev/html/css-vars-custom-property-case-sensitive-001.htm": [ { "path": "css-variables-1_dev/html/css-vars-custom-property-case-sensitive-001.htm", @@ -489685,6 +493319,18 @@ "url": "/css21_dev/html4/before-after-positioned-001.htm" } ], + "css21_dev/html4/before-after-selector-001.htm": [ + { + "path": "css21_dev/html4/before-after-selector-001.htm", + "references": [ + [ + "/css21_dev/html4/reference/before-after-selector-001-ref.htm", + "==" + ] + ], + "url": "/css21_dev/html4/before-after-selector-001.htm" + } + ], "css21_dev/html4/before-after-table-parts-001.htm": [ { "path": "css21_dev/html4/before-after-table-parts-001.htm", @@ -522873,6 +526519,18 @@ "url": "/css21_dev/html4/keywords-001.htm" } ], + "css21_dev/html4/lang-selector-001.htm": [ + { + "path": "css21_dev/html4/lang-selector-001.htm", + "references": [ + [ + "/css21_dev/html4/reference/lang-selector-001-ref.htm", + "==" + ] + ], + "url": "/css21_dev/html4/lang-selector-001.htm" + } + ], "css21_dev/html4/lang-selector-002.htm": [ { "path": "css21_dev/html4/lang-selector-002.htm", @@ -560997,6 +564655,18 @@ "url": "/css21_dev/xhtml1/before-after-positioned-001.xht" } ], + "css21_dev/xhtml1/before-after-selector-001.xht": [ + { + "path": "css21_dev/xhtml1/before-after-selector-001.xht", + "references": [ + [ + "/css21_dev/xhtml1/reference/before-after-selector-001-ref.xht", + "==" + ] + ], + "url": "/css21_dev/xhtml1/before-after-selector-001.xht" + } + ], "css21_dev/xhtml1/before-after-table-parts-001.xht": [ { "path": "css21_dev/xhtml1/before-after-table-parts-001.xht", @@ -593813,6 +597483,18 @@ "url": "/css21_dev/xhtml1/keywords-001.xht" } ], + "css21_dev/xhtml1/lang-selector-001.xht": [ + { + "path": "css21_dev/xhtml1/lang-selector-001.xht", + "references": [ + [ + "/css21_dev/xhtml1/reference/lang-selector-001-ref.xht", + "==" + ] + ], + "url": "/css21_dev/xhtml1/lang-selector-001.xht" + } + ], "css21_dev/xhtml1/lang-selector-002.xht": [ { "path": "css21_dev/xhtml1/lang-selector-002.xht", @@ -631637,6 +635319,18 @@ "url": "/css21_dev/xhtml1print/before-after-positioned-001.xht" } ], + "css21_dev/xhtml1print/before-after-selector-001.xht": [ + { + "path": "css21_dev/xhtml1print/before-after-selector-001.xht", + "references": [ + [ + "/css21_dev/xhtml1print/reference/before-after-selector-001-ref.xht", + "==" + ] + ], + "url": "/css21_dev/xhtml1print/before-after-selector-001.xht" + } + ], "css21_dev/xhtml1print/before-after-table-parts-001.xht": [ { "path": "css21_dev/xhtml1print/before-after-table-parts-001.xht", @@ -664453,6 +668147,18 @@ "url": "/css21_dev/xhtml1print/keywords-001.xht" } ], + "css21_dev/xhtml1print/lang-selector-001.xht": [ + { + "path": "css21_dev/xhtml1print/lang-selector-001.xht", + "references": [ + [ + "/css21_dev/xhtml1print/reference/lang-selector-001-ref.xht", + "==" + ] + ], + "url": "/css21_dev/xhtml1print/lang-selector-001.xht" + } + ], "css21_dev/xhtml1print/lang-selector-002.xht": [ { "path": "css21_dev/xhtml1print/lang-selector-002.xht", @@ -690714,7 +694420,7 @@ } ] }, - "rev": "465c03e3d8d42ce98b9dfa0c8d8e7b4b8d48ebd7", + "rev": "d13905941293af83ea8c3c1750dba652e0423fb0", "url_base": "/", "version": 2 } \ No newline at end of file diff --git a/tests/wpt/metadata-css/css21_dev/html4/lang-selector-001.htm.ini b/tests/wpt/metadata-css/css21_dev/html4/lang-selector-001.htm.ini new file mode 100644 index 00000000000..2f8519669f6 --- /dev/null +++ b/tests/wpt/metadata-css/css21_dev/html4/lang-selector-001.htm.ini @@ -0,0 +1,3 @@ +[lang-selector-001.htm] + type: reftest + expected: FAIL From af91c980f2cf7c8aa1c502b0094052c07dd9a7df Mon Sep 17 00:00:00 2001 From: KALPESH KRISHNA <kalpeshk2011@gmail.com> Date: Fri, 30 Oct 2015 17:51:21 +0530 Subject: [PATCH 35/58] Implementing activation behavior for <label> --- components/script/dom/element.rs | 5 +++ components/script/dom/htmllabelelement.rs | 37 +++++++++++++++++++++++ 2 files changed, 42 insertions(+) diff --git a/components/script/dom/element.rs b/components/script/dom/element.rs index 0bdca0714a7..bdcc21ca158 100644 --- a/components/script/dom/element.rs +++ b/components/script/dom/element.rs @@ -42,6 +42,7 @@ use dom::htmlfieldsetelement::HTMLFieldSetElement; use dom::htmlfontelement::HTMLFontElement; use dom::htmliframeelement::HTMLIFrameElement; use dom::htmlinputelement::{HTMLInputElement, RawLayoutHTMLInputElementHelpers}; +use dom::htmllabelelement::HTMLLabelElement; use dom::htmllegendelement::HTMLLegendElement; use dom::htmloptgroupelement::HTMLOptGroupElement; use dom::htmltablecellelement::{HTMLTableCellElement, HTMLTableCellElementLayoutHelpers}; @@ -1753,6 +1754,10 @@ impl Element { let element = self.downcast::<HTMLAnchorElement>().unwrap(); Some(element as &Activatable) }, + NodeTypeId::Element(ElementTypeId::HTMLElement(HTMLElementTypeId::HTMLLabelElement)) => { + let element = self.downcast::<HTMLLabelElement>().unwrap(); + Some(element as &Activatable) + }, _ => { None } diff --git a/components/script/dom/htmllabelelement.rs b/components/script/dom/htmllabelelement.rs index bcda8df24cc..ae1aa580cc3 100644 --- a/components/script/dom/htmllabelelement.rs +++ b/components/script/dom/htmllabelelement.rs @@ -2,6 +2,7 @@ * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ +use dom::activation::Activatable; use dom::attr::AttrValue; use dom::bindings::codegen::Bindings::HTMLLabelElementBinding; use dom::bindings::codegen::Bindings::HTMLLabelElementBinding::HTMLLabelElementMethods; @@ -9,6 +10,8 @@ use dom::bindings::conversions::Castable; use dom::bindings::js::Root; use dom::document::Document; use dom::element::Element; +use dom::event::Event; +use dom::eventtarget::EventTarget; use dom::htmlelement::HTMLElement; use dom::htmlformelement::{FormControl, HTMLFormElement}; use dom::node::{document_from_node, Node}; @@ -40,6 +43,40 @@ impl HTMLLabelElement { } } +impl Activatable for HTMLLabelElement { + fn as_element(&self) -> &Element { + self.upcast::<Element>() + } + + fn is_instance_activatable(&self) -> bool { + return true; + } + + // https://html.spec.whatwg.org/multipage/#run-pre-click-activation-steps + // https://html.spec.whatwg.org/multipage/#the-button-element:activation-behavior + fn pre_click_activation(&self) { + } + + // https://html.spec.whatwg.org/multipage/#run-canceled-activation-steps + fn canceled_activation(&self) { + } + + // https://html.spec.whatwg.org/multipage/#run-post-click-activation-steps + fn activation_behavior(&self, _event: &Event, _target: &EventTarget) { + self.upcast::<Element>() + .as_maybe_activatable() + .map(|a| a.synthetic_click_activation(false, false, false, false)); + } + + // https://html.spec.whatwg.org/multipage/#implicit-submission + fn implicit_submission(&self, ctrlKey: bool, shiftKey: bool, altKey: bool, metaKey: bool) { + //FIXME: Investigate and implement implicit submission for label elements + // Issue filed at https://github.com/servo/servo/issues/8263 + } + + +} + impl HTMLLabelElementMethods for HTMLLabelElement { // https://html.spec.whatwg.org/multipage/#dom-fae-form fn GetForm(&self) -> Option<Root<HTMLFormElement>> { From aef06f2f20aafd888a8f60c3c37d5d07e77e275f Mon Sep 17 00:00:00 2001 From: Eli Friedman <eli.friedman@gmail.com> Date: Thu, 15 Oct 2015 17:16:47 -0700 Subject: [PATCH 36/58] Consistently use content-type sniffing with all protocols. --- components/net/about_loader.rs | 10 ++++++---- components/net/data_loader.rs | 32 +++++++++++++++----------------- components/net/file_loader.rs | 25 +++++++++++++++++-------- components/net/resource_task.rs | 10 ++-------- tests/unit/net/data_loader.rs | 5 ++++- 5 files changed, 44 insertions(+), 38 deletions(-) diff --git a/components/net/about_loader.rs b/components/net/about_loader.rs index 4308b4a8ccc..04878fed70b 100644 --- a/components/net/about_loader.rs +++ b/components/net/about_loader.rs @@ -9,7 +9,7 @@ use hyper::mime::{Mime, SubLevel, TopLevel}; use mime_classifier::MIMEClassifier; use net_traits::ProgressMsg::Done; use net_traits::{LoadConsumer, LoadData, Metadata}; -use resource_task::{send_error, start_sending}; +use resource_task::{send_error, start_sending_sniffed_opt}; use std::fs::PathExt; use std::sync::Arc; use url::Url; @@ -18,14 +18,16 @@ use util::resource_files::resources_dir_path; pub fn factory(mut load_data: LoadData, start_chan: LoadConsumer, classifier: Arc<MIMEClassifier>) { match load_data.url.non_relative_scheme_data().unwrap() { "blank" => { - let chan = start_sending(start_chan, Metadata { + let metadata = Metadata { final_url: load_data.url, content_type: Some(ContentType(Mime(TopLevel::Text, SubLevel::Html, vec![]))), charset: Some("utf-8".to_owned()), headers: None, status: Some(RawStatus(200, "OK".into())), - }); - chan.send(Done(Ok(()))).unwrap(); + }; + if let Ok(chan) = start_sending_sniffed_opt(start_chan, metadata, classifier, &[]) { + let _ = chan.send(Done(Ok(()))); + } return } "crash" => panic!("Loading the about:crash URL."), diff --git a/components/net/data_loader.rs b/components/net/data_loader.rs index f9276d8f0a2..f2f72bac88e 100644 --- a/components/net/data_loader.rs +++ b/components/net/data_loader.rs @@ -6,21 +6,21 @@ use hyper::mime::{Mime, TopLevel, SubLevel, Attr, Value}; use mime_classifier::MIMEClassifier; use net_traits::ProgressMsg::{Done, Payload}; use net_traits::{LoadConsumer, LoadData, Metadata}; -use resource_task::{send_error, start_sending}; +use resource_task::{send_error, start_sending_sniffed_opt}; use rustc_serialize::base64::FromBase64; use std::sync::Arc; use url::SchemeData; use url::percent_encoding::percent_decode; -pub fn factory(load_data: LoadData, senders: LoadConsumer, _classifier: Arc<MIMEClassifier>) { +pub fn factory(load_data: LoadData, senders: LoadConsumer, classifier: Arc<MIMEClassifier>) { // NB: we don't spawn a new task. // Hypothesis: data URLs are too small for parallel base64 etc. to be worth it. // Should be tested at some point. // Left in separate function to allow easy moving to a task, if desired. - load(load_data, senders) + load(load_data, senders, classifier) } -pub fn load(load_data: LoadData, start_chan: LoadConsumer) { +pub fn load(load_data: LoadData, start_chan: LoadConsumer, classifier: Arc<MIMEClassifier>) { let url = load_data.url; assert!(&*url.scheme == "data"); @@ -62,27 +62,25 @@ pub fn load(load_data: LoadData, start_chan: LoadConsumer) { content_type = Some(Mime(TopLevel::Text, SubLevel::Plain, vec!((Attr::Charset, Value::Ext("US-ASCII".to_owned()))))); } - let mut metadata = Metadata::default(url); - metadata.set_content_type(content_type.as_ref()); - let progress_chan = start_sending(start_chan, metadata); let bytes = percent_decode(parts[1].as_bytes()); - if is_base64 { + let bytes = if is_base64 { // FIXME(#2909): Itโ€™s unclear what to do with non-alphabet characters, // but Acid 3 apparently depends on spaces being ignored. let bytes = bytes.into_iter().filter(|&b| b != ' ' as u8).collect::<Vec<u8>>(); match bytes.from_base64() { - Err(..) => { - progress_chan.send(Done(Err("non-base64 data uri".to_owned()))).unwrap(); - } - Ok(data) => { - progress_chan.send(Payload(data)).unwrap(); - progress_chan.send(Done(Ok(()))).unwrap(); - } + Err(..) => return send_error(url, "non-base64 data uri".to_owned(), start_chan), + Ok(data) => data, } } else { - progress_chan.send(Payload(bytes)).unwrap(); - progress_chan.send(Done(Ok(()))).unwrap(); + bytes + }; + + let mut metadata = Metadata::default(url); + metadata.set_content_type(content_type.as_ref()); + if let Ok(chan) = start_sending_sniffed_opt(start_chan, metadata, classifier, &bytes) { + let _ = chan.send(Payload(bytes)); + let _ = chan.send(Done(Ok(()))); } } diff --git a/components/net/file_loader.rs b/components/net/file_loader.rs index f1ffe9c957f..c41f382f949 100644 --- a/components/net/file_loader.rs +++ b/components/net/file_loader.rs @@ -5,7 +5,7 @@ use mime_classifier::MIMEClassifier; use net_traits::ProgressMsg::{Done, Payload}; use net_traits::{LoadConsumer, LoadData, Metadata}; -use resource_task::{ProgressSender, send_error, start_sending, start_sending_sniffed}; +use resource_task::{ProgressSender, send_error, start_sending_sniffed, start_sending_sniffed_opt}; use std::borrow::ToOwned; use std::error::Error; use std::fs::File; @@ -52,19 +52,28 @@ pub fn factory(load_data: LoadData, senders: LoadConsumer, classifier: Arc<MIMEC Ok(file_path) => { match File::open(&file_path) { Ok(ref mut reader) => { - let metadata = Metadata::default(url); - let res = read_block(reader); - let (res, progress_chan) = match res { + match read_block(reader) { Ok(ReadStatus::Partial(buf)) => { + let metadata = Metadata::default(url); let progress_chan = start_sending_sniffed(senders, metadata, classifier, &buf); progress_chan.send(Payload(buf)).unwrap(); - (read_all(reader, &progress_chan), progress_chan) + let res = read_all(reader, &progress_chan); + let _ = progress_chan.send(Done(res)); + } + Ok(ReadStatus::EOF) => { + let metadata = Metadata::default(url); + if let Ok(chan) = start_sending_sniffed_opt(senders, + metadata, + classifier, + &[]) { + let _ = chan.send(Done(Ok(()))); + } + } + Err(e) => { + send_error(url, e, senders); } - Ok(ReadStatus::EOF) | Err(_) => - (res.map(|_| ()), start_sending(senders, metadata)), }; - progress_chan.send(Done(res)).unwrap(); } Err(e) => { send_error(url, e.description().to_owned(), senders); diff --git a/components/net/resource_task.rs b/components/net/resource_task.rs index 9fef339e838..529f79b448e 100644 --- a/components/net/resource_task.rs +++ b/components/net/resource_task.rs @@ -59,11 +59,6 @@ pub fn send_error(url: Url, err: String, start_chan: LoadConsumer) { } } -/// For use by loaders in responding to a Load message. -pub fn start_sending(start_chan: LoadConsumer, metadata: Metadata) -> ProgressSender { - start_sending_opt(start_chan, metadata).ok().unwrap() -} - /// For use by loaders in responding to a Load message that allows content sniffing. pub fn start_sending_sniffed(start_chan: LoadConsumer, metadata: Metadata, classifier: Arc<MIMEClassifier>, partial_body: &[u8]) @@ -122,7 +117,7 @@ fn apache_bug_predicate(last_raw_content_type: &[u8]) -> ApacheBugFlag { } /// For use by loaders in responding to a Load message. -pub fn start_sending_opt(start_chan: LoadConsumer, metadata: Metadata) -> Result<ProgressSender, ()> { +fn start_sending_opt(start_chan: LoadConsumer, metadata: Metadata) -> Result<ProgressSender, ()> { match start_chan { LoadConsumer::Channel(start_chan) => { let (progress_chan, progress_port) = ipc::channel().unwrap(); @@ -253,8 +248,7 @@ impl ResourceManager { "about" => from_factory(about_loader::factory), _ => { debug!("resource_task: no loader for scheme {}", load_data.url.scheme); - start_sending(consumer, Metadata::default(load_data.url)) - .send(ProgressMsg::Done(Err("no loader for scheme".to_owned()))).unwrap(); + send_error(load_data.url, "no loader for scheme".to_owned(), consumer); return } }; diff --git a/tests/unit/net/data_loader.rs b/tests/unit/net/data_loader.rs index 05f735413ab..06271396189 100644 --- a/tests/unit/net/data_loader.rs +++ b/tests/unit/net/data_loader.rs @@ -17,11 +17,14 @@ fn assert_parse(url: &'static str, charset: Option<String>, data: Option<Vec<u8>>) { use net::data_loader::load; + use net::mime_classifier::MIMEClassifier; + use std::sync::Arc; use std::sync::mpsc::channel; use url::Url; let (start_chan, start_port) = ipc::channel().unwrap(); - load(LoadData::new(Url::parse(url).unwrap(), None), Channel(start_chan)); + let classifier = Arc::new(MIMEClassifier::new()); + load(LoadData::new(Url::parse(url).unwrap(), None), Channel(start_chan), classifier); let response = start_port.recv().unwrap(); assert_eq!(&response.metadata.content_type, &content_type); From dcaa764b578879509927035a5db615d49adfeaab Mon Sep 17 00:00:00 2001 From: Eli Friedman <eli.friedman@gmail.com> Date: Sat, 31 Oct 2015 12:21:51 -0700 Subject: [PATCH 37/58] Fix unused variable warnings. --- components/script/dom/htmllabelelement.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/components/script/dom/htmllabelelement.rs b/components/script/dom/htmllabelelement.rs index ae1aa580cc3..0e13261026d 100644 --- a/components/script/dom/htmllabelelement.rs +++ b/components/script/dom/htmllabelelement.rs @@ -69,7 +69,7 @@ impl Activatable for HTMLLabelElement { } // https://html.spec.whatwg.org/multipage/#implicit-submission - fn implicit_submission(&self, ctrlKey: bool, shiftKey: bool, altKey: bool, metaKey: bool) { + fn implicit_submission(&self, _ctrlKey: bool, _shiftKey: bool, _altKey: bool, _metaKey: bool) { //FIXME: Investigate and implement implicit submission for label elements // Issue filed at https://github.com/servo/servo/issues/8263 } From 41dfd07d16340d437182c83517484b16303a83c9 Mon Sep 17 00:00:00 2001 From: Bobby Holley <bobbyholley@gmail.com> Date: Fri, 30 Oct 2015 16:08:09 -0700 Subject: [PATCH 38/58] Rev rust-selectors. --- components/servo/Cargo.lock | 2 +- ports/cef/Cargo.lock | 2 +- ports/gonk/Cargo.lock | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/components/servo/Cargo.lock b/components/servo/Cargo.lock index 5c4478bfb36..d62b48cec42 100644 --- a/components/servo/Cargo.lock +++ b/components/servo/Cargo.lock @@ -1594,7 +1594,7 @@ dependencies = [ [[package]] name = "selectors" version = "0.2.0" -source = "git+https://github.com/servo/rust-selectors#d3bd9b7c665c838f703ef0bbc7fd67b89847550d" +source = "git+https://github.com/servo/rust-selectors#53f5e09a37684f6a42eb894d7a6fd0b14380a1c6" dependencies = [ "bitflags 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)", "cssparser 0.3.9 (registry+https://github.com/rust-lang/crates.io-index)", diff --git a/ports/cef/Cargo.lock b/ports/cef/Cargo.lock index 051695a4b02..1fa03c0f628 100644 --- a/ports/cef/Cargo.lock +++ b/ports/cef/Cargo.lock @@ -1518,7 +1518,7 @@ dependencies = [ [[package]] name = "selectors" version = "0.2.0" -source = "git+https://github.com/servo/rust-selectors#d3bd9b7c665c838f703ef0bbc7fd67b89847550d" +source = "git+https://github.com/servo/rust-selectors#53f5e09a37684f6a42eb894d7a6fd0b14380a1c6" dependencies = [ "bitflags 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)", "cssparser 0.3.9 (registry+https://github.com/rust-lang/crates.io-index)", diff --git a/ports/gonk/Cargo.lock b/ports/gonk/Cargo.lock index 07d85f98b20..4004400466a 100644 --- a/ports/gonk/Cargo.lock +++ b/ports/gonk/Cargo.lock @@ -1467,7 +1467,7 @@ dependencies = [ [[package]] name = "selectors" version = "0.2.0" -source = "git+https://github.com/servo/rust-selectors#d3bd9b7c665c838f703ef0bbc7fd67b89847550d" +source = "git+https://github.com/servo/rust-selectors#53f5e09a37684f6a42eb894d7a6fd0b14380a1c6" dependencies = [ "bitflags 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)", "cssparser 0.3.9 (registry+https://github.com/rust-lang/crates.io-index)", From 45fc7f2930682fc52822db0e5aaaeab0f732229a Mon Sep 17 00:00:00 2001 From: Bobby Holley <bobbyholley@gmail.com> Date: Tue, 20 Oct 2015 21:58:50 -0700 Subject: [PATCH 39/58] Implement restyle hints for state changes. --- components/layout/layout_task.rs | 7 +- components/layout/wrapper.rs | 68 ++++--- components/style/lib.rs | 3 +- components/style/restyle_hints.rs | 247 ++++++++++++++++++++++++++ components/style/selector_matching.rs | 18 ++ 5 files changed, 315 insertions(+), 28 deletions(-) create mode 100644 components/style/restyle_hints.rs diff --git a/components/layout/layout_task.rs b/components/layout/layout_task.rs index 4ebe8363fbc..273d56bca80 100644 --- a/components/layout/layout_task.rs +++ b/components/layout/layout_task.rs @@ -1182,9 +1182,10 @@ impl LayoutTask { let state_changes = document.drain_element_state_changes(); if !needs_dirtying { - for &(el, state) in state_changes.iter() { - assert!(!state.is_empty()); - el.note_state_change(); + for &(el, state_change) in state_changes.iter() { + debug_assert!(!state_change.is_empty()); + let hint = rw_data.stylist.restyle_hint_for_state_change(&el, el.get_state(), state_change); + el.note_restyle_hint(hint); } } diff --git a/components/layout/wrapper.rs b/components/layout/wrapper.rs index 46a2caed506..a9bb80ee49a 100644 --- a/components/layout/wrapper.rs +++ b/components/layout/wrapper.rs @@ -70,6 +70,7 @@ use style::legacy::UnsignedIntegerAttribute; use style::node::TElementAttributes; use style::properties::ComputedValues; use style::properties::{PropertyDeclaration, PropertyDeclarationBlock}; +use style::restyle_hints::{RESTYLE_DESCENDANTS, RESTYLE_LATER_SIBLINGS, RESTYLE_SELF, RestyleHint}; use url::Url; use util::str::{is_whitespace, search_index}; @@ -408,39 +409,58 @@ impl<'le> LayoutElement<'le> { } } - /// Properly marks nodes as dirty in response to state changes. - /// - /// Currently this implementation is very conservative, and basically mirrors node::dirty_impl. - /// With restyle hints, we can do less work here. - pub fn note_state_change(&self) { - let node = self.as_node(); + pub fn get_state(&self) -> ElementState { + self.element.get_state_for_layout() + } - // Bail out if we're already dirty. This won't be valid when we start doing more targeted - // dirtying with restyle hints. - if node.is_dirty() { return } - - // Dirty descendants. - fn dirty_subtree(node: LayoutNode) { - // Stop if this subtree is already dirty. This won't be valid with restyle hints, see above. - if node.is_dirty() { return } - - unsafe { - node.set_dirty(true); - node.set_dirty_descendants(true); - } - - for kid in node.children() { - dirty_subtree(kid); - } + /// Properly marks nodes as dirty in response to restyle hints. + pub fn note_restyle_hint(&self, hint: RestyleHint) { + // Bail early if there's no restyling to do. + if hint.is_empty() { + return; } - dirty_subtree(node); + // If the restyle hint is non-empty, we need to restyle either this element + // or one of its siblings. Mark our ancestor chain as having dirty descendants. + let node = self.as_node(); let mut curr = node; while let Some(parent) = curr.parent_node() { if parent.has_dirty_descendants() { break } unsafe { parent.set_dirty_descendants(true); } curr = parent; } + + // Set up our helpers. + fn dirty_node(node: &LayoutNode) { + unsafe { + node.set_dirty(true); + node.set_dirty_descendants(true); + } + } + fn dirty_descendants(node: &LayoutNode) { + for ref child in node.children() { + dirty_node(child); + dirty_descendants(child); + } + } + + // Process hints. + if hint.contains(RESTYLE_SELF) { + dirty_node(&node); + } + if hint.contains(RESTYLE_DESCENDANTS) { + unsafe { node.set_dirty_descendants(true); } + dirty_descendants(&node); + } + if hint.contains(RESTYLE_LATER_SIBLINGS) { + let mut next = ::selectors::Element::next_sibling_element(self); + while let Some(sib) = next { + let sib_node = sib.as_node(); + dirty_node(&sib_node); + dirty_descendants(&sib_node); + next = ::selectors::Element::next_sibling_element(&sib); + } + } } } diff --git a/components/style/lib.rs b/components/style/lib.rs index ed898ff2f60..997cd90b79c 100644 --- a/components/style/lib.rs +++ b/components/style/lib.rs @@ -34,7 +34,7 @@ extern crate euclid; extern crate fnv; extern crate num; extern crate rustc_serialize; -extern crate selectors; +#[macro_use(state_pseudo_classes)] extern crate selectors; extern crate serde; extern crate smallvec; extern crate string_cache; @@ -48,6 +48,7 @@ pub mod legacy; pub mod media_queries; pub mod node; pub mod parser; +pub mod restyle_hints; pub mod selector_matching; pub mod stylesheets; #[macro_use] diff --git a/components/style/restyle_hints.rs b/components/style/restyle_hints.rs new file mode 100644 index 00000000000..acb521b0f10 --- /dev/null +++ b/components/style/restyle_hints.rs @@ -0,0 +1,247 @@ +/* This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ + +use selectors::Element; +use selectors::matching::matches_compound_selector; +use selectors::parser::{AttrSelector, Combinator, CompoundSelector, SimpleSelector}; +use selectors::states::*; +use std::clone::Clone; +use std::sync::Arc; +use string_cache::{Atom, Namespace}; + +/// When the ElementState of an element (like IN_HOVER_STATE) changes, certain +/// pseudo-classes (like :hover) may require us to restyle that element, its +/// siblings, and/or its descendants. Doing this conservatively is expensive, +/// and so we RestyleHints to short-circuit work we know is unnecessary. +/// +/// NB: We should extent restyle hints to check for attribute-dependent style +/// in addition to state-dependent style (Gecko does this). + + +bitflags! { + flags RestyleHint: u8 { + #[doc = "Rerun selector matching on the element."] + const RESTYLE_SELF = 0x01, + #[doc = "Rerun selector matching on all of the element's descendants."] + // NB: In Gecko, we have RESTYLE_SUBTREE which is inclusive of self, but heycam isn't aware + // of a good reason for that. + const RESTYLE_DESCENDANTS = 0x02, + #[doc = "Rerun selector matching on all later siblings of the element and all of their descendants."] + const RESTYLE_LATER_SIBLINGS = 0x04, + } +} + +/// In order to compute restyle hints, we perform a selector match against a list of partial +/// selectors whose rightmost simple selector may be sensitive to the thing being changed. We +/// do this matching twice, once for the element as it exists now and once for the element as it +/// existed at the time of the last restyle. If the results of the selector match differ, that means +/// that the given partial selector is sensitive to the change, and we compute a restyle hint +/// based on its combinator. +/// +/// In order to run selector matching against the old element state, we generate a wrapper for +/// the element which claims to have the old state. This is the ElementWrapper logic below. +/// +/// Gecko does this differently for element states, and passes a mask called mStateMask, which +/// indicates the states that need to be ignored during selector matching. This saves an ElementWrapper +/// allocation and an additional selector match call at the expense of additional complexity inside +/// the selector matching logic. This only works for boolean states though, so we still need to +/// take the ElementWrapper approach for attribute-dependent style. So we do it the same both ways for +/// now to reduce complexity, but it's worth measuring the performance impact (if any) of the +/// mStateMask approach. +struct ElementWrapper<E> where E: Element { + element: E, + state_override: ElementState, +} + +impl<'a, E> ElementWrapper<E> where E: Element { + pub fn new(el: E) -> ElementWrapper<E> { + ElementWrapper { element: el, state_override: ElementState::empty() } + } + + pub fn new_with_override(el: E, state: ElementState) -> ElementWrapper<E> { + ElementWrapper { element: el, state_override: state } + } +} + +macro_rules! overridden_state_accessors { + ($( + $(#[$Flag_attr: meta])* + state $css: expr => $variant: ident / $method: ident / + $flag: ident = $value: expr, + )+) => { $( fn $method(&self) -> bool { self.state_override.contains($flag) } )+ + } +} + +impl<E> Element for ElementWrapper<E> where E: Element { + + // Implement the state accessors on Element to use our overridden state. + state_pseudo_classes!(overridden_state_accessors); + + fn parent_element(&self) -> Option<Self> { + self.element.parent_element().map(|el| ElementWrapper::new(el)) + } + fn first_child_element(&self) -> Option<Self> { + self.element.first_child_element().map(|el| ElementWrapper::new(el)) + } + fn last_child_element(&self) -> Option<Self> { + self.element.last_child_element().map(|el| ElementWrapper::new(el)) + } + fn prev_sibling_element(&self) -> Option<Self> { + self.element.prev_sibling_element().map(|el| ElementWrapper::new(el)) + } + fn next_sibling_element(&self) -> Option<Self> { + self.element.next_sibling_element().map(|el| ElementWrapper::new(el)) + } + fn is_html_element_in_html_document(&self) -> bool { + self.element.is_html_element_in_html_document() + } + fn get_local_name<'b>(&'b self) -> &'b Atom { + self.element.get_local_name() + } + fn get_namespace<'b>(&'b self) -> &'b Namespace { + self.element.get_namespace() + } + fn get_id(&self) -> Option<Atom> { + self.element.get_id() + } + fn has_class(&self, name: &Atom) -> bool { + self.element.has_class(name) + } + fn match_attr<F>(&self, attr: &AttrSelector, test: F) -> bool + where F: Fn(&str) -> bool { + self.element.match_attr(attr, test) + } + fn is_empty(&self) -> bool { + self.element.is_empty() + } + fn is_root(&self) -> bool { + self.element.is_root() + } + fn is_link(&self) -> bool { + self.element.is_link() + } + fn is_visited_link(&self) -> bool { + self.element.is_visited_link() + } + fn is_unvisited_link(&self) -> bool { + self.element.is_unvisited_link() + } + fn each_class<F>(&self, callback: F) where F: FnMut(&Atom) { + self.element.each_class(callback) + } +} + +macro_rules! gen_selector_to_state { + ($( + $(#[$Flag_attr: meta])* + state $css: expr => $variant: ident / $method: ident / + $flag: ident = $value: expr, + )+) => { + fn selector_to_state(sel: &SimpleSelector) -> ElementState { + match *sel { + $( SimpleSelector::$variant => $flag, )+ + _ => ElementState::empty(), + } + } + } +} + +fn combinator_to_restyle_hint(combinator: Option<Combinator>) -> RestyleHint { + match combinator { + None => RESTYLE_SELF, + Some(c) => match c { + Combinator::Child => RESTYLE_DESCENDANTS, + Combinator::Descendant => RESTYLE_DESCENDANTS, + Combinator::NextSibling => RESTYLE_LATER_SIBLINGS, + Combinator::LaterSibling => RESTYLE_LATER_SIBLINGS, + } + } +} + +state_pseudo_classes!(gen_selector_to_state); + +// Mapping between (partial) CompoundSelectors (and the combinator to their right) +// and the states they depend on. +// +// In general, for all selectors in all applicable stylesheets of the form: +// +// |s _ s:X _ s _ s:Y _ s| +// +// Where: +// * Each |s| is an arbitrary simple selector. +// * Each |s| is an arbitrary combinator (or nothing). +// * X and Y are state-dependent pseudo-classes like :hover. +// +// We generate a StateDependency for both |s _ s:X _| and |s _ s:X _ s _ s:Y _|, even +// though those selectors may not appear on their own in any stylesheet. This allows +// us to quickly scan through the operation points of pseudo-classes and determine the +// maximum effect their associated state changes may have on the style of elements in +// the document. +#[derive(Debug)] +struct StateDependency { + selector: Arc<CompoundSelector>, + combinator: Option<Combinator>, + state: ElementState, +} + +#[derive(Debug)] +pub struct StateDependencySet { + deps: Vec<StateDependency>, +} + +impl StateDependencySet { + pub fn new() -> StateDependencySet { + StateDependencySet { deps: Vec::new() } + } + + pub fn compute_hint<E>(&self, el: &E, current_state: ElementState, state_changes: ElementState) + -> RestyleHint where E: Element, E: Clone { + let mut hint = RestyleHint::empty(); + let mut old_state = current_state; + old_state.toggle(state_changes); + for dep in &self.deps { + if state_changes.intersects(dep.state) { + let old_el: ElementWrapper<E> = ElementWrapper::new_with_override(el.clone(), old_state); + let matched_then = matches_compound_selector(&*dep.selector, &old_el, None, &mut false); + let matches_now = matches_compound_selector(&*dep.selector, el, None, &mut false); + if matched_then != matches_now { + hint.insert(combinator_to_restyle_hint(dep.combinator)); + if hint.is_all() { + break + } + } + } + } + hint + } + + pub fn note_selector(&mut self, selector: Arc<CompoundSelector>) { + let mut cur = selector; + let mut combinator: Option<Combinator> = None; + loop { + if let Some(rightmost) = cur.simple_selectors.last() { + let state_dep = selector_to_state(rightmost); + if !state_dep.is_empty() { + self.deps.push(StateDependency { + selector: cur.clone(), + combinator: combinator, + state: state_dep, + }); + } + } + + cur = match cur.next { + Some((ref sel, comb)) => { + combinator = Some(comb); + sel.clone() + } + None => break, + } + } + } + + pub fn clear(&mut self) { + self.deps.clear(); + } +} diff --git a/components/style/selector_matching.rs b/components/style/selector_matching.rs index b758c535da8..53f1a0d3589 100644 --- a/components/style/selector_matching.rs +++ b/components/style/selector_matching.rs @@ -6,11 +6,13 @@ use legacy::PresentationalHintSynthesis; use media_queries::Device; use node::TElementAttributes; use properties::{PropertyDeclaration, PropertyDeclarationBlock}; +use restyle_hints::{RestyleHint, StateDependencySet}; use selectors::Element; use selectors::bloom::BloomFilter; use selectors::matching::DeclarationBlock as GenericDeclarationBlock; use selectors::matching::{Rule, SelectorMap}; use selectors::parser::PseudoElement; +use selectors::states::*; use smallvec::VecLike; use std::process; use style_traits::viewport::ViewportConstraints; @@ -41,6 +43,9 @@ pub struct Stylist { before_map: PerPseudoElementSelectorMap, after_map: PerPseudoElementSelectorMap, rules_source_order: usize, + + // Selector state dependencies used to compute restyle hints. + state_deps: StateDependencySet, } impl Stylist { @@ -55,6 +60,7 @@ impl Stylist { before_map: PerPseudoElementSelectorMap::new(), after_map: PerPseudoElementSelectorMap::new(), rules_source_order: 0, + state_deps: StateDependencySet::new(), }; // FIXME: Add iso-8859-9.css when the documentโ€™s encoding is ISO-8859-8. // FIXME: presentational-hints.css should be at author origin with zero specificity. @@ -102,6 +108,7 @@ impl Stylist { self.before_map = PerPseudoElementSelectorMap::new(); self.after_map = PerPseudoElementSelectorMap::new(); self.rules_source_order = 0; + self.state_deps.clear(); for stylesheet in &self.stylesheets { let (mut element_map, mut before_map, mut after_map) = match stylesheet.origin { @@ -151,6 +158,9 @@ impl Stylist { append!(style_rule, normal); append!(style_rule, important); rules_source_order += 1; + for selector in &style_rule.selectors { + self.state_deps.note_selector(selector.compound_selectors.clone()); + } } self.rules_source_order = rules_source_order; } @@ -162,6 +172,14 @@ impl Stylist { false } + pub fn restyle_hint_for_state_change<E>(&self, element: &E, + current_state: ElementState, + state_change: ElementState) + -> RestyleHint + where E: Element + Clone { + self.state_deps.compute_hint(element, current_state, state_change) + } + pub fn set_device(&mut self, device: Device) { let is_dirty = self.is_dirty || self.stylesheets.iter() .flat_map(|stylesheet| stylesheet.rules().media()) From 564170f41bb82c57620541dc7f40bac32d63b4a6 Mon Sep 17 00:00:00 2001 From: Bobby Holley <bobbyholley@gmail.com> Date: Thu, 29 Oct 2015 17:49:49 -0700 Subject: [PATCH 40/58] State restyle hint tests. This handles the state part of #6942. --- tests/wpt/mozilla/meta/MANIFEST.json | 24 ++++++++++ .../mozilla/tests/css/restyle_hints_state.css | 36 +++++++++++++++ .../tests/css/restyle_hints_state.html | 44 +++++++++++++++++++ .../tests/css/restyle_hints_state_ref.html | 19 ++++++++ 4 files changed, 123 insertions(+) create mode 100644 tests/wpt/mozilla/tests/css/restyle_hints_state.css create mode 100644 tests/wpt/mozilla/tests/css/restyle_hints_state.html create mode 100644 tests/wpt/mozilla/tests/css/restyle_hints_state_ref.html diff --git a/tests/wpt/mozilla/meta/MANIFEST.json b/tests/wpt/mozilla/meta/MANIFEST.json index 2c07bd173f4..bc04fb431a2 100644 --- a/tests/wpt/mozilla/meta/MANIFEST.json +++ b/tests/wpt/mozilla/meta/MANIFEST.json @@ -2927,6 +2927,18 @@ "url": "/_mozilla/css/quotes_simple_a.html" } ], + "css/restyle_hints_state.html": [ + { + "path": "css/restyle_hints_state.html", + "references": [ + [ + "/_mozilla/css/restyle_hints_state_ref.html", + "==" + ] + ], + "url": "/_mozilla/css/restyle_hints_state.html" + } + ], "css/root_height_a.html": [ { "path": "css/root_height_a.html", @@ -7560,6 +7572,18 @@ "url": "/_mozilla/css/quotes_simple_a.html" } ], + "css/restyle_hints_state.html": [ + { + "path": "css/restyle_hints_state.html", + "references": [ + [ + "/_mozilla/css/restyle_hints_state_ref.html", + "==" + ] + ], + "url": "/_mozilla/css/restyle_hints_state.html" + } + ], "css/root_height_a.html": [ { "path": "css/root_height_a.html", diff --git a/tests/wpt/mozilla/tests/css/restyle_hints_state.css b/tests/wpt/mozilla/tests/css/restyle_hints_state.css new file mode 100644 index 00000000000..673ac25d572 --- /dev/null +++ b/tests/wpt/mozilla/tests/css/restyle_hints_state.css @@ -0,0 +1,36 @@ +fieldset { + width: 200px; +} + +div { + background-color: black; + padding: 10px; + width: 50px; + height: 50px; +} + +fieldset div { + background-color: red; +} +fieldset:enabled div { + color: aqua; + background-color: green; +} +fieldset:enabled > div { + background-color: yellow; +} +fieldset:enabled ~ div { + color: pink; + background-color: purple; +} +fieldset:enabled + div { + color: brown; + background-color: orange; +} + +input:checked:enabled + span { + color: khaki; +} +input:checked:disabled + span { + color: lawngreen; +} diff --git a/tests/wpt/mozilla/tests/css/restyle_hints_state.html b/tests/wpt/mozilla/tests/css/restyle_hints_state.html new file mode 100644 index 00000000000..52f82bc905d --- /dev/null +++ b/tests/wpt/mozilla/tests/css/restyle_hints_state.html @@ -0,0 +1,44 @@ +<!doctype html> +<html> +<meta charset=utf-8> +<title></title> +<link rel=match href=/_mozilla/css/restyle_hints_state_ref.html> +<link rel="stylesheet" href="restyle_hints_state.css"> +<body> + <fieldset id="fs1" disabled="1"> + <div> + <div>sometext</div> + </div> + </fieldset> + <div>othertext</div> + <div></div> + <fieldset id="fs2"> + <input id="cb" type="checkbox"></input> + <span>I should be lawngreen</span> + </fieldset> + + <script> + /* + * Servo currently dirties the entire subtree whenever an attribute is + * changed, so we want to avoid changing attributes if we want to properly + * test restyle hints. This means that we can't use reftest-wait, since + * that will cause us to dirty the entire subtree of the <html> element just + * before we generate the rendering we want to check. + * + * Note that the 'disabled' and 'checked' setters forward to attributes, so + * we're not getting as much test coverage there as we'd like. When we + * implement attribute-based restyle hints, we can stop dirtying the subtree + * on attribute modifications, and these tests will start to be more useful. + */ + var $ = document.getElementById.bind(document); + function syncRestyle() { window.dummy != $("fs2").offsetTop; } + syncRestyle(); + $('fs1').disabled = true; + syncRestyle(); + $('fs1').disabled = false; + syncRestyle(); + $('cb').checked = true; + syncRestyle(); + $('fs2').disabled = true; + </script> +</body> diff --git a/tests/wpt/mozilla/tests/css/restyle_hints_state_ref.html b/tests/wpt/mozilla/tests/css/restyle_hints_state_ref.html new file mode 100644 index 00000000000..d8d0ad1dd09 --- /dev/null +++ b/tests/wpt/mozilla/tests/css/restyle_hints_state_ref.html @@ -0,0 +1,19 @@ +<!doctype html> +<meta charset=utf-8> +<title></title> +<link rel="stylesheet" href="restyle_hints_state.css"> + +</style> +<body> + <fieldset> + <div> + <div>sometext</div> + </div> + </fieldset> + <div>othertext</div> + <div></div> + <fieldset disabled> + <input id="cb" type="checkbox" checked></input> + <span>I should be lawngreen</span> + </fieldset> +</body> From 468eaac096c81c68995fd2bc64f64036c18232da Mon Sep 17 00:00:00 2001 From: nxnfufunezn <nxnfufunezn@gmail.com> Date: Sat, 31 Oct 2015 01:25:16 +0530 Subject: [PATCH 41/58] Accept Brotli-compressed HTTP responses #8156 --- components/net/Cargo.toml | 3 ++ components/net/http_loader.rs | 17 +++++--- components/net/lib.rs | 1 + components/servo/Cargo.lock | 6 +++ ports/cef/Cargo.lock | 6 +++ ports/gonk/Cargo.lock | 6 +++ tests/unit/net/http_loader.rs | 8 +++- tests/wpt/metadata/MANIFEST.json | 2 +- tests/wpt/mozilla/meta/MANIFEST.json | 8 +++- .../mozilla/tests/mozilla/resources/brotli.py | 7 ++++ .../tests/mozilla/response-data-brotli.htm | 42 +++++++++++++++++++ 11 files changed, 97 insertions(+), 9 deletions(-) create mode 100644 tests/wpt/mozilla/tests/mozilla/resources/brotli.py create mode 100644 tests/wpt/mozilla/tests/mozilla/response-data-brotli.htm diff --git a/components/net/Cargo.toml b/components/net/Cargo.toml index 51573136d4e..620a10ca1b6 100644 --- a/components/net/Cargo.toml +++ b/components/net/Cargo.toml @@ -16,6 +16,9 @@ path = "../util" [dependencies.devtools_traits] path = "../devtools_traits" +[dependencies.brotli] +git = "https://github.com/ende76/brotli-rs" + [dependencies.plugins] path = "../plugins" diff --git a/components/net/http_loader.rs b/components/net/http_loader.rs index 521af527a37..62e461dbc21 100644 --- a/components/net/http_loader.rs +++ b/components/net/http_loader.rs @@ -3,6 +3,7 @@ * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ +use brotli::Decompressor; use cookie; use cookie_storage::CookieStorage; use devtools_traits::{ChromeToDevtoolsControlMsg, DevtoolsControlMsg, HttpRequest as DevtoolsHttpRequest}; @@ -154,10 +155,9 @@ pub trait HttpResponse: Read { Some(Encoding::Gzip) } else if encodings.contains(&Encoding::Deflate) { Some(Encoding::Deflate) - } else { - // TODO: Is this the correct behaviour? - None - } + } else if encodings.contains(&Encoding::EncodingExt("br".to_owned())) { + Some(Encoding::EncodingExt("br".to_owned())) + } else { None } } } }) @@ -302,7 +302,8 @@ fn set_default_accept_encoding(headers: &mut Headers) { headers.set(AcceptEncoding(vec![ qitem(Encoding::Gzip), - qitem(Encoding::Deflate) + qitem(Encoding::Deflate), + qitem(Encoding::EncodingExt("br".to_owned())) ])); } @@ -394,6 +395,7 @@ impl<R: HttpResponse> Read for StreamedResponse<R> { match self.decoder { Decoder::Gzip(ref mut d) => d.read(buf), Decoder::Deflate(ref mut d) => d.read(buf), + Decoder::Brotli(ref mut d) => d.read(buf), Decoder::Plain(ref mut d) => d.read(buf) } } @@ -421,6 +423,10 @@ impl<R: HttpResponse> StreamedResponse<R> { let response_decoding = DeflateDecoder::new(response); Ok(StreamedResponse::new(m, Decoder::Deflate(response_decoding))) } + Some(Encoding::EncodingExt(ref ext)) if ext == "br" => { + let response_decoding = Decompressor::new(response); + Ok(StreamedResponse::new(m, Decoder::Brotli(response_decoding))) + } _ => { Ok(StreamedResponse::new(m, Decoder::Plain(response))) } @@ -431,6 +437,7 @@ impl<R: HttpResponse> StreamedResponse<R> { enum Decoder<R: Read> { Gzip(GzDecoder<R>), Deflate(DeflateDecoder<R>), + Brotli(Decompressor<R>), Plain(R) } diff --git a/components/net/lib.rs b/components/net/lib.rs index d09d28fa5ba..e0bae6b829d 100644 --- a/components/net/lib.rs +++ b/components/net/lib.rs @@ -17,6 +17,7 @@ extern crate cookie as cookie_rs; extern crate devtools_traits; extern crate euclid; extern crate flate2; +extern crate brotli; extern crate hyper; extern crate ipc_channel; extern crate net_traits; diff --git a/components/servo/Cargo.lock b/components/servo/Cargo.lock index d62b48cec42..c4d436e5451 100644 --- a/components/servo/Cargo.lock +++ b/components/servo/Cargo.lock @@ -138,6 +138,11 @@ dependencies = [ "libc 0.1.10 (registry+https://github.com/rust-lang/crates.io-index)", ] +[[package]] +name = "brotli" +version = "0.3.17" +source = "git+https://github.com/ende76/brotli-rs#4a8c42cce771ded65fe64d6816f5d7303006b2ea" + [[package]] name = "byteorder" version = "0.3.13" @@ -1200,6 +1205,7 @@ dependencies = [ name = "net" version = "0.0.1" dependencies = [ + "brotli 0.3.17 (git+https://github.com/ende76/brotli-rs)", "cookie 0.1.21 (registry+https://github.com/rust-lang/crates.io-index)", "devtools_traits 0.0.1", "euclid 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)", diff --git a/ports/cef/Cargo.lock b/ports/cef/Cargo.lock index 1fa03c0f628..e95466b2112 100644 --- a/ports/cef/Cargo.lock +++ b/ports/cef/Cargo.lock @@ -128,6 +128,11 @@ dependencies = [ "libc 0.1.10 (registry+https://github.com/rust-lang/crates.io-index)", ] +[[package]] +name = "brotli" +version = "0.3.17" +source = "git+https://github.com/ende76/brotli-rs#4a8c42cce771ded65fe64d6816f5d7303006b2ea" + [[package]] name = "byteorder" version = "0.3.13" @@ -1150,6 +1155,7 @@ dependencies = [ name = "net" version = "0.0.1" dependencies = [ + "brotli 0.3.17 (git+https://github.com/ende76/brotli-rs)", "cookie 0.1.21 (registry+https://github.com/rust-lang/crates.io-index)", "devtools_traits 0.0.1", "euclid 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)", diff --git a/ports/gonk/Cargo.lock b/ports/gonk/Cargo.lock index 4004400466a..bf4ebfd0ee4 100644 --- a/ports/gonk/Cargo.lock +++ b/ports/gonk/Cargo.lock @@ -120,6 +120,11 @@ dependencies = [ "libc 0.1.10 (registry+https://github.com/rust-lang/crates.io-index)", ] +[[package]] +name = "brotli" +version = "0.3.17" +source = "git+https://github.com/ende76/brotli-rs#4a8c42cce771ded65fe64d6816f5d7303006b2ea" + [[package]] name = "byteorder" version = "0.3.13" @@ -1099,6 +1104,7 @@ dependencies = [ name = "net" version = "0.0.1" dependencies = [ + "brotli 0.3.17 (git+https://github.com/ende76/brotli-rs)", "cookie 0.1.21 (registry+https://github.com/rust-lang/crates.io-index)", "devtools_traits 0.0.1", "euclid 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)", diff --git a/tests/unit/net/http_loader.rs b/tests/unit/net/http_loader.rs index 27bd6341af0..ede8b7d8ed0 100644 --- a/tests/unit/net/http_loader.rs +++ b/tests/unit/net/http_loader.rs @@ -307,7 +307,9 @@ fn test_check_default_headers_loaded_in_every_request() { load_data.method = Method::Get; let mut headers = Headers::new(); - headers.set(AcceptEncoding(vec![qitem(Encoding::Gzip), qitem(Encoding::Deflate)])); + headers.set(AcceptEncoding(vec![qitem(Encoding::Gzip), + qitem(Encoding::Deflate), + qitem(Encoding::EncodingExt("br".to_owned()))])); headers.set(Host { hostname: "mozilla.com".to_owned() , port: None }); let accept = Accept(vec![ qitem(Mime(TopLevel::Text, SubLevel::Html, vec![])), @@ -776,7 +778,9 @@ fn test_load_uses_explicit_accept_encoding_from_load_data_headers() { #[test] fn test_load_sets_default_accept_encoding_to_gzip_and_deflate() { let mut accept_encoding_headers = Headers::new(); - accept_encoding_headers.set(AcceptEncoding(vec![qitem(Encoding::Gzip), qitem(Encoding::Deflate)])); + accept_encoding_headers.set(AcceptEncoding(vec![qitem(Encoding::Gzip), + qitem(Encoding::Deflate), + qitem(Encoding::EncodingExt("br".to_owned()))])); let url = Url::parse("http://mozilla.com").unwrap(); let mut load_data = LoadData::new(url.clone(), None); diff --git a/tests/wpt/metadata/MANIFEST.json b/tests/wpt/metadata/MANIFEST.json index 3222090ad1d..f279b5f318f 100644 --- a/tests/wpt/metadata/MANIFEST.json +++ b/tests/wpt/metadata/MANIFEST.json @@ -35349,4 +35349,4 @@ "rev": "7123012427f92f0dc38a120e6e86a75b6c03aab5", "url_base": "/", "version": 2 -} \ No newline at end of file +} diff --git a/tests/wpt/mozilla/meta/MANIFEST.json b/tests/wpt/mozilla/meta/MANIFEST.json index bc04fb431a2..e46ba1e0aa6 100644 --- a/tests/wpt/mozilla/meta/MANIFEST.json +++ b/tests/wpt/mozilla/meta/MANIFEST.json @@ -4567,6 +4567,12 @@ "url": "/_mozilla/mozilla/proxy_setter.html" } ], + "mozilla/response-data-brotli.htm": [ + { + "path": "mozilla/response-data-brotli.htm", + "url": "/_mozilla/mozilla/response-data-brotli.htm" + } + ], "mozilla/script_type.html": [ { "path": "mozilla/script_type.html", @@ -8730,4 +8736,4 @@ "rev": null, "url_base": "/_mozilla/", "version": 2 -} +} \ No newline at end of file diff --git a/tests/wpt/mozilla/tests/mozilla/resources/brotli.py b/tests/wpt/mozilla/tests/mozilla/resources/brotli.py new file mode 100644 index 00000000000..7e27b5c7d17 --- /dev/null +++ b/tests/wpt/mozilla/tests/mozilla/resources/brotli.py @@ -0,0 +1,7 @@ +def main(request, response): + output = '\x1b\x03)\x00\xa4\xcc\xde\xe2\xb3 vA\x00\x0c' + headers = [("Content-type", "text/plain"), + ("Content-Encoding", "br"), + ("Content-Length", len(output))] + + return headers, output diff --git a/tests/wpt/mozilla/tests/mozilla/response-data-brotli.htm b/tests/wpt/mozilla/tests/mozilla/response-data-brotli.htm new file mode 100644 index 00000000000..e46a0e5fb04 --- /dev/null +++ b/tests/wpt/mozilla/tests/mozilla/response-data-brotli.htm @@ -0,0 +1,42 @@ +<!doctype html> +<html> + <head> + <title>XMLHttpRequest: Brotli response was correctly inflated</title> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> + <link rel="help" href="https://dvcs.w3.org/hg/xhr/raw-file/tip/Overview.html#the-send()-method" data-tested-assertations="following::p[contains(text(),'content-encodings')]" /> + </head> + <body> + <div id="log"></div> + <script> + function request(input) { + var test = async_test(); + test.step(function() { + var client = new XMLHttpRequest() + + client.open("POST", "resources/brotli.py", false); + + client.onreadystatechange = test.step_func(function () { + if (client.readyState === 4) { + var len = parseInt(client.getResponseHeader('content-length'), 10); + + assert_equals(client.getResponseHeader('content-encoding'), 'br'); + assert_true(len < input.length); + assert_equals(client.responseText, input); + test.done(); + } + }); + + client.send(input); + }, document.title); + } + + var wellCompressableData = ''; + for (var i = 0; i < 500; i++) { + wellCompressableData += 'foofoofoofoofoofoofoo'; + } + + request(wellCompressableData); + </script> + </body> +</html> From aebf87cf5bab8c25bb4793c13dea048de8087512 Mon Sep 17 00:00:00 2001 From: Olivia Nordquist <nolivia@umich.edu> Date: Sat, 31 Oct 2015 22:29:16 -0700 Subject: [PATCH 42/58] Un-boxed ScriptReflow --- components/layout/layout_task.rs | 2 +- components/script/dom/window.rs | 2 +- components/script/layout_interface.rs | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/components/layout/layout_task.rs b/components/layout/layout_task.rs index 5f9c732d87c..878597f24f7 100644 --- a/components/layout/layout_task.rs +++ b/components/layout/layout_task.rs @@ -593,7 +593,7 @@ impl LayoutTask { profile(time::ProfilerCategory::LayoutPerform, self.profiler_metadata(), self.time_profiler_chan.clone(), - || self.handle_reflow(&*data, possibly_locked_rw_data)); + || self.handle_reflow(&data, possibly_locked_rw_data)); }, Msg::TickAnimations => self.tick_all_animations(possibly_locked_rw_data), Msg::ReflowWithNewlyLoadedWebFont => { diff --git a/components/script/dom/window.rs b/components/script/dom/window.rs index abe693696fd..c074935938b 100644 --- a/components/script/dom/window.rs +++ b/components/script/dom/window.rs @@ -910,7 +910,7 @@ impl Window { } // Send new document and relevant styles to layout. - let reflow = box ScriptReflow { + let reflow = ScriptReflow { reflow_info: Reflow { goal: goal, page_clip_rect: self.page_clip_rect.get(), diff --git a/components/script/layout_interface.rs b/components/script/layout_interface.rs index 5c41a04363c..acb69a02321 100644 --- a/components/script/layout_interface.rs +++ b/components/script/layout_interface.rs @@ -47,7 +47,7 @@ pub enum Msg { SetQuirksMode, /// Requests a reflow. - Reflow(Box<ScriptReflow>), + Reflow(ScriptReflow), /// Get an RPC interface. GetRPC(Sender<Box<LayoutRPC + Send>>), From 95a0d0584ff9e628da01d497cef8184822188d1e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Emilio=20Cobos=20=C3=81lvarez?= <ecoal95@gmail.com> Date: Sun, 1 Nov 2015 13:29:46 +0100 Subject: [PATCH 43/58] webgl: Add destructors for texture, program, shader, buffer and framebuffer This allows to cleanup resources earlier if they stop being used. Right now all resources were cleaned up when the context was destroyed, this is a slightly better approach. We ignore the possible failure of the send() call, since we don't keep track of these resources from the `WebGLRenderingContext` structure, so a texture could be destroyed after the context and give us problems. --- components/script/dom/webglbuffer.rs | 8 +++++++- components/script/dom/webglframebuffer.rs | 8 +++++++- components/script/dom/webglprogram.rs | 8 +++++++- components/script/dom/webglrenderbuffer.rs | 2 +- components/script/dom/webglshader.rs | 8 +++++++- components/script/dom/webgltexture.rs | 8 +++++++- 6 files changed, 36 insertions(+), 6 deletions(-) diff --git a/components/script/dom/webglbuffer.rs b/components/script/dom/webglbuffer.rs index 05f8d7263bb..17f13f33380 100644 --- a/components/script/dom/webglbuffer.rs +++ b/components/script/dom/webglbuffer.rs @@ -71,7 +71,13 @@ impl WebGLBuffer { pub fn delete(&self) { if !self.is_deleted.get() { self.is_deleted.set(true); - self.renderer.send(CanvasMsg::WebGL(CanvasWebGLMsg::DeleteBuffer(self.id))).unwrap(); + let _ = self.renderer.send(CanvasMsg::WebGL(CanvasWebGLMsg::DeleteBuffer(self.id))); } } } + +impl Drop for WebGLBuffer { + fn drop(&mut self) { + self.delete(); + } +} diff --git a/components/script/dom/webglframebuffer.rs b/components/script/dom/webglframebuffer.rs index a3a9781fbfb..6239312f9a9 100644 --- a/components/script/dom/webglframebuffer.rs +++ b/components/script/dom/webglframebuffer.rs @@ -60,7 +60,13 @@ impl WebGLFramebuffer { pub fn delete(&self) { if !self.is_deleted.get() { self.is_deleted.set(true); - self.renderer.send(CanvasMsg::WebGL(CanvasWebGLMsg::DeleteFramebuffer(self.id))).unwrap(); + let _ = self.renderer.send(CanvasMsg::WebGL(CanvasWebGLMsg::DeleteFramebuffer(self.id))); } } } + +impl Drop for WebGLFramebuffer { + fn drop(&mut self) { + self.delete(); + } +} diff --git a/components/script/dom/webglprogram.rs b/components/script/dom/webglprogram.rs index 997f48c96b4..5e51172cb68 100644 --- a/components/script/dom/webglprogram.rs +++ b/components/script/dom/webglprogram.rs @@ -58,7 +58,7 @@ impl WebGLProgram { pub fn delete(&self) { if !self.is_deleted.get() { self.is_deleted.set(true); - self.renderer.send(CanvasMsg::WebGL(CanvasWebGLMsg::DeleteProgram(self.id))).unwrap(); + let _ = self.renderer.send(CanvasMsg::WebGL(CanvasWebGLMsg::DeleteProgram(self.id))); } } @@ -125,3 +125,9 @@ impl WebGLProgram { Ok(receiver.recv().unwrap()) } } + +impl Drop for WebGLProgram { + fn drop(&mut self) { + self.delete(); + } +} diff --git a/components/script/dom/webglrenderbuffer.rs b/components/script/dom/webglrenderbuffer.rs index b01bcce896a..6a534da53e6 100644 --- a/components/script/dom/webglrenderbuffer.rs +++ b/components/script/dom/webglrenderbuffer.rs @@ -59,7 +59,7 @@ impl WebGLRenderbuffer { pub fn delete(&self) { if !self.is_deleted.get() { self.is_deleted.set(true); - self.renderer.send(CanvasMsg::WebGL(CanvasWebGLMsg::DeleteRenderbuffer(self.id))).unwrap(); + let _ = self.renderer.send(CanvasMsg::WebGL(CanvasWebGLMsg::DeleteRenderbuffer(self.id))); } } } diff --git a/components/script/dom/webglshader.rs b/components/script/dom/webglshader.rs index e33b27d3839..65dc958033f 100644 --- a/components/script/dom/webglshader.rs +++ b/components/script/dom/webglshader.rs @@ -121,7 +121,7 @@ impl WebGLShader { pub fn delete(&self) { if !self.is_deleted.get() { self.is_deleted.set(true); - self.renderer.send(CanvasMsg::WebGL(CanvasWebGLMsg::DeleteShader(self.id))).unwrap() + let _ = self.renderer.send(CanvasMsg::WebGL(CanvasWebGLMsg::DeleteShader(self.id))); } } @@ -152,3 +152,9 @@ impl WebGLShader { *self.source.borrow_mut() = Some(source); } } + +impl Drop for WebGLShader { + fn drop(&mut self) { + self.delete(); + } +} diff --git a/components/script/dom/webgltexture.rs b/components/script/dom/webgltexture.rs index fb8ee4033fd..d5f7ad8258e 100644 --- a/components/script/dom/webgltexture.rs +++ b/components/script/dom/webgltexture.rs @@ -78,7 +78,7 @@ impl WebGLTexture { pub fn delete(&self) { if !self.is_deleted.get() { self.is_deleted.set(true); - self.renderer.send(CanvasMsg::WebGL(CanvasWebGLMsg::DeleteTexture(self.id))).unwrap(); + let _ = self.renderer.send(CanvasMsg::WebGL(CanvasWebGLMsg::DeleteTexture(self.id))); } } @@ -145,3 +145,9 @@ impl WebGLTexture { } } } + +impl Drop for WebGLTexture { + fn drop(&mut self) { + self.delete(); + } +} From 2c87249311cda3cbac64a144135847351d8181c5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Emilio=20Cobos=20=C3=81lvarez?= <ecoal95@gmail.com> Date: Sun, 1 Nov 2015 13:31:52 +0100 Subject: [PATCH 44/58] Bump offscreen_rendering_context to remove duplicated Glutin dependency --- components/servo/Cargo.lock | 34 ++-------------------------------- ports/cef/Cargo.lock | 34 ++-------------------------------- ports/gonk/Cargo.lock | 7 ++++--- 3 files changed, 8 insertions(+), 67 deletions(-) diff --git a/components/servo/Cargo.lock b/components/servo/Cargo.lock index d62b48cec42..446af0a8638 100644 --- a/components/servo/Cargo.lock +++ b/components/servo/Cargo.lock @@ -749,36 +749,6 @@ dependencies = [ "x11-dl 2.0.1 (registry+https://github.com/rust-lang/crates.io-index)", ] -[[package]] -name = "glutin" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -dependencies = [ - "android_glue 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)", - "cgl 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", - "cocoa 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)", - "core-foundation 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", - "core-graphics 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)", - "dwmapi-sys 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", - "gdi32-sys 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)", - "gl_common 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", - "gl_generator 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", - "kernel32-sys 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)", - "khronos_api 0.0.8 (registry+https://github.com/rust-lang/crates.io-index)", - "lazy_static 0.1.15 (registry+https://github.com/rust-lang/crates.io-index)", - "libc 0.1.10 (registry+https://github.com/rust-lang/crates.io-index)", - "objc 0.1.7 (registry+https://github.com/rust-lang/crates.io-index)", - "osmesa-sys 0.0.5 (registry+https://github.com/rust-lang/crates.io-index)", - "shared_library 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", - "shell32-sys 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)", - "user32-sys 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)", - "wayland-client 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)", - "wayland-kbd 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)", - "wayland-window 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", - "winapi 0.2.4 (registry+https://github.com/rust-lang/crates.io-index)", - "x11-dl 2.0.1 (registry+https://github.com/rust-lang/crates.io-index)", -] - [[package]] name = "glutin_app" version = "0.0.1" @@ -1303,14 +1273,14 @@ dependencies = [ [[package]] name = "offscreen_gl_context" version = "0.1.0" -source = "git+https://github.com/ecoal95/rust-offscreen-rendering-context#a33af19355dfdd0076a3f2836dc66e0fea44bcab" +source = "git+https://github.com/ecoal95/rust-offscreen-rendering-context#05a1ea3a7cb6fac044e2c6133ab334ca522d2b92" dependencies = [ "cgl 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", "core-foundation 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", "euclid 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)", "gl_generator 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", "gleam 0.1.13 (registry+https://github.com/rust-lang/crates.io-index)", - "glutin 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)", + "glutin 0.4.0 (git+https://github.com/servo/glutin?branch=servo)", "khronos_api 0.0.8 (registry+https://github.com/rust-lang/crates.io-index)", "layers 0.1.0 (git+https://github.com/servo/rust-layers)", "libc 0.1.10 (registry+https://github.com/rust-lang/crates.io-index)", diff --git a/ports/cef/Cargo.lock b/ports/cef/Cargo.lock index 1fa03c0f628..d77a6d26efd 100644 --- a/ports/cef/Cargo.lock +++ b/ports/cef/Cargo.lock @@ -699,36 +699,6 @@ dependencies = [ "x11-dl 2.0.1 (registry+https://github.com/rust-lang/crates.io-index)", ] -[[package]] -name = "glutin" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -dependencies = [ - "android_glue 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)", - "cgl 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", - "cocoa 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)", - "core-foundation 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", - "core-graphics 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)", - "dwmapi-sys 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", - "gdi32-sys 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)", - "gl_common 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", - "gl_generator 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", - "kernel32-sys 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)", - "khronos_api 0.0.8 (registry+https://github.com/rust-lang/crates.io-index)", - "lazy_static 0.1.15 (registry+https://github.com/rust-lang/crates.io-index)", - "libc 0.1.10 (registry+https://github.com/rust-lang/crates.io-index)", - "objc 0.1.7 (registry+https://github.com/rust-lang/crates.io-index)", - "osmesa-sys 0.0.5 (registry+https://github.com/rust-lang/crates.io-index)", - "shared_library 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", - "shell32-sys 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)", - "user32-sys 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)", - "wayland-client 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)", - "wayland-kbd 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)", - "wayland-window 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", - "winapi 0.2.4 (registry+https://github.com/rust-lang/crates.io-index)", - "x11-dl 2.0.1 (registry+https://github.com/rust-lang/crates.io-index)", -] - [[package]] name = "glutin_app" version = "0.0.1" @@ -1237,14 +1207,14 @@ dependencies = [ [[package]] name = "offscreen_gl_context" version = "0.1.0" -source = "git+https://github.com/ecoal95/rust-offscreen-rendering-context#a33af19355dfdd0076a3f2836dc66e0fea44bcab" +source = "git+https://github.com/ecoal95/rust-offscreen-rendering-context#05a1ea3a7cb6fac044e2c6133ab334ca522d2b92" dependencies = [ "cgl 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", "core-foundation 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", "euclid 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)", "gl_generator 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", "gleam 0.1.13 (registry+https://github.com/rust-lang/crates.io-index)", - "glutin 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)", + "glutin 0.4.0 (git+https://github.com/servo/glutin?branch=servo)", "khronos_api 0.0.8 (registry+https://github.com/rust-lang/crates.io-index)", "layers 0.1.0 (git+https://github.com/servo/rust-layers)", "libc 0.1.10 (registry+https://github.com/rust-lang/crates.io-index)", diff --git a/ports/gonk/Cargo.lock b/ports/gonk/Cargo.lock index 4004400466a..e3a26fa1e21 100644 --- a/ports/gonk/Cargo.lock +++ b/ports/gonk/Cargo.lock @@ -673,7 +673,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" [[package]] name = "glutin" version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" +source = "git+https://github.com/servo/glutin?branch=servo#6525e224e3b5b3ad4f0af8d87460512eb64e8c59" dependencies = [ "android_glue 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)", "cgl 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", @@ -697,6 +697,7 @@ dependencies = [ "wayland-kbd 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)", "wayland-window 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", "winapi 0.2.4 (registry+https://github.com/rust-lang/crates.io-index)", + "x11 2.1.0 (registry+https://github.com/rust-lang/crates.io-index)", "x11-dl 2.0.1 (registry+https://github.com/rust-lang/crates.io-index)", ] @@ -1186,14 +1187,14 @@ dependencies = [ [[package]] name = "offscreen_gl_context" version = "0.1.0" -source = "git+https://github.com/ecoal95/rust-offscreen-rendering-context#a33af19355dfdd0076a3f2836dc66e0fea44bcab" +source = "git+https://github.com/ecoal95/rust-offscreen-rendering-context#05a1ea3a7cb6fac044e2c6133ab334ca522d2b92" dependencies = [ "cgl 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", "core-foundation 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", "euclid 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)", "gl_generator 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", "gleam 0.1.13 (registry+https://github.com/rust-lang/crates.io-index)", - "glutin 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)", + "glutin 0.4.0 (git+https://github.com/servo/glutin?branch=servo)", "khronos_api 0.0.8 (registry+https://github.com/rust-lang/crates.io-index)", "layers 0.1.0 (git+https://github.com/servo/rust-layers)", "libc 0.1.10 (registry+https://github.com/rust-lang/crates.io-index)", From 35473b0009123de2a95d8072d93ff6703008b094 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Emilio=20Cobos=20=C3=81lvarez?= <ecoal95@gmail.com> Date: Sun, 1 Nov 2015 13:37:56 +0100 Subject: [PATCH 45/58] Try to re-enable webgl reftests I can't reproduce locally the failure that produced them, and since the builds that triggered them are deleted for some reason (like http://build.servo.org/builders/linux-dev/builds/419), it could be a good moment to troubleshoot it. If merged closes #7931 --- tests/ref/basic.list | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/tests/ref/basic.list b/tests/ref/basic.list index dd24a6924f1..c5c5cbe46dd 100644 --- a/tests/ref/basic.list +++ b/tests/ref/basic.list @@ -107,13 +107,12 @@ resolution=800x600 == viewport_percentage_vw_vh.html viewport_percentage_vw_vh_a # resolution=600x800 == viewport_percentage_vw_vh.html viewport_percentage_vw_vh_b.html prefs:"layout.viewport.enabled" == viewport_rule.html viewport_rule_ref.html -# https://github.com/servo/servo/issues/7931 -# == webgl-context/clearcolor.html webgl-context/clearcolor_ref.html -# == webgl-context/draw_arrays_simple.html webgl-context/draw_arrays_simple_ref.html -# == webgl-context/tex_image_2d_canvas.html webgl-context/tex_image_2d_canvas_ref.html -# == webgl-context/tex_image_2d_canvas2d.html webgl-context/tex_image_2d_canvas_ref.html -# == webgl-context/tex_image_2d_canvas_no_context.html webgl-context/tex_image_2d_canvas_no_context_ref.html -# == webgl-context/tex_image_2d_simple.html webgl-context/tex_image_2d_simple_ref.html +== webgl-context/clearcolor.html webgl-context/clearcolor_ref.html +== webgl-context/draw_arrays_simple.html webgl-context/draw_arrays_simple_ref.html +== webgl-context/tex_image_2d_canvas.html webgl-context/tex_image_2d_canvas_ref.html +== webgl-context/tex_image_2d_canvas2d.html webgl-context/tex_image_2d_canvas_ref.html +== webgl-context/tex_image_2d_canvas_no_context.html webgl-context/tex_image_2d_canvas_no_context_ref.html +== webgl-context/tex_image_2d_simple.html webgl-context/tex_image_2d_simple_ref.html flaky_macos == white_space_intrinsic_sizes_a.html white_space_intrinsic_sizes_ref.html From 9df375195eb389ae851acac525bc00f10421d36b Mon Sep 17 00:00:00 2001 From: Corey Farwell <coreyf@rwell.org> Date: Sat, 10 Oct 2015 13:44:28 -0400 Subject: [PATCH 46/58] Implement 'labels' attribute on 'labelable elements' --- components/script/dom/htmlbuttonelement.rs | 6 ++ components/script/dom/htmlelement.rs | 44 +++++++++++++- components/script/dom/htmlinputelement.rs | 11 ++++ components/script/dom/htmllabelelement.rs | 2 +- components/script/dom/htmlmeterelement.rs | 11 +++- components/script/dom/htmloutputelement.rs | 7 +++ components/script/dom/htmlprogresselement.rs | 11 +++- components/script/dom/htmlselectelement.rs | 6 ++ components/script/dom/htmltextareaelement.rs | 6 ++ components/script/dom/nodelist.rs | 4 ++ .../dom/webidls/HTMLButtonElement.webidl | 2 +- .../dom/webidls/HTMLInputElement.webidl | 2 +- .../dom/webidls/HTMLMeterElement.webidl | 2 +- .../dom/webidls/HTMLOutputElement.webidl | 2 +- .../dom/webidls/HTMLProgressElement.webidl | 2 +- .../dom/webidls/HTMLSelectElement.webidl | 2 +- .../dom/webidls/HTMLTextAreaElement.webidl | 2 +- .../wpt/metadata/html/dom/interfaces.html.ini | 42 ------------- .../label-attributes.html.ini | 9 --- .../labelable-elements.html.ini | 3 + .../the-label-element/label-attributes.html | 11 +++- .../the-label-element/labelable-elements.html | 60 +++++++++++++++++++ 22 files changed, 184 insertions(+), 63 deletions(-) diff --git a/components/script/dom/htmlbuttonelement.rs b/components/script/dom/htmlbuttonelement.rs index 203f04c0009..7ea783fc68b 100644 --- a/components/script/dom/htmlbuttonelement.rs +++ b/components/script/dom/htmlbuttonelement.rs @@ -17,6 +17,7 @@ use dom::htmlfieldsetelement::HTMLFieldSetElement; use dom::htmlformelement::{FormControl, FormSubmitter}; use dom::htmlformelement::{SubmittedFrom, HTMLFormElement}; use dom::node::{Node, document_from_node, window_from_node}; +use dom::nodelist::NodeList; use dom::validitystate::ValidityState; use dom::virtualmethods::VirtualMethods; use selectors::states::*; @@ -131,6 +132,11 @@ impl HTMLButtonElementMethods for HTMLButtonElement { // https://html.spec.whatwg.org/multipage/#dom-button-value make_setter!(SetValue, "value"); + + // https://html.spec.whatwg.org/multipage/#dom-lfe-labels + fn Labels(&self) -> Root<NodeList> { + self.upcast::<HTMLElement>().labels() + } } impl VirtualMethods for HTMLButtonElement { diff --git a/components/script/dom/htmlelement.rs b/components/script/dom/htmlelement.rs index 6ebf0106099..8d73511c6d5 100644 --- a/components/script/dom/htmlelement.rs +++ b/components/script/dom/htmlelement.rs @@ -4,6 +4,7 @@ use dom::attr::Attr; use dom::attr::AttrValue; +use dom::bindings::codegen::Bindings::ElementBinding::ElementMethods; use dom::bindings::codegen::Bindings::EventHandlerBinding::EventHandlerNonNull; use dom::bindings::codegen::Bindings::HTMLElementBinding; use dom::bindings::codegen::Bindings::HTMLElementBinding::HTMLElementMethods; @@ -12,7 +13,7 @@ use dom::bindings::codegen::Bindings::WindowBinding::WindowMethods; use dom::bindings::codegen::InheritTypes::{ElementTypeId, HTMLElementTypeId, NodeTypeId}; use dom::bindings::conversions::Castable; use dom::bindings::error::{Error, ErrorResult}; -use dom::bindings::js::{JS, MutNullableHeap, Root}; +use dom::bindings::js::{JS, MutNullableHeap, Root, RootedReference}; use dom::bindings::utils::Reflectable; use dom::cssstyledeclaration::{CSSModificationAccess, CSSStyleDeclaration}; use dom::document::Document; @@ -23,8 +24,10 @@ use dom::htmlbodyelement::HTMLBodyElement; use dom::htmlframesetelement::HTMLFrameSetElement; use dom::htmlhtmlelement::HTMLHtmlElement; use dom::htmlinputelement::HTMLInputElement; +use dom::htmllabelelement::HTMLLabelElement; use dom::node::{Node, SEQUENTIALLY_FOCUSABLE}; use dom::node::{document_from_node, window_from_node}; +use dom::nodelist::NodeList; use dom::virtualmethods::VirtualMethods; use msg::constellation_msg::FocusType; use selectors::states::*; @@ -365,6 +368,45 @@ impl HTMLElement { to_camel_case(&raw_name) }).collect() } + + // https://html.spec.whatwg.org/multipage/#dom-lfe-labels + pub fn labels(&self) -> Root<NodeList> { + debug_assert!(self.is_labelable_element()); + + let element = self.upcast::<Element>(); + let window = window_from_node(element); + + // Traverse ancestors for implicitly associated <label> elements + // https://html.spec.whatwg.org/multipage/#the-label-element:attr-label-for-4 + let ancestors = + self.upcast::<Node>() + .ancestors() + .filter_map(Root::downcast::<HTMLElement>) + // If we reach a labelable element, we have a guarantee no ancestors above it + // will be a label for this HTMLElement + .take_while(|elem| !elem.is_labelable_element()) + .filter_map(Root::downcast::<HTMLLabelElement>) + .filter(|elem| !elem.upcast::<Element>().has_attribute(&atom!("for"))) + .filter(|elem| elem.first_labelable_descendant().r() == Some(self)) + .map(Root::upcast::<Node>); + + let id = element.Id(); + let id = match &id as &str { + "" => return NodeList::new_simple_list(window.r(), ancestors), + id => id, + }; + + // Traverse entire tree for <label> elements with `for` attribute matching `id` + let root_element = element.get_root_element(); + let root_node = root_element.upcast::<Node>(); + let children = root_node.traverse_preorder() + .filter_map(Root::downcast::<Element>) + .filter(|elem| elem.is::<HTMLLabelElement>()) + .filter(|elem| elem.get_string_attribute(&atom!("for")) == id) + .map(Root::upcast::<Node>); + + NodeList::new_simple_list(window.r(), children.chain(ancestors)) + } } impl VirtualMethods for HTMLElement { diff --git a/components/script/dom/htmlinputelement.rs b/components/script/dom/htmlinputelement.rs index 1adfc56b304..fe75140558f 100644 --- a/components/script/dom/htmlinputelement.rs +++ b/components/script/dom/htmlinputelement.rs @@ -25,6 +25,7 @@ use dom::htmlformelement::{ResetFrom, SubmittedFrom}; use dom::keyboardevent::KeyboardEvent; use dom::node::{Node, NodeDamage}; use dom::node::{document_from_node, window_from_node}; +use dom::nodelist::NodeList; use dom::virtualmethods::VirtualMethods; use msg::constellation_msg::ConstellationChan; use selectors::states::*; @@ -333,6 +334,16 @@ impl HTMLInputElementMethods for HTMLInputElement { fn SetIndeterminate(&self, val: bool) { self.upcast::<Element>().set_state(IN_INDETERMINATE_STATE, val) } + + // https://html.spec.whatwg.org/multipage/#dom-lfe-labels + fn Labels(&self) -> Root<NodeList> { + if self.Type() == "hidden" { + let window = window_from_node(self); + NodeList::empty(&window) + } else { + self.upcast::<HTMLElement>().labels() + } + } } diff --git a/components/script/dom/htmllabelelement.rs b/components/script/dom/htmllabelelement.rs index bcda8df24cc..448e5075ba5 100644 --- a/components/script/dom/htmllabelelement.rs +++ b/components/script/dom/htmllabelelement.rs @@ -86,7 +86,7 @@ impl VirtualMethods for HTMLLabelElement { } impl HTMLLabelElement { - fn first_labelable_descendant(&self) -> Option<Root<HTMLElement>> { + pub fn first_labelable_descendant(&self) -> Option<Root<HTMLElement>> { self.upcast::<Node>() .traverse_preorder() .filter_map(Root::downcast::<HTMLElement>) diff --git a/components/script/dom/htmlmeterelement.rs b/components/script/dom/htmlmeterelement.rs index cfe1a4eb5d2..74b48434339 100644 --- a/components/script/dom/htmlmeterelement.rs +++ b/components/script/dom/htmlmeterelement.rs @@ -2,11 +2,13 @@ * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ -use dom::bindings::codegen::Bindings::HTMLMeterElementBinding; +use dom::bindings::codegen::Bindings::HTMLMeterElementBinding::{self, HTMLMeterElementMethods}; +use dom::bindings::conversions::Castable; use dom::bindings::js::Root; use dom::document::Document; use dom::htmlelement::HTMLElement; use dom::node::Node; +use dom::nodelist::NodeList; use util::str::DOMString; #[dom_struct] @@ -31,3 +33,10 @@ impl HTMLMeterElement { Node::reflect_node(box element, document, HTMLMeterElementBinding::Wrap) } } + +impl HTMLMeterElementMethods for HTMLMeterElement { + // https://html.spec.whatwg.org/multipage/#dom-lfe-labels + fn Labels(&self) -> Root<NodeList> { + self.upcast::<HTMLElement>().labels() + } +} diff --git a/components/script/dom/htmloutputelement.rs b/components/script/dom/htmloutputelement.rs index 26c5b9c6bae..937fcea3919 100644 --- a/components/script/dom/htmloutputelement.rs +++ b/components/script/dom/htmloutputelement.rs @@ -4,11 +4,13 @@ use dom::bindings::codegen::Bindings::HTMLOutputElementBinding; use dom::bindings::codegen::Bindings::HTMLOutputElementBinding::HTMLOutputElementMethods; +use dom::bindings::conversions::Castable; use dom::bindings::js::Root; use dom::document::Document; use dom::htmlelement::HTMLElement; use dom::htmlformelement::{FormControl, HTMLFormElement}; use dom::node::{Node, window_from_node}; +use dom::nodelist::NodeList; use dom::validitystate::ValidityState; use util::str::DOMString; @@ -47,6 +49,11 @@ impl HTMLOutputElementMethods for HTMLOutputElement { fn GetForm(&self) -> Option<Root<HTMLFormElement>> { self.form_owner() } + + // https://html.spec.whatwg.org/multipage/#dom-lfe-labels + fn Labels(&self) -> Root<NodeList> { + self.upcast::<HTMLElement>().labels() + } } impl FormControl for HTMLOutputElement {} diff --git a/components/script/dom/htmlprogresselement.rs b/components/script/dom/htmlprogresselement.rs index 7bee428c8f4..669f25942b6 100644 --- a/components/script/dom/htmlprogresselement.rs +++ b/components/script/dom/htmlprogresselement.rs @@ -2,11 +2,13 @@ * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ -use dom::bindings::codegen::Bindings::HTMLProgressElementBinding; +use dom::bindings::codegen::Bindings::HTMLProgressElementBinding::{self, HTMLProgressElementMethods}; +use dom::bindings::conversions::Castable; use dom::bindings::js::Root; use dom::document::Document; use dom::htmlelement::HTMLElement; use dom::node::Node; +use dom::nodelist::NodeList; use util::str::DOMString; #[dom_struct] @@ -32,3 +34,10 @@ impl HTMLProgressElement { Node::reflect_node(box element, document, HTMLProgressElementBinding::Wrap) } } + +impl HTMLProgressElementMethods for HTMLProgressElement { + // https://html.spec.whatwg.org/multipage/#dom-lfe-labels + fn Labels(&self) -> Root<NodeList> { + self.upcast::<HTMLElement>().labels() + } +} diff --git a/components/script/dom/htmlselectelement.rs b/components/script/dom/htmlselectelement.rs index c6e90e12c84..fc2c12fe9bd 100644 --- a/components/script/dom/htmlselectelement.rs +++ b/components/script/dom/htmlselectelement.rs @@ -17,6 +17,7 @@ use dom::htmlfieldsetelement::HTMLFieldSetElement; use dom::htmlformelement::{FormControl, HTMLFormElement}; use dom::htmloptionelement::HTMLOptionElement; use dom::node::{Node, window_from_node}; +use dom::nodelist::NodeList; use dom::validitystate::ValidityState; use dom::virtualmethods::VirtualMethods; use selectors::states::*; @@ -158,6 +159,11 @@ impl HTMLSelectElementMethods for HTMLSelectElement { "select-one".to_owned() } } + + // https://html.spec.whatwg.org/multipage/#dom-lfe-labels + fn Labels(&self) -> Root<NodeList> { + self.upcast::<HTMLElement>().labels() + } } impl VirtualMethods for HTMLSelectElement { diff --git a/components/script/dom/htmltextareaelement.rs b/components/script/dom/htmltextareaelement.rs index b057204245f..b75a54a1026 100644 --- a/components/script/dom/htmltextareaelement.rs +++ b/components/script/dom/htmltextareaelement.rs @@ -22,6 +22,7 @@ use dom::htmlformelement::{FormControl, HTMLFormElement}; use dom::keyboardevent::KeyboardEvent; use dom::node::{ChildrenMutation, Node, NodeDamage}; use dom::node::{document_from_node, window_from_node}; +use dom::nodelist::NodeList; use dom::virtualmethods::VirtualMethods; use msg::constellation_msg::ConstellationChan; use script_task::ScriptTaskEventCategory::InputEvent; @@ -205,6 +206,11 @@ impl HTMLTextAreaElementMethods for HTMLTextAreaElement { self.force_relayout(); } + + // https://html.spec.whatwg.org/multipage/#dom-lfe-labels + fn Labels(&self) -> Root<NodeList> { + self.upcast::<HTMLElement>().labels() + } } diff --git a/components/script/dom/nodelist.rs b/components/script/dom/nodelist.rs index 68e3b7ee424..f059cf6bbb6 100644 --- a/components/script/dom/nodelist.rs +++ b/components/script/dom/nodelist.rs @@ -51,6 +51,10 @@ impl NodeList { pub fn new_child_list(window: &Window, node: &Node) -> Root<NodeList> { NodeList::new(window, NodeListType::Children(ChildrenList::new(node))) } + + pub fn empty(window: &Window) -> Root<NodeList> { + NodeList::new(window, NodeListType::Simple(vec![])) + } } impl NodeListMethods for NodeList { diff --git a/components/script/dom/webidls/HTMLButtonElement.webidl b/components/script/dom/webidls/HTMLButtonElement.webidl index 0edba3293d4..56ee8de8d74 100644 --- a/components/script/dom/webidls/HTMLButtonElement.webidl +++ b/components/script/dom/webidls/HTMLButtonElement.webidl @@ -25,5 +25,5 @@ interface HTMLButtonElement : HTMLElement { //boolean reportValidity(); //void setCustomValidity(DOMString error); - //readonly attribute NodeList labels; + readonly attribute NodeList labels; }; diff --git a/components/script/dom/webidls/HTMLInputElement.webidl b/components/script/dom/webidls/HTMLInputElement.webidl index 0628f386ea6..a5472818afe 100644 --- a/components/script/dom/webidls/HTMLInputElement.webidl +++ b/components/script/dom/webidls/HTMLInputElement.webidl @@ -57,7 +57,7 @@ interface HTMLInputElement : HTMLElement { //boolean reportValidity(); //void setCustomValidity(DOMString error); - //readonly attribute NodeList labels; + readonly attribute NodeList labels; //void select(); // attribute unsigned long selectionStart; diff --git a/components/script/dom/webidls/HTMLMeterElement.webidl b/components/script/dom/webidls/HTMLMeterElement.webidl index 2e174381fcb..29f6ed89205 100644 --- a/components/script/dom/webidls/HTMLMeterElement.webidl +++ b/components/script/dom/webidls/HTMLMeterElement.webidl @@ -11,5 +11,5 @@ interface HTMLMeterElement : HTMLElement { // attribute double low; // attribute double high; // attribute double optimum; - //readonly attribute NodeList labels; + readonly attribute NodeList labels; }; diff --git a/components/script/dom/webidls/HTMLOutputElement.webidl b/components/script/dom/webidls/HTMLOutputElement.webidl index 86ca8ecf86b..aa85afd7b8d 100644 --- a/components/script/dom/webidls/HTMLOutputElement.webidl +++ b/components/script/dom/webidls/HTMLOutputElement.webidl @@ -20,5 +20,5 @@ interface HTMLOutputElement : HTMLElement { //boolean reportValidity(); //void setCustomValidity(DOMString error); - //readonly attribute NodeList labels; + readonly attribute NodeList labels; }; diff --git a/components/script/dom/webidls/HTMLProgressElement.webidl b/components/script/dom/webidls/HTMLProgressElement.webidl index 46ffa6b83f2..3b4b0f4032f 100644 --- a/components/script/dom/webidls/HTMLProgressElement.webidl +++ b/components/script/dom/webidls/HTMLProgressElement.webidl @@ -8,5 +8,5 @@ interface HTMLProgressElement : HTMLElement { // attribute double value; // attribute double max; //readonly attribute double position; - //readonly attribute NodeList labels; + readonly attribute NodeList labels; }; diff --git a/components/script/dom/webidls/HTMLSelectElement.webidl b/components/script/dom/webidls/HTMLSelectElement.webidl index fb6aed7e40c..599cb9f74de 100644 --- a/components/script/dom/webidls/HTMLSelectElement.webidl +++ b/components/script/dom/webidls/HTMLSelectElement.webidl @@ -36,5 +36,5 @@ interface HTMLSelectElement : HTMLElement { //boolean reportValidity(); //void setCustomValidity(DOMString error); - //readonly attribute NodeList labels; + readonly attribute NodeList labels; }; diff --git a/components/script/dom/webidls/HTMLTextAreaElement.webidl b/components/script/dom/webidls/HTMLTextAreaElement.webidl index d7a13d9c959..797a537d0cc 100644 --- a/components/script/dom/webidls/HTMLTextAreaElement.webidl +++ b/components/script/dom/webidls/HTMLTextAreaElement.webidl @@ -35,7 +35,7 @@ interface HTMLTextAreaElement : HTMLElement { //boolean reportValidity(); //void setCustomValidity(DOMString error); - //readonly attribute NodeList labels; + readonly attribute NodeList labels; //void select(); // attribute unsigned long selectionStart; diff --git a/tests/wpt/metadata/html/dom/interfaces.html.ini b/tests/wpt/metadata/html/dom/interfaces.html.ini index a449fbbb70f..cd95e91d7d6 100644 --- a/tests/wpt/metadata/html/dom/interfaces.html.ini +++ b/tests/wpt/metadata/html/dom/interfaces.html.ini @@ -4968,9 +4968,6 @@ [HTMLInputElement interface: operation setCustomValidity(DOMString)] expected: FAIL - [HTMLInputElement interface: attribute labels] - expected: FAIL - [HTMLInputElement interface: operation select()] expected: FAIL @@ -5103,9 +5100,6 @@ [HTMLInputElement interface: calling setCustomValidity(DOMString) on document.createElement("input") with too few arguments must throw TypeError] expected: FAIL - [HTMLInputElement interface: document.createElement("input") must inherit property "labels" with the proper type (48)] - expected: FAIL - [HTMLInputElement interface: document.createElement("input") must inherit property "select" with the proper type (49)] expected: FAIL @@ -5169,9 +5163,6 @@ [HTMLButtonElement interface: operation setCustomValidity(DOMString)] expected: FAIL - [HTMLButtonElement interface: attribute labels] - expected: FAIL - [HTMLButtonElement interface: document.createElement("button") must inherit property "autofocus" with the proper type (0)] expected: FAIL @@ -5199,9 +5190,6 @@ [HTMLButtonElement interface: calling setCustomValidity(DOMString) on document.createElement("button") with too few arguments must throw TypeError] expected: FAIL - [HTMLButtonElement interface: document.createElement("button") must inherit property "labels" with the proper type (18)] - expected: FAIL - [HTMLSelectElement interface: existence and properties of interface object] expected: FAIL @@ -5256,9 +5244,6 @@ [HTMLSelectElement interface: operation setCustomValidity(DOMString)] expected: FAIL - [HTMLSelectElement interface: attribute labels] - expected: FAIL - [HTMLSelectElement interface: document.createElement("select") must inherit property "autocomplete" with the proper type (0)] expected: FAIL @@ -5313,9 +5298,6 @@ [HTMLSelectElement interface: calling setCustomValidity(DOMString) on document.createElement("select") with too few arguments must throw TypeError] expected: FAIL - [HTMLSelectElement interface: document.createElement("select") must inherit property "labels" with the proper type (26)] - expected: FAIL - [HTMLDataListElement interface: existence and properties of interface object] expected: FAIL @@ -5385,9 +5367,6 @@ [HTMLTextAreaElement interface: operation setCustomValidity(DOMString)] expected: FAIL - [HTMLTextAreaElement interface: attribute labels] - expected: FAIL - [HTMLTextAreaElement interface: operation select()] expected: FAIL @@ -5451,9 +5430,6 @@ [HTMLTextAreaElement interface: calling setCustomValidity(DOMString) on document.createElement("textarea") with too few arguments must throw TypeError] expected: FAIL - [HTMLTextAreaElement interface: document.createElement("textarea") must inherit property "labels" with the proper type (25)] - expected: FAIL - [HTMLTextAreaElement interface: document.createElement("textarea") must inherit property "select" with the proper type (26)] expected: FAIL @@ -5622,9 +5598,6 @@ [HTMLOutputElement interface: operation setCustomValidity(DOMString)] expected: FAIL - [HTMLOutputElement interface: attribute labels] - expected: FAIL - [HTMLOutputElement interface: document.createElement("output") must inherit property "htmlFor" with the proper type (0)] expected: FAIL @@ -5658,9 +5631,6 @@ [HTMLOutputElement interface: calling setCustomValidity(DOMString) on document.createElement("output") with too few arguments must throw TypeError] expected: FAIL - [HTMLOutputElement interface: document.createElement("output") must inherit property "labels" with the proper type (12)] - expected: FAIL - [HTMLProgressElement interface: existence and properties of interface object] expected: FAIL @@ -5673,9 +5643,6 @@ [HTMLProgressElement interface: attribute position] expected: FAIL - [HTMLProgressElement interface: attribute labels] - expected: FAIL - [HTMLProgressElement interface: document.createElement("progress") must inherit property "value" with the proper type (0)] expected: FAIL @@ -5685,9 +5652,6 @@ [HTMLProgressElement interface: document.createElement("progress") must inherit property "position" with the proper type (2)] expected: FAIL - [HTMLProgressElement interface: document.createElement("progress") must inherit property "labels" with the proper type (3)] - expected: FAIL - [HTMLMeterElement interface: existence and properties of interface object] expected: FAIL @@ -5709,9 +5673,6 @@ [HTMLMeterElement interface: attribute optimum] expected: FAIL - [HTMLMeterElement interface: attribute labels] - expected: FAIL - [HTMLMeterElement interface: document.createElement("meter") must inherit property "value" with the proper type (0)] expected: FAIL @@ -5730,9 +5691,6 @@ [HTMLMeterElement interface: document.createElement("meter") must inherit property "optimum" with the proper type (5)] expected: FAIL - [HTMLMeterElement interface: document.createElement("meter") must inherit property "labels" with the proper type (6)] - expected: FAIL - [HTMLFieldSetElement interface: existence and properties of interface object] expected: FAIL diff --git a/tests/wpt/metadata/html/semantics/forms/the-label-element/label-attributes.html.ini b/tests/wpt/metadata/html/semantics/forms/the-label-element/label-attributes.html.ini index 655c489ce75..9caf6fc4cf7 100644 --- a/tests/wpt/metadata/html/semantics/forms/the-label-element/label-attributes.html.ini +++ b/tests/wpt/metadata/html/semantics/forms/the-label-element/label-attributes.html.ini @@ -3,12 +3,3 @@ [A non-control follows by a control with same ID.] expected: FAIL - [A form control has multiple labels.] - expected: FAIL - - [A form control has no label 1.] - expected: FAIL - - [A form control has no label 2.] - expected: FAIL - diff --git a/tests/wpt/metadata/html/semantics/forms/the-label-element/labelable-elements.html.ini b/tests/wpt/metadata/html/semantics/forms/the-label-element/labelable-elements.html.ini index be4d7c998ba..c7fb71a9e53 100644 --- a/tests/wpt/metadata/html/semantics/forms/the-label-element/labelable-elements.html.ini +++ b/tests/wpt/metadata/html/semantics/forms/the-label-element/labelable-elements.html.ini @@ -3,3 +3,6 @@ [Check if the keygen element is a labelable element] expected: FAIL + [Check if the keygen element can access 'labels'] + expected: FAIL + diff --git a/tests/wpt/web-platform-tests/html/semantics/forms/the-label-element/label-attributes.html b/tests/wpt/web-platform-tests/html/semantics/forms/the-label-element/label-attributes.html index 58f440258c1..86a6cf8cf95 100644 --- a/tests/wpt/web-platform-tests/html/semantics/forms/the-label-element/label-attributes.html +++ b/tests/wpt/web-platform-tests/html/semantics/forms/the-label-element/label-attributes.html @@ -53,6 +53,7 @@ "A label element not in a document should not label an element in a document."); document.body.appendChild(label); assert_equals(label.control, document.getElementById("test1")); + label.remove(); }, "A label element not in a document can not label any element in the document."); test(function () { @@ -63,6 +64,7 @@ document.getElementById("lbl1").insertBefore(input, document.getElementById("test2")); assert_equals(document.getElementById("lbl1").control, input, "The first labelable descendant of a label element in tree order should be its labeled control."); + input.remove(); }, "The labeled control for a label element that has no 'for' attribute is the first labelable element which is a descendant of that label element."); test(function () { @@ -95,12 +97,19 @@ document.getElementById("fm").insertBefore(newLabel, document.getElementById("lbl0")); assert_array_equals(document.getElementById("test7").labels, [newLabel, document.getElementById("lbl5"), document.getElementById("lbl6")], "The labels for a form control should be returned in tree order."); + newLabel.remove(); }, "A form control has multiple labels."); + test(function () { + var labels = document.getElementById("test3").labels; + assert_true(labels instanceof NodeList, "A form control's 'labels' property should be an instance of a NodeList."); + assert_equals(labels.length, 1, "The form control has an ancestor with no explicit associated label, and is the first labelable descendant."); + }, "A form control has an implicit label."); + test(function () { var labels = document.getElementById("test4").labels; assert_true(labels instanceof NodeList, "A form control's 'labels' property should be an instance of a NodeList."); - assert_equals(labels.length, 0, "The number of labels should be 0 if the associated form control isn't referenced by any <label>."); + assert_equals(labels.length, 0, "The form control has an ancestor with no explicit associated label, but is *not* the first labelable descendant"); }, "A form control has no label 1."); test(function () { diff --git a/tests/wpt/web-platform-tests/html/semantics/forms/the-label-element/labelable-elements.html b/tests/wpt/web-platform-tests/html/semantics/forms/the-label-element/labelable-elements.html index 38706cb8c75..7bbb0b395e8 100644 --- a/tests/wpt/web-platform-tests/html/semantics/forms/the-label-element/labelable-elements.html +++ b/tests/wpt/web-platform-tests/html/semantics/forms/the-label-element/labelable-elements.html @@ -36,61 +36,121 @@ </form> <script> +function testLabelsAttr(formElementId, labelElementId, hasLabels) { + var elem = document.getElementById(formElementId); + if (labelElementId) { + assert_equals(elem.labels.length, 1); + assert_equals(elem.labels[0].id, labelElementId); + } else { + assert_equals(elem.labels.length, 0); + } +} test(function() { assert_equals(document.getElementById("lbl0").control.id, "testoutput", "An output element should be labelable."); }, "Check if the output element is a labelable element"); +test(function() { + testLabelsAttr("testoutput", "lbl0"); +}, "Check if the output element can access 'labels'"); + test(function() { assert_equals(document.getElementById("lbl1").control.id, "testprogress", "A progress element should be labelable."); }, "Check if the progress element is a labelable element"); +test(function() { + testLabelsAttr("testprogress", "lbl1"); +}, "Check if the progress element can access 'labels'"); + test(function() { assert_equals(document.getElementById("lbl2").control.id, "testselect", "A select element should be labelable."); }, "Check if the select element is a labelable element"); +test(function() { + testLabelsAttr("testselect", "lbl2"); +}, "Check if the select element can access 'labels'"); + test(function() { assert_equals(document.getElementById("lbl3").control.id, "testarea", "A textarea element should be labelable."); }, "Check if the textarea element is a labelable form-element"); +test(function() { + testLabelsAttr("testarea", "lbl3"); +}, "Check if the textarea element can access 'labels'"); + test(function() { assert_equals(document.getElementById("lbl4").control.id, "testButton", "A button element should be labelable."); }, "Check if the button element is a labelable element"); +test(function() { + testLabelsAttr("testButton", "lbl4"); +}, "Check if the button element can access 'labels'"); + test(function() { assert_equals(document.getElementById("lbl5").control, null, "An input element in hidden state should not be labelable."); }, "Check if the hidden input element is not a labelable element."); +test(function() { + testLabelsAttr("testHidden", null); +}, "Check if the hidden input element can access 'labels'"); + test(function() { assert_equals(document.getElementById("lbl6").control.id, "testRadio", "An input element in radio state should be labelable."); }, "Check if the input element in radio state is a labelable element"); +test(function() { + testLabelsAttr("testRadio", "lbl6"); +}, "Check if the input element in radio state can access 'labels'"); + test(function() { assert_equals(document.getElementById("lbl7").control.id, "testkeygen", "A keygen element should be labelable."); }, "Check if the keygen element is a labelable element"); +test(function() { + testLabelsAttr("testkeygen", "lbl7"); +}, "Check if the keygen element can access 'labels'"); + test(function() { assert_equals(document.getElementById("lbl8").control.id, "testmeter", "A meter element should be labelable."); }, "Check if the meter element is a labelable element"); +test(function() { + testLabelsAttr("testmeter", "lbl8"); +}, "Check if the meter element can access 'labels'"); + test(function() { assert_not_equals(document.getElementById("lbl9").control, document.getElementById("testfieldset")); assert_equals(document.getElementById("lbl9").control, null, "A fieldset element should not be labelable."); }, "Check if the fieldset element is not a labelable element"); +test(function() { + assert_equals(document.getElementById("testfieldset").labels, undefined); +}, "Check if the fieldset element can access 'labels'"); + test(function() { assert_not_equals(document.getElementById("lbl9").control, document.getElementById("testlabel")); assert_equals(document.getElementById("lbl10").control, null, "A label element should not be labelable."); }, "Check if the label element is not a labelable element"); +test(function() { + assert_equals(document.getElementById("testlabel").labels, undefined); +}, "Check if the label element can access 'labels'"); + test(function() { assert_not_equals(document.getElementById("lbl9").control, document.getElementById("testobject")); assert_equals(document.getElementById("lbl11").control, null, "An object element should not be labelable."); }, "Check if the object element is not a labelable element"); +test(function() { + assert_equals(document.getElementById("testobject").labels, undefined); +}, "Check if the object element can access 'labels'"); + test(function() { assert_not_equals(document.getElementById("lbl9").control, document.getElementById("testimg")); assert_equals(document.getElementById("lbl12").control, null, "An img element should not be labelable."); }, "Check if the img element is not a labelable element"); +test(function() { + assert_equals(document.getElementById("lbl9").labels, undefined); +}, "Check if the img element can access 'labels'"); </script> From 0070adb71ff4b41f1661a88242372f0572525525 Mon Sep 17 00:00:00 2001 From: David Zbarsky <dzbarsky@gmail.com> Date: Sun, 25 Oct 2015 10:29:33 -0700 Subject: [PATCH 47/58] Use an Atom for Event.type --- components/script/dom/event.rs | 14 ++++++++---- components/script/dom/eventdispatcher.rs | 2 +- components/script/dom/eventtarget.rs | 24 ++++++++++---------- components/script/dom/htmlinputelement.rs | 4 ++-- components/script/dom/htmltextareaelement.rs | 4 ++-- 5 files changed, 27 insertions(+), 21 deletions(-) diff --git a/components/script/dom/event.rs b/components/script/dom/event.rs index c56d44e15c3..0aa57146a8e 100644 --- a/components/script/dom/event.rs +++ b/components/script/dom/event.rs @@ -13,6 +13,7 @@ use dom::eventtarget::EventTarget; use std::borrow::ToOwned; use std::cell::Cell; use std::default::Default; +use string_cache::Atom; use time; use util::str::DOMString; @@ -43,7 +44,7 @@ pub struct Event { reflector_: Reflector, current_target: MutNullableHeap<JS<EventTarget>>, target: MutNullableHeap<JS<EventTarget>>, - type_: DOMRefCell<DOMString>, + type_: DOMRefCell<Atom>, phase: Cell<EventPhase>, canceled: Cell<bool>, stop_propagation: Cell<bool>, @@ -62,7 +63,7 @@ impl Event { reflector_: Reflector::new(), current_target: Default::default(), target: Default::default(), - type_: DOMRefCell::new("".to_owned()), + type_: DOMRefCell::new(atom!("")), phase: Cell::new(EventPhase::None), canceled: Cell::new(false), stop_propagation: Cell::new(false), @@ -153,6 +154,11 @@ impl Event { pub fn initialized(&self) -> bool { self.initialized.get() } + + #[inline] + pub fn type_(&self) -> Atom { + self.type_.borrow().clone() + } } impl EventMethods for Event { @@ -163,7 +169,7 @@ impl EventMethods for Event { // https://dom.spec.whatwg.org/#dom-event-type fn Type(&self) -> DOMString { - self.type_.borrow().clone() + (*self.type_()).to_owned() } // https://dom.spec.whatwg.org/#dom-event-target @@ -229,7 +235,7 @@ impl EventMethods for Event { self.canceled.set(false); self.trusted.set(false); self.target.set(None); - *self.type_.borrow_mut() = type_; + *self.type_.borrow_mut() = Atom::from_slice(&type_); self.bubbles.set(bubbles); self.cancelable.set(cancelable); } diff --git a/components/script/dom/eventdispatcher.rs b/components/script/dom/eventdispatcher.rs index 2b0e1942843..503ddc147e3 100644 --- a/components/script/dom/eventdispatcher.rs +++ b/components/script/dom/eventdispatcher.rs @@ -60,7 +60,7 @@ fn dispatch_to_listeners(event: &Event, target: &EventTarget, chain: &[&EventTar _ => None, }; - let type_ = event.Type(); + let type_ = event.type_(); /* capturing */ event.set_phase(EventPhase::Capturing); diff --git a/components/script/dom/eventtarget.rs b/components/script/dom/eventtarget.rs index 179e82917aa..9f62cb5b139 100644 --- a/components/script/dom/eventtarget.rs +++ b/components/script/dom/eventtarget.rs @@ -19,7 +19,6 @@ use js::jsapi::{HandleObject, JSContext, RootedFunction}; use js::jsapi::{JSAutoCompartment, JSAutoRequest}; use js::rust::{AutoObjectVectorWrapper, CompileOptionsWrapper}; use libc::{c_char, size_t}; -use std::borrow::ToOwned; use std::collections::HashMap; use std::collections::hash_map::Entry::{Occupied, Vacant}; use std::collections::hash_state::DefaultState; @@ -27,6 +26,7 @@ use std::default::Default; use std::ffi::CString; use std::rc::Rc; use std::{intrinsics, ptr}; +use string_cache::Atom; use url::Url; use util::mem::HeapSizeOf; use util::str::DOMString; @@ -114,7 +114,7 @@ pub struct EventListenerEntry { #[dom_struct] pub struct EventTarget { reflector_: Reflector, - handlers: DOMRefCell<HashMap<DOMString, Vec<EventListenerEntry>, DefaultState<FnvHasher>>>, + handlers: DOMRefCell<HashMap<Atom, Vec<EventListenerEntry>, DefaultState<FnvHasher>>>, } impl EventTarget { @@ -125,13 +125,13 @@ impl EventTarget { } } - pub fn get_listeners(&self, type_: &str) -> Option<Vec<EventListenerType>> { + pub fn get_listeners(&self, type_: &Atom) -> Option<Vec<EventListenerType>> { self.handlers.borrow().get(type_).map(|listeners| { listeners.iter().map(|entry| entry.listener.clone()).collect() }) } - pub fn get_listeners_for(&self, type_: &str, desired_phase: ListenerPhase) + pub fn get_listeners_for(&self, type_: &Atom, desired_phase: ListenerPhase) -> Option<Vec<EventListenerType>> { self.handlers.borrow().get(type_).map(|listeners| { let filtered = listeners.iter().filter(|entry| entry.phase == desired_phase); @@ -150,8 +150,8 @@ impl EventTarget { } pub fn set_inline_event_listener(&self, - ty: DOMString, - listener: Option<Rc<EventHandler>>) { + ty: Atom, + listener: Option<Rc<EventHandler>>) { let mut handlers = self.handlers.borrow_mut(); let entries = match handlers.entry(ty) { Occupied(entry) => entry.into_mut(), @@ -185,9 +185,9 @@ impl EventTarget { } } - pub fn get_inline_event_listener(&self, ty: DOMString) -> Option<Rc<EventHandler>> { + pub fn get_inline_event_listener(&self, ty: &Atom) -> Option<Rc<EventHandler>> { let handlers = self.handlers.borrow(); - let entries = handlers.get(&ty); + let entries = handlers.get(ty); entries.and_then(|entries| entries.iter().filter_map(|entry| { match entry.listener { EventListenerType::Inline(ref handler) => Some(handler.clone()), @@ -243,11 +243,11 @@ impl EventTarget { { let event_listener = listener.map(|listener| EventHandlerNonNull::new(listener.callback())); - self.set_inline_event_listener(ty.to_owned(), event_listener); + self.set_inline_event_listener(Atom::from_slice(ty), event_listener); } pub fn get_event_handler_common<T: CallbackContainer>(&self, ty: &str) -> Option<Rc<T>> { - let listener = self.get_inline_event_listener(ty.to_owned()); + let listener = self.get_inline_event_listener(&Atom::from_slice(ty)); listener.map(|listener| CallbackContainer::new(listener.parent.callback())) } @@ -265,7 +265,7 @@ impl EventTargetMethods for EventTarget { match listener { Some(listener) => { let mut handlers = self.handlers.borrow_mut(); - let entry = match handlers.entry(ty) { + let entry = match handlers.entry(Atom::from_slice(&ty)) { Occupied(entry) => entry.into_mut(), Vacant(entry) => entry.insert(vec!()), }; @@ -291,7 +291,7 @@ impl EventTargetMethods for EventTarget { match listener { Some(ref listener) => { let mut handlers = self.handlers.borrow_mut(); - let entry = handlers.get_mut(&ty); + let entry = handlers.get_mut(&Atom::from_slice(&ty)); for entry in entry { let phase = if capture { ListenerPhase::Capturing } else { ListenerPhase::Bubbling }; let old_entry = EventListenerEntry { diff --git a/components/script/dom/htmlinputelement.rs b/components/script/dom/htmlinputelement.rs index 1adfc56b304..9e5874c1a18 100644 --- a/components/script/dom/htmlinputelement.rs +++ b/components/script/dom/htmlinputelement.rs @@ -607,7 +607,7 @@ impl VirtualMethods for HTMLInputElement { s.handle_event(event); } - if &*event.Type() == "click" && !event.DefaultPrevented() { + if event.type_() == atom!("click") && !event.DefaultPrevented() { match self.input_type.get() { InputType::InputRadio => self.update_checked_state(true, true), _ => {} @@ -619,7 +619,7 @@ impl VirtualMethods for HTMLInputElement { //TODO: set the editing position for text inputs document_from_node(self).request_focus(self.upcast()); - } else if &*event.Type() == "keydown" && !event.DefaultPrevented() && + } else if event.type_() == atom!("keydown") && !event.DefaultPrevented() && (self.input_type.get() == InputType::InputText || self.input_type.get() == InputType::InputPassword) { if let Some(keyevent) = event.downcast::<KeyboardEvent>() { diff --git a/components/script/dom/htmltextareaelement.rs b/components/script/dom/htmltextareaelement.rs index b057204245f..3b16e90f7ca 100644 --- a/components/script/dom/htmltextareaelement.rs +++ b/components/script/dom/htmltextareaelement.rs @@ -323,11 +323,11 @@ impl VirtualMethods for HTMLTextAreaElement { s.handle_event(event); } - if &*event.Type() == "click" && !event.DefaultPrevented() { + if event.type_() == atom!("click") && !event.DefaultPrevented() { //TODO: set the editing position for text inputs document_from_node(self).request_focus(self.upcast()); - } else if &*event.Type() == "keydown" && !event.DefaultPrevented() { + } else if event.type_() == atom!("keydown") && !event.DefaultPrevented() { if let Some(kevent) = event.downcast::<KeyboardEvent>() { match self.textinput.borrow_mut().handle_keydown(kevent) { KeyReaction::TriggerDefaultAction => (), From 938a05428aede1ddf65258d2d259baba9a5866b5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Emilio=20Cobos=20=C3=81lvarez?= <ecoal95@gmail.com> Date: Sun, 1 Nov 2015 14:47:46 +0100 Subject: [PATCH 48/58] servo/main: Load gl symbols in headless mode This allows running WebGL reftests in wpt. --- components/servo/Cargo.lock | 1 + components/servo/Cargo.toml | 3 +++ components/servo/main.rs | 16 ++++++++++++++++ 3 files changed, 20 insertions(+) diff --git a/components/servo/Cargo.lock b/components/servo/Cargo.lock index 446af0a8638..56143d3776d 100644 --- a/components/servo/Cargo.lock +++ b/components/servo/Cargo.lock @@ -24,6 +24,7 @@ dependencies = [ "net 0.0.1", "net_tests 0.0.1", "net_traits 0.0.1", + "offscreen_gl_context 0.1.0 (git+https://github.com/ecoal95/rust-offscreen-rendering-context)", "profile 0.0.1", "profile_traits 0.0.1", "script 0.0.1", diff --git a/components/servo/Cargo.toml b/components/servo/Cargo.toml index db611072946..d1bb7634689 100644 --- a/components/servo/Cargo.toml +++ b/components/servo/Cargo.toml @@ -133,6 +133,9 @@ features = ["plugins"] [dependencies.gleam] version = "0.1" +[dependencies.offscreen_gl_context] +git = "https://github.com/ecoal95/rust-offscreen-rendering-context" + [dependencies] env_logger = "0.3" time = "0.1.12" diff --git a/components/servo/main.rs b/components/servo/main.rs index b339babb972..6d830e7be73 100644 --- a/components/servo/main.rs +++ b/components/servo/main.rs @@ -29,12 +29,25 @@ extern crate log; extern crate servo; extern crate time; +extern crate gleam; +extern crate offscreen_gl_context; + +use gleam::gl; +use offscreen_gl_context::GLContext; use servo::Browser; use servo::compositing::windowing::WindowEvent; use servo::net_traits::hosts; use servo::util::opts; use std::rc::Rc; +#[cfg(not(target_os = "android"))] +fn load_gl_when_headless() { + gl::load_with(|addr| GLContext::get_proc_address(addr) as *const _); +} + +#[cfg(target_os = "android")] +fn load_gl_when_headless() {} + fn main() { env_logger::init().unwrap(); @@ -47,6 +60,9 @@ fn main() { hosts::global_init(); let window = if opts::get().headless { + // Load gl functions even when in headless mode, + // to avoid crashing with webgl + load_gl_when_headless(); None } else { Some(app::create_window(std::ptr::null_mut())) From 12d1464220b0b820a5ebdc6f6ab8912ca388e875 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Emilio=20Cobos=20=C3=81lvarez?= <ecoal95@gmail.com> Date: Sun, 1 Nov 2015 14:48:57 +0100 Subject: [PATCH 49/58] Move WebGL reftests to wpt/mozilla --- tests/ref/basic.list | 7 -- tests/wpt/mozilla/meta/MANIFEST.json | 72 ++++++++++++++++++ .../tests/mozilla/webgl}/clearcolor.html | 0 .../tests/mozilla/webgl}/clearcolor_ref.html | 0 .../mozilla/webgl}/draw_arrays_simple.html | 0 .../webgl}/draw_arrays_simple_ref.html | 0 .../mozilla/webgl}/img/rust-logo-256x256.png | Bin .../mozilla/webgl}/tex_image_2d_canvas.html | 0 .../mozilla/webgl}/tex_image_2d_canvas2d.html | 0 .../tex_image_2d_canvas_no_context.html | 0 .../tex_image_2d_canvas_no_context_ref.html | 0 .../webgl}/tex_image_2d_canvas_ref.html | 0 .../mozilla/webgl}/tex_image_2d_simple.html | 0 .../webgl}/tex_image_2d_simple_ref.html | 0 14 files changed, 72 insertions(+), 7 deletions(-) rename tests/{ref/webgl-context => wpt/mozilla/tests/mozilla/webgl}/clearcolor.html (100%) rename tests/{ref/webgl-context => wpt/mozilla/tests/mozilla/webgl}/clearcolor_ref.html (100%) rename tests/{ref/webgl-context => wpt/mozilla/tests/mozilla/webgl}/draw_arrays_simple.html (100%) rename tests/{ref/webgl-context => wpt/mozilla/tests/mozilla/webgl}/draw_arrays_simple_ref.html (100%) rename tests/{ref/webgl-context => wpt/mozilla/tests/mozilla/webgl}/img/rust-logo-256x256.png (100%) rename tests/{ref/webgl-context => wpt/mozilla/tests/mozilla/webgl}/tex_image_2d_canvas.html (100%) rename tests/{ref/webgl-context => wpt/mozilla/tests/mozilla/webgl}/tex_image_2d_canvas2d.html (100%) rename tests/{ref/webgl-context => wpt/mozilla/tests/mozilla/webgl}/tex_image_2d_canvas_no_context.html (100%) rename tests/{ref/webgl-context => wpt/mozilla/tests/mozilla/webgl}/tex_image_2d_canvas_no_context_ref.html (100%) rename tests/{ref/webgl-context => wpt/mozilla/tests/mozilla/webgl}/tex_image_2d_canvas_ref.html (100%) rename tests/{ref/webgl-context => wpt/mozilla/tests/mozilla/webgl}/tex_image_2d_simple.html (100%) rename tests/{ref/webgl-context => wpt/mozilla/tests/mozilla/webgl}/tex_image_2d_simple_ref.html (100%) diff --git a/tests/ref/basic.list b/tests/ref/basic.list index c5c5cbe46dd..c363d8f96f6 100644 --- a/tests/ref/basic.list +++ b/tests/ref/basic.list @@ -107,13 +107,6 @@ resolution=800x600 == viewport_percentage_vw_vh.html viewport_percentage_vw_vh_a # resolution=600x800 == viewport_percentage_vw_vh.html viewport_percentage_vw_vh_b.html prefs:"layout.viewport.enabled" == viewport_rule.html viewport_rule_ref.html -== webgl-context/clearcolor.html webgl-context/clearcolor_ref.html -== webgl-context/draw_arrays_simple.html webgl-context/draw_arrays_simple_ref.html -== webgl-context/tex_image_2d_canvas.html webgl-context/tex_image_2d_canvas_ref.html -== webgl-context/tex_image_2d_canvas2d.html webgl-context/tex_image_2d_canvas_ref.html -== webgl-context/tex_image_2d_canvas_no_context.html webgl-context/tex_image_2d_canvas_no_context_ref.html -== webgl-context/tex_image_2d_simple.html webgl-context/tex_image_2d_simple_ref.html - flaky_macos == white_space_intrinsic_sizes_a.html white_space_intrinsic_sizes_ref.html diff --git a/tests/wpt/mozilla/meta/MANIFEST.json b/tests/wpt/mozilla/meta/MANIFEST.json index bc04fb431a2..b8c52f7f5be 100644 --- a/tests/wpt/mozilla/meta/MANIFEST.json +++ b/tests/wpt/mozilla/meta/MANIFEST.json @@ -4078,6 +4078,78 @@ ], "url": "/_mozilla/mozilla/canvas/drawimage_html_image_9.html" } + ], + "mozilla/webgl/clearcolor.html": [ + { + "path": "mozilla/webgl/clearcolor.html", + "references": [ + [ + "/_mozilla/mozilla/webgl/clearcolor_ref.html", + "==" + ] + ], + "url": "/_mozilla/mozilla/webgl/clearcolor.html" + } + ], + "mozilla/webgl/tex_image_2d_canvas_no_context.html": [ + { + "path": "mozilla/webgl/tex_image_2d_canvas_no_context.html", + "references": [ + [ + "/_mozilla/mozilla/webgl/tex_image_2d_canvas_no_context_ref.html", + "==" + ] + ], + "url": "/_mozilla/mozilla/webgl/tex_image_2d_canvas_no_context.html" + } + ], + "mozilla/webgl/tex_image_2d_canvas2d.html": [ + { + "path": "mozilla/webgl/tex_image_2d_canvas2d.html", + "references": [ + [ + "/_mozilla/mozilla/webgl/tex_image_2d_canvas_ref.html", + "==" + ] + ], + "url": "/_mozilla/mozilla/webgl/tex_image_2d_canvas2d.html" + } + ], + "mozilla/webgl/tex_image_2d_canvas.html": [ + { + "path": "mozilla/webgl/tex_image_2d_canvas.html", + "references": [ + [ + "/_mozilla/mozilla/webgl/tex_image_2d_canvas_ref.html", + "==" + ] + ], + "url": "/_mozilla/mozilla/webgl/tex_image_2d_canvas.html" + } + ], + "mozilla/webgl/tex_image_2d_simple.html": [ + { + "path": "mozilla/webgl/tex_image_2d_simple.html", + "references": [ + [ + "/_mozilla/mozilla/webgl/tex_image_2d_simple_ref.html", + "==" + ] + ], + "url": "/_mozilla/mozilla/webgl/tex_image_2d_simple.html" + } + ], + "mozilla/webgl/draw_arrays_simple.html": [ + { + "path": "mozilla/webgl/draw_arrays_simple.html", + "references": [ + [ + "/_mozilla/mozilla/webgl/draw_arrays_simple_ref.html", + "==" + ] + ], + "url": "/_mozilla/mozilla/webgl/draw_arrays_simple.html" + } ] }, "testharness": { diff --git a/tests/ref/webgl-context/clearcolor.html b/tests/wpt/mozilla/tests/mozilla/webgl/clearcolor.html similarity index 100% rename from tests/ref/webgl-context/clearcolor.html rename to tests/wpt/mozilla/tests/mozilla/webgl/clearcolor.html diff --git a/tests/ref/webgl-context/clearcolor_ref.html b/tests/wpt/mozilla/tests/mozilla/webgl/clearcolor_ref.html similarity index 100% rename from tests/ref/webgl-context/clearcolor_ref.html rename to tests/wpt/mozilla/tests/mozilla/webgl/clearcolor_ref.html diff --git a/tests/ref/webgl-context/draw_arrays_simple.html b/tests/wpt/mozilla/tests/mozilla/webgl/draw_arrays_simple.html similarity index 100% rename from tests/ref/webgl-context/draw_arrays_simple.html rename to tests/wpt/mozilla/tests/mozilla/webgl/draw_arrays_simple.html diff --git a/tests/ref/webgl-context/draw_arrays_simple_ref.html b/tests/wpt/mozilla/tests/mozilla/webgl/draw_arrays_simple_ref.html similarity index 100% rename from tests/ref/webgl-context/draw_arrays_simple_ref.html rename to tests/wpt/mozilla/tests/mozilla/webgl/draw_arrays_simple_ref.html diff --git a/tests/ref/webgl-context/img/rust-logo-256x256.png b/tests/wpt/mozilla/tests/mozilla/webgl/img/rust-logo-256x256.png similarity index 100% rename from tests/ref/webgl-context/img/rust-logo-256x256.png rename to tests/wpt/mozilla/tests/mozilla/webgl/img/rust-logo-256x256.png diff --git a/tests/ref/webgl-context/tex_image_2d_canvas.html b/tests/wpt/mozilla/tests/mozilla/webgl/tex_image_2d_canvas.html similarity index 100% rename from tests/ref/webgl-context/tex_image_2d_canvas.html rename to tests/wpt/mozilla/tests/mozilla/webgl/tex_image_2d_canvas.html diff --git a/tests/ref/webgl-context/tex_image_2d_canvas2d.html b/tests/wpt/mozilla/tests/mozilla/webgl/tex_image_2d_canvas2d.html similarity index 100% rename from tests/ref/webgl-context/tex_image_2d_canvas2d.html rename to tests/wpt/mozilla/tests/mozilla/webgl/tex_image_2d_canvas2d.html diff --git a/tests/ref/webgl-context/tex_image_2d_canvas_no_context.html b/tests/wpt/mozilla/tests/mozilla/webgl/tex_image_2d_canvas_no_context.html similarity index 100% rename from tests/ref/webgl-context/tex_image_2d_canvas_no_context.html rename to tests/wpt/mozilla/tests/mozilla/webgl/tex_image_2d_canvas_no_context.html diff --git a/tests/ref/webgl-context/tex_image_2d_canvas_no_context_ref.html b/tests/wpt/mozilla/tests/mozilla/webgl/tex_image_2d_canvas_no_context_ref.html similarity index 100% rename from tests/ref/webgl-context/tex_image_2d_canvas_no_context_ref.html rename to tests/wpt/mozilla/tests/mozilla/webgl/tex_image_2d_canvas_no_context_ref.html diff --git a/tests/ref/webgl-context/tex_image_2d_canvas_ref.html b/tests/wpt/mozilla/tests/mozilla/webgl/tex_image_2d_canvas_ref.html similarity index 100% rename from tests/ref/webgl-context/tex_image_2d_canvas_ref.html rename to tests/wpt/mozilla/tests/mozilla/webgl/tex_image_2d_canvas_ref.html diff --git a/tests/ref/webgl-context/tex_image_2d_simple.html b/tests/wpt/mozilla/tests/mozilla/webgl/tex_image_2d_simple.html similarity index 100% rename from tests/ref/webgl-context/tex_image_2d_simple.html rename to tests/wpt/mozilla/tests/mozilla/webgl/tex_image_2d_simple.html diff --git a/tests/ref/webgl-context/tex_image_2d_simple_ref.html b/tests/wpt/mozilla/tests/mozilla/webgl/tex_image_2d_simple_ref.html similarity index 100% rename from tests/ref/webgl-context/tex_image_2d_simple_ref.html rename to tests/wpt/mozilla/tests/mozilla/webgl/tex_image_2d_simple_ref.html From 641e54bd41235fc52cc7995b276b7c3c35cd288c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Emilio=20Cobos=20=C3=81lvarez?= <ecoal95@gmail.com> Date: Sun, 1 Nov 2015 20:51:23 +0100 Subject: [PATCH 50/58] Bump offscreen_gl_context This new version shold prevent crashing on the linux buildbots. --- components/servo/Cargo.lock | 2 +- ports/cef/Cargo.lock | 3 ++- ports/gonk/Cargo.lock | 3 ++- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/components/servo/Cargo.lock b/components/servo/Cargo.lock index 56143d3776d..3408bc362c9 100644 --- a/components/servo/Cargo.lock +++ b/components/servo/Cargo.lock @@ -1274,7 +1274,7 @@ dependencies = [ [[package]] name = "offscreen_gl_context" version = "0.1.0" -source = "git+https://github.com/ecoal95/rust-offscreen-rendering-context#05a1ea3a7cb6fac044e2c6133ab334ca522d2b92" +source = "git+https://github.com/ecoal95/rust-offscreen-rendering-context#aae6e57969c553973c43ce5e4246831ccc2868f0" dependencies = [ "cgl 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", "core-foundation 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", diff --git a/ports/cef/Cargo.lock b/ports/cef/Cargo.lock index d77a6d26efd..83441a25f5d 100644 --- a/ports/cef/Cargo.lock +++ b/ports/cef/Cargo.lock @@ -1207,7 +1207,7 @@ dependencies = [ [[package]] name = "offscreen_gl_context" version = "0.1.0" -source = "git+https://github.com/ecoal95/rust-offscreen-rendering-context#05a1ea3a7cb6fac044e2c6133ab334ca522d2b92" +source = "git+https://github.com/ecoal95/rust-offscreen-rendering-context#aae6e57969c553973c43ce5e4246831ccc2868f0" dependencies = [ "cgl 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", "core-foundation 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", @@ -1557,6 +1557,7 @@ dependencies = [ "msg 0.0.1", "net 0.0.1", "net_traits 0.0.1", + "offscreen_gl_context 0.1.0 (git+https://github.com/ecoal95/rust-offscreen-rendering-context)", "profile 0.0.1", "profile_traits 0.0.1", "script 0.0.1", diff --git a/ports/gonk/Cargo.lock b/ports/gonk/Cargo.lock index e3a26fa1e21..5a6271d15ca 100644 --- a/ports/gonk/Cargo.lock +++ b/ports/gonk/Cargo.lock @@ -1187,7 +1187,7 @@ dependencies = [ [[package]] name = "offscreen_gl_context" version = "0.1.0" -source = "git+https://github.com/ecoal95/rust-offscreen-rendering-context#05a1ea3a7cb6fac044e2c6133ab334ca522d2b92" +source = "git+https://github.com/ecoal95/rust-offscreen-rendering-context#aae6e57969c553973c43ce5e4246831ccc2868f0" dependencies = [ "cgl 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", "core-foundation 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", @@ -1536,6 +1536,7 @@ dependencies = [ "msg 0.0.1", "net 0.0.1", "net_traits 0.0.1", + "offscreen_gl_context 0.1.0 (git+https://github.com/ecoal95/rust-offscreen-rendering-context)", "profile 0.0.1", "profile_traits 0.0.1", "script 0.0.1", From cf8f2b1874a83df30f785e063139e808de690c78 Mon Sep 17 00:00:00 2001 From: Eli Friedman <eli.friedman@gmail.com> Date: Sun, 1 Nov 2015 12:47:28 -0800 Subject: [PATCH 51/58] Use attribute getter/setter macros for misc DOM attributes. This fixes a few minor bugs. Also adds some better testing for "unsigned long" attributes. --- components/script/dom/htmlbuttonelement.rs | 10 +- components/script/dom/htmlimageelement.rs | 15 +-- components/script/dom/htmloptionelement.rs | 4 +- components/script/dom/htmltablecellelement.rs | 2 +- .../html/dom/reflection-embedded.html.ini | 102 ++++++++++++------ .../html/dom/reflection-obsolete.html.ini | 72 +++++++++++++ .../html/dom/reflection-tabular.html.ini | 48 +++++++++ .../select-ask-for-reset.html.ini | 1 + .../web-platform-tests/html/dom/reflection.js | 27 ++--- 9 files changed, 214 insertions(+), 67 deletions(-) diff --git a/components/script/dom/htmlbuttonelement.rs b/components/script/dom/htmlbuttonelement.rs index 5146c7e4888..7d73a2ad64f 100644 --- a/components/script/dom/htmlbuttonelement.rs +++ b/components/script/dom/htmlbuttonelement.rs @@ -81,15 +81,7 @@ impl HTMLButtonElementMethods for HTMLButtonElement { } // https://html.spec.whatwg.org/multipage/#dom-button-type - fn Type(&self) -> DOMString { - let mut ty = self.upcast::<Element>().get_string_attribute(&atom!("type")); - ty.make_ascii_lowercase(); - // https://html.spec.whatwg.org/multipage/#attr-button-type - match &*ty { - "reset" | "button" | "menu" => ty, - _ => "submit".to_owned() - } - } + make_enumerated_getter!(Type, "submit", ("reset") | ("button") | ("menu")); // https://html.spec.whatwg.org/multipage/#dom-button-type make_setter!(SetType, "type"); diff --git a/components/script/dom/htmlimageelement.rs b/components/script/dom/htmlimageelement.rs index 25b93621c02..e3b2fd85111 100644 --- a/components/script/dom/htmlimageelement.rs +++ b/components/script/dom/htmlimageelement.rs @@ -14,7 +14,7 @@ use dom::bindings::global::GlobalRef; use dom::bindings::js::{LayoutJS, Root}; use dom::bindings::refcounted::Trusted; use dom::document::Document; -use dom::element::{AttributeMutation, Element}; +use dom::element::AttributeMutation; use dom::event::{Event, EventBubbles, EventCancelable}; use dom::htmlelement::HTMLElement; use dom::node::{Node, NodeDamage, document_from_node, window_from_node}; @@ -196,11 +196,8 @@ impl HTMLImageElementMethods for HTMLImageElement { // https://html.spec.whatwg.org/multipage/#dom-img-ismap make_bool_getter!(IsMap); - // https://html.spec.whatwg.org/multipage/#dom-img-ismap - fn SetIsMap(&self, is_map: bool) { - self.upcast::<Element>().set_string_attribute(&atom!("ismap"), is_map.to_string()) - } + make_bool_setter!(SetIsMap, "ismap"); // https://html.spec.whatwg.org/multipage/#dom-img-width fn Width(&self) -> u32 { @@ -210,9 +207,7 @@ impl HTMLImageElementMethods for HTMLImageElement { } // https://html.spec.whatwg.org/multipage/#dom-img-width - fn SetWidth(&self, width: u32) { - self.upcast::<Element>().set_uint_attribute(&atom!("width"), width) - } + make_uint_setter!(SetWidth, "width"); // https://html.spec.whatwg.org/multipage/#dom-img-height fn Height(&self) -> u32 { @@ -222,9 +217,7 @@ impl HTMLImageElementMethods for HTMLImageElement { } // https://html.spec.whatwg.org/multipage/#dom-img-height - fn SetHeight(&self, height: u32) { - self.upcast::<Element>().set_uint_attribute(&atom!("height"), height) - } + make_uint_setter!(SetHeight, "height"); // https://html.spec.whatwg.org/multipage/#dom-img-naturalwidth fn NaturalWidth(&self) -> u32 { diff --git a/components/script/dom/htmloptionelement.rs b/components/script/dom/htmloptionelement.rs index 8c7dea8ac1e..03ea7aabf84 100644 --- a/components/script/dom/htmloptionelement.rs +++ b/components/script/dom/htmloptionelement.rs @@ -91,9 +91,7 @@ impl HTMLOptionElementMethods for HTMLOptionElement { make_bool_getter!(Disabled); // https://html.spec.whatwg.org/multipage/#dom-option-disabled - fn SetDisabled(&self, disabled: bool) { - self.upcast::<Element>().set_bool_attribute(&atom!("disabled"), disabled) - } + make_bool_setter!(SetDisabled, "disabled"); // https://html.spec.whatwg.org/multipage/#dom-option-text fn Text(&self) -> DOMString { diff --git a/components/script/dom/htmltablecellelement.rs b/components/script/dom/htmltablecellelement.rs index 3f1b13633f2..afb1cebdb3d 100644 --- a/components/script/dom/htmltablecellelement.rs +++ b/components/script/dom/htmltablecellelement.rs @@ -53,7 +53,7 @@ impl HTMLTableCellElementMethods for HTMLTableCellElement { make_uint_getter!(ColSpan, "colspan", DEFAULT_COLSPAN); // https://html.spec.whatwg.org/multipage/#dom-tdth-colspan - make_uint_setter!(SetColSpan, "colspan"); + make_uint_setter!(SetColSpan, "colspan", DEFAULT_COLSPAN); // https://html.spec.whatwg.org/multipage/#dom-tdth-cellindex fn CellIndex(&self) -> i32 { diff --git a/tests/wpt/metadata/html/dom/reflection-embedded.html.ini b/tests/wpt/metadata/html/dom/reflection-embedded.html.ini index 1b4b1e10f3c..82044b1a910 100644 --- a/tests/wpt/metadata/html/dom/reflection-embedded.html.ini +++ b/tests/wpt/metadata/html/dom/reflection-embedded.html.ini @@ -912,36 +912,6 @@ [img.crossOrigin: IDL set to "USE-CREDENTIALS" followed by IDL get] expected: FAIL - [img.isMap: IDL set to "" followed by hasAttribute()] - expected: FAIL - - [img.isMap: IDL set to "" followed by IDL get] - expected: FAIL - - [img.isMap: IDL set to undefined followed by hasAttribute()] - expected: FAIL - - [img.isMap: IDL set to undefined followed by IDL get] - expected: FAIL - - [img.isMap: IDL set to null followed by hasAttribute()] - expected: FAIL - - [img.isMap: IDL set to null followed by IDL get] - expected: FAIL - - [img.isMap: IDL set to false followed by hasAttribute()] - expected: FAIL - - [img.isMap: IDL set to false followed by IDL get] - expected: FAIL - - [img.isMap: IDL set to NaN followed by hasAttribute()] - expected: FAIL - - [img.isMap: IDL set to NaN followed by IDL get] - expected: FAIL - [img.width: IDL set to 1 followed by IDL get] expected: FAIL @@ -22107,3 +22077,75 @@ [data.itemValue (<data value>): IDL set to object "test-valueOf" followed by IDL get] expected: FAIL + [object.hspace: IDL set to 2147483648 followed by getAttribute()] + expected: FAIL + + [object.hspace: IDL set to 2147483648 followed by IDL get] + expected: FAIL + + [object.hspace: IDL set to 4294967295 followed by getAttribute()] + expected: FAIL + + [object.hspace: IDL set to 4294967295 followed by IDL get] + expected: FAIL + + [object.vspace: IDL set to 2147483648 followed by getAttribute()] + expected: FAIL + + [object.vspace: IDL set to 2147483648 followed by IDL get] + expected: FAIL + + [object.vspace: IDL set to 4294967295 followed by getAttribute()] + expected: FAIL + + [object.vspace: IDL set to 4294967295 followed by IDL get] + expected: FAIL + + [video.width: IDL set to 2147483648 followed by getAttribute()] + expected: FAIL + + [video.width: IDL set to 2147483648 followed by IDL get] + expected: FAIL + + [video.width: IDL set to 4294967295 followed by getAttribute()] + expected: FAIL + + [video.width: IDL set to 4294967295 followed by IDL get] + expected: FAIL + + [video.height: IDL set to 2147483648 followed by getAttribute()] + expected: FAIL + + [video.height: IDL set to 2147483648 followed by IDL get] + expected: FAIL + + [video.height: IDL set to 4294967295 followed by getAttribute()] + expected: FAIL + + [video.height: IDL set to 4294967295 followed by IDL get] + expected: FAIL + + [canvas.width: IDL set to 2147483648 followed by getAttribute()] + expected: FAIL + + [canvas.width: IDL set to 2147483648 followed by IDL get] + expected: FAIL + + [canvas.width: IDL set to 4294967295 followed by getAttribute()] + expected: FAIL + + [canvas.width: IDL set to 4294967295 followed by IDL get] + expected: FAIL + + [canvas.height: IDL set to 2147483648 followed by getAttribute()] + expected: FAIL + + [canvas.height: IDL set to 2147483648 followed by IDL get] + expected: FAIL + + [canvas.height: IDL set to 4294967295 followed by getAttribute()] + expected: FAIL + + [canvas.height: IDL set to 4294967295 followed by IDL get] + expected: FAIL + diff --git a/tests/wpt/metadata/html/dom/reflection-obsolete.html.ini b/tests/wpt/metadata/html/dom/reflection-obsolete.html.ini index f81b0e937f2..03d95573fc2 100644 --- a/tests/wpt/metadata/html/dom/reflection-obsolete.html.ini +++ b/tests/wpt/metadata/html/dom/reflection-obsolete.html.ini @@ -10869,3 +10869,75 @@ [data.itemValue (<data value>): IDL set to object "test-valueOf" followed by IDL get] expected: FAIL + [applet.hspace: IDL set to 2147483648 followed by getAttribute()] + expected: FAIL + + [applet.hspace: IDL set to 2147483648 followed by IDL get] + expected: FAIL + + [applet.hspace: IDL set to 4294967295 followed by getAttribute()] + expected: FAIL + + [applet.hspace: IDL set to 4294967295 followed by IDL get] + expected: FAIL + + [applet.vspace: IDL set to 2147483648 followed by getAttribute()] + expected: FAIL + + [applet.vspace: IDL set to 2147483648 followed by IDL get] + expected: FAIL + + [applet.vspace: IDL set to 4294967295 followed by getAttribute()] + expected: FAIL + + [applet.vspace: IDL set to 4294967295 followed by IDL get] + expected: FAIL + + [marquee.hspace: IDL set to 2147483648 followed by getAttribute()] + expected: FAIL + + [marquee.hspace: IDL set to 2147483648 followed by IDL get] + expected: FAIL + + [marquee.hspace: IDL set to 4294967295 followed by getAttribute()] + expected: FAIL + + [marquee.hspace: IDL set to 4294967295 followed by IDL get] + expected: FAIL + + [marquee.scrollAmount: IDL set to 2147483648 followed by getAttribute()] + expected: FAIL + + [marquee.scrollAmount: IDL set to 2147483648 followed by IDL get] + expected: FAIL + + [marquee.scrollAmount: IDL set to 4294967295 followed by getAttribute()] + expected: FAIL + + [marquee.scrollAmount: IDL set to 4294967295 followed by IDL get] + expected: FAIL + + [marquee.scrollDelay: IDL set to 2147483648 followed by getAttribute()] + expected: FAIL + + [marquee.scrollDelay: IDL set to 2147483648 followed by IDL get] + expected: FAIL + + [marquee.scrollDelay: IDL set to 4294967295 followed by getAttribute()] + expected: FAIL + + [marquee.scrollDelay: IDL set to 4294967295 followed by IDL get] + expected: FAIL + + [marquee.vspace: IDL set to 2147483648 followed by getAttribute()] + expected: FAIL + + [marquee.vspace: IDL set to 2147483648 followed by IDL get] + expected: FAIL + + [marquee.vspace: IDL set to 4294967295 followed by getAttribute()] + expected: FAIL + + [marquee.vspace: IDL set to 4294967295 followed by IDL get] + expected: FAIL + diff --git a/tests/wpt/metadata/html/dom/reflection-tabular.html.ini b/tests/wpt/metadata/html/dom/reflection-tabular.html.ini index 351a0fc5e29..969134a9c08 100644 --- a/tests/wpt/metadata/html/dom/reflection-tabular.html.ini +++ b/tests/wpt/metadata/html/dom/reflection-tabular.html.ini @@ -17691,3 +17691,51 @@ [data.itemValue (<data value>): IDL set to object "test-valueOf" followed by IDL get] expected: FAIL + [colgroup.span: IDL set to 2147483648 followed by getAttribute()] + expected: FAIL + + [colgroup.span: IDL set to 2147483648 followed by IDL get] + expected: FAIL + + [colgroup.span: IDL set to 4294967295 followed by getAttribute()] + expected: FAIL + + [colgroup.span: IDL set to 4294967295 followed by IDL get] + expected: FAIL + + [col.span: IDL set to 2147483648 followed by getAttribute()] + expected: FAIL + + [col.span: IDL set to 2147483648 followed by IDL get] + expected: FAIL + + [col.span: IDL set to 4294967295 followed by getAttribute()] + expected: FAIL + + [col.span: IDL set to 4294967295 followed by IDL get] + expected: FAIL + + [td.rowSpan: IDL set to 2147483648 followed by getAttribute()] + expected: FAIL + + [td.rowSpan: IDL set to 2147483648 followed by IDL get] + expected: FAIL + + [td.rowSpan: IDL set to 4294967295 followed by getAttribute()] + expected: FAIL + + [td.rowSpan: IDL set to 4294967295 followed by IDL get] + expected: FAIL + + [th.rowSpan: IDL set to 2147483648 followed by getAttribute()] + expected: FAIL + + [th.rowSpan: IDL set to 2147483648 followed by IDL get] + expected: FAIL + + [th.rowSpan: IDL set to 4294967295 followed by getAttribute()] + expected: FAIL + + [th.rowSpan: IDL set to 4294967295 followed by IDL get] + expected: FAIL + diff --git a/tests/wpt/metadata/html/semantics/forms/the-select-element/select-ask-for-reset.html.ini b/tests/wpt/metadata/html/semantics/forms/the-select-element/select-ask-for-reset.html.ini index f858a12d101..dd109c994dd 100644 --- a/tests/wpt/metadata/html/semantics/forms/the-select-element/select-ask-for-reset.html.ini +++ b/tests/wpt/metadata/html/semantics/forms/the-select-element/select-ask-for-reset.html.ini @@ -2,3 +2,4 @@ type: testharness [ask for reset on node remove, non multiple.] expected: FAIL + diff --git a/tests/wpt/web-platform-tests/html/dom/reflection.js b/tests/wpt/web-platform-tests/html/dom/reflection.js index 7bd41d51622..35099c1d5da 100644 --- a/tests/wpt/web-platform-tests/html/dom/reflection.js +++ b/tests/wpt/web-platform-tests/html/dom/reflection.js @@ -139,10 +139,9 @@ var maxUnsigned = 4294967295; * * Note that all tests/expected values are only baselines, and can be expanded * with additional tests hardcoded into the function for particular types if - * necessary (e.g., enum). null means "default" as a DOM expected value, and - * "throw an INDEX_SIZE_ERR exception" as an IDL expected value. (This is a - * kind of stupid and fragile convention, but it's simple and works for now.) - * Expected DOM values are cast to strings by adding "". + * necessary. For example, a special codepath is used for enums, and for + * IDL setters which throw an exception. null means "defaultVal" is the + * expected value. Expected DOM values are cast to strings by adding "". * * TODO: Test strings that aren't valid UTF-16. Desired behavior is not clear * here at the time of writing, see @@ -379,8 +378,8 @@ ReflectionTests.typeMap = { } return parsed; }, - "idlTests": [minInt, -36, -1, 0, 1, maxInt], - "idlDomExpected": [null, null, null, 0, 1, maxInt] + "idlTests": [minInt, -36, -1, 0, 1, maxInt], + "idlDomExpected": [null/*exception*/, null/*exception*/, null/*exception*/, 0, 1, maxInt] }, /** * "If a reflecting IDL attribute is an unsigned integer type (unsigned @@ -416,8 +415,9 @@ ReflectionTests.typeMap = { } return parsed; }, - "idlTests": [0, 1, 257, 2147483647, "-0"], - "idlIdlExpected": [0, 1, 257, 2147483647, 0] + "idlTests": [0, 1, 257, maxInt, "-0", maxInt + 1, maxUnsigned], + "idlIdlExpected": [0, 1, 257, maxInt, 0, null, null], + "idlDomExpected": [0, 1, 257, maxInt, 0, null, null], }, /** * "If a reflecting IDL attribute is an unsigned integer type (unsigned @@ -457,8 +457,8 @@ ReflectionTests.typeMap = { } return parsed; }, - "idlTests": [0, 1, 2147483647], - "idlDomExpected": [null, 1, 2147483647] + "idlTests": [0, 1, maxInt, maxInt + 1, maxUnsigned], + "idlDomExpected": [null/*exception*/, 1, maxInt, null, null] }, /** * "If a reflecting IDL attribute is a floating point number type (double), @@ -610,8 +610,8 @@ ReflectionTests.doReflects = function(data, idlName, idlObj, domName, domObj) { var domTests = typeInfo.domTests.slice(0); var domExpected = typeInfo.domExpected.map(function(val) { return val === null ? defaultVal : val; }); var idlTests = typeInfo.idlTests.slice(0); - var idlDomExpected = typeInfo.idlDomExpected.slice(0); - var idlIdlExpected = typeInfo.idlIdlExpected.slice(0); + var idlDomExpected = typeInfo.idlDomExpected.map(function(val) { return val === null ? defaultVal : val; }); + var idlIdlExpected = typeInfo.idlIdlExpected.map(function(val) { return val === null ? defaultVal : val; }); switch (data.type) { // Extra tests and other special-casing case "boolean": @@ -712,7 +712,8 @@ ReflectionTests.doReflects = function(data, idlName, idlObj, domName, domObj) { } for (var i = 0; i < idlTests.length; i++) { - if (idlDomExpected[i] === null && data.type != "enum") { + if ((data.type == "limited long" && idlTests[i] < 0) || + (data.type == "limited unsigned long" && idlTests[i] == 0)) { ReflectionHarness.testException("INDEX_SIZE_ERR", function() { idlObj[idlName] = idlTests[i]; }, "IDL set to " + ReflectionHarness.stringRep(idlTests[i]) + " must throw INDEX_SIZE_ERR"); From 00980ea595dd54643eee59c1a0e2ddef39286e7f Mon Sep 17 00:00:00 2001 From: David Zbarsky <dzbarsky@gmail.com> Date: Thu, 20 Aug 2015 12:31:19 -0400 Subject: [PATCH 52/58] Implement calc expressions for more value types --- components/layout/block.rs | 4 + components/layout/inline.rs | 7 +- components/layout/model.rs | 2 + components/script/dom/element.rs | 5 +- components/style/animation.rs | 24 +- components/style/properties.mako.rs | 157 +++++---- components/style/values.rs | 346 ++++++++++++++----- tests/wpt/mozilla/meta/mozilla/calc.html.ini | 110 +----- tests/wpt/mozilla/tests/mozilla/calc.html | 40 ++- 9 files changed, 383 insertions(+), 312 deletions(-) diff --git a/components/layout/block.rs b/components/layout/block.rs index adb48e3248f..399b3e5a9f4 100644 --- a/components/layout/block.rs +++ b/components/layout/block.rs @@ -340,6 +340,10 @@ impl CandidateBSizeIterator { (LengthOrPercentageOrNone::Percentage(percent), Some(block_container_block_size)) => { Some(block_container_block_size.scale_by(percent)) } + (LengthOrPercentageOrNone::Calc(calc), Some(block_container_block_size)) => { + Some(block_container_block_size.scale_by(calc.percentage()) + calc.length()) + } + (LengthOrPercentageOrNone::Calc(_), _) | (LengthOrPercentageOrNone::Percentage(_), None) | (LengthOrPercentageOrNone::None, _) => None, (LengthOrPercentageOrNone::Length(length), _) => Some(length), diff --git a/components/layout/inline.rs b/components/layout/inline.rs index 5bd622871e1..8711881ffaf 100644 --- a/components/layout/inline.rs +++ b/components/layout/inline.rs @@ -27,6 +27,7 @@ use std::{fmt, isize, mem}; use style::computed_values::{display, overflow_x, position, text_align, text_justify}; use style::computed_values::{text_overflow, vertical_align, white_space}; use style::properties::ComputedValues; +use style::values::computed::LengthOrPercentage; use text; use unicode_bidi; use util; @@ -953,15 +954,15 @@ impl InlineFlow { offset_from_baseline = offset_from_baseline - *depth_below_baseline } }, - vertical_align::T::Length(length) => { + vertical_align::T::LengthOrPercentage(LengthOrPercentage::Length(length)) => { offset_from_baseline = offset_from_baseline - length } - vertical_align::T::Percentage(p) => { + vertical_align::T::LengthOrPercentage(LengthOrPercentage::Percentage(p)) => { let line_height = fragment.calculate_line_height(layout_context); let percent_offset = line_height.scale_by(p); offset_from_baseline = offset_from_baseline - percent_offset } - vertical_align::T::Calc(calc) => { + vertical_align::T::LengthOrPercentage(LengthOrPercentage::Calc(calc)) => { let line_height = fragment.calculate_line_height(layout_context); let percent_offset = line_height.scale_by(calc.percentage()); offset_from_baseline = offset_from_baseline - percent_offset - calc.length() diff --git a/components/layout/model.rs b/components/layout/model.rs index 8ee98a39678..f49ac51ad21 100644 --- a/components/layout/model.rs +++ b/components/layout/model.rs @@ -411,6 +411,8 @@ pub fn specified_or_none(length: LengthOrPercentageOrNone, containing_length: Au match length { LengthOrPercentageOrNone::None => None, LengthOrPercentageOrNone::Percentage(percent) => Some(containing_length.scale_by(percent)), + LengthOrPercentageOrNone::Calc(calc) => + Some(containing_length.scale_by(calc.percentage()) + calc.length()), LengthOrPercentageOrNone::Length(length) => Some(length), } } diff --git a/components/script/dom/element.rs b/components/script/dom/element.rs index 4fc714ed1fe..d07d2566371 100644 --- a/components/script/dom/element.rs +++ b/components/script/dom/element.rs @@ -80,7 +80,7 @@ use style::properties::DeclaredValue; use style::properties::longhands::{self, background_image, border_spacing, font_family, font_size}; use style::properties::{PropertyDeclaration, PropertyDeclarationBlock, parse_style_attribute}; use style::values::CSSFloat; -use style::values::specified::{self, CSSColor, CSSRGBA}; +use style::values::specified::{self, CSSColor, CSSRGBA, LengthOrPercentage}; use url::UrlParser; use util::mem::HeapSizeOf; use util::str::{DOMString, LengthOrPercentageOrAuto}; @@ -347,7 +347,8 @@ impl LayoutElementHelpers for LayoutJS<Element> { hints.push(from_declaration( PropertyDeclaration::FontSize( DeclaredValue::Value( - font_size::SpecifiedValue(font_size))))) + font_size::SpecifiedValue( + LengthOrPercentage::Length(font_size)))))) } let cellspacing = if let Some(this) = self.downcast::<HTMLTableElement>() { diff --git a/components/style/animation.rs b/components/style/animation.rs index 30c0b658fec..a073c39ae73 100644 --- a/components/style/animation.rs +++ b/components/style/animation.rs @@ -28,7 +28,7 @@ use std::iter::repeat; use util::bezier::Bezier; use values::CSSFloat; use values::computed::{Angle, LengthOrPercentageOrAuto, LengthOrPercentageOrNone}; -use values::computed::{Calc, Length, LengthOrPercentage, Time}; +use values::computed::{CalcLengthOrPercentage, Length, LengthOrPercentage, Time}; #[derive(Clone, Debug)] pub struct PropertyAnimation { @@ -461,10 +461,10 @@ impl Interpolate for VerticalAlign { fn interpolate(&self, other: &VerticalAlign, time: f64) -> Option<VerticalAlign> { match (*self, *other) { - (VerticalAlign::Length(ref this), - VerticalAlign::Length(ref other)) => { + (VerticalAlign::LengthOrPercentage(LengthOrPercentage::Length(ref this)), + VerticalAlign::LengthOrPercentage(LengthOrPercentage::Length(ref other))) => { this.interpolate(other, time).and_then(|value| { - Some(VerticalAlign::Length(value)) + Some(VerticalAlign::LengthOrPercentage(LengthOrPercentage::Length(value))) }) } (_, _) => None, @@ -513,11 +513,11 @@ impl Interpolate for Color { } } -impl Interpolate for Calc { +impl Interpolate for CalcLengthOrPercentage { #[inline] - fn interpolate(&self, other: &Calc, time: f64) - -> Option<Calc> { - Some(Calc { + fn interpolate(&self, other: &CalcLengthOrPercentage, time: f64) + -> Option<CalcLengthOrPercentage> { + Some(CalcLengthOrPercentage { length: self.length().interpolate(&other.length(), time), percentage: self.percentage().interpolate(&other.percentage(), time), }) @@ -542,8 +542,8 @@ impl Interpolate for LengthOrPercentage { }) } (this, other) => { - let this: Calc = From::from(this); - let other: Calc = From::from(other); + let this: CalcLengthOrPercentage = From::from(this); + let other: CalcLengthOrPercentage = From::from(other); this.interpolate(&other, time).and_then(|value| { Some(LengthOrPercentage::Calc(value)) }) @@ -573,8 +573,8 @@ impl Interpolate for LengthOrPercentageOrAuto { Some(LengthOrPercentageOrAuto::Auto) } (this, other) => { - let this: Option<Calc> = From::from(this); - let other: Option<Calc> = From::from(other); + let this: Option<CalcLengthOrPercentage> = From::from(this); + let other: Option<CalcLengthOrPercentage> = From::from(other); this.interpolate(&other, time).unwrap_or(None).and_then(|value| { Some(LengthOrPercentageOrAuto::Calc(value)) }) diff --git a/components/style/properties.mako.rs b/components/style/properties.mako.rs index c8f1834b1ac..2912d4ea871 100644 --- a/components/style/properties.mako.rs +++ b/components/style/properties.mako.rs @@ -611,7 +611,7 @@ pub mod longhands { if input.try(|input| input.expect_ident_matching("auto")).is_ok() { Ok(computed_value::T::Auto) } else { - Ok(computed_value::T::Number(try!(input.expect_integer()) as i32)) + specified::parse_integer(input).map(computed_value::T::Number) } } </%self:longhand> @@ -658,18 +658,16 @@ pub mod longhands { #[derive(Clone, PartialEq, Copy)] pub enum SpecifiedValue { Normal, - Length(specified::Length), Number(CSSFloat), - Percentage(CSSFloat), + LengthOrPercentage(specified::LengthOrPercentage), } impl ToCss for SpecifiedValue { fn to_css<W>(&self, dest: &mut W) -> fmt::Result where W: fmt::Write { match *self { SpecifiedValue::Normal => dest.write_str("normal"), - SpecifiedValue::Length(length) => length.to_css(dest), + SpecifiedValue::LengthOrPercentage(value) => value.to_css(dest), SpecifiedValue::Number(number) => write!(dest, "{}", number), - SpecifiedValue::Percentage(number) => write!(dest, "{}%", number * 100.), } } } @@ -677,22 +675,19 @@ pub mod longhands { pub fn parse(_context: &ParserContext, input: &mut Parser) -> Result<SpecifiedValue, ()> { use cssparser::Token; use std::ascii::AsciiExt; - match try!(input.next()) { - Token::Number(ref value) if value.value >= 0. => { - Ok(SpecifiedValue::Number(value.value)) + input.try(specified::LengthOrPercentage::parse_non_negative) + .map(SpecifiedValue::LengthOrPercentage) + .or_else(|()| { + match try!(input.next()) { + Token::Number(ref value) if value.value >= 0. => { + Ok(SpecifiedValue::Number(value.value)) + } + Token::Ident(ref value) if value.eq_ignore_ascii_case("normal") => { + Ok(SpecifiedValue::Normal) + } + _ => Err(()), } - Token::Percentage(ref value) if value.unit_value >= 0. => { - Ok(SpecifiedValue::Percentage(value.unit_value)) - } - Token::Dimension(ref value, ref unit) if value.value >= 0. => { - specified::Length::parse_dimension(value.value, unit) - .map(SpecifiedValue::Length) - } - Token::Ident(ref value) if value.eq_ignore_ascii_case("normal") => { - Ok(SpecifiedValue::Normal) - } - _ => Err(()), - } + }) } pub mod computed_value { use app_units::Au; @@ -733,13 +728,22 @@ pub mod longhands { fn to_computed_value(&self, context: &Context) -> computed_value::T { match *self { SpecifiedValue::Normal => computed_value::T::Normal, - SpecifiedValue::Length(value) => { - computed_value::T::Length(value.to_computed_value(context)) - } SpecifiedValue::Number(value) => computed_value::T::Number(value), - SpecifiedValue::Percentage(value) => { - let fr = specified::Length::FontRelative(specified::FontRelativeLength::Em(value)); - computed_value::T::Length(fr.to_computed_value(context)) + SpecifiedValue::LengthOrPercentage(value) => { + match value { + specified::LengthOrPercentage::Length(value) => + computed_value::T::Length(value.to_computed_value(context)), + specified::LengthOrPercentage::Percentage(specified::Percentage(value)) => { + let fr = specified::Length::FontRelative(specified::FontRelativeLength::Em(value)); + computed_value::T::Length(fr.to_computed_value(context)) + }, + specified::LengthOrPercentage::Calc(calc) => { + let calc = calc.to_computed_value(context); + let fr = specified::FontRelativeLength::Em(calc.percentage()); + let fr = specified::Length::FontRelative(fr); + computed_value::T::Length(calc.length() + fr.to_computed_value(context)) + } + } } } } @@ -804,9 +808,7 @@ pub mod longhands { % for keyword in vertical_align_keywords: ${to_rust_ident(keyword)}, % endfor - Length(Au), - Percentage(CSSFloat), - Calc(computed::Calc), + LengthOrPercentage(computed::LengthOrPercentage), } impl fmt::Debug for T { fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { @@ -814,9 +816,7 @@ pub mod longhands { % for keyword in vertical_align_keywords: T::${to_rust_ident(keyword)} => write!(f, "${keyword}"), % endfor - T::Length(length) => write!(f, "{:?}", length), - T::Percentage(number) => write!(f, "{}%", number), - T::Calc(calc) => write!(f, "{:?}", calc) + T::LengthOrPercentage(value) => write!(f, "{:?}", value), } } } @@ -826,9 +826,7 @@ pub mod longhands { % for keyword in vertical_align_keywords: T::${to_rust_ident(keyword)} => dest.write_str("${keyword}"), % endfor - T::Length(value) => value.to_css(dest), - T::Percentage(percentage) => write!(dest, "{}%", percentage * 100.), - T::Calc(calc) => calc.to_css(dest), + T::LengthOrPercentage(value) => value.to_css(dest), } } } @@ -847,16 +845,8 @@ pub mod longhands { computed_value::T::${to_rust_ident(keyword)} } % endfor - SpecifiedValue::LengthOrPercentage(value) => { - match value.to_computed_value(context) { - computed::LengthOrPercentage::Length(value) => - computed_value::T::Length(value), - computed::LengthOrPercentage::Percentage(value) => - computed_value::T::Percentage(value), - computed::LengthOrPercentage::Calc(value) => - computed_value::T::Calc(value), - } - } + SpecifiedValue::LengthOrPercentage(value) => + computed_value::T::LengthOrPercentage(value.to_computed_value(context)), } } } @@ -1311,7 +1301,8 @@ pub mod longhands { if content::counter_name_is_illegal(&counter_name) { return Err(()) } - let counter_delta = input.try(|input| input.expect_integer()).unwrap_or(1) as i32; + let counter_delta = + input.try(|input| specified::parse_integer(input)).unwrap_or(1); counters.push((counter_name, counter_delta)) } @@ -1478,8 +1469,7 @@ pub mod longhands { PositionCategory::VerticalKeyword, specified::PositionComponent::Center => PositionCategory::OtherKeyword, - specified::PositionComponent::Length(_) | - specified::PositionComponent::Percentage(_) => + specified::PositionComponent::LengthOrPercentage(_) => PositionCategory::LengthOrPercentage, } } @@ -1929,7 +1919,7 @@ pub mod longhands { } #[derive(Clone, PartialEq)] - pub struct SpecifiedValue(pub specified::Length); // Percentages are the same as em. + pub struct SpecifiedValue(pub specified::LengthOrPercentage); pub mod computed_value { use app_units::Au; pub type T = Au; @@ -1949,17 +1939,14 @@ pub mod longhands { } /// <length> | <percentage> | <absolute-size> | <relative-size> pub fn parse(_context: &ParserContext, input: &mut Parser) -> Result<SpecifiedValue, ()> { + use values::specified::{Length, LengthOrPercentage}; + input.try(specified::LengthOrPercentage::parse_non_negative) - .and_then(|value| match value { - specified::LengthOrPercentage::Length(value) => Ok(value), - specified::LengthOrPercentage::Percentage(value) => - Ok(specified::Length::FontRelative(specified::FontRelativeLength::Em(value.0))), - // FIXME(dzbarsky) handle calc for font-size - specified::LengthOrPercentage::Calc(_) => Err(()) - }) .or_else(|()| { let ident = try!(input.expect_ident()); - specified::Length::from_str(&ident as &str).ok_or(()) + specified::Length::from_str(&ident as &str) + .ok_or(()) + .map(specified::LengthOrPercentage::Length) }) .map(SpecifiedValue) } @@ -2649,7 +2636,7 @@ pub mod longhands { if input.try(|input| input.expect_ident_matching("auto")).is_ok() { Ok(SpecifiedValue::Auto) } else { - let count = try!(input.expect_integer()); + let count = try!(specified::parse_integer(input)); // Zero is invalid if count <= 0 { return Err(()) @@ -2763,7 +2750,7 @@ pub mod longhands { } } fn parse(_context: &ParserContext, input: &mut Parser) -> Result<SpecifiedValue, ()> { - input.expect_number().map(SpecifiedValue) + specified::parse_number(input).map(SpecifiedValue) } </%self:longhand> @@ -3628,10 +3615,10 @@ pub mod longhands { } fn parse_two_floats(input: &mut Parser) -> Result<(CSSFloat,CSSFloat),()> { - let first = try!(input.expect_number()); + let first = try!(specified::parse_number(input)); let second = input.try(|input| { try!(input.expect_comma()); - input.expect_number() + specified::parse_number(input) }).unwrap_or(first); Ok((first, second)) } @@ -3771,7 +3758,7 @@ pub mod longhands { "matrix" => { try!(input.parse_nested_block(|input| { let values = try!(input.parse_comma_separated(|input| { - input.expect_number() + specified::parse_number(input) })); if values.len() != 6 { return Err(()) @@ -3789,7 +3776,7 @@ pub mod longhands { "matrix3d" => { try!(input.parse_nested_block(|input| { let values = try!(input.parse_comma_separated(|input| { - input.expect_number() + specified::parse_number(input) })); if values.len() != 16 { return Err(()) @@ -3872,32 +3859,32 @@ pub mod longhands { }, "scalex" => { try!(input.parse_nested_block(|input| { - let sx = try!(input.expect_number()); + let sx = try!(specified::parse_number(input)); result.push(SpecifiedOperation::Scale(sx, 1.0, 1.0)); Ok(()) })) }, "scaley" => { try!(input.parse_nested_block(|input| { - let sy = try!(input.expect_number()); + let sy = try!(specified::parse_number(input)); result.push(SpecifiedOperation::Scale(1.0, sy, 1.0)); Ok(()) })) }, "scalez" => { try!(input.parse_nested_block(|input| { - let sz = try!(input.expect_number()); + let sz = try!(specified::parse_number(input)); result.push(SpecifiedOperation::Scale(1.0, 1.0, sz)); Ok(()) })) }, "scale3d" => { try!(input.parse_nested_block(|input| { - let sx = try!(input.expect_number()); + let sx = try!(specified::parse_number(input)); try!(input.expect_comma()); - let sy = try!(input.expect_number()); + let sy = try!(specified::parse_number(input)); try!(input.expect_comma()); - let sz = try!(input.expect_number()); + let sz = try!(specified::parse_number(input)); result.push(SpecifiedOperation::Scale(sx, sy, sz)); Ok(()) })) @@ -3932,11 +3919,11 @@ pub mod longhands { }, "rotate3d" => { try!(input.parse_nested_block(|input| { - let ax = try!(input.expect_number()); + let ax = try!(specified::parse_number(input)); try!(input.expect_comma()); - let ay = try!(input.expect_number()); + let ay = try!(specified::parse_number(input)); try!(input.expect_comma()); - let az = try!(input.expect_number()); + let az = try!(specified::parse_number(input)); try!(input.expect_comma()); let theta = try!(specified::Angle::parse(input)); // TODO(gw): Check the axis can be normalized!! @@ -4539,13 +4526,13 @@ pub mod longhands { "cubic-bezier" => { let (mut p1x, mut p1y, mut p2x, mut p2y) = (0.0, 0.0, 0.0, 0.0); try!(input.parse_nested_block(|input| { - p1x = try!(input.expect_number()); + p1x = try!(specified::parse_number(input)); try!(input.expect_comma()); - p1y = try!(input.expect_number()); + p1y = try!(specified::parse_number(input)); try!(input.expect_comma()); - p2x = try!(input.expect_number()); + p2x = try!(specified::parse_number(input)); try!(input.expect_comma()); - p2y = try!(input.expect_number()); + p2y = try!(specified::parse_number(input)); Ok(()) })); let (p1, p2) = (Point2D::new(p1x, p1y), Point2D::new(p2x, p2y)); @@ -4554,7 +4541,7 @@ pub mod longhands { "steps" => { let (mut step_count, mut start_end) = (0, computed_value::StartEnd::Start); try!(input.parse_nested_block(|input| { - step_count = try!(input.expect_integer()); + step_count = try!(specified::parse_integer(input)); try!(input.expect_comma()); start_end = try!(match_ignore_ascii_case! { try!(input.expect_ident()), @@ -6520,6 +6507,7 @@ pub fn cascade(viewport_size: Size2D<Au>, // Initialize `context` // Declarations blocks are already stored in increasing precedence order. for sub_list in applicable_declarations { + use values::specified::{LengthOrPercentage, Percentage}; // Declarations are stored in reverse source order, we want them in forward order here. for declaration in sub_list.declarations.iter().rev() { match *declaration { @@ -6528,14 +6516,23 @@ pub fn cascade(viewport_size: Size2D<Au>, value, &custom_properties, |value| match *value { DeclaredValue::Value(ref specified_value) => { match specified_value.0 { - Length::FontRelative(value) => { + LengthOrPercentage::Length(Length::FontRelative(value)) => { value.to_computed_value(context.inherited_font_size, context.root_font_size) } - Length::ServoCharacterWidth(value) => { + LengthOrPercentage::Length(Length::ServoCharacterWidth(value)) => { value.to_computed_value(context.inherited_font_size) } - _ => specified_value.0.to_computed_value(&context) + LengthOrPercentage::Length(l) => { + l.to_computed_value(&context) + } + LengthOrPercentage::Percentage(Percentage(value)) => { + context.inherited_font_size.scale_by(value) + } + LengthOrPercentage::Calc(calc) => { + let calc = calc.to_computed_value(&context); + calc.length() + context.inherited_font_size.scale_by(calc.percentage()) + } } } DeclaredValue::Initial => longhands::font_size::get_initial_value(), diff --git a/components/style/values.rs b/components/style/values.rs index d8850dc31cf..a32b668fa9c 100644 --- a/components/style/values.rs +++ b/components/style/values.rs @@ -232,6 +232,8 @@ pub mod specified { /// This cannot be specified by the user directly and is only generated by /// `Stylist::synthesize_rules_for_legacy_attributes()`. ServoCharacterWidth(CharacterWidth), + + Calc(CalcLengthOrPercentage), } impl ToCss for Length { @@ -240,6 +242,7 @@ pub mod specified { Length::Absolute(length) => write!(dest, "{}px", length.to_f32_px()), Length::FontRelative(length) => length.to_css(dest), Length::ViewportPercentage(length) => length.to_css(dest), + Length::Calc(calc) => calc.to_css(dest), Length::ServoCharacterWidth(_) => panic!("internal CSS values should never be serialized"), } @@ -255,6 +258,7 @@ pub mod specified { Length::Absolute(Au(v)) => Length::Absolute(Au(((v as f32) * scalar) as i32)), Length::FontRelative(v) => Length::FontRelative(v * scalar), Length::ViewportPercentage(v) => Length::ViewportPercentage(v * scalar), + Length::Calc(_) => panic!("Can't multiply Calc!"), Length::ServoCharacterWidth(_) => panic!("Can't multiply ServoCharacterWidth!"), } } @@ -292,6 +296,7 @@ pub mod specified { const AU_PER_IN: CSSFloat = AU_PER_PX * 96.; const AU_PER_CM: CSSFloat = AU_PER_IN / 2.54; const AU_PER_MM: CSSFloat = AU_PER_IN / 25.4; + const AU_PER_Q: CSSFloat = AU_PER_MM / 4.; const AU_PER_PT: CSSFloat = AU_PER_IN / 72.; const AU_PER_PC: CSSFloat = AU_PER_PT * 12.; impl Length { @@ -320,6 +325,8 @@ pub mod specified { Length::parse_dimension(value.value, unit), Token::Number(ref value) if value.value == 0. => Ok(Length::Absolute(Au(0))), + Token::Function(ref name) if name.eq_ignore_ascii_case("calc") => + input.parse_nested_block(CalcLengthOrPercentage::parse_length), _ => Err(()) } } @@ -335,6 +342,7 @@ pub mod specified { "in" => Ok(Length::Absolute(Au((value * AU_PER_IN) as i32))), "cm" => Ok(Length::Absolute(Au((value * AU_PER_CM) as i32))), "mm" => Ok(Length::Absolute(Au((value * AU_PER_MM) as i32))), + "q" => Ok(Length::Absolute(Au((value * AU_PER_Q) as i32))), "pt" => Ok(Length::Absolute(Au((value * AU_PER_PT) as i32))), "pc" => Ok(Length::Absolute(Au((value * AU_PER_PC) as i32))), // font-relative @@ -369,6 +377,8 @@ pub mod specified { #[derive(Clone, Debug)] enum CalcValueNode { Length(Length), + Angle(Angle), + Time(Time), Percentage(CSSFloat), Number(CSSFloat), Sum(Box<CalcSumNode>), @@ -392,6 +402,8 @@ pub mod specified { #[derive(Clone, Debug)] enum SimplifiedValueNode { Length(Length), + Angle(Angle), + Time(Time), Percentage(CSSFloat), Number(CSSFloat), Sum(Box<SimplifiedSumNode>), @@ -404,6 +416,8 @@ pub mod specified { match *self { SimplifiedValueNode::Length(l) => SimplifiedValueNode::Length(l * scalar), SimplifiedValueNode::Percentage(p) => SimplifiedValueNode::Percentage(p * scalar), + SimplifiedValueNode::Angle(Angle(a)) => SimplifiedValueNode::Angle(Angle(a * scalar)), + SimplifiedValueNode::Time(Time(t)) => SimplifiedValueNode::Time(Time(t * scalar)), SimplifiedValueNode::Number(n) => SimplifiedValueNode::Number(n * scalar), SimplifiedValueNode::Sum(box ref s) => { let sum = s * scalar; @@ -413,8 +427,68 @@ pub mod specified { } } + pub fn parse_integer(input: &mut Parser) -> Result<i32, ()> { + match try!(input.next()) { + Token::Number(ref value) => value.int_value.ok_or(()), + Token::Function(ref name) if name.eq_ignore_ascii_case("calc") => { + let ast = try!(input.parse_nested_block(|i| CalcLengthOrPercentage::parse_sum(i, CalcUnit::Integer))); + + let mut result = None; + + for ref node in ast.products { + match try!(CalcLengthOrPercentage::simplify_product(node)) { + SimplifiedValueNode::Number(val) => + result = Some(result.unwrap_or(0) + val as i32), + _ => unreachable!() + } + } + + match result { + Some(result) => Ok(result), + _ => Err(()) + } + } + _ => Err(()) + } + } + + pub fn parse_number(input: &mut Parser) -> Result<f32, ()> { + match try!(input.next()) { + Token::Number(ref value) => Ok(value.value), + Token::Function(ref name) if name.eq_ignore_ascii_case("calc") => { + let ast = try!(input.parse_nested_block(|i| CalcLengthOrPercentage::parse_sum(i, CalcUnit::Number))); + + let mut result = None; + + for ref node in ast.products { + match try!(CalcLengthOrPercentage::simplify_product(node)) { + SimplifiedValueNode::Number(val) => + result = Some(result.unwrap_or(0.) + val), + _ => unreachable!() + } + } + + match result { + Some(result) => Ok(result), + _ => Err(()) + } + } + _ => Err(()) + } + } + + #[derive(Clone, Copy, PartialEq)] + enum CalcUnit { + Number, + Integer, + Length, + LengthOrPercentage, + Angle, + Time, + } + #[derive(Clone, PartialEq, Copy, Debug, HeapSizeOf)] - pub struct Calc { + pub struct CalcLengthOrPercentage { pub absolute: Option<Au>, pub vw: Option<ViewportPercentageLength>, pub vh: Option<ViewportPercentageLength>, @@ -426,18 +500,18 @@ pub mod specified { pub rem: Option<FontRelativeLength>, pub percentage: Option<Percentage>, } - impl Calc { - fn parse_sum(input: &mut Parser) -> Result<CalcSumNode, ()> { + impl CalcLengthOrPercentage { + fn parse_sum(input: &mut Parser, expected_unit: CalcUnit) -> Result<CalcSumNode, ()> { let mut products = Vec::new(); - products.push(try!(Calc::parse_product(input))); + products.push(try!(CalcLengthOrPercentage::parse_product(input, expected_unit))); loop { match input.next() { Ok(Token::Delim('+')) => { - products.push(try!(Calc::parse_product(input))); + products.push(try!(CalcLengthOrPercentage::parse_product(input, expected_unit))); } Ok(Token::Delim('-')) => { - let mut right = try!(Calc::parse_product(input)); + let mut right = try!(CalcLengthOrPercentage::parse_product(input, expected_unit)); right.values.push(CalcValueNode::Number(-1.)); products.push(right); } @@ -449,17 +523,17 @@ pub mod specified { Ok(CalcSumNode { products: products }) } - fn parse_product(input: &mut Parser) -> Result<CalcProductNode, ()> { + fn parse_product(input: &mut Parser, expected_unit: CalcUnit) -> Result<CalcProductNode, ()> { let mut values = Vec::new(); - values.push(try!(Calc::parse_value(input))); + values.push(try!(CalcLengthOrPercentage::parse_value(input, expected_unit))); loop { let position = input.position(); match input.next() { Ok(Token::Delim('*')) => { - values.push(try!(Calc::parse_value(input))); + values.push(try!(CalcLengthOrPercentage::parse_value(input, expected_unit))); } - Ok(Token::Delim('/')) => { + Ok(Token::Delim('/')) if expected_unit != CalcUnit::Integer => { if let Ok(Token::Number(ref value)) = input.next() { if value.value == 0. { return Err(()); @@ -479,16 +553,24 @@ pub mod specified { Ok(CalcProductNode { values: values }) } - fn parse_value(input: &mut Parser) -> Result<CalcValueNode, ()> { - match input.next() { - Ok(Token::Number(ref value)) => Ok(CalcValueNode::Number(value.value)), - Ok(Token::Dimension(ref value, ref unit)) => - Length::parse_dimension(value.value, unit).map(CalcValueNode::Length), - Ok(Token::Percentage(ref value)) => + fn parse_value(input: &mut Parser, expected_unit: CalcUnit) -> Result<CalcValueNode, ()> { + match (try!(input.next()), expected_unit) { + (Token::Number(ref value), _) => Ok(CalcValueNode::Number(value.value)), + (Token::Dimension(ref value, ref unit), CalcUnit::Length) | + (Token::Dimension(ref value, ref unit), CalcUnit::LengthOrPercentage) => { + Length::parse_dimension(value.value, unit).map(CalcValueNode::Length) + } + (Token::Dimension(ref value, ref unit), CalcUnit::Angle) => { + Angle::parse_dimension(value.value, unit).map(CalcValueNode::Angle) + } + (Token::Dimension(ref value, ref unit), CalcUnit::Time) => { + Time::parse_dimension(value.value, unit).map(CalcValueNode::Time) + } + (Token::Percentage(ref value), CalcUnit::LengthOrPercentage) => Ok(CalcValueNode::Percentage(value.unit_value)), - Ok(Token::ParenthesisBlock) => { - let result = try!(input.parse_nested_block(Calc::parse_sum)); - Ok(CalcValueNode::Sum(box result)) + (Token::ParenthesisBlock, _) => { + input.parse_nested_block(|i| CalcLengthOrPercentage::parse_sum(i, expected_unit)) + .map(|result| CalcValueNode::Sum(box result)) }, _ => Err(()) } @@ -497,7 +579,7 @@ pub mod specified { fn simplify_value_to_number(node: &CalcValueNode) -> Option<CSSFloat> { match *node { CalcValueNode::Number(number) => Some(number), - CalcValueNode::Sum(box ref sum) => Calc::simplify_sum_to_number(sum), + CalcValueNode::Sum(box ref sum) => CalcLengthOrPercentage::simplify_sum_to_number(sum), _ => None } } @@ -505,7 +587,7 @@ pub mod specified { fn simplify_sum_to_number(node: &CalcSumNode) -> Option<CSSFloat> { let mut sum = 0.; for ref product in &node.products { - match Calc::simplify_product_to_number(product) { + match CalcLengthOrPercentage::simplify_product_to_number(product) { Some(number) => sum += number, _ => return None } @@ -516,7 +598,7 @@ pub mod specified { fn simplify_product_to_number(node: &CalcProductNode) -> Option<CSSFloat> { let mut product = 1.; for ref value in &node.values { - match Calc::simplify_value_to_number(value) { + match CalcLengthOrPercentage::simplify_value_to_number(value) { Some(number) => product *= number, _ => return None } @@ -527,7 +609,7 @@ pub mod specified { fn simplify_products_in_sum(node: &CalcSumNode) -> Result<SimplifiedValueNode, ()> { let mut simplified = Vec::new(); for product in &node.products { - match try!(Calc::simplify_product(product)) { + match try!(CalcLengthOrPercentage::simplify_product(product)) { SimplifiedValueNode::Sum(box sum) => simplified.push_all(&sum.values), val => simplified.push(val), } @@ -544,13 +626,15 @@ pub mod specified { let mut multiplier = 1.; let mut node_with_unit = None; for node in &node.values { - match Calc::simplify_value_to_number(&node) { + match CalcLengthOrPercentage::simplify_value_to_number(&node) { Some(number) => multiplier *= number, _ if node_with_unit.is_none() => { node_with_unit = Some(match *node { CalcValueNode::Sum(box ref sum) => - try!(Calc::simplify_products_in_sum(sum)), + try!(CalcLengthOrPercentage::simplify_products_in_sum(sum)), CalcValueNode::Length(l) => SimplifiedValueNode::Length(l), + CalcValueNode::Angle(a) => SimplifiedValueNode::Angle(a), + CalcValueNode::Time(t) => SimplifiedValueNode::Time(t), CalcValueNode::Percentage(p) => SimplifiedValueNode::Percentage(p), _ => unreachable!("Numbers should have been handled by simplify_value_to_nubmer") }) @@ -565,12 +649,20 @@ pub mod specified { } } - pub fn parse(input: &mut Parser) -> Result<Calc, ()> { - let ast = try!(Calc::parse_sum(input)); + fn parse_length(input: &mut Parser) -> Result<Length, ()> { + CalcLengthOrPercentage::parse(input, CalcUnit::Length).map(Length::Calc) + } + + fn parse_length_or_percentage(input: &mut Parser) -> Result<CalcLengthOrPercentage, ()> { + CalcLengthOrPercentage::parse(input, CalcUnit::LengthOrPercentage) + } + + fn parse(input: &mut Parser, expected_unit: CalcUnit) -> Result<CalcLengthOrPercentage, ()> { + let ast = try!(CalcLengthOrPercentage::parse_sum(input, expected_unit)); let mut simplified = Vec::new(); for ref node in ast.products { - match try!(Calc::simplify_product(node)) { + match try!(CalcLengthOrPercentage::simplify_product(node)) { SimplifiedValueNode::Sum(sum) => simplified.push_all(&sum.values), value => simplified.push(value), } @@ -617,11 +709,11 @@ pub mod specified { rem = Some(rem.unwrap_or(0.) + val), }, SimplifiedValueNode::Number(val) => number = Some(number.unwrap_or(0.) + val), - _ => unreachable!() + _ => return Err(()), } } - Ok(Calc { + Ok(CalcLengthOrPercentage { absolute: absolute.map(Au), vw: vw.map(ViewportPercentageLength::Vw), vh: vh.map(ViewportPercentageLength::Vh), @@ -634,9 +726,66 @@ pub mod specified { percentage: percentage.map(Percentage), }) } + + pub fn parse_time(input: &mut Parser) -> Result<Time, ()> { + let ast = try!(CalcLengthOrPercentage::parse_sum(input, CalcUnit::Time)); + + let mut simplified = Vec::new(); + for ref node in ast.products { + match try!(CalcLengthOrPercentage::simplify_product(node)) { + SimplifiedValueNode::Sum(sum) => simplified.push_all(&sum.values), + value => simplified.push(value), + } + } + + let mut time = None; + + for value in simplified { + match value { + SimplifiedValueNode::Time(Time(val)) => + time = Some(time.unwrap_or(0.) + val), + _ => return Err(()), + } + } + + match time { + Some(time) => Ok(Time(time)), + _ => Err(()) + } + } + + pub fn parse_angle(input: &mut Parser) -> Result<Angle, ()> { + let ast = try!(CalcLengthOrPercentage::parse_sum(input, CalcUnit::Angle)); + + let mut simplified = Vec::new(); + for ref node in ast.products { + match try!(CalcLengthOrPercentage::simplify_product(node)) { + SimplifiedValueNode::Sum(sum) => simplified.push_all(&sum.values), + value => simplified.push(value), + } + } + + let mut angle = None; + let mut number = None; + + for value in simplified { + match value { + SimplifiedValueNode::Angle(Angle(val)) => + angle = Some(angle.unwrap_or(0.) + val), + SimplifiedValueNode::Number(val) => number = Some(number.unwrap_or(0.) + val), + _ => unreachable!() + } + } + + match (angle, number) { + (Some(angle), None) => Ok(Angle(angle)), + (None, Some(value)) if value == 0. => Ok(Angle(0.)), + _ => Err(()) + } + } } - impl ToCss for Calc { + impl ToCss for CalcLengthOrPercentage { #[allow(unused_assignments)] fn to_css<W>(&self, dest: &mut W) -> fmt::Result where W: fmt::Write { @@ -701,7 +850,7 @@ pub mod specified { pub enum LengthOrPercentage { Length(Length), Percentage(Percentage), - Calc(Calc), + Calc(CalcLengthOrPercentage), } impl ToCss for LengthOrPercentage { @@ -729,7 +878,7 @@ pub mod specified { Token::Number(ref value) if value.value == 0. => Ok(LengthOrPercentage::Length(Length::Absolute(Au(0)))), Token::Function(ref name) if name.eq_ignore_ascii_case("calc") => { - let calc = try!(input.parse_nested_block(Calc::parse)); + let calc = try!(input.parse_nested_block(CalcLengthOrPercentage::parse_length_or_percentage)); Ok(LengthOrPercentage::Calc(calc)) }, _ => Err(()) @@ -750,7 +899,7 @@ pub mod specified { Length(Length), Percentage(Percentage), Auto, - Calc(Calc), + Calc(CalcLengthOrPercentage), } impl ToCss for LengthOrPercentageOrAuto { @@ -778,7 +927,7 @@ pub mod specified { Token::Ident(ref value) if value.eq_ignore_ascii_case("auto") => Ok(LengthOrPercentageOrAuto::Auto), Token::Function(ref name) if name.eq_ignore_ascii_case("calc") => { - let calc = try!(input.parse_nested_block(Calc::parse)); + let calc = try!(input.parse_nested_block(CalcLengthOrPercentage::parse_length_or_percentage)); Ok(LengthOrPercentageOrAuto::Calc(calc)) }, _ => Err(()) @@ -798,6 +947,7 @@ pub mod specified { pub enum LengthOrPercentageOrNone { Length(Length), Percentage(Percentage), + Calc(CalcLengthOrPercentage), None, } @@ -806,6 +956,7 @@ pub mod specified { match *self { LengthOrPercentageOrNone::Length(length) => length.to_css(dest), LengthOrPercentageOrNone::Percentage(percentage) => percentage.to_css(dest), + LengthOrPercentageOrNone::Calc(calc) => calc.to_css(dest), LengthOrPercentageOrNone::None => dest.write_str("none"), } } @@ -821,6 +972,10 @@ pub mod specified { Ok(LengthOrPercentageOrNone::Percentage(Percentage(value.unit_value))), Token::Number(ref value) if value.value == 0. => Ok(LengthOrPercentageOrNone::Length(Length::Absolute(Au(0)))), + Token::Function(ref name) if name.eq_ignore_ascii_case("calc") => { + let calc = try!(input.parse_nested_block(CalcLengthOrPercentage::parse_length_or_percentage)); + Ok(LengthOrPercentageOrNone::Calc(calc)) + }, Token::Ident(ref value) if value.eq_ignore_ascii_case("none") => Ok(LengthOrPercentageOrNone::None), _ => Err(()) @@ -859,6 +1014,8 @@ pub mod specified { Length::parse_dimension(value.value, unit).map(LengthOrNone::Length), Token::Number(ref value) if value.value == 0. => Ok(LengthOrNone::Length(Length::Absolute(Au(0)))), + Token::Function(ref name) if name.eq_ignore_ascii_case("calc") => + input.parse_nested_block(CalcLengthOrPercentage::parse_length).map(LengthOrNone::Length), Token::Ident(ref value) if value.eq_ignore_ascii_case("none") => Ok(LengthOrNone::None), _ => Err(()) @@ -911,8 +1068,7 @@ pub mod specified { // http://dev.w3.org/csswg/css2/colors.html#propdef-background-position #[derive(Clone, PartialEq, Copy)] pub enum PositionComponent { - Length(Length), - Percentage(Percentage), + LengthOrPercentage(LengthOrPercentage), Center, Left, Right, @@ -921,35 +1077,29 @@ pub mod specified { } impl PositionComponent { pub fn parse(input: &mut Parser) -> Result<PositionComponent, ()> { - match try!(input.next()) { - Token::Dimension(ref value, ref unit) => { - Length::parse_dimension(value.value, unit) - .map(PositionComponent::Length) + + input.try(LengthOrPercentage::parse) + .map(PositionComponent::LengthOrPercentage) + .or_else(|()| { + match try!(input.next()) { + Token::Ident(value) => { + match_ignore_ascii_case! { value, + "center" => Ok(PositionComponent::Center), + "left" => Ok(PositionComponent::Left), + "right" => Ok(PositionComponent::Right), + "top" => Ok(PositionComponent::Top), + "bottom" => Ok(PositionComponent::Bottom) + _ => Err(()) + } + }, + _ => Err(()) } - Token::Percentage(ref value) => { - Ok(PositionComponent::Percentage(Percentage(value.unit_value))) - } - Token::Number(ref value) if value.value == 0. => { - Ok(PositionComponent::Length(Length::Absolute(Au(0)))) - } - Token::Ident(value) => { - match_ignore_ascii_case! { value, - "center" => Ok(PositionComponent::Center), - "left" => Ok(PositionComponent::Left), - "right" => Ok(PositionComponent::Right), - "top" => Ok(PositionComponent::Top), - "bottom" => Ok(PositionComponent::Bottom) - _ => Err(()) - } - } - _ => Err(()) - } + }) } #[inline] pub fn to_length_or_percentage(self) -> LengthOrPercentage { match self { - PositionComponent::Length(x) => LengthOrPercentage::Length(x), - PositionComponent::Percentage(x) => LengthOrPercentage::Percentage(x), + PositionComponent::LengthOrPercentage(value) => value, PositionComponent::Center => LengthOrPercentage::Percentage(Percentage(0.5)), PositionComponent::Left | PositionComponent::Top => LengthOrPercentage::Percentage(Percentage(0.0)), @@ -984,19 +1134,24 @@ pub mod specified { /// Parses an angle according to CSS-VALUES ยง 6.1. pub fn parse(input: &mut Parser) -> Result<Angle, ()> { match try!(input.next()) { - Token::Dimension(value, unit) => { - match_ignore_ascii_case! { unit, - "deg" => Ok(Angle(value.value * RAD_PER_DEG)), - "grad" => Ok(Angle(value.value * RAD_PER_GRAD)), - "turn" => Ok(Angle(value.value * RAD_PER_TURN)), - "rad" => Ok(Angle(value.value)) - _ => Err(()) - } - } + Token::Dimension(ref value, ref unit) => Angle::parse_dimension(value.value, unit), Token::Number(ref value) if value.value == 0. => Ok(Angle(0.)), + Token::Function(ref name) if name.eq_ignore_ascii_case("calc") => { + input.parse_nested_block(CalcLengthOrPercentage::parse_angle) + }, _ => Err(()) } } + + pub fn parse_dimension(value: CSSFloat, unit: &str) -> Result<Angle, ()> { + match_ignore_ascii_case! { unit, + "deg" => Ok(Angle(value * RAD_PER_DEG)), + "grad" => Ok(Angle(value * RAD_PER_GRAD)), + "turn" => Ok(Angle(value * RAD_PER_TURN)), + "rad" => Ok(Angle(value)) + _ => Err(()) + } + } } /// Specified values for an image according to CSS-IMAGES. @@ -1235,7 +1390,10 @@ pub mod specified { Ok(Token::Dimension(ref value, ref unit)) => { Time::parse_dimension(value.value, &unit) } - _ => Err(()), + Ok(Token::Function(ref name)) if name.eq_ignore_ascii_case("calc") => { + input.parse_nested_block(CalcLengthOrPercentage::parse_time) + } + _ => Err(()) } } } @@ -1251,7 +1409,7 @@ pub mod specified { impl ToCss for Time { fn to_css<W>(&self, dest: &mut W) -> fmt::Result where W: fmt::Write { - write!(dest, "{}ms", self.0) + write!(dest, "{}s", self.0) } } } @@ -1328,6 +1486,7 @@ pub mod computed { fn to_computed_value(&self, context: &Context) -> Au { match *self { specified::Length::Absolute(length) => length, + specified::Length::Calc(calc) => calc.to_computed_value(context).length(), specified::Length::FontRelative(length) => length.to_computed_value(context.font_size, context.root_font_size), specified::Length::ViewportPercentage(length) => @@ -1339,12 +1498,12 @@ pub mod computed { } #[derive(Clone, PartialEq, Copy, Debug, HeapSizeOf)] - pub struct Calc { + pub struct CalcLengthOrPercentage { pub length: Option<Au>, pub percentage: Option<CSSFloat>, } - impl Calc { + impl CalcLengthOrPercentage { pub fn length(&self) -> Au { self.length.unwrap_or(Au(0)) } @@ -1354,17 +1513,17 @@ pub mod computed { } } - impl From<LengthOrPercentage> for Calc { - fn from(len: LengthOrPercentage) -> Calc { + impl From<LengthOrPercentage> for CalcLengthOrPercentage { + fn from(len: LengthOrPercentage) -> CalcLengthOrPercentage { match len { LengthOrPercentage::Percentage(this) => { - Calc { + CalcLengthOrPercentage { length: None, percentage: Some(this), } } LengthOrPercentage::Length(this) => { - Calc { + CalcLengthOrPercentage { length: Some(this), percentage: None, } @@ -1376,17 +1535,17 @@ pub mod computed { } } - impl From<LengthOrPercentageOrAuto> for Option<Calc> { - fn from(len: LengthOrPercentageOrAuto) -> Option<Calc> { + impl From<LengthOrPercentageOrAuto> for Option<CalcLengthOrPercentage> { + fn from(len: LengthOrPercentageOrAuto) -> Option<CalcLengthOrPercentage> { match len { LengthOrPercentageOrAuto::Percentage(this) => { - Some(Calc { + Some(CalcLengthOrPercentage { length: None, percentage: Some(this), }) } LengthOrPercentageOrAuto::Length(this) => { - Some(Calc { + Some(CalcLengthOrPercentage { length: Some(this), percentage: None, }) @@ -1401,7 +1560,7 @@ pub mod computed { } } - impl ::cssparser::ToCss for Calc { + impl ::cssparser::ToCss for CalcLengthOrPercentage { fn to_css<W>(&self, dest: &mut W) -> fmt::Result where W: fmt::Write { match (self.length, self.percentage) { (None, Some(p)) => write!(dest, "{}%", p * 100.), @@ -1412,10 +1571,10 @@ pub mod computed { } } - impl ToComputedValue for specified::Calc { - type ComputedValue = Calc; + impl ToComputedValue for specified::CalcLengthOrPercentage { + type ComputedValue = CalcLengthOrPercentage; - fn to_computed_value(&self, context: &Context) -> Calc { + fn to_computed_value(&self, context: &Context) -> CalcLengthOrPercentage { let mut length = None; if let Some(absolute) = self.absolute { @@ -1435,7 +1594,7 @@ pub mod computed { } } - Calc { length: length, percentage: self.percentage.map(|p| p.0) } + CalcLengthOrPercentage { length: length, percentage: self.percentage.map(|p| p.0) } } } @@ -1474,7 +1633,7 @@ pub mod computed { pub enum LengthOrPercentage { Length(Au), Percentage(CSSFloat), - Calc(Calc), + Calc(CalcLengthOrPercentage), } impl LengthOrPercentage { @@ -1527,7 +1686,7 @@ pub mod computed { Length(Au), Percentage(CSSFloat), Auto, - Calc(Calc), + Calc(CalcLengthOrPercentage), } impl fmt::Debug for LengthOrPercentageOrAuto { fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { @@ -1578,6 +1737,7 @@ pub mod computed { pub enum LengthOrPercentageOrNone { Length(Au), Percentage(CSSFloat), + Calc(CalcLengthOrPercentage), None, } impl fmt::Debug for LengthOrPercentageOrNone { @@ -1585,6 +1745,7 @@ pub mod computed { match *self { LengthOrPercentageOrNone::Length(length) => write!(f, "{:?}", length), LengthOrPercentageOrNone::Percentage(percentage) => write!(f, "{}%", percentage * 100.), + LengthOrPercentageOrNone::Calc(calc) => write!(f, "{:?}", calc), LengthOrPercentageOrNone::None => write!(f, "none"), } } @@ -1602,6 +1763,9 @@ pub mod computed { specified::LengthOrPercentageOrNone::Percentage(value) => { LengthOrPercentageOrNone::Percentage(value.0) } + specified::LengthOrPercentageOrNone::Calc(calc) => { + LengthOrPercentageOrNone::Calc(calc.to_computed_value(context)) + } specified::LengthOrPercentageOrNone::None => { LengthOrPercentageOrNone::None } @@ -1615,6 +1779,7 @@ pub mod computed { LengthOrPercentageOrNone::Length(length) => length.to_css(dest), LengthOrPercentageOrNone::Percentage(percentage) => write!(dest, "{}%", percentage * 100.), + LengthOrPercentageOrNone::Calc(calc) => calc.to_css(dest), LengthOrPercentageOrNone::None => dest.write_str("none"), } } @@ -1640,6 +1805,9 @@ pub mod computed { #[inline] fn to_computed_value(&self, context: &Context) -> LengthOrNone { match *self { + specified::LengthOrNone::Length(specified::Length::Calc(calc)) => { + LengthOrNone::Length(calc.to_computed_value(context).length()) + } specified::LengthOrNone::Length(value) => { LengthOrNone::Length(value.to_computed_value(context)) } diff --git a/tests/wpt/mozilla/meta/mozilla/calc.html.ini b/tests/wpt/mozilla/meta/mozilla/calc.html.ini index ad1ebaf3617..e365575ac70 100644 --- a/tests/wpt/mozilla/meta/mozilla/calc.html.ini +++ b/tests/wpt/mozilla/meta/mozilla/calc.html.ini @@ -6,123 +6,15 @@ [calc(0px + 0pt + 0pc + 0in + 0cm + 0mm + 0rem + 0em + 0ex + 0% + 0vw + 0vh + 0vmin + 0vmax)] expected: FAIL - [calc for border-width] - expected: FAIL - - [calc for border-top-width] - expected: FAIL - - [calc for border-left-width] - expected: FAIL - - [calc for border-right-width] - expected: FAIL - - [calc for border-bottom-width] - expected: FAIL - - [calc for outline-width] - expected: FAIL - - [calc for outline-offset] - expected: FAIL - - [calc for letter-spacing] - expected: FAIL - - [calc for word-spacing] - expected: FAIL - - [calc for border-spacing] - expected: FAIL - [calc for column-width] expected: FAIL [calc for column-gap] expected: FAIL - [calc for perspective] - expected: FAIL - - [calc for border-top-left-radius] - expected: FAIL - - [calc for border-bottom-left-radius] - expected: FAIL - - [calc for border-top-right-radius] - expected: FAIL - - [calc for border-bottom-right-radius] - expected: FAIL - - [calc for top] - expected: FAIL - - [calc for left] - expected: FAIL - - [calc for bottom] - expected: FAIL - - [calc for right] - expected: FAIL - - [calc for width] - expected: FAIL - - [calc for height] - expected: FAIL - - [calc for min-width] - expected: FAIL - - [calc for min-height] - expected: FAIL - - [calc for max-width] - expected: FAIL - - [calc for max-height] - expected: FAIL - - [calc for line-height] - expected: FAIL - - [calc for vertical-align] - expected: FAIL - - [calc for background-position] - expected: FAIL - - [calc for background-size] - expected: FAIL - - [calc for font-size] - expected: FAIL - - [calc for text-indent] - expected: FAIL - - [calc for transform-origin] - expected: FAIL - - [calc for perspective-origin] - expected: FAIL - - [calc for transition-delay] - expected: FAIL - - [calc for z-index] - expected: FAIL - [calc for column-count] expected: FAIL - [calc for opacity] - expected: FAIL - - [calc for transition-duration] + [calc(0ch + 0px + 0pt + 0pc + 0in + 0cm + 0mm + 0rem + 0em + 0ex + 0% + 0vw + 0vh + 0vmin + 0vmax)] expected: FAIL diff --git a/tests/wpt/mozilla/tests/mozilla/calc.html b/tests/wpt/mozilla/tests/mozilla/calc.html index b69c28e67d0..1db42bb6f25 100644 --- a/tests/wpt/mozilla/tests/mozilla/calc.html +++ b/tests/wpt/mozilla/tests/mozilla/calc.html @@ -39,8 +39,8 @@ var widthTests = [ ['calc(1px + 1pt + 1pc + 1in + 1cm + 1mm)', '155.88333333333333px', '155.88333333333333px'], // Alphabetical order - ['calc(0px + 0pt + 0pc + 0in + 0cm + 0mm + 0rem + 0em + 0ex + 0% + 0vw + 0vh + 0vmin + 0vmax)', - 'calc(0em + 0ex + 0px + 0rem + 0vh + 0vmax + 0vmin + 0vw + 0%)', + ['calc(0ch + 0px + 0pt + 0pc + 0in + 0cm + 0mm + 0rem + 0em + 0ex + 0% + 0vw + 0vh + 0vmin + 0vmax)', + 'calc(0ch + 0em + 0ex + 0px + 0rem + 0vh + 0vmax + 0vmin + 0vw + 0%)', '0px'], // Simplification @@ -59,7 +59,6 @@ widthTests.forEach(function(item) { }); var lengthProperties = [ - 'border-width', 'border-top-width', 'border-left-width', 'border-right-width', @@ -68,7 +67,6 @@ var lengthProperties = [ 'outline-offset', 'letter-spacing', 'word-spacing', - 'border-spacing', 'column-width', 'column-gap', 'perspective', @@ -78,15 +76,10 @@ lengthProperties.forEach(function(prop) { test(function() { div.style.setProperty(prop, 'calc(1px)'); assert_equals(div.style.getPropertyValue(prop), '1px'); - assert_equals(window.getComputedStyle(div).getPropertyValue(prop), '1px'); }, 'calc for ' + prop); }); var lengthOrPercentageProperties = [ - 'border-top-left-radius', - 'border-bottom-left-radius', - 'border-top-right-radius', - 'border-bottom-right-radius', 'top', 'left', 'bottom', @@ -99,31 +92,26 @@ var lengthOrPercentageProperties = [ 'max-height', 'line-height', 'vertical-align', - 'background-position', - 'background-size', 'font-size', 'text-indent', - 'transform-origin', - 'perspective-origin', ]; lengthOrPercentageProperties.forEach(function(prop) { test(function() { div.style.setProperty(prop, 'calc(1px + 0%)'); assert_equals(div.style.getPropertyValue(prop), 'calc(1px + 0%)'); - assert_equals(window.getComputedStyle(div).getPropertyValue(prop), '1px'); }, 'calc for ' + prop); }); var timeProperties = [ 'transition-delay', + 'transition-duration', ]; timeProperties.forEach(function(prop) { test(function() { div.style.setProperty(prop, 'calc(1s)'); assert_equals(div.style.getPropertyValue(prop), '1s'); - assert_equals(window.getComputedStyle(div).getPropertyValue(prop), '1s'); }, 'calc for ' + prop); }); @@ -131,22 +119,40 @@ var numberProperties = [ 'z-index', 'column-count', 'opacity', - 'transition-duration', ]; numberProperties.forEach(function(prop) { test(function() { div.style.setProperty(prop, 'calc(1)'); assert_equals(div.style.getPropertyValue(prop), '1'); - assert_equals(window.getComputedStyle(div).getPropertyValue(prop), '1'); }, 'calc for ' + prop); }); +var otherProperties = [ + ['border-width', 'calc(1px)', '1px 1px 1px 1px'], + ['border-spacing', 'calc(1px)', '1px 1px'], + ['transform-origin', 'calc(1px + 0%)', 'calc(1px + 0%) 50% 0px'], + ['perspective-origin', 'calc(1px + 0%)', 'calc(1px + 0%) 50%'], + ['background-size', 'calc(1px + 0%)', 'calc(1px + 0%) auto'], + ['background-position', 'calc(1px + 0%) calc(2px + 0%)', 'calc(1px + 0%) calc(2px + 0%)'], + ['border-top-left-radius', 'calc(1px + 0%)', 'calc(1px + 0%) calc(1px + 0%)'], + ['border-bottom-left-radius', 'calc(1px + 0%)', 'calc(1px + 0%) calc(1px + 0%)'], + ['border-top-right-radius', 'calc(1px + 0%)', 'calc(1px + 0%) calc(1px + 0%)'], + ['border-bottom-right-radius', 'calc(1px + 0%)', 'calc(1px + 0%) calc(1px + 0%)'], +]; + +otherProperties.forEach(function(testcase) { + test(function() { + div.style.setProperty(testcase[0], testcase[1]); + assert_equals(div.style.getPropertyValue(testcase[0]), testcase[2]); + }, 'calc for ' + testcase[0]); +}); /* TODO: test these: counter-increment, counter-reset, color, box-shadow, clip, text-shadow, transform transition-timing-function + angles */ </script> </head> From 0dacd331020dfb17ef6da9352cfea1f01842a8f2 Mon Sep 17 00:00:00 2001 From: Ms2ger <Ms2ger@gmail.com> Date: Mon, 2 Nov 2015 11:42:39 +0100 Subject: [PATCH 53/58] Remove RawLayoutHTMLInputElementHelpers. --- components/script/dom/element.rs | 8 +++---- components/script/dom/htmlinputelement.rs | 29 +++++++---------------- 2 files changed, 12 insertions(+), 25 deletions(-) diff --git a/components/script/dom/element.rs b/components/script/dom/element.rs index d07d2566371..a78ba89b485 100644 --- a/components/script/dom/element.rs +++ b/components/script/dom/element.rs @@ -42,7 +42,7 @@ use dom::htmlcollection::HTMLCollection; use dom::htmlfieldsetelement::HTMLFieldSetElement; use dom::htmlfontelement::HTMLFontElement; use dom::htmliframeelement::HTMLIFrameElement; -use dom::htmlinputelement::{HTMLInputElement, RawLayoutHTMLInputElementHelpers}; +use dom::htmlinputelement::{HTMLInputElement, LayoutHTMLInputElementHelpers}; use dom::htmllabelelement::HTMLLabelElement; use dom::htmllegendelement::HTMLLegendElement; use dom::htmloptgroupelement::HTMLOptGroupElement; @@ -374,7 +374,7 @@ impl LayoutElementHelpers for LayoutJS<Element> { // a text field match (*self.unsafe_get()).get_attr_val_for_layout(&ns!(""), &atom!("type")) { Some("text") | Some("password") => { - match (*this.unsafe_get()).get_size_for_layout() { + match this.get_size_for_layout() { 0 => None, s => Some(s as i32), } @@ -574,7 +574,7 @@ impl LayoutElementHelpers for LayoutJS<Element> { // TODO option and menuitem can also have a checked state. match self.downcast::<HTMLInputElement>() { Some(input) => unsafe { - (*input.unsafe_get()).get_checked_state_for_layout() + input.get_checked_state_for_layout() }, None => false, } @@ -586,7 +586,7 @@ impl LayoutElementHelpers for LayoutJS<Element> { // TODO progress elements can also be matched with :indeterminate match self.downcast::<HTMLInputElement>() { Some(input) => unsafe { - (*input.unsafe_get()).get_indeterminate_state_for_layout() + input.get_indeterminate_state_for_layout() }, None => false, } diff --git a/components/script/dom/htmlinputelement.rs b/components/script/dom/htmlinputelement.rs index b2f9069c1ec..f1a5bc8a818 100644 --- a/components/script/dom/htmlinputelement.rs +++ b/components/script/dom/htmlinputelement.rs @@ -15,7 +15,7 @@ use dom::bindings::conversions::Castable; use dom::bindings::global::GlobalRef; use dom::bindings::js::{JS, LayoutJS, Root, RootedReference}; use dom::document::Document; -use dom::element::{AttributeMutation, Element, RawLayoutElementHelpers}; +use dom::element::{AttributeMutation, Element, RawLayoutElementHelpers, LayoutElementHelpers}; use dom::event::{Event, EventBubbles, EventCancelable}; use dom::eventtarget::EventTarget; use dom::htmlelement::HTMLElement; @@ -136,15 +136,10 @@ pub trait LayoutHTMLInputElementHelpers { unsafe fn get_size_for_layout(self) -> u32; #[allow(unsafe_code)] unsafe fn get_insertion_point_for_layout(self) -> Option<TextPoint>; -} - -pub trait RawLayoutHTMLInputElementHelpers { #[allow(unsafe_code)] - unsafe fn get_checked_state_for_layout(&self) -> bool; + unsafe fn get_checked_state_for_layout(self) -> bool; #[allow(unsafe_code)] - unsafe fn get_indeterminate_state_for_layout(&self) -> bool; - #[allow(unsafe_code)] - unsafe fn get_size_for_layout(&self) -> u32; + unsafe fn get_indeterminate_state_for_layout(self) -> bool; } impl LayoutHTMLInputElementHelpers for LayoutJS<HTMLInputElement> { @@ -184,7 +179,7 @@ impl LayoutHTMLInputElementHelpers for LayoutJS<HTMLInputElement> { #[allow(unrooted_must_root)] #[allow(unsafe_code)] unsafe fn get_size_for_layout(self) -> u32 { - (*self.unsafe_get()).get_size_for_layout() + (*self.unsafe_get()).size.get() } #[allow(unrooted_must_root)] @@ -196,25 +191,17 @@ impl LayoutHTMLInputElementHelpers for LayoutJS<HTMLInputElement> { _ => None } } -} -impl RawLayoutHTMLInputElementHelpers for HTMLInputElement { #[allow(unrooted_must_root)] #[allow(unsafe_code)] - unsafe fn get_checked_state_for_layout(&self) -> bool { - self.Checked() + unsafe fn get_checked_state_for_layout(self) -> bool { + self.upcast::<Element>().get_state_for_layout().contains(IN_CHECKED_STATE) } #[allow(unrooted_must_root)] #[allow(unsafe_code)] - unsafe fn get_indeterminate_state_for_layout(&self) -> bool { - self.Indeterminate() - } - - #[allow(unrooted_must_root)] - #[allow(unsafe_code)] - unsafe fn get_size_for_layout(&self) -> u32 { - self.size.get() + unsafe fn get_indeterminate_state_for_layout(self) -> bool { + self.upcast::<Element>().get_state_for_layout().contains(IN_INDETERMINATE_STATE) } } From 8fff34e2e78137b5117ab0db86f9aadd56cc50e5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Emilio=20Cobos=20=C3=81lvarez?= <ecoal95@gmail.com> Date: Mon, 2 Nov 2015 14:05:05 +0100 Subject: [PATCH 54/58] Disable WebGL reftests on linux --- tests/wpt/mozilla/meta/mozilla/webgl/clearcolor.html.ini | 4 ++++ .../mozilla/meta/mozilla/webgl/draw_arrays_simple.html.ini | 4 ++++ .../mozilla/meta/mozilla/webgl/tex_image_2d_canvas.html.ini | 4 ++++ .../mozilla/meta/mozilla/webgl/tex_image_2d_canvas2d.html.ini | 4 ++++ .../mozilla/webgl/tex_image_2d_canvas_no_context.html.ini | 4 ++++ .../mozilla/meta/mozilla/webgl/tex_image_2d_simple.html.ini | 4 ++++ 6 files changed, 24 insertions(+) create mode 100644 tests/wpt/mozilla/meta/mozilla/webgl/clearcolor.html.ini create mode 100644 tests/wpt/mozilla/meta/mozilla/webgl/draw_arrays_simple.html.ini create mode 100644 tests/wpt/mozilla/meta/mozilla/webgl/tex_image_2d_canvas.html.ini create mode 100644 tests/wpt/mozilla/meta/mozilla/webgl/tex_image_2d_canvas2d.html.ini create mode 100644 tests/wpt/mozilla/meta/mozilla/webgl/tex_image_2d_canvas_no_context.html.ini create mode 100644 tests/wpt/mozilla/meta/mozilla/webgl/tex_image_2d_simple.html.ini diff --git a/tests/wpt/mozilla/meta/mozilla/webgl/clearcolor.html.ini b/tests/wpt/mozilla/meta/mozilla/webgl/clearcolor.html.ini new file mode 100644 index 00000000000..1e165de7e35 --- /dev/null +++ b/tests/wpt/mozilla/meta/mozilla/webgl/clearcolor.html.ini @@ -0,0 +1,4 @@ +[clearcolor.html] + type: testharness + disabled: + if os == "linux": https://github.com/servo/servo/issues/7931 diff --git a/tests/wpt/mozilla/meta/mozilla/webgl/draw_arrays_simple.html.ini b/tests/wpt/mozilla/meta/mozilla/webgl/draw_arrays_simple.html.ini new file mode 100644 index 00000000000..a2e2bcbe38c --- /dev/null +++ b/tests/wpt/mozilla/meta/mozilla/webgl/draw_arrays_simple.html.ini @@ -0,0 +1,4 @@ +[draw_arrays_simple.html] + type: testharness + disabled: + if os == "linux": https://github.com/servo/servo/issues/7931 diff --git a/tests/wpt/mozilla/meta/mozilla/webgl/tex_image_2d_canvas.html.ini b/tests/wpt/mozilla/meta/mozilla/webgl/tex_image_2d_canvas.html.ini new file mode 100644 index 00000000000..607db76d5b0 --- /dev/null +++ b/tests/wpt/mozilla/meta/mozilla/webgl/tex_image_2d_canvas.html.ini @@ -0,0 +1,4 @@ +[tex_image_2d_canvas.html] + type: testharness + disabled: + if os == "linux": https://github.com/servo/servo/issues/7931 diff --git a/tests/wpt/mozilla/meta/mozilla/webgl/tex_image_2d_canvas2d.html.ini b/tests/wpt/mozilla/meta/mozilla/webgl/tex_image_2d_canvas2d.html.ini new file mode 100644 index 00000000000..7ac62f03efb --- /dev/null +++ b/tests/wpt/mozilla/meta/mozilla/webgl/tex_image_2d_canvas2d.html.ini @@ -0,0 +1,4 @@ +[tex_image_2d_canvas2d.html] + type: testharness + disabled: + if os == "linux": https://github.com/servo/servo/issues/7931 diff --git a/tests/wpt/mozilla/meta/mozilla/webgl/tex_image_2d_canvas_no_context.html.ini b/tests/wpt/mozilla/meta/mozilla/webgl/tex_image_2d_canvas_no_context.html.ini new file mode 100644 index 00000000000..fe7aa9f7c18 --- /dev/null +++ b/tests/wpt/mozilla/meta/mozilla/webgl/tex_image_2d_canvas_no_context.html.ini @@ -0,0 +1,4 @@ +[tex_image_2d_canvas_no_context.html] + type: testharness + disabled: + if os == "linux": https://github.com/servo/servo/issues/7931 diff --git a/tests/wpt/mozilla/meta/mozilla/webgl/tex_image_2d_simple.html.ini b/tests/wpt/mozilla/meta/mozilla/webgl/tex_image_2d_simple.html.ini new file mode 100644 index 00000000000..6e8ee6ab2c1 --- /dev/null +++ b/tests/wpt/mozilla/meta/mozilla/webgl/tex_image_2d_simple.html.ini @@ -0,0 +1,4 @@ +[tex_image_2d_simple.html] + type: testharness + disabled: + if os == "linux": https://github.com/servo/servo/issues/7931 From 4fdf73d1055a31f7acef69fa1152615b6aa8e840 Mon Sep 17 00:00:00 2001 From: Adenilson Cavalcanti <cavalcantii@gmail.com> Date: Mon, 2 Nov 2015 08:53:21 -0800 Subject: [PATCH 55/58] Adding a reference test where a bigger area than the original element is defined in script. The test is now using wpt infrastructure (thanks Manishearth!). --- tests/wpt/mozilla/meta/MANIFEST.json | 14 +++++++- .../mozilla/tests/css/canvas_over_area.html | 32 +++++++++++++++++++ .../tests/css/canvas_over_area_ref.html | 11 +++++++ 3 files changed, 56 insertions(+), 1 deletion(-) create mode 100644 tests/wpt/mozilla/tests/css/canvas_over_area.html create mode 100644 tests/wpt/mozilla/tests/css/canvas_over_area_ref.html diff --git a/tests/wpt/mozilla/meta/MANIFEST.json b/tests/wpt/mozilla/meta/MANIFEST.json index 6132dea8524..1ec8719b951 100644 --- a/tests/wpt/mozilla/meta/MANIFEST.json +++ b/tests/wpt/mozilla/meta/MANIFEST.json @@ -4153,6 +4153,18 @@ ] }, "testharness": { + "css/canvas_over_area.html": [ + { + "path": "css/canvas_over_area.html", + "references": [ + [ + "/_mozilla/css/canvas_over_area_ref.html", + "==" + ] + ], + "url": "/_mozilla/css/canvas_over_area.html" + } + ], "css/test_variable_legal_values.html": [ { "path": "css/test_variable_legal_values.html", @@ -8808,4 +8820,4 @@ "rev": null, "url_base": "/_mozilla/", "version": 2 -} \ No newline at end of file +} diff --git a/tests/wpt/mozilla/tests/css/canvas_over_area.html b/tests/wpt/mozilla/tests/css/canvas_over_area.html new file mode 100644 index 00000000000..d7c3b3e3f78 --- /dev/null +++ b/tests/wpt/mozilla/tests/css/canvas_over_area.html @@ -0,0 +1,32 @@ +<style> + +#base { + background-color: red; + height: 100px; + width: 100px; +} + +#painted { + width: 100px; + height: 100px; + position: relative; + top: -100px; +} +</style> + +<div id="base"></div> +<canvas id="painted"></canvas> + + +<script> +onload = function() { + var obj = document.getElementById("painted"); + obj.width = 500; + obj.height = 500; + var context = obj.getContext("2d"); + context.save(); + context.fillStyle = "green"; + context.fillRect(0, 0, 500, 500); + context.restore(); +}; +</script> diff --git a/tests/wpt/mozilla/tests/css/canvas_over_area_ref.html b/tests/wpt/mozilla/tests/css/canvas_over_area_ref.html new file mode 100644 index 00000000000..5cfa3c76ad6 --- /dev/null +++ b/tests/wpt/mozilla/tests/css/canvas_over_area_ref.html @@ -0,0 +1,11 @@ +<style> + +#base { + background-color: green; + height: 100px; + width: 100px; +} + +</style> + +<div id="base"></div> From bcea688e1f6e974b0a9dd8d77f5b4770a66706de Mon Sep 17 00:00:00 2001 From: Adenilson Cavalcanti <cavalcantii@gmail.com> Date: Mon, 2 Nov 2015 09:13:16 -0800 Subject: [PATCH 56/58] Telling the test runner what compare the test with. --- tests/wpt/mozilla/tests/css/canvas_over_area.html | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/tests/wpt/mozilla/tests/css/canvas_over_area.html b/tests/wpt/mozilla/tests/css/canvas_over_area.html index d7c3b3e3f78..c1e062cad68 100644 --- a/tests/wpt/mozilla/tests/css/canvas_over_area.html +++ b/tests/wpt/mozilla/tests/css/canvas_over_area.html @@ -1,3 +1,6 @@ +<!doctype html> +<body> +<link rel='match' href='canvas_over_area_ref.html'> <style> #base { @@ -30,3 +33,5 @@ onload = function() { context.restore(); }; </script> +</body> +</html> From b1197c31d1bff0192d0e25c1a65e21bd3c76c0f6 Mon Sep 17 00:00:00 2001 From: Adenilson Cavalcanti <cavalcantii@gmail.com> Date: Mon, 2 Nov 2015 09:46:34 -0800 Subject: [PATCH 57/58] The end of the MANIFEST odyssey. --- tests/wpt/mozilla/meta/MANIFEST.json | 36 ++++++++++++++++++---------- 1 file changed, 24 insertions(+), 12 deletions(-) diff --git a/tests/wpt/mozilla/meta/MANIFEST.json b/tests/wpt/mozilla/meta/MANIFEST.json index 1ec8719b951..10980937d89 100644 --- a/tests/wpt/mozilla/meta/MANIFEST.json +++ b/tests/wpt/mozilla/meta/MANIFEST.json @@ -1007,6 +1007,18 @@ "url": "/_mozilla/css/canvas_linear_gradient_a.html" } ], + "css/canvas_over_area.html": [ + { + "path": "css/canvas_over_area.html", + "references": [ + [ + "/_mozilla/css/canvas_over_area_ref.html", + "==" + ] + ], + "url": "/_mozilla/css/canvas_over_area.html" + } + ], "css/case-insensitive-font-family.html": [ { "path": "css/case-insensitive-font-family.html", @@ -4153,18 +4165,6 @@ ] }, "testharness": { - "css/canvas_over_area.html": [ - { - "path": "css/canvas_over_area.html", - "references": [ - [ - "/_mozilla/css/canvas_over_area_ref.html", - "==" - ] - ], - "url": "/_mozilla/css/canvas_over_area.html" - } - ], "css/test_variable_legal_values.html": [ { "path": "css/test_variable_legal_values.html", @@ -5742,6 +5742,18 @@ "url": "/_mozilla/css/canvas_linear_gradient_a.html" } ], + "css/canvas_over_area.html": [ + { + "path": "css/canvas_over_area.html", + "references": [ + [ + "/_mozilla/css/canvas_over_area_ref.html", + "==" + ] + ], + "url": "/_mozilla/css/canvas_over_area.html" + } + ], "css/case-insensitive-font-family.html": [ { "path": "css/case-insensitive-font-family.html", From df7fb8fa326e2b061e2da8c833cc558273db5f37 Mon Sep 17 00:00:00 2001 From: Eli Friedman <eli.friedman@gmail.com> Date: Mon, 2 Nov 2015 14:21:11 -0800 Subject: [PATCH 58/58] Remove JSTraceable implementation from RefCell. The implementation wasn't really right, and we would rather just use DOMRefCell anyway. --- components/script/dom/bindings/trace.rs | 28 +------------------ .../script/dom/canvasrenderingcontext2d.rs | 10 +++---- components/script/dom/document.rs | 6 ++-- components/script/dom/filereader.rs | 7 +++-- components/script/dom/htmlscriptelement.rs | 6 ++-- components/script/dom/keyboardevent.rs | 11 ++++---- components/script/dom/url.rs | 6 ++-- components/script/dom/webglshader.rs | 11 ++++---- components/script/dom/websocket.rs | 6 ++-- components/script/dom/window.rs | 14 +++++----- components/script/script_task.rs | 4 +-- 11 files changed, 43 insertions(+), 66 deletions(-) diff --git a/components/script/dom/bindings/trace.rs b/components/script/dom/bindings/trace.rs index f18719073fc..d656ae0fcad 100644 --- a/components/script/dom/bindings/trace.rs +++ b/components/script/dom/bindings/trace.rs @@ -66,7 +66,7 @@ use selectors::states::*; use serde::{Deserialize, Serialize}; use smallvec::SmallVec; use std::boxed::FnBox; -use std::cell::{Cell, RefCell, UnsafeCell}; +use std::cell::{Cell, UnsafeCell}; use std::collections::hash_state::HashState; use std::collections::{HashMap, HashSet}; use std::ffi::CString; @@ -139,12 +139,6 @@ pub fn trace_object(tracer: *mut JSTracer, description: &str, obj: &Heap<*mut JS } } -impl<T: JSTraceable> JSTraceable for RefCell<T> { - fn trace(&self, trc: *mut JSTracer) { - self.borrow().trace(trc) - } -} - impl<T: JSTraceable> JSTraceable for Rc<T> { fn trace(&self, trc: *mut JSTracer) { (**self).trace(trc) @@ -157,26 +151,6 @@ impl<T: JSTraceable> JSTraceable for Box<T> { } } -impl<T: JSTraceable> JSTraceable for *const T { - fn trace(&self, trc: *mut JSTracer) { - if !self.is_null() { - unsafe { - (**self).trace(trc) - } - } - } -} - -impl<T: JSTraceable> JSTraceable for *mut T { - fn trace(&self, trc: *mut JSTracer) { - if !self.is_null() { - unsafe { - (**self).trace(trc) - } - } - } -} - impl<T: JSTraceable + Copy> JSTraceable for Cell<T> { fn trace(&self, trc: *mut JSTracer) { self.get().trace(trc) diff --git a/components/script/dom/canvasrenderingcontext2d.rs b/components/script/dom/canvasrenderingcontext2d.rs index a42e98a1a03..dbb9718e134 100644 --- a/components/script/dom/canvasrenderingcontext2d.rs +++ b/components/script/dom/canvasrenderingcontext2d.rs @@ -8,6 +8,7 @@ use canvas_traits::{CompositionOrBlending, LineCapStyle, LineJoinStyle}; use canvas_traits::{FillOrStrokeStyle, LinearGradientStyle, RadialGradientStyle, RepetitionStyle}; use cssparser::Color as CSSColor; use cssparser::{Parser, RGBA}; +use dom::bindings::cell::DOMRefCell; use dom::bindings::codegen::Bindings::CanvasRenderingContext2DBinding; use dom::bindings::codegen::Bindings::CanvasRenderingContext2DBinding::CanvasRenderingContext2DMethods; use dom::bindings::codegen::Bindings::CanvasRenderingContext2DBinding::CanvasWindingRule; @@ -37,7 +38,6 @@ use net_traits::image::base::PixelFormat; use net_traits::image_cache_task::ImageResponse; use num::{Float, ToPrimitive}; use std::borrow::ToOwned; -use std::cell::RefCell; use std::str::FromStr; use std::sync::mpsc::channel; use std::{cmp, fmt}; @@ -63,8 +63,8 @@ pub struct CanvasRenderingContext2D { #[ignore_heap_size_of = "Defined in ipc-channel"] ipc_renderer: IpcSender<CanvasMsg>, canvas: JS<HTMLCanvasElement>, - state: RefCell<CanvasContextState>, - saved_states: RefCell<Vec<CanvasContextState>>, + state: DOMRefCell<CanvasContextState>, + saved_states: DOMRefCell<Vec<CanvasContextState>>, } #[must_root] @@ -126,8 +126,8 @@ impl CanvasRenderingContext2D { renderer_id: renderer_id, ipc_renderer: ipc_renderer, canvas: JS::from_ref(canvas), - state: RefCell::new(CanvasContextState::new()), - saved_states: RefCell::new(Vec::new()), + state: DOMRefCell::new(CanvasContextState::new()), + saved_states: DOMRefCell::new(Vec::new()), } } diff --git a/components/script/dom/document.rs b/components/script/dom/document.rs index 781c53e2331..42530e4922c 100644 --- a/components/script/dom/document.rs +++ b/components/script/dom/document.rs @@ -89,7 +89,7 @@ use selectors::states::*; use std::ascii::AsciiExt; use std::borrow::ToOwned; use std::boxed::FnBox; -use std::cell::{Cell, Ref, RefCell, RefMut}; +use std::cell::{Cell, Ref, RefMut}; use std::collections::HashMap; use std::collections::hash_map::Entry::{Occupied, Vacant}; use std::default::Default; @@ -163,7 +163,7 @@ pub struct Document { /// https://html.spec.whatwg.org/multipage/#list-of-animation-frame-callbacks /// List of animation frame callbacks #[ignore_heap_size_of = "closures are hard"] - animation_frame_list: RefCell<HashMap<u32, Box<FnBox(f64)>>>, + animation_frame_list: DOMRefCell<HashMap<u32, Box<FnBox(f64)>>>, /// Tracks all outstanding loads related to this document. loader: DOMRefCell<DocumentLoader>, /// The current active HTML parser, to allow resuming after interruptions. @@ -1262,7 +1262,7 @@ impl Document { asap_scripts_set: DOMRefCell::new(vec!()), scripting_enabled: Cell::new(true), animation_frame_ident: Cell::new(0), - animation_frame_list: RefCell::new(HashMap::new()), + animation_frame_list: DOMRefCell::new(HashMap::new()), loader: DOMRefCell::new(doc_loader), current_parser: Default::default(), reflow_timeout: Cell::new(None), diff --git a/components/script/dom/filereader.rs b/components/script/dom/filereader.rs index dce7ef438dc..606debbc106 100644 --- a/components/script/dom/filereader.rs +++ b/components/script/dom/filereader.rs @@ -2,6 +2,7 @@ * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ +use dom::bindings::cell::DOMRefCell; use dom::bindings::codegen::Bindings::BlobBinding::BlobMethods; use dom::bindings::codegen::Bindings::EventHandlerBinding::EventHandlerNonNull; use dom::bindings::codegen::Bindings::FileReaderBinding::{self, FileReaderConstants, FileReaderMethods}; @@ -23,7 +24,7 @@ use hyper::mime::{Attr, Mime}; use rustc_serialize::base64::{CharacterSet, Config, Newline, ToBase64}; use script_task::ScriptTaskEventCategory::FileRead; use script_task::{CommonScriptMsg, Runnable, ScriptChan, ScriptPort}; -use std::cell::{Cell, RefCell}; +use std::cell::Cell; use std::sync::mpsc; use std::sync::mpsc::Receiver; use util::str::DOMString; @@ -72,7 +73,7 @@ pub struct FileReader { global: GlobalField, ready_state: Cell<FileReaderReadyState>, error: MutNullableHeap<JS<DOMException>>, - result: RefCell<Option<DOMString>>, + result: DOMRefCell<Option<DOMString>>, generation_id: Cell<GenerationId>, } @@ -83,7 +84,7 @@ impl FileReader { global: GlobalField::from_rooted(&global), ready_state: Cell::new(FileReaderReadyState::Empty), error: MutNullableHeap::new(None), - result: RefCell::new(None), + result: DOMRefCell::new(None), generation_id: Cell::new(GenerationId(0)), } } diff --git a/components/script/dom/htmlscriptelement.rs b/components/script/dom/htmlscriptelement.rs index 4f1b0ca135a..3b0f17a881f 100644 --- a/components/script/dom/htmlscriptelement.rs +++ b/components/script/dom/htmlscriptelement.rs @@ -37,7 +37,7 @@ use network_listener::{NetworkListener, PreInvoke}; use script_task::ScriptTaskEventCategory::ScriptEvent; use script_task::{CommonScriptMsg, Runnable, ScriptChan}; use std::ascii::AsciiExt; -use std::cell::{Cell, RefCell}; +use std::cell::Cell; use std::mem; use std::sync::{Arc, Mutex}; use url::{Url, UrlParser}; @@ -65,7 +65,7 @@ pub struct HTMLScriptElement { parser_document: JS<Document>, /// The source this script was loaded from - load: RefCell<Option<ScriptOrigin>>, + load: DOMRefCell<Option<ScriptOrigin>>, #[ignore_heap_size_of = "Defined in rust-encoding"] /// https://html.spec.whatwg.org/multipage/#concept-script-encoding @@ -83,7 +83,7 @@ impl HTMLScriptElement { non_blocking: Cell::new(creator != ElementCreator::ParserCreated), ready_to_be_parser_executed: Cell::new(false), parser_document: JS::from_ref(document), - load: RefCell::new(None), + load: DOMRefCell::new(None), block_character_encoding: DOMRefCell::new(UTF_8 as EncodingRef), } } diff --git a/components/script/dom/keyboardevent.rs b/components/script/dom/keyboardevent.rs index e3d2bf4f657..7883cc89306 100644 --- a/components/script/dom/keyboardevent.rs +++ b/components/script/dom/keyboardevent.rs @@ -2,6 +2,7 @@ * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ +use dom::bindings::cell::DOMRefCell; use dom::bindings::codegen::Bindings::KeyboardEventBinding; use dom::bindings::codegen::Bindings::KeyboardEventBinding::{KeyboardEventConstants, KeyboardEventMethods}; use dom::bindings::codegen::Bindings::UIEventBinding::UIEventMethods; @@ -17,7 +18,7 @@ use msg::constellation_msg; use msg::constellation_msg::{ALT, CONTROL, SHIFT, SUPER}; use msg::constellation_msg::{Key, KeyModifiers}; use std::borrow::ToOwned; -use std::cell::{Cell, RefCell}; +use std::cell::Cell; use util::str::DOMString; no_jsmanaged_fields!(Key); @@ -26,8 +27,8 @@ no_jsmanaged_fields!(Key); pub struct KeyboardEvent { uievent: UIEvent, key: Cell<Option<Key>>, - key_string: RefCell<DOMString>, - code: RefCell<DOMString>, + key_string: DOMRefCell<DOMString>, + code: DOMRefCell<DOMString>, location: Cell<u32>, ctrl: Cell<bool>, alt: Cell<bool>, @@ -44,8 +45,8 @@ impl KeyboardEvent { KeyboardEvent { uievent: UIEvent::new_inherited(), key: Cell::new(None), - key_string: RefCell::new("".to_owned()), - code: RefCell::new("".to_owned()), + key_string: DOMRefCell::new("".to_owned()), + code: DOMRefCell::new("".to_owned()), location: Cell::new(0), ctrl: Cell::new(false), alt: Cell::new(false), diff --git a/components/script/dom/url.rs b/components/script/dom/url.rs index 9ff22b53597..3bb1d48cee9 100644 --- a/components/script/dom/url.rs +++ b/components/script/dom/url.rs @@ -2,6 +2,7 @@ * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ +use dom::bindings::cell::DOMRefCell; use dom::bindings::codegen::Bindings::URLBinding::{self, URLMethods}; use dom::bindings::error::{Error, ErrorResult, Fallible}; use dom::bindings::global::GlobalRef; @@ -10,7 +11,6 @@ use dom::bindings::str::USVString; use dom::bindings::utils::{Reflector, reflect_dom_object}; use dom::urlhelper::UrlHelper; use std::borrow::ToOwned; -use std::cell::RefCell; use url::{Host, ParseResult, Url, UrlParser}; use util::str::DOMString; @@ -20,7 +20,7 @@ pub struct URL { reflector_: Reflector, // https://url.spec.whatwg.org/#concept-urlutils-url - url: RefCell<Url>, + url: DOMRefCell<Url>, // https://url.spec.whatwg.org/#concept-urlutils-get-the-base base: Option<Url>, @@ -30,7 +30,7 @@ impl URL { fn new_inherited(url: Url, base: Option<Url>) -> URL { URL { reflector_: Reflector::new(), - url: RefCell::new(url), + url: DOMRefCell::new(url), base: base, } } diff --git a/components/script/dom/webglshader.rs b/components/script/dom/webglshader.rs index 65dc958033f..cd7ea165ae6 100644 --- a/components/script/dom/webglshader.rs +++ b/components/script/dom/webglshader.rs @@ -5,6 +5,7 @@ // https://www.khronos.org/registry/webgl/specs/latest/1.0/webgl.idl use angle::hl::{BuiltInResources, Output, ShaderValidator}; use canvas_traits::{CanvasMsg, CanvasWebGLMsg, WebGLError, WebGLResult, WebGLShaderParameter}; +use dom::bindings::cell::DOMRefCell; use dom::bindings::codegen::Bindings::WebGLRenderingContextBinding::WebGLRenderingContextConstants as constants; use dom::bindings::codegen::Bindings::WebGLShaderBinding; use dom::bindings::global::GlobalRef; @@ -12,7 +13,7 @@ use dom::bindings::js::Root; use dom::bindings::utils::reflect_dom_object; use dom::webglobject::WebGLObject; use ipc_channel::ipc::{self, IpcSender}; -use std::cell::{Cell, RefCell}; +use std::cell::Cell; use std::sync::{ONCE_INIT, Once}; #[derive(Clone, Copy, PartialEq, Debug, JSTraceable, HeapSizeOf)] @@ -27,8 +28,8 @@ pub struct WebGLShader { webgl_object: WebGLObject, id: u32, gl_type: u32, - source: RefCell<Option<String>>, - info_log: RefCell<Option<String>>, + source: DOMRefCell<Option<String>>, + info_log: DOMRefCell<Option<String>>, is_deleted: Cell<bool>, compilation_status: Cell<ShaderCompilationStatus>, #[ignore_heap_size_of = "Defined in ipc-channel"] @@ -50,8 +51,8 @@ impl WebGLShader { webgl_object: WebGLObject::new_inherited(), id: id, gl_type: shader_type, - source: RefCell::new(None), - info_log: RefCell::new(None), + source: DOMRefCell::new(None), + info_log: DOMRefCell::new(None), is_deleted: Cell::new(false), compilation_status: Cell::new(ShaderCompilationStatus::NotCompiled), renderer: renderer, diff --git a/components/script/dom/websocket.rs b/components/script/dom/websocket.rs index 88f3c6a2f8e..c0933aaa7e0 100644 --- a/components/script/dom/websocket.rs +++ b/components/script/dom/websocket.rs @@ -28,7 +28,7 @@ use net_traits::hosts::replace_hosts; use script_task::ScriptTaskEventCategory::WebSocketEvent; use script_task::{CommonScriptMsg, Runnable}; use std::borrow::ToOwned; -use std::cell::{Cell, RefCell}; +use std::cell::Cell; use std::sync::{Arc, Mutex}; use std::{ptr, slice}; use util::str::DOMString; @@ -133,7 +133,7 @@ pub struct WebSocket { buffered_amount: Cell<u32>, clearing_buffer: Cell<bool>, //Flag to tell if there is a running task to clear buffered_amount #[ignore_heap_size_of = "Defined in std"] - sender: RefCell<Option<Arc<Mutex<Sender<WebSocketStream>>>>>, + sender: DOMRefCell<Option<Arc<Mutex<Sender<WebSocketStream>>>>>, failed: Cell<bool>, //Flag to tell if websocket was closed due to failure full: Cell<bool>, //Flag to tell if websocket queue is full clean_close: Cell<bool>, //Flag to tell if the websocket closed cleanly (not due to full or fail) @@ -175,7 +175,7 @@ impl WebSocket { buffered_amount: Cell::new(0), clearing_buffer: Cell::new(false), failed: Cell::new(false), - sender: RefCell::new(None), + sender: DOMRefCell::new(None), full: Cell::new(false), clean_close: Cell::new(true), code: Cell::new(0), diff --git a/components/script/dom/window.rs b/components/script/dom/window.rs index c074935938b..d87b04cbfba 100644 --- a/components/script/dom/window.rs +++ b/components/script/dom/window.rs @@ -58,7 +58,7 @@ use script_traits::{ConstellationControlMsg, TimerEventChan, TimerEventId, Timer use selectors::parser::PseudoElement; use std::ascii::AsciiExt; use std::borrow::ToOwned; -use std::cell::{Cell, Ref, RefCell}; +use std::cell::{Cell, Ref}; use std::collections::HashSet; use std::default::Default; use std::ffi::CString; @@ -144,9 +144,9 @@ pub struct Window { /// For sending timeline markers. Will be ignored if /// no devtools server #[ignore_heap_size_of = "TODO(#6909) need to measure HashSet"] - devtools_markers: RefCell<HashSet<TimelineMarkerType>>, + devtools_markers: DOMRefCell<HashSet<TimelineMarkerType>>, #[ignore_heap_size_of = "channels are hard"] - devtools_marker_sender: RefCell<Option<IpcSender<TimelineMarker>>>, + devtools_marker_sender: DOMRefCell<Option<IpcSender<TimelineMarker>>>, /// A flag to indicate whether the developer tools have requested live updates of /// page changes. @@ -208,7 +208,7 @@ pub struct Window { /// A channel for communicating results of async scripts back to the webdriver server #[ignore_heap_size_of = "channels are hard"] - webdriver_script_chan: RefCell<Option<IpcSender<WebDriverJSResult>>>, + webdriver_script_chan: DOMRefCell<Option<IpcSender<WebDriverJSResult>>>, /// The current state of the window object current_state: Cell<WindowState>, @@ -1276,10 +1276,10 @@ impl Window { pending_reflow_count: Cell::new(0), current_state: Cell::new(WindowState::Alive), - devtools_marker_sender: RefCell::new(None), - devtools_markers: RefCell::new(HashSet::new()), + devtools_marker_sender: DOMRefCell::new(None), + devtools_markers: DOMRefCell::new(HashSet::new()), devtools_wants_updates: Cell::new(false), - webdriver_script_chan: RefCell::new(None), + webdriver_script_chan: DOMRefCell::new(None), }; WindowBinding::Wrap(runtime.cx(), win) diff --git a/components/script/script_task.rs b/components/script/script_task.rs index 4939a58e086..cd4a4a09308 100644 --- a/components/script/script_task.rs +++ b/components/script/script_task.rs @@ -414,7 +414,7 @@ pub struct ScriptTask { mouse_over_targets: DOMRefCell<Vec<JS<Element>>>, /// List of pipelines that have been owned and closed by this script task. - closed_pipelines: RefCell<HashSet<PipelineId>>, + closed_pipelines: DOMRefCell<HashSet<PipelineId>>, scheduler_chan: Sender<TimerEventRequest>, timer_event_chan: Sender<TimerEvent>, @@ -643,7 +643,7 @@ impl ScriptTask { js_runtime: Rc::new(runtime), mouse_over_targets: DOMRefCell::new(vec!()), - closed_pipelines: RefCell::new(HashSet::new()), + closed_pipelines: DOMRefCell::new(HashSet::new()), scheduler_chan: state.scheduler_chan, timer_event_chan: timer_event_chan,