aboutsummaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorPatrick Walton <pcwalton@mimiga.net>2015-08-18 18:41:55 -0700
committerPatrick Walton <pcwalton@mimiga.net>2015-08-18 18:44:50 -0700
commit02b15e016d7adb89c9142e9e89a7048c15d9c085 (patch)
treeeb83a72f980ac3279d85fff7d1fc2153549b3d7a /tests
parent19d466b06250f10169e88fc7f0b447c7f2f8209e (diff)
downloadservo-02b15e016d7adb89c9142e9e89a7048c15d9c085.tar.gz
servo-02b15e016d7adb89c9142e9e89a7048c15d9c085.zip
layout: Avoid a division by zero in `tile_image()`.
Fixes a crash on Facebook Timeline.
Diffstat (limited to 'tests')
-rw-r--r--tests/ref/background_size_zero_a.html9
-rw-r--r--tests/ref/background_size_zero_ref.html3
-rw-r--r--tests/ref/basic.list1
3 files changed, 13 insertions, 0 deletions
diff --git a/tests/ref/background_size_zero_a.html b/tests/ref/background_size_zero_a.html
new file mode 100644
index 00000000000..c059881513b
--- /dev/null
+++ b/tests/ref/background_size_zero_a.html
@@ -0,0 +1,9 @@
+<!DOCTYPE html>
+<style>
+body {
+ background-image: url(400x400_green.png);
+ background-size: 0 0;
+}
+</style>
+Don't crash!
+
diff --git a/tests/ref/background_size_zero_ref.html b/tests/ref/background_size_zero_ref.html
new file mode 100644
index 00000000000..017aab9d2bc
--- /dev/null
+++ b/tests/ref/background_size_zero_ref.html
@@ -0,0 +1,3 @@
+<!DOCTYPE html>
+Don't crash!
+
diff --git a/tests/ref/basic.list b/tests/ref/basic.list
index 5eba71f26b0..3d3ceeba10f 100644
--- a/tests/ref/basic.list
+++ b/tests/ref/basic.list
@@ -37,6 +37,7 @@ flaky_cpu == append_style_a.html append_style_b.html
== background_repeat_y_a.html background_repeat_y_b.html
== background_size_a.html background_size_ref.html
== background_size_shorthand_a.html background_size_shorthand_ref.html
+== background_size_zero_a.html background_size_zero_ref.html
== background_style_attr.html background_ref.html
== basic_width_px.html basic_width_em.html
== block_formatting_context_a.html block_formatting_context_ref.html