[gtk+/css-fixes: 2/8] Add reftest to test border-style: none



commit 7a2b0abac9835f48f5e061cdc3ea30c2f3d9c45d
Author: Alexander Larsson <alexl redhat com>
Date:   Thu Nov 24 18:25:08 2011 +0100

    Add reftest to test border-style: none
    
    From the css docs at http://www.w3.org/TR/CSS2/box.html:
    
    8.5.1 Border width: 'border-top-width', 'border-right-width', 'border-bottom-width',
    'border-left-width', and 'border-width'
    
    Computed value:  	absolute length; '0' if the border style is 'none' or 'hidden'
    
    So, if i specify border-style none and a border-width > 0 that should give the
    same result as border-width 0.

 tests/reftests/Makefile.am              |    3 +++
 tests/reftests/border-style-none.css    |   19 +++++++++++++++++++
 tests/reftests/border-style-none.ref.ui |   19 +++++++++++++++++++
 tests/reftests/border-style-none.ui     |   18 ++++++++++++++++++
 4 files changed, 59 insertions(+), 0 deletions(-)
---
diff --git a/tests/reftests/Makefile.am b/tests/reftests/Makefile.am
index 844643a..b3ffb1e 100644
--- a/tests/reftests/Makefile.am
+++ b/tests/reftests/Makefile.am
@@ -57,6 +57,9 @@ EXTRA_DIST += \
 	border-radius-clamp.css\
 	border-radius-clamp.ref.ui \
 	border-radius-clamp.ui \
+	border-style-none.css \
+	border-style-none.ref.ui \
+	border-style-none.ui \
 	box-packing.css \
 	box-packing.ref.ui \
 	box-packing.ui \
diff --git a/tests/reftests/border-style-none.css b/tests/reftests/border-style-none.css
new file mode 100644
index 0000000..d54ec1a
--- /dev/null
+++ b/tests/reftests/border-style-none.css
@@ -0,0 +1,19 @@
+* {
+  border-color: red;
+  border-image: none;
+  background-image: none;
+}
+
+GtkButton {
+  background-color: purple;
+  border-style: solid;
+  border-width: 0;
+  border-radius: 15;
+}
+
+#reference {
+  border-style: none;
+  border-width: 5;
+  border-radius: 15;
+}
+
diff --git a/tests/reftests/border-style-none.ref.ui b/tests/reftests/border-style-none.ref.ui
new file mode 100644
index 0000000..2fce514
--- /dev/null
+++ b/tests/reftests/border-style-none.ref.ui
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<interface>
+  <!-- interface-requires gtk+ 3.0 -->
+  <object class="GtkWindow" id="window1">
+    <property name="can_focus">False</property>
+    <property name="type">popup</property>
+    <child>
+      <object class="GtkButton" id="button1">
+        <property name="name">reference</property>
+        <property name="visible">True</property>
+        <property name="can_focus">True</property>
+        <property name="receives_default">True</property>
+        <property name="use_action_appearance">False</property>
+	<property name="width_request">144</property>
+        <property name="height_request">144</property>
+      </object>
+    </child>
+  </object>
+</interface>
diff --git a/tests/reftests/border-style-none.ui b/tests/reftests/border-style-none.ui
new file mode 100644
index 0000000..7b3abc5
--- /dev/null
+++ b/tests/reftests/border-style-none.ui
@@ -0,0 +1,18 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<interface>
+  <!-- interface-requires gtk+ 3.0 -->
+  <object class="GtkWindow" id="window1">
+    <property name="can_focus">False</property>
+    <property name="type">popup</property>
+    <child>
+      <object class="GtkButton" id="button1">
+        <property name="visible">True</property>
+        <property name="can_focus">True</property>
+        <property name="receives_default">True</property>
+        <property name="use_action_appearance">False</property>
+	<property name="width_request">144</property>
+        <property name="height_request">144</property>
+      </object>
+    </child>
+  </object>
+</interface>



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]