-# Copyright (c) 2023 Cisco and/or its affiliates.
+# Copyright (c) 2024 Cisco and/or its affiliates.
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at:
Units are ignored, as both parent and current are tested
with the same CSIT code so the unit should be identical.
+ The test results are sorted by test_id,
+ as the filesystem order is not deterministic enough.
+
The result is also cached as results.json file.
:param dirpath: Path to the directory tree to examine.
results[name] = [result_object["bandwidth"]["value"]]
else:
raise RuntimeError(f"Unknown result type: {result_type}")
+ results = {test_id: results[test_id] for test_id in sorted(results)}
with open(resultpath, "wt", encoding="utf8") as file_out:
json.dump(results, file_out, indent=1, separators=(", ", ": "))
return results