ara-cli 0.1.9.77__py3-none-any.whl → 0.1.10.8__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of ara-cli might be problematic. Click here for more details.
- ara_cli/__init__.py +18 -2
- ara_cli/__main__.py +245 -66
- ara_cli/ara_command_action.py +128 -63
- ara_cli/ara_config.py +201 -177
- ara_cli/ara_subcommands/__init__.py +0 -0
- ara_cli/ara_subcommands/autofix.py +26 -0
- ara_cli/ara_subcommands/chat.py +27 -0
- ara_cli/ara_subcommands/classifier_directory.py +16 -0
- ara_cli/ara_subcommands/common.py +100 -0
- ara_cli/ara_subcommands/create.py +75 -0
- ara_cli/ara_subcommands/delete.py +22 -0
- ara_cli/ara_subcommands/extract.py +22 -0
- ara_cli/ara_subcommands/fetch_templates.py +14 -0
- ara_cli/ara_subcommands/list.py +65 -0
- ara_cli/ara_subcommands/list_tags.py +25 -0
- ara_cli/ara_subcommands/load.py +48 -0
- ara_cli/ara_subcommands/prompt.py +136 -0
- ara_cli/ara_subcommands/read.py +47 -0
- ara_cli/ara_subcommands/read_status.py +20 -0
- ara_cli/ara_subcommands/read_user.py +20 -0
- ara_cli/ara_subcommands/reconnect.py +27 -0
- ara_cli/ara_subcommands/rename.py +22 -0
- ara_cli/ara_subcommands/scan.py +14 -0
- ara_cli/ara_subcommands/set_status.py +22 -0
- ara_cli/ara_subcommands/set_user.py +22 -0
- ara_cli/ara_subcommands/template.py +16 -0
- ara_cli/artefact_autofix.py +214 -28
- ara_cli/artefact_creator.py +5 -8
- ara_cli/artefact_deleter.py +2 -4
- ara_cli/artefact_fuzzy_search.py +13 -6
- ara_cli/artefact_lister.py +29 -55
- ara_cli/artefact_models/artefact_data_retrieval.py +23 -0
- ara_cli/artefact_models/artefact_model.py +106 -25
- ara_cli/artefact_models/artefact_templates.py +23 -13
- ara_cli/artefact_models/epic_artefact_model.py +11 -2
- ara_cli/artefact_models/feature_artefact_model.py +56 -1
- ara_cli/artefact_models/userstory_artefact_model.py +15 -3
- ara_cli/artefact_reader.py +4 -5
- ara_cli/artefact_renamer.py +6 -2
- ara_cli/artefact_scan.py +2 -2
- ara_cli/chat.py +594 -219
- ara_cli/chat_agent/__init__.py +0 -0
- ara_cli/chat_agent/agent_communicator.py +62 -0
- ara_cli/chat_agent/agent_process_manager.py +211 -0
- ara_cli/chat_agent/agent_status_manager.py +73 -0
- ara_cli/chat_agent/agent_workspace_manager.py +76 -0
- ara_cli/commands/__init__.py +0 -0
- ara_cli/commands/command.py +7 -0
- ara_cli/commands/extract_command.py +15 -0
- ara_cli/commands/load_command.py +65 -0
- ara_cli/commands/load_image_command.py +34 -0
- ara_cli/commands/read_command.py +117 -0
- ara_cli/completers.py +144 -0
- ara_cli/directory_navigator.py +37 -4
- ara_cli/error_handler.py +134 -0
- ara_cli/file_classifier.py +3 -2
- ara_cli/file_loaders/__init__.py +0 -0
- ara_cli/file_loaders/binary_file_loader.py +33 -0
- ara_cli/file_loaders/document_file_loader.py +34 -0
- ara_cli/file_loaders/document_reader.py +245 -0
- ara_cli/file_loaders/document_readers.py +233 -0
- ara_cli/file_loaders/file_loader.py +50 -0
- ara_cli/file_loaders/file_loaders.py +123 -0
- ara_cli/file_loaders/image_processor.py +89 -0
- ara_cli/file_loaders/markdown_reader.py +75 -0
- ara_cli/file_loaders/text_file_loader.py +187 -0
- ara_cli/global_file_lister.py +51 -0
- ara_cli/prompt_extractor.py +214 -87
- ara_cli/prompt_handler.py +508 -146
- ara_cli/tag_extractor.py +54 -24
- ara_cli/template_loader.py +245 -0
- ara_cli/template_manager.py +14 -4
- ara_cli/templates/prompt-modules/commands/empty.commands.md +2 -12
- ara_cli/templates/prompt-modules/commands/extract_general.commands.md +12 -0
- ara_cli/templates/prompt-modules/commands/extract_markdown.commands.md +11 -0
- ara_cli/templates/prompt-modules/commands/extract_python.commands.md +13 -0
- ara_cli/templates/prompt-modules/commands/feature_add_or_modifiy_specified_behavior.commands.md +36 -0
- ara_cli/templates/prompt-modules/commands/feature_generate_initial_specified_bevahior.commands.md +53 -0
- ara_cli/templates/prompt-modules/commands/prompt_template_tech_stack_transformer.commands.md +95 -0
- ara_cli/templates/prompt-modules/commands/python_bug_fixing_code.commands.md +34 -0
- ara_cli/templates/prompt-modules/commands/python_generate_code.commands.md +27 -0
- ara_cli/templates/prompt-modules/commands/python_refactoring_code.commands.md +39 -0
- ara_cli/templates/prompt-modules/commands/python_step_definitions_generation_and_fixing.commands.md +40 -0
- ara_cli/templates/prompt-modules/commands/python_unittest_generation_and_fixing.commands.md +48 -0
- ara_cli/update_config_prompt.py +7 -1
- ara_cli/version.py +1 -1
- ara_cli-0.1.10.8.dist-info/METADATA +241 -0
- {ara_cli-0.1.9.77.dist-info → ara_cli-0.1.10.8.dist-info}/RECORD +104 -59
- tests/test_ara_command_action.py +66 -52
- tests/test_ara_config.py +200 -279
- tests/test_artefact_autofix.py +361 -5
- tests/test_artefact_lister.py +52 -132
- tests/test_artefact_scan.py +1 -1
- tests/test_chat.py +2009 -603
- tests/test_file_classifier.py +23 -0
- tests/test_file_creator.py +3 -5
- tests/test_global_file_lister.py +131 -0
- tests/test_prompt_handler.py +746 -0
- tests/test_tag_extractor.py +19 -13
- tests/test_template_loader.py +192 -0
- tests/test_template_manager.py +5 -4
- ara_cli/ara_command_parser.py +0 -536
- ara_cli/templates/prompt-modules/blueprints/complete_pytest_unittest.blueprint.md +0 -27
- ara_cli/templates/prompt-modules/blueprints/task_todo_list_implement_feature_BDD_way.blueprint.md +0 -30
- ara_cli/templates/prompt-modules/commands/artefact_classification.commands.md +0 -9
- ara_cli/templates/prompt-modules/commands/artefact_extension.commands.md +0 -17
- ara_cli/templates/prompt-modules/commands/artefact_formulation.commands.md +0 -14
- ara_cli/templates/prompt-modules/commands/behave_step_generation.commands.md +0 -102
- ara_cli/templates/prompt-modules/commands/code_generation_complex.commands.md +0 -20
- ara_cli/templates/prompt-modules/commands/code_generation_simple.commands.md +0 -13
- ara_cli/templates/prompt-modules/commands/error_fixing.commands.md +0 -20
- ara_cli/templates/prompt-modules/commands/feature_file_update.commands.md +0 -18
- ara_cli/templates/prompt-modules/commands/feature_formulation.commands.md +0 -43
- ara_cli/templates/prompt-modules/commands/js_code_generation_simple.commands.md +0 -13
- ara_cli/templates/prompt-modules/commands/refactoring.commands.md +0 -15
- ara_cli/templates/prompt-modules/commands/refactoring_analysis.commands.md +0 -9
- ara_cli/templates/prompt-modules/commands/reverse_engineer_feature_file.commands.md +0 -15
- ara_cli/templates/prompt-modules/commands/reverse_engineer_program_flow.commands.md +0 -19
- ara_cli-0.1.9.77.dist-info/METADATA +0 -18
- {ara_cli-0.1.9.77.dist-info → ara_cli-0.1.10.8.dist-info}/WHEEL +0 -0
- {ara_cli-0.1.9.77.dist-info → ara_cli-0.1.10.8.dist-info}/entry_points.txt +0 -0
- {ara_cli-0.1.9.77.dist-info → ara_cli-0.1.10.8.dist-info}/top_level.txt +0 -0
|
@@ -1,53 +1,100 @@
|
|
|
1
|
-
ara_cli/__init__.py,sha256=
|
|
2
|
-
ara_cli/__main__.py,sha256=
|
|
3
|
-
ara_cli/ara_command_action.py,sha256=
|
|
4
|
-
ara_cli/
|
|
5
|
-
ara_cli/
|
|
6
|
-
ara_cli/
|
|
7
|
-
ara_cli/
|
|
8
|
-
ara_cli/
|
|
9
|
-
ara_cli/artefact_fuzzy_search.py,sha256=iBlDqjZf-_D3VUjFf7ZwkiQbpQDcwRndIU7aG_sRTgE,2668
|
|
1
|
+
ara_cli/__init__.py,sha256=w_BYefMe7IdHoAycBTn0VxHr686Ha9oCCVnO5eWjeTU,504
|
|
2
|
+
ara_cli/__main__.py,sha256=S-ZqXq8vZermZ6qCH9sq_T__RXjwDpclysNQk9MfMHY,11435
|
|
3
|
+
ara_cli/ara_command_action.py,sha256=yWtZXxwGp-n5kl-I6bMvwESfyRVGHHBYHVapu-8knl4,24618
|
|
4
|
+
ara_cli/ara_config.py,sha256=vZsY2zYJdlSExRE84L5LqRH3DjveeuMSmG5fC8HDIVc,9794
|
|
5
|
+
ara_cli/artefact_autofix.py,sha256=wLAWKGjhNqXZjsBqy98L3ZpDzg8S5OzFeroJBxGyAAw,26308
|
|
6
|
+
ara_cli/artefact_creator.py,sha256=fRrDaGZvOqJqDb_DLXqMTed2XfIvQMIHjLgOuHOi3Qg,5973
|
|
7
|
+
ara_cli/artefact_deleter.py,sha256=T1vS2s3k_BW86Sd8FExx8nC3BIL05xE9KZLkeZsZrKM,1891
|
|
8
|
+
ara_cli/artefact_fuzzy_search.py,sha256=XMzbMBOJ2YrgFi566jYNB3XeRAmJh7-zqV2QJYbhtlc,3006
|
|
10
9
|
ara_cli/artefact_link_updater.py,sha256=nKdxTpDKqWTOAMD8viKmUaklSFGWzJZ8S8E8xW_ADuM,3775
|
|
11
|
-
ara_cli/artefact_lister.py,sha256=
|
|
12
|
-
ara_cli/artefact_reader.py,sha256
|
|
13
|
-
ara_cli/artefact_renamer.py,sha256=
|
|
14
|
-
ara_cli/artefact_scan.py,sha256=
|
|
15
|
-
ara_cli/chat.py,sha256=
|
|
10
|
+
ara_cli/artefact_lister.py,sha256=M-ggazAgZ-OLeW9NB48r_sd6zPx0p4hEpeS63qHwI1A,4176
|
|
11
|
+
ara_cli/artefact_reader.py,sha256=-6E1VhIlh2oJE1Rn8ARcHRc_E9N4uk8cEViKMoywm6E,7753
|
|
12
|
+
ara_cli/artefact_renamer.py,sha256=8S4QWD19_FGKsKlWojnu_RUOxx0u9rmLugydM4s4VDc,4219
|
|
13
|
+
ara_cli/artefact_scan.py,sha256=qY2Gp4zVcqMXhtuP7rICW0UBG4pcj3W2ABofnL9SIG8,4806
|
|
14
|
+
ara_cli/chat.py,sha256=_1xjUPuBWFxeXQ-9QDf1pJe5x7Xr9lEaSkeQMrCTpYg,44337
|
|
16
15
|
ara_cli/classifier.py,sha256=zWskj7rBYdqYBGjksBm46iTgVU5IIf2PZsJr4qeiwVU,1878
|
|
17
16
|
ara_cli/codefusionretriever.py,sha256=fCHgXdIBRzkVAnapX-KI2NQ44XbrrF4tEQmn5J6clUI,1980
|
|
18
17
|
ara_cli/codehierachieretriever.py,sha256=Xd3EgEWWhkSf1TmTWtf8X5_YvyE_4B66nRrqarwSiTU,1182
|
|
19
18
|
ara_cli/commandline_completer.py,sha256=b00Dqb5n7SecpxYIDLxAfYhp8X6e3c8a5qYz6ko0i3E,1192
|
|
20
|
-
ara_cli/
|
|
21
|
-
ara_cli/
|
|
19
|
+
ara_cli/completers.py,sha256=V4bcmUnuFkdgMpJ3bLAL7cnxinxZb8wwB17WnRHIrHM,5404
|
|
20
|
+
ara_cli/directory_navigator.py,sha256=mr34qhuz8MT2Qj_sTddffCB2nzYpWCg9AWLPdaFjeOM,4518
|
|
21
|
+
ara_cli/error_handler.py,sha256=nNaJSq82f3xiz_QFRKPg5kX_-oI-UoFdRJ2OTj1AR18,4019
|
|
22
|
+
ara_cli/file_classifier.py,sha256=nUcNrhflUydCyCRbXHjEEXYwwwfUm65lYnNEvc86fpM,4026
|
|
22
23
|
ara_cli/file_lister.py,sha256=0C-j8IzajXo5qlvnuy5WFfe43ALwJ-0JFh2K6Xx2ccw,2332
|
|
23
24
|
ara_cli/filename_validator.py,sha256=Aw9PL8d5-Ymhp3EY6lDrUBk3cudaNqo1Uw5RzPpI1jA,118
|
|
25
|
+
ara_cli/global_file_lister.py,sha256=y2UCDoNXODnTAjmlzlV5cf7QxiZ55KEBbbOGQ_JpiHw,2303
|
|
24
26
|
ara_cli/list_filter.py,sha256=qKGwwQsrWe7L5FbdxEbBYD1bbbi8c-RMypjXqXvLbgs,5291
|
|
25
27
|
ara_cli/output_suppressor.py,sha256=nwiHaQLwabOjMoJOeUESBnZszGMxrQZfJ3N2OvahX7Y,389
|
|
26
28
|
ara_cli/prompt_chat.py,sha256=kd_OINDQFit6jN04bb7mzgY259JBbRaTaNp9F-webkc,1346
|
|
27
|
-
ara_cli/prompt_extractor.py,sha256=
|
|
28
|
-
ara_cli/prompt_handler.py,sha256=
|
|
29
|
+
ara_cli/prompt_extractor.py,sha256=sMrpxmpPMU76_PBvOU15kuflsG6mgdpSIlGPmnDRpc0,12349
|
|
30
|
+
ara_cli/prompt_handler.py,sha256=3iSdEJe6RL496Gc1KncOREK_Nb9HYr7Ti9KTTwA_sTU,30393
|
|
29
31
|
ara_cli/prompt_rag.py,sha256=ydlhe4CUqz0jdzlY7jBbpKaf_5fjMrAZKnriKea3ZAg,7485
|
|
30
32
|
ara_cli/run_file_lister.py,sha256=XbrrDTJXp1LFGx9Lv91SNsEHZPP-PyEMBF_P4btjbDA,2360
|
|
31
|
-
ara_cli/tag_extractor.py,sha256=
|
|
32
|
-
ara_cli/
|
|
33
|
-
ara_cli/
|
|
34
|
-
ara_cli/
|
|
33
|
+
ara_cli/tag_extractor.py,sha256=vjuPGGlT3mQpez6eY9LLgIBFQqPsTEgfAWODbXlgODc,4057
|
|
34
|
+
ara_cli/template_loader.py,sha256=nYQ4zadcXX6oXSNgFNlXx8u5961BZCj3dw0tSKHdNfE,10756
|
|
35
|
+
ara_cli/template_manager.py,sha256=l2c785YHB7m0e2TjE0CX-nwXrS4v3EiT9qrS5KuatAc,7105
|
|
36
|
+
ara_cli/update_config_prompt.py,sha256=moqj2Kha7S7fEGzTReU0v2y8UjXC8QfnoiieOQr35C4,5157
|
|
37
|
+
ara_cli/version.py,sha256=VrW4sVDpe3z0UrnPRa4kYW5IIh6VoFKe2Q9JTx-prQg,146
|
|
38
|
+
ara_cli/ara_subcommands/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
39
|
+
ara_cli/ara_subcommands/autofix.py,sha256=h7-6hV97Q6PisUJ_U1Qs4sHYwkHsDpeYH63y_LQsfSc,1095
|
|
40
|
+
ara_cli/ara_subcommands/chat.py,sha256=9zorWKbM0ulu9xFhW2tzV5vl8hCLOCjcp2E9hYgZJ90,1239
|
|
41
|
+
ara_cli/ara_subcommands/classifier_directory.py,sha256=7GH3w4DtvFCM1Sr6Qqk_kjp0EC8jNJDieJJMshYJ_6k,620
|
|
42
|
+
ara_cli/ara_subcommands/common.py,sha256=6bAfPbFHx3CzDSQMm4vL7keFgVnOpqiupgDDWj7QdUQ,2898
|
|
43
|
+
ara_cli/ara_subcommands/create.py,sha256=2tIpzKgzytTIdVV26p6cvrcBo8WLm_3qK7GJyn47Jaw,2527
|
|
44
|
+
ara_cli/ara_subcommands/delete.py,sha256=DxWRQ5Z8h5ZpMhyjLHNuLxONgxIQ97hVkQ8VkX15FDk,827
|
|
45
|
+
ara_cli/ara_subcommands/extract.py,sha256=11atXek579W2RP6PYHlGuyVjWBTuyh1viondCjuce_k,765
|
|
46
|
+
ara_cli/ara_subcommands/fetch_templates.py,sha256=f1bXOTlM67hyf3oGPZEQQjSwUsTte7Cd9-yqq76Ud08,432
|
|
47
|
+
ara_cli/ara_subcommands/list.py,sha256=HtX3kKQ9nrfCcJPxJng0ZnoOqLQ11-aui2zxVei8PlI,3562
|
|
48
|
+
ara_cli/ara_subcommands/list_tags.py,sha256=drEzJgJa4OqqYfIuvT7XkjG4o7VB-ikHE0ArIdljoTI,1113
|
|
49
|
+
ara_cli/ara_subcommands/load.py,sha256=czaflU5Xv-TBlpgalvm6yn5oBBAnNfxSeoIFuLPfi-U,1825
|
|
50
|
+
ara_cli/ara_subcommands/prompt.py,sha256=A8L0lJNBm5zkwJJrzz1kpdycwpm1y8hzd2iVleylpck,4630
|
|
51
|
+
ara_cli/ara_subcommands/read.py,sha256=zTPNMvEPf1WvhtUiauXu5HFiXHRIBJVCkHu44L_scSk,2396
|
|
52
|
+
ara_cli/ara_subcommands/read_status.py,sha256=ZqdxuYXC-idJ2JtMIcZzT4XYI55PnqA6sYv2FcMuchw,695
|
|
53
|
+
ara_cli/ara_subcommands/read_user.py,sha256=NuhaC7dBbi8PUHnGGpqbBVSbQ__nT_L52c7tdKkxjlA,681
|
|
54
|
+
ara_cli/ara_subcommands/reconnect.py,sha256=5Q90rbSnYf7YO6n_9esWsYv7o8GQ-Fnzgy4d8S-X-DQ,1088
|
|
55
|
+
ara_cli/ara_subcommands/rename.py,sha256=IggQdvXjTbZ5CkqzebydVVTcaxO4SDOyORqXDL5jnY8,784
|
|
56
|
+
ara_cli/ara_subcommands/scan.py,sha256=XXwIzq4T9sDMXV0ZcMTSakQ7SyosuCfKjMiiTz7533A,363
|
|
57
|
+
ara_cli/ara_subcommands/set_status.py,sha256=6zzuqLR9k-V63e5UQBpsooftbYHuENEP2s3AdI2jyG0,786
|
|
58
|
+
ara_cli/ara_subcommands/set_user.py,sha256=ADgZIj9xIWK9QKY95lIW_GJGYZysALV--y8j6IuvGxs,755
|
|
59
|
+
ara_cli/ara_subcommands/template.py,sha256=gp_BzrNHcVylU5xav1vmPe3-0vQR7UHm44G7w2i370Q,552
|
|
35
60
|
ara_cli/artefact_models/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
61
|
+
ara_cli/artefact_models/artefact_data_retrieval.py,sha256=CooXOJBYWSyiViN2xkC8baS8OUaslry3YGVVUeDxRAU,527
|
|
36
62
|
ara_cli/artefact_models/artefact_load.py,sha256=IXzWxP-Q_j_oDGMno0m-OuXCQ7Vd5c_NctshGr4ROBw,621
|
|
37
63
|
ara_cli/artefact_models/artefact_mapping.py,sha256=8aD0spBjkJ8toMAmFawc6UTUxB6-tEEViZXv2I-r88Q,1874
|
|
38
|
-
ara_cli/artefact_models/artefact_model.py,sha256=
|
|
39
|
-
ara_cli/artefact_models/artefact_templates.py,sha256=
|
|
64
|
+
ara_cli/artefact_models/artefact_model.py,sha256=Ek7CPzYyj5GajoSdb0G8_I9HbBXFAzRq7DB5CEyNZH0,18817
|
|
65
|
+
ara_cli/artefact_models/artefact_templates.py,sha256=u2VxVXIzrC2PKWiHlhwP4pbCQGjacVqcZ8mZTdV2bE0,10042
|
|
40
66
|
ara_cli/artefact_models/businessgoal_artefact_model.py,sha256=GYT5S2xEnQHwv-k-lEeX5NMSqA-UEfV3PhNjgPDUJpw,4698
|
|
41
67
|
ara_cli/artefact_models/capability_artefact_model.py,sha256=SZqHx4O2mj4urn77Stnj4_Jxtlq3-LgBBU9SMkByppI,3079
|
|
42
|
-
ara_cli/artefact_models/epic_artefact_model.py,sha256=
|
|
68
|
+
ara_cli/artefact_models/epic_artefact_model.py,sha256=_HlFmOJqkDKj3SRpLI4H5rU-va-nFamxhMH4BCODR5c,6053
|
|
43
69
|
ara_cli/artefact_models/example_artefact_model.py,sha256=UXrKbaPotg1jwcrVSdCeo-XH4tTD_-U1e3giaBn5_xg,1384
|
|
44
|
-
ara_cli/artefact_models/feature_artefact_model.py,sha256=
|
|
70
|
+
ara_cli/artefact_models/feature_artefact_model.py,sha256=PvvZDgwsHV1AMS2FXBxwWxkHFlJ0tyFPRX2NGnbnt1Q,21353
|
|
45
71
|
ara_cli/artefact_models/issue_artefact_model.py,sha256=v6CpKnkqiUh6Wch2kkEmyyW49c8ysdy1qz8l1Ft9uJA,2552
|
|
46
72
|
ara_cli/artefact_models/keyfeature_artefact_model.py,sha256=J9oXLsCAo22AW31D5Z104y02ss0S0O4tPCcd09zYCD0,4066
|
|
47
73
|
ara_cli/artefact_models/serialize_helper.py,sha256=Wks30wy-UrwJURetydKykLgJkdGRgXFHkDT24vHe5tU,595
|
|
48
74
|
ara_cli/artefact_models/task_artefact_model.py,sha256=1BSMbz9D-RXvdpdd0RlAr9hUx84Rcuysk2YfQC8Qy14,6046
|
|
49
|
-
ara_cli/artefact_models/userstory_artefact_model.py,sha256=
|
|
75
|
+
ara_cli/artefact_models/userstory_artefact_model.py,sha256=P5an9UrZ1QrQ57TxSJ48F2OwKxhqEz1B-QxTtHeSZFI,7172
|
|
50
76
|
ara_cli/artefact_models/vision_artefact_model.py,sha256=frjaUJj-mmIlVHEhzAQztCGs-CtvNu_odSborgztfzo,5251
|
|
77
|
+
ara_cli/chat_agent/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
78
|
+
ara_cli/chat_agent/agent_communicator.py,sha256=Tru2o7LZ0n2iQ1ip01ZFt5d9iwAI6Pcgj6NBK5OF1_A,2349
|
|
79
|
+
ara_cli/chat_agent/agent_process_manager.py,sha256=k_AfG1pr2xbhDVSUm79r5RnOKpdzCvTS3VpUpgIvHUA,7349
|
|
80
|
+
ara_cli/chat_agent/agent_status_manager.py,sha256=CflNgTKjF6MnyiU_5u97LUfpUw9vvAdDm71xFROSupY,2337
|
|
81
|
+
ara_cli/chat_agent/agent_workspace_manager.py,sha256=2Oj8GP6qpme9kTI0Ele3H9VNJr2O6VpuHE8-nsy3LRE,2683
|
|
82
|
+
ara_cli/commands/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
83
|
+
ara_cli/commands/command.py,sha256=Y_2dNeuxRjbyI3ScXNv55lptSe8Hs_ya78L0nPYNZHA,154
|
|
84
|
+
ara_cli/commands/extract_command.py,sha256=CzUOwDembG587PYbxg5rge4XSfdsuTyOPUvkobkXCIs,573
|
|
85
|
+
ara_cli/commands/load_command.py,sha256=H3CfeHIL-criDU5oi4BONTSpyzJ4m8DzJ0ZCIiAZFeI,2204
|
|
86
|
+
ara_cli/commands/load_image_command.py,sha256=g9-PXAYdqx5Ed1PdVo-FIb4CyJGEpRFbgQf9Dxg6DmM,886
|
|
87
|
+
ara_cli/commands/read_command.py,sha256=xne8jlertuJNcsyzjR0bJeUUHi4NkEfd0h0DRbU9rC4,4347
|
|
88
|
+
ara_cli/file_loaders/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
89
|
+
ara_cli/file_loaders/binary_file_loader.py,sha256=1HHH1Nk4lEM83CTnf4z9wYz6rMLgpxydFoRcSgkBHmQ,940
|
|
90
|
+
ara_cli/file_loaders/document_file_loader.py,sha256=VxGFChYyM9K-e6eOCK3yk5jQuEXgz01Mh_NoA6CA_RM,1017
|
|
91
|
+
ara_cli/file_loaders/document_reader.py,sha256=SD9_5-XJ6homKUes6o8GWcG--X63UslfAosPbrJZQvo,7721
|
|
92
|
+
ara_cli/file_loaders/document_readers.py,sha256=aG7xrUJwLxWpuFTYlvxzDqoS00Idpvwzt865L0OuQcA,8124
|
|
93
|
+
ara_cli/file_loaders/file_loader.py,sha256=bc1BrMG4pEtwsZLm3Ct53YsMPgnbSaEvZEd8isRDYRY,1711
|
|
94
|
+
ara_cli/file_loaders/file_loaders.py,sha256=9QqArTRDmcUUar58JEr-qnpiAtH9ySP-MV9bvooQNpI,4290
|
|
95
|
+
ara_cli/file_loaders/image_processor.py,sha256=laPThh-i0-obYyS_linQTMcTUwuxMxrSjedGRYb8cIA,3462
|
|
96
|
+
ara_cli/file_loaders/markdown_reader.py,sha256=R-hvvc9Sj9pWwENqJ0j6wrW0eN1tUqEKWcK2YUFsvsU,2542
|
|
97
|
+
ara_cli/file_loaders/text_file_loader.py,sha256=nD0MmjMlr-suMrK7GNwaMd0qv2lJyt4XBijx8SsFvEI,6848
|
|
51
98
|
ara_cli/templates/agile.artefacts,sha256=nTA8dp98HWKAD-0qhmNpVYIfkVGoJshZqMJGnphiOsE,7932
|
|
52
99
|
ara_cli/templates/template.businessgoal.prompt_log.md,sha256=xF6bkgj_GqAAqHxJWJiQNt11mEuSGemIqoZ2wOo6dI0,214
|
|
53
100
|
ara_cli/templates/template.capability.prompt_log.md,sha256=eO8EzrHgb2vYJ-DP1jGzAfDlMo8nY75hZDfhh0s40uQ,208
|
|
@@ -60,29 +107,24 @@ ara_cli/templates/template.steps.prompt_log.md,sha256=sd8g1KtwgpPvU-vGWAFCDXiWHk
|
|
|
60
107
|
ara_cli/templates/template.task.prompt_log.md,sha256=4kAy1zC0k3_y3SoYb-mg3rQEJCW_c43X7ggOLZ321TE,190
|
|
61
108
|
ara_cli/templates/template.userstory.prompt_log.md,sha256=Yp62iF7zDy2XNIwwJN35jKKSmezinK_JKbSvVuagtmA,205
|
|
62
109
|
ara_cli/templates/template.vision.prompt_log.md,sha256=CAzBzj3O23CzrPIUq3xzpXGKn3_nAvyBLRUi-5Bnq_0,196
|
|
63
|
-
ara_cli/templates/prompt-modules/blueprints/complete_pytest_unittest.blueprint.md,sha256=DtZsdfVDNy9_cGE_Nn_TE2T3oRwr27kecZchOp5uIG0,672
|
|
64
110
|
ara_cli/templates/prompt-modules/blueprints/empty.blueprint.md,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
65
111
|
ara_cli/templates/prompt-modules/blueprints/task_todo_list_C4_architecture_analysis.blueprint.md,sha256=jEZrZaVK_pkRhLp1SpTX3xR6BGXkox6NafXEjX_GDvM,3099
|
|
66
|
-
ara_cli/templates/prompt-modules/blueprints/task_todo_list_implement_feature_BDD_way.blueprint.md,sha256=EimfgzjhFIsZnJ0qMNbVlUQEU0vC9Sv1VupesLz7A1E,2088
|
|
67
112
|
ara_cli/templates/prompt-modules/commands/architecture_C4_analysis.commands.md,sha256=xzfmOBsETlh90P1haJOiC8y8eLPboZ3yFodbuSUPLBU,1557
|
|
68
113
|
ara_cli/templates/prompt-modules/commands/architecture_radon_cc_score.commands.md,sha256=t-cozhSQPGUOoYfdySBL4n-yQykvCc4s5n0AKpKCn0Q,3074
|
|
69
114
|
ara_cli/templates/prompt-modules/commands/architecture_radon_halstead_v.commands.md,sha256=YBQKZdTJ4QRnBocsWTvT9dmaHOKys1hE0NJC7LPl2vQ,1676
|
|
70
115
|
ara_cli/templates/prompt-modules/commands/architecture_radon_maintainability_score.commands.md,sha256=9nBsY_EYNI9GmD-KzbGKdtEDP4YoY7ECV2QWEzoznfc,5511
|
|
71
|
-
ara_cli/templates/prompt-modules/commands/
|
|
72
|
-
ara_cli/templates/prompt-modules/commands/
|
|
73
|
-
ara_cli/templates/prompt-modules/commands/
|
|
74
|
-
ara_cli/templates/prompt-modules/commands/
|
|
75
|
-
ara_cli/templates/prompt-modules/commands/
|
|
76
|
-
ara_cli/templates/prompt-modules/commands/
|
|
77
|
-
ara_cli/templates/prompt-modules/commands/
|
|
78
|
-
ara_cli/templates/prompt-modules/commands/
|
|
79
|
-
ara_cli/templates/prompt-modules/commands/
|
|
80
|
-
ara_cli/templates/prompt-modules/commands/
|
|
81
|
-
ara_cli/templates/prompt-modules/commands/
|
|
82
|
-
ara_cli/templates/prompt-modules/commands/
|
|
83
|
-
ara_cli/templates/prompt-modules/commands/refactoring_analysis.commands.md,sha256=RjMAa6rBCou0XGhu1-IFGy21EgcxSUkGWSCCqbw6CFw,1028
|
|
84
|
-
ara_cli/templates/prompt-modules/commands/reverse_engineer_feature_file.commands.md,sha256=9togxxeBTcSvD5hLdBqyC-rUCF-xhU68PtD5rQySbFY,964
|
|
85
|
-
ara_cli/templates/prompt-modules/commands/reverse_engineer_program_flow.commands.md,sha256=-pW71nV064aTfLTyYEnkH5eAaZPH3HRdOQsSxAfiNu8,1315
|
|
116
|
+
ara_cli/templates/prompt-modules/commands/empty.commands.md,sha256=vgi8-ep2JZBuv0cocpBWJe1-gDzpw1OpHt5KANtaH58,80
|
|
117
|
+
ara_cli/templates/prompt-modules/commands/extract_general.commands.md,sha256=g21jnK5gd0UX8dLv8IpxOX-r5A61EpVgT1VcmxXPcTw,718
|
|
118
|
+
ara_cli/templates/prompt-modules/commands/extract_markdown.commands.md,sha256=em3jFTXNzT5ULdOyFg__DlRciYOTuCXrHiImnJS5B4M,657
|
|
119
|
+
ara_cli/templates/prompt-modules/commands/extract_python.commands.md,sha256=BhTtbfnrr_ABHza0XmGYlQ8YzrESQumyobQj2Ff9dNM,641
|
|
120
|
+
ara_cli/templates/prompt-modules/commands/feature_add_or_modifiy_specified_behavior.commands.md,sha256=vuGfxSifR1UGxUhOQakEYA2KkoK66s_jf2pn6ClHuM0,2444
|
|
121
|
+
ara_cli/templates/prompt-modules/commands/feature_generate_initial_specified_bevahior.commands.md,sha256=oufTleuQcHiYmdzKTtDleMHHN6anw-n8JSpUKUzE7GQ,2810
|
|
122
|
+
ara_cli/templates/prompt-modules/commands/prompt_template_tech_stack_transformer.commands.md,sha256=Z32V1Ux94Uol3gqxqV8V6gdiKSIyrbtd6re7tuLIRsM,4446
|
|
123
|
+
ara_cli/templates/prompt-modules/commands/python_bug_fixing_code.commands.md,sha256=slOySzxZnIXzmIma3jZVvGcNC-llkqlhUil1cuWYE2U,2273
|
|
124
|
+
ara_cli/templates/prompt-modules/commands/python_generate_code.commands.md,sha256=LYNfVuAhtBHB1CDjUqy5Y6dDmq9PVfo8UbJbfB2_mKE,2601
|
|
125
|
+
ara_cli/templates/prompt-modules/commands/python_refactoring_code.commands.md,sha256=p-Y1r10-80Eo7lUmz2hX7uJto8J2-d2C0RMV595t0Sg,2453
|
|
126
|
+
ara_cli/templates/prompt-modules/commands/python_step_definitions_generation_and_fixing.commands.md,sha256=i74lgqMc9KFu9QWfOcZR1jcDMLAZCW4wvGvGRK7Yng0,3204
|
|
127
|
+
ara_cli/templates/prompt-modules/commands/python_unittest_generation_and_fixing.commands.md,sha256=jMuMfOiw_H8RL-I8J5OqBO4rpzYmGgGgzh-kKt_fNkg,3561
|
|
86
128
|
ara_cli/templates/prompt-modules/intentions/classify_task.intention.md,sha256=9ZiEOBFiku24SX4kBJlSCgm5ScYlNZIcNPoHwtGbWIU,254
|
|
87
129
|
ara_cli/templates/prompt-modules/intentions/empty.intention.md,sha256=6dqUtORC992KagZX2Up2yHHvBjVgDTj--wIyYbG4jhc,48
|
|
88
130
|
ara_cli/templates/prompt-modules/intentions/error_fixing.intention.md,sha256=pcfG4csCF830lk8anDCkOA0ewTYnRo5mg0Y0w-fyEJU,206
|
|
@@ -122,27 +164,30 @@ ara_cli/templates/specification_breakdown_files/template.step.md,sha256=nzDRl9Xo
|
|
|
122
164
|
ara_cli/templates/specification_breakdown_files/template.technology.exploration.md,sha256=zQyiJcmbUfXdte-5uZwZUpT6ey0zwfZ00P4VwI97jQk,2274
|
|
123
165
|
ara_cli/templates/specification_breakdown_files/template.technology.md,sha256=bySiksz-8xtq0Nnj4svqe2MgUftWrVkbK9AcrDUE3KY,952
|
|
124
166
|
tests/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
125
|
-
tests/test_ara_command_action.py,sha256=
|
|
126
|
-
tests/test_ara_config.py,sha256=
|
|
127
|
-
tests/test_artefact_autofix.py,sha256=
|
|
167
|
+
tests/test_ara_command_action.py,sha256=gLXFAW6K0qCkNKvWvmbshfpJqczvdgBoNGT4rugF7JI,27181
|
|
168
|
+
tests/test_ara_config.py,sha256=RbVhS0SS1lr_SVopEMT1Fake5a-4rWN8MprgJtgI-FA,15883
|
|
169
|
+
tests/test_artefact_autofix.py,sha256=vcN11CY6XJq97N0php4OW-rPbEMEh_nYFISrg-pN1mE,38332
|
|
128
170
|
tests/test_artefact_fuzzy_search.py,sha256=5Sh3_l9QK8-WHn6JpGPU1b6h4QEnl2JoMq1Tdp2cj1U,1261
|
|
129
171
|
tests/test_artefact_link_updater.py,sha256=biqbEp2jCOz8giv72hu2P2hDfeJfJ9OrVGdAv5d9cK4,2191
|
|
130
|
-
tests/test_artefact_lister.py,sha256=
|
|
172
|
+
tests/test_artefact_lister.py,sha256=35R13UU-YsX1HOsEN8M2-vIiCUA9RSBm6SwestDaFhE,20388
|
|
131
173
|
tests/test_artefact_reader.py,sha256=660K-d8ed-j8hulsUB_7baPD2-hhbg9TffUR5yVc4Uo,927
|
|
132
174
|
tests/test_artefact_renamer.py,sha256=lSnKCCfoFGgKhTdDZrEaeBq1xJAak1QoqH5aSeOe9Ro,3494
|
|
133
|
-
tests/test_artefact_scan.py,sha256=
|
|
134
|
-
tests/test_chat.py,sha256=
|
|
175
|
+
tests/test_artefact_scan.py,sha256=SzMtJeh8_oOBec9yzy3vJRHxs9i1E5gEU2RfF6CJZqE,16888
|
|
176
|
+
tests/test_chat.py,sha256=D2HRRTdnvcDvB9TWz4O91ZONbLJL6w4v8TRTDwjtzzI,86104
|
|
135
177
|
tests/test_classifier.py,sha256=grYGPksydNdPsaEBQxYHZTuTdcJWz7VQtikCKA6BNaQ,1920
|
|
136
178
|
tests/test_directory_navigator.py,sha256=7G0MVrBbtBvbrFUpL0zb_9EkEWi1dulWuHsrQxMJxDY,140
|
|
137
|
-
tests/test_file_classifier.py,sha256=
|
|
138
|
-
tests/test_file_creator.py,sha256=
|
|
179
|
+
tests/test_file_classifier.py,sha256=4O1C_iDpGGm35b7aI-HIJd5kkWxFUOrI2n4lEpiDNTM,11855
|
|
180
|
+
tests/test_file_creator.py,sha256=tgBCq6KPv-qMSDhj9AZvQIJABiAqgpFRnEg1fqbVrTI,2013
|
|
139
181
|
tests/test_file_lister.py,sha256=Q9HwhKKx540EPzTmfzOCnvtAgON0aMmpJE2eOe1J3EA,4324
|
|
182
|
+
tests/test_global_file_lister.py,sha256=E-RxGIwxbUsUxadlcFRTAOtgQcnFd-LnKsLzbH9H7ME,5498
|
|
140
183
|
tests/test_list_filter.py,sha256=fJA3d_SdaOAUkE7jn68MOVS0THXGghy1fye_64Zvo1U,7964
|
|
141
|
-
tests/
|
|
142
|
-
tests/
|
|
184
|
+
tests/test_prompt_handler.py,sha256=4__q8Ap2hVGXVF1DvvWqq-K630buC7yjccoWkk_FG18,34255
|
|
185
|
+
tests/test_tag_extractor.py,sha256=7eVD10Y1uLkoSrEgqkXzRvPFs8lJ1RiaJzDu7ml_FZE,3118
|
|
186
|
+
tests/test_template_loader.py,sha256=R7s8HJZbKqja-1TRBMBkVKPTgajofUjjRKUJq7a3_Oc,7427
|
|
187
|
+
tests/test_template_manager.py,sha256=qliEeYgAEakn8JIqIHa8u0Ht6DY4L3T6DcHBXkjzR4I,4167
|
|
143
188
|
tests/test_update_config_prompt.py,sha256=xsqj1WTn4BsG5Q2t-sNPfu7EoMURFcS-hfb5VSXUnJc,6765
|
|
144
|
-
ara_cli-0.1.
|
|
145
|
-
ara_cli-0.1.
|
|
146
|
-
ara_cli-0.1.
|
|
147
|
-
ara_cli-0.1.
|
|
148
|
-
ara_cli-0.1.
|
|
189
|
+
ara_cli-0.1.10.8.dist-info/METADATA,sha256=VQnpWRb8ZVtD90Bfmq-rgDa76JdwHtgMSkePRewjGOo,8141
|
|
190
|
+
ara_cli-0.1.10.8.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
|
191
|
+
ara_cli-0.1.10.8.dist-info/entry_points.txt,sha256=v4h7MzysTgSIDYfEo3oj4Kz_8lzsRa3hq-KJHEcLVX8,45
|
|
192
|
+
ara_cli-0.1.10.8.dist-info/top_level.txt,sha256=WM4cLHT5DYUaWzLtRj-gu3yVNFpGQ6lLRI3FMmC-38I,14
|
|
193
|
+
ara_cli-0.1.10.8.dist-info/RECORD,,
|
tests/test_ara_command_action.py
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import pytest
|
|
2
2
|
from unittest.mock import patch, MagicMock, call, mock_open
|
|
3
|
+
from ara_cli.error_handler import AraValidationError
|
|
3
4
|
from ara_cli.ara_command_action import (
|
|
4
5
|
check_validity,
|
|
5
6
|
create_action,
|
|
@@ -16,6 +17,12 @@ from ara_cli.ara_command_action import (
|
|
|
16
17
|
)
|
|
17
18
|
|
|
18
19
|
|
|
20
|
+
@pytest.fixture
|
|
21
|
+
def mock_handle_errors():
|
|
22
|
+
with patch("ara_cli.ara_command_action.handle_errors", lambda context: (lambda f: f)):
|
|
23
|
+
yield
|
|
24
|
+
|
|
25
|
+
|
|
19
26
|
@pytest.fixture
|
|
20
27
|
def mock_dependencies():
|
|
21
28
|
with patch(
|
|
@@ -28,8 +35,10 @@ def mock_dependencies():
|
|
|
28
35
|
"ara_cli.template_manager.SpecificationBreakdownAspects"
|
|
29
36
|
) as MockSpecificationBreakdownAspects, patch(
|
|
30
37
|
"ara_cli.artefact_fuzzy_search.find_closest_rule"
|
|
31
|
-
) as mock_find_closest_rule
|
|
32
|
-
|
|
38
|
+
) as mock_find_closest_rule, patch(
|
|
39
|
+
"ara_cli.artefact_reader.ArtefactReader"
|
|
40
|
+
) as MockArtefactReader:
|
|
41
|
+
yield MockArtefactCreator, MockClassifier, mock_is_valid_filename, MockSpecificationBreakdownAspects, mock_find_closest_rule, MockArtefactReader
|
|
33
42
|
|
|
34
43
|
|
|
35
44
|
@pytest.fixture
|
|
@@ -102,65 +111,70 @@ def mock_suggest_close_name_matches():
|
|
|
102
111
|
yield mock_suggest_close_name_matches
|
|
103
112
|
|
|
104
113
|
|
|
105
|
-
|
|
106
|
-
"condition
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
)
|
|
110
|
-
def test_check_validity(condition, error_message):
|
|
111
|
-
with patch("sys.exit") as mock_exit, patch("builtins.print") as mock_print:
|
|
112
|
-
if condition:
|
|
113
|
-
check_validity(condition, error_message)
|
|
114
|
-
mock_exit.assert_not_called()
|
|
115
|
-
mock_print.assert_not_called()
|
|
116
|
-
else:
|
|
117
|
-
check_validity(condition, error_message)
|
|
118
|
-
mock_exit.assert_called_once_with(1)
|
|
119
|
-
mock_print.assert_called_once_with(error_message)
|
|
114
|
+
def test_check_validity_with_true_condition():
|
|
115
|
+
"""Test that check_validity does nothing when condition is True."""
|
|
116
|
+
# This should not raise any exception
|
|
117
|
+
check_validity(True, "This should not be printed")
|
|
120
118
|
|
|
121
119
|
|
|
122
|
-
|
|
123
|
-
"
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
120
|
+
def test_check_validity_with_false_condition():
|
|
121
|
+
"""Test that check_validity raises AraValidationError when condition is False."""
|
|
122
|
+
error_message = "This is a test error message"
|
|
123
|
+
|
|
124
|
+
with pytest.raises(AraValidationError, match=error_message):
|
|
125
|
+
check_validity(False, error_message)
|
|
126
|
+
|
|
127
|
+
|
|
128
|
+
def test_check_validity_error_message_content():
|
|
129
|
+
"""Test that the raised exception contains the correct error message."""
|
|
130
|
+
error_message = "Custom validation error"
|
|
131
|
+
|
|
132
|
+
with pytest.raises(AraValidationError) as exc_info:
|
|
133
|
+
check_validity(False, error_message)
|
|
134
|
+
|
|
135
|
+
assert str(exc_info.value) == error_message
|
|
136
|
+
|
|
137
|
+
|
|
138
|
+
def setup_create_args_and_mocks(classifier_valid, filename_valid, mock_dependencies):
|
|
139
|
+
(MockArtefactCreator, MockClassifier, mock_is_valid_filename, _, _, MockArtefactReader) = mock_dependencies
|
|
136
140
|
MockClassifier.is_valid_classifier.return_value = classifier_valid
|
|
137
141
|
mock_is_valid_filename.return_value = filename_valid
|
|
138
|
-
|
|
142
|
+
MockArtefactReader.read_artefact.return_value = (None, None)
|
|
139
143
|
|
|
140
144
|
args = MagicMock()
|
|
141
145
|
args.classifier = "test_classifier"
|
|
142
146
|
args.parameter = "test_parameter"
|
|
147
|
+
return args
|
|
143
148
|
|
|
149
|
+
# Test for valid classifier and filename
|
|
150
|
+
def test_create_action_with_valid_params(mock_handle_errors, mock_dependencies):
|
|
151
|
+
args = setup_create_args_and_mocks(True, True, mock_dependencies)
|
|
144
152
|
with patch("ara_cli.ara_command_action.check_validity") as mock_check_validity:
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
153
|
+
create_action(args)
|
|
154
|
+
mock_check_validity.assert_any_call(True, "Invalid classifier provided. Please provide a valid classifier.")
|
|
155
|
+
mock_check_validity.assert_any_call(True, "Invalid filename provided. Please provide a valid filename.")
|
|
156
|
+
|
|
157
|
+
# Test for invalid classifier
|
|
158
|
+
def test_create_action_with_invalid_classifier(mock_handle_errors, mock_dependencies):
|
|
159
|
+
args = setup_create_args_and_mocks(False, True, mock_dependencies)
|
|
160
|
+
with patch("ara_cli.ara_command_action.check_validity") as mock_check_validity:
|
|
161
|
+
create_action(args)
|
|
162
|
+
mock_check_validity.assert_any_call(False, "Invalid classifier provided. Please provide a valid classifier.")
|
|
163
|
+
|
|
164
|
+
# Test for invalid filename
|
|
165
|
+
def test_create_action_with_invalid_filename(mock_handle_errors, mock_dependencies):
|
|
166
|
+
args = setup_create_args_and_mocks(True, False, mock_dependencies)
|
|
167
|
+
with patch("ara_cli.ara_command_action.check_validity") as mock_check_validity:
|
|
168
|
+
create_action(args)
|
|
169
|
+
mock_check_validity.assert_any_call(False, "Invalid filename provided. Please provide a valid filename.")
|
|
170
|
+
|
|
171
|
+
# Test for both invalid classifier and filename
|
|
172
|
+
def test_create_action_with_invalid_classifier_and_filename(mock_handle_errors, mock_dependencies):
|
|
173
|
+
args = setup_create_args_and_mocks(False, False, mock_dependencies)
|
|
174
|
+
with patch("ara_cli.ara_command_action.check_validity") as mock_check_validity:
|
|
175
|
+
create_action(args)
|
|
176
|
+
mock_check_validity.assert_any_call(False, "Invalid classifier provided. Please provide a valid classifier.")
|
|
177
|
+
mock_check_validity.assert_any_call(False, "Invalid filename provided. Please provide a valid filename.")
|
|
164
178
|
|
|
165
179
|
|
|
166
180
|
@pytest.mark.parametrize(
|
|
@@ -406,7 +420,7 @@ def test_read_status_action(classifier, artefact_name, artefact_exists, status,
|
|
|
406
420
|
# Verify behavior
|
|
407
421
|
if not artefact_exists:
|
|
408
422
|
# Should suggest close matches when artefact not found
|
|
409
|
-
mock_suggest_close_name_matches.assert_called_once_with(artefact_name, all_artefact_names)
|
|
423
|
+
mock_suggest_close_name_matches.assert_called_once_with(artefact_name, all_artefact_names, report_as_error=True)
|
|
410
424
|
mock_open.assert_not_called()
|
|
411
425
|
else:
|
|
412
426
|
# Should open the file and read content
|