-# Copyright (c) 2021 Cisco and/or its affiliates.
+# Copyright (c) 2022 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:
*.pyc
*~
.idea
+*.raw.json
+*.info.json
\ No newline at end of file
-# Copyright (c) 2021 Cisco and/or its affiliates.
+# Copyright (c) 2022 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:
impl_log="edited_files.log"
git diff --name-only HEAD~ > "${impl_log}"
-if ! grep -q '^resources/libraries/python/model' "${impl_log}"; then
+if ! grep -q '^docs/model/current/schema/test_case*' "${impl_log}"; then
# Failing grep means no model edits.
warn "No model implementation edits detected."
warn
-# Copyright (c) 2021 Cisco and/or its affiliates.
+# Copyright (c) 2022 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:
"""
raw_data = _pre_serialize_root(raw_data)
os.makedirs(os.path.dirname(raw_file_path), exist_ok=True)
- with open(raw_file_path, u"xt", encoding="utf-8") as file_out:
+ with open(raw_file_path, u"wt", encoding="utf-8") as file_out:
json.dump(raw_data, file_out, indent=1)
-# Copyright (c) 2021 Cisco and/or its affiliates.
+# Copyright (c) 2022 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:
suite_data[u"teardown_log"] = teardown_data[u"log"]
suite_info_path = u"suite".join(teardown_info_path.rsplit(u"teardown", 1))
- with open(suite_info_path, u"xt", encoding="utf-8") as file_out:
+ with open(suite_info_path, u"wt", encoding="utf-8") as file_out:
json.dump(suite_data, file_out, indent=1)
# We moved everything useful from temporary setup/teardown info files.
os.remove(setup_info_path)
data = _convert_to_info_in_memory(data)
- with open(to_info_path, u"xt", encoding="utf-8") as file_out:
+ with open(to_info_path, u"wt", encoding="utf-8") as file_out:
json.dump(data, file_out, indent=1)
if to_info_path.endswith(u"/teardown.info.json"):
to_info_path = _merge_into_suite_info_file(to_info_path)