Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 3 additions & 4 deletions compliance_tool/aas_compliance_tool/cli.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) 2025 the Eclipse BaSyx Authors
# Copyright (c) 2026 the Eclipse BaSyx Authors
#
# This program and the accompanying materials are made available under the terms of the MIT License, available in
# the LICENSE file of this project.
Expand Down Expand Up @@ -76,7 +76,7 @@ def parse_cli_arguments() -> argparse.ArgumentParser:
parser.add_argument('-v', '--verbose', help="Print detailed information for each check. Multiple -v options "
"increase the verbosity. 1: Detailed error information, 2: Additional "
"detailed success information", action='count', default=0)
parser.add_argument('-q', '--quite', help="no information output if successful", action='store_true')
parser.add_argument('-q', '--quiet', help="no information output if successful", action='store_true')
group = parser.add_mutually_exclusive_group(required=True)
group.add_argument('--json', help="Use AAS json format when checking or creating files", action='store_true')
group.add_argument('--xml', help="Use AAS xml format when checking or creating files", action='store_true')
Expand Down Expand Up @@ -177,9 +177,8 @@ def main():
**data_checker_kwargs)
else:
parser.error("f or files requires two file path.")
exit()

if manager.status is Status.SUCCESS and args.quite:
if manager.status is Status.SUCCESS and args.quiet:
exit()

print(manager.format_state_manager(args.verbose))
Expand Down
8 changes: 7 additions & 1 deletion compliance_tool/test/test_aas_compliance_tool.py
Original file line number Diff line number Diff line change
Expand Up @@ -115,11 +115,17 @@ def test_parse_args(self) -> None:
self.assertNotIn('ERROR', str(output.stderr))
self.assertIn('INFO', str(output.stdout))

# test quite
# test quiet (short form)
output = _run_compliance_tool("e", os.path.join(test_file_path, "test_demo_full_example.json"), "--json", "-q")
self.assertEqual(0, output.returncode)
self.assertEqual("b''", str(output.stdout))

# test quiet (long form -- previously misspelled as --quite)
output = _run_compliance_tool("e", os.path.join(test_file_path, "test_demo_full_example.json"), "--json",
"--quiet")
self.assertEqual(0, output.returncode)
self.assertEqual("b''", str(output.stdout))

# test logfile
output = _run_compliance_tool("e", os.path.join(test_file_path, "test_demo_full_example.json"), "--json", "-l")
self.assertNotEqual(0, output.returncode)
Expand Down
Loading