mirror of
https://github.com/1f349/dendrite.git
synced 2024-11-26 05:31:32 +00:00
Are we synapse yet: Accept tests without a group rather than dying (#1142)
Produces output like: ``` Non-Spec APIs: 0% (0/52 tests) -------------- Non-Spec API : 0% (0/50 tests) Unknown API (no group specified): 0% (0/2 tests) ``` Co-authored-by: Neil Alexander <neilalexander@users.noreply.github.com>
This commit is contained in:
parent
23bed196e6
commit
c7f7ae69eb
@ -33,6 +33,7 @@ import sys
|
|||||||
|
|
||||||
test_mappings = {
|
test_mappings = {
|
||||||
"nsp": "Non-Spec API",
|
"nsp": "Non-Spec API",
|
||||||
|
"unk": "Unknown API (no group specified)",
|
||||||
"f": "Federation", # flag to mark test involves federation
|
"f": "Federation", # flag to mark test involves federation
|
||||||
|
|
||||||
"federation_apis": {
|
"federation_apis": {
|
||||||
@ -214,7 +215,8 @@ def main(results_tap_path, verbose):
|
|||||||
# }
|
# }
|
||||||
},
|
},
|
||||||
"nonspec": {
|
"nonspec": {
|
||||||
"nsp": {}
|
"nsp": {},
|
||||||
|
"unk": {}
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
with open(results_tap_path, "r") as f:
|
with open(results_tap_path, "r") as f:
|
||||||
@ -225,7 +227,7 @@ def main(results_tap_path, verbose):
|
|||||||
name = test_result["name"]
|
name = test_result["name"]
|
||||||
group_id = test_name_to_group_id.get(name)
|
group_id = test_name_to_group_id.get(name)
|
||||||
if not group_id:
|
if not group_id:
|
||||||
raise Exception("The test '%s' doesn't have a group" % (name,))
|
summary["nonspec"]["unk"][name] = test_result["ok"]
|
||||||
if group_id == "nsp":
|
if group_id == "nsp":
|
||||||
summary["nonspec"]["nsp"][name] = test_result["ok"]
|
summary["nonspec"]["nsp"][name] = test_result["ok"]
|
||||||
elif group_id in test_mappings["federation_apis"]:
|
elif group_id in test_mappings["federation_apis"]:
|
||||||
|
Loading…
Reference in New Issue
Block a user