aboutsummaryrefslogtreecommitdiffstats
path: root/python/servo
diff options
context:
space:
mode:
authorbors-servo <lbergstrom+bors@mozilla.com>2016-03-29 13:34:08 +0530
committerbors-servo <lbergstrom+bors@mozilla.com>2016-03-29 13:34:08 +0530
commitdf73a18a61e57f62e2e17541d45dcd3818b35b7c (patch)
treefbb298d93dc84cef14074dcd7ed061efeab50b8f /python/servo
parentaac2da75f40f4c55a4b450b6d9d134429fcf741e (diff)
parent6de7228945f9e9882ae5a8d45fd3ed40906057db (diff)
downloadservo-df73a18a61e57f62e2e17541d45dcd3818b35b7c.tar.gz
servo-df73a18a61e57f62e2e17541d45dcd3818b35b7c.zip
Auto merge of #10208 - jrasanen:jr/issue10196, r=SimonSapin
Generate html and json of supported css properties. Fixes #10196. Outputs html and json of supported css properties to `target/doc/` directory when deploying github-pages. <!-- Reviewable:start --> --- This change is [<img src="https://reviewable.io/review_button.svg" height="35" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/10208) <!-- Reviewable:end -->
Diffstat (limited to 'python/servo')
-rw-r--r--python/servo/testing_commands.py11
1 files changed, 9 insertions, 2 deletions
diff --git a/python/servo/testing_commands.py b/python/servo/testing_commands.py
index b99dd147b9a..acfce6157cf 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 = 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