aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--components/style/list_properties.py1
-rw-r--r--python/servo/testing_commands.py11
2 files changed, 9 insertions, 3 deletions
diff --git a/components/style/list_properties.py b/components/style/list_properties.py
index a56c0141c76..34043be888b 100644
--- a/components/style/list_properties.py
+++ b/components/style/list_properties.py
@@ -23,7 +23,6 @@ properties = dict(
)
json_dump = json.dumps(properties, indent=4)
-print(json_dump)
#
# Resolve path to doc directory and write CSS properties and JSON.
diff --git a/python/servo/testing_commands.py b/python/servo/testing_commands.py
index b99dd147b9a..95bace157d5 100644
--- a/python/servo/testing_commands.py
+++ b/python/servo/testing_commands.py
@@ -163,10 +163,17 @@ class MachCommands(CommandBase):
@CommandArgument('test_name', nargs=argparse.REMAINDER,
help="Only run tests that match this pattern or file path")
def test_unit(self, test_name=None, package=None):
- properties = json.loads(subprocess.check_output([
+ subprocess.check_output([
sys.executable,
path.join(self.context.topdir, "components", "style", "list_properties.py")
- ]))
+ ])
+
+ this_file = style = os.path.dirname(__file__)
+ servo_doc_path = os.path.abspath(os.path.join(this_file, '../', '../', 'target', 'doc', 'servo'))
+
+ with open(os.path.join(servo_doc_path, 'css-properties.json'), 'r') as property_file:
+ properties = json.loads(property_file.read())
+
assert len(properties) >= 100
assert "margin-top" in properties
assert "margin" in properties