codemie-test-harness 0.1.162__py3-none-any.whl → 0.1.163__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 codemie-test-harness might be problematic. Click here for more details.
- codemie_test_harness/tests/assistant/tools/datamanagement/test_assistant_with_data_management_tools.py +0 -3
- codemie_test_harness/tests/test_data/direct_tools/data_management_tools_test_data.py +6 -1
- codemie_test_harness/tests/workflow/direct_tools_calling/test_workflow_with_data_management_tools_elastic.py +103 -0
- {codemie_test_harness-0.1.162.dist-info → codemie_test_harness-0.1.163.dist-info}/METADATA +2 -2
- {codemie_test_harness-0.1.162.dist-info → codemie_test_harness-0.1.163.dist-info}/RECORD +7 -6
- {codemie_test_harness-0.1.162.dist-info → codemie_test_harness-0.1.163.dist-info}/WHEEL +0 -0
- {codemie_test_harness-0.1.162.dist-info → codemie_test_harness-0.1.163.dist-info}/entry_points.txt +0 -0
|
@@ -57,9 +57,6 @@ def test_create_assistant_with_elastic_tool(
|
|
|
57
57
|
sql_tools_test_data,
|
|
58
58
|
)
|
|
59
59
|
@pytest.mark.testcase("EPMCDME-6132")
|
|
60
|
-
@pytest.mark.skipif(
|
|
61
|
-
EnvironmentResolver.is_localhost(), reason="Skipping this test on local environment"
|
|
62
|
-
)
|
|
63
60
|
def test_create_assistant_with_sql_tool(
|
|
64
61
|
integration_utils, assistant_utils, assistant, similarity_check, db_dialect
|
|
65
62
|
):
|
|
@@ -1,9 +1,14 @@
|
|
|
1
1
|
import pytest
|
|
2
2
|
|
|
3
|
-
from codemie_test_harness.tests.enums.tools import DataManagementTool, Toolkit
|
|
4
3
|
from codemie_test_harness.tests.enums.integrations import DataBaseDialect
|
|
4
|
+
from codemie_test_harness.tests.enums.tools import DataManagementTool, Toolkit
|
|
5
5
|
from codemie_test_harness.tests.utils.env_resolver import EnvironmentResolver
|
|
6
6
|
|
|
7
|
+
ELASTIC_TOOL_TASK = {
|
|
8
|
+
"index": "_all",
|
|
9
|
+
"query": '{"query": {"prefix": {"_index": "codemie"}}}',
|
|
10
|
+
}
|
|
11
|
+
|
|
7
12
|
sql_tools_test_data = [
|
|
8
13
|
(
|
|
9
14
|
Toolkit.DATA_MANAGEMENT,
|
|
@@ -0,0 +1,103 @@
|
|
|
1
|
+
import copy
|
|
2
|
+
import json
|
|
3
|
+
import random
|
|
4
|
+
|
|
5
|
+
import pytest
|
|
6
|
+
from codemie_sdk.models.integration import CredentialTypes
|
|
7
|
+
from hamcrest import assert_that, has_length, greater_than
|
|
8
|
+
|
|
9
|
+
from codemie_test_harness.tests.enums.tools import DataManagementTool
|
|
10
|
+
from codemie_test_harness.tests.test_data.direct_tools.data_management_tools_test_data import (
|
|
11
|
+
ELASTIC_TOOL_TASK,
|
|
12
|
+
)
|
|
13
|
+
from codemie_test_harness.tests.utils.aws_parameters_store import CredentialsUtil
|
|
14
|
+
from codemie_test_harness.tests.utils.base_utils import get_random_name
|
|
15
|
+
from codemie_test_harness.tests.utils.env_resolver import EnvironmentResolver
|
|
16
|
+
|
|
17
|
+
pytestmark = pytest.mark.skipif(
|
|
18
|
+
EnvironmentResolver.is_localhost(),
|
|
19
|
+
reason="Skipping this tests on local environment",
|
|
20
|
+
)
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
@pytest.mark.workflow
|
|
24
|
+
@pytest.mark.direct_tool
|
|
25
|
+
@pytest.mark.elastic
|
|
26
|
+
@pytest.mark.regression
|
|
27
|
+
def test_workflow_with_elastic_tools_direct(
|
|
28
|
+
workflow_with_tool, workflow_utils, integration_utils
|
|
29
|
+
):
|
|
30
|
+
assistant_and_state_name = get_random_name()
|
|
31
|
+
credential_values = CredentialsUtil.elastic_credentials()
|
|
32
|
+
integration = integration_utils.create_integration(
|
|
33
|
+
CredentialTypes.ELASTIC, credential_values
|
|
34
|
+
)
|
|
35
|
+
|
|
36
|
+
test_workflow = workflow_with_tool(
|
|
37
|
+
assistant_and_state_name,
|
|
38
|
+
DataManagementTool.ELASTIC,
|
|
39
|
+
integration=integration,
|
|
40
|
+
)
|
|
41
|
+
|
|
42
|
+
response = workflow_utils.execute_workflow(
|
|
43
|
+
test_workflow.id, assistant_and_state_name, json.dumps(ELASTIC_TOOL_TASK)
|
|
44
|
+
)
|
|
45
|
+
|
|
46
|
+
assert_that(json.loads(response)["hits"]["hits"], has_length(greater_than(0)))
|
|
47
|
+
|
|
48
|
+
|
|
49
|
+
@pytest.mark.workflow
|
|
50
|
+
@pytest.mark.direct_tool
|
|
51
|
+
@pytest.mark.elastic
|
|
52
|
+
@pytest.mark.regression
|
|
53
|
+
def test_workflow_with_elastic_tools_with_hardcoded_args(
|
|
54
|
+
workflow_with_tool, workflow_utils, integration_utils
|
|
55
|
+
):
|
|
56
|
+
assistant_and_state_name = get_random_name()
|
|
57
|
+
credential_values = CredentialsUtil.elastic_credentials()
|
|
58
|
+
integration = integration_utils.create_integration(
|
|
59
|
+
CredentialTypes.ELASTIC, credential_values
|
|
60
|
+
)
|
|
61
|
+
|
|
62
|
+
test_workflow = workflow_with_tool(
|
|
63
|
+
assistant_and_state_name,
|
|
64
|
+
DataManagementTool.ELASTIC,
|
|
65
|
+
integration=integration,
|
|
66
|
+
tool_args=ELASTIC_TOOL_TASK,
|
|
67
|
+
)
|
|
68
|
+
|
|
69
|
+
response = workflow_utils.execute_workflow(
|
|
70
|
+
test_workflow.id, assistant_and_state_name
|
|
71
|
+
)
|
|
72
|
+
|
|
73
|
+
assert_that(json.loads(response)["hits"]["hits"], has_length(greater_than(0)))
|
|
74
|
+
|
|
75
|
+
|
|
76
|
+
@pytest.mark.workflow
|
|
77
|
+
@pytest.mark.direct_tool
|
|
78
|
+
@pytest.mark.elastic
|
|
79
|
+
@pytest.mark.regression
|
|
80
|
+
def test_workflow_with_elastic_tools_with_overriding_args(
|
|
81
|
+
workflow_with_tool, workflow_utils, integration_utils
|
|
82
|
+
):
|
|
83
|
+
assistant_and_state_name = get_random_name()
|
|
84
|
+
credential_values = CredentialsUtil.elastic_credentials()
|
|
85
|
+
integration = integration_utils.create_integration(
|
|
86
|
+
CredentialTypes.ELASTIC, credential_values
|
|
87
|
+
)
|
|
88
|
+
|
|
89
|
+
args_copy = copy.deepcopy(ELASTIC_TOOL_TASK)
|
|
90
|
+
args_copy = {key: random.randint(1, 10) for key in args_copy}
|
|
91
|
+
|
|
92
|
+
test_workflow = workflow_with_tool(
|
|
93
|
+
assistant_and_state_name,
|
|
94
|
+
DataManagementTool.ELASTIC,
|
|
95
|
+
integration=integration,
|
|
96
|
+
tool_args=args_copy,
|
|
97
|
+
)
|
|
98
|
+
|
|
99
|
+
response = workflow_utils.execute_workflow(
|
|
100
|
+
test_workflow.id, assistant_and_state_name, json.dumps(ELASTIC_TOOL_TASK)
|
|
101
|
+
)
|
|
102
|
+
|
|
103
|
+
assert_that(json.loads(response)["hits"]["hits"], has_length(greater_than(0)))
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.3
|
|
2
2
|
Name: codemie-test-harness
|
|
3
|
-
Version: 0.1.
|
|
3
|
+
Version: 0.1.163
|
|
4
4
|
Summary: Autotest for CodeMie backend and UI
|
|
5
5
|
Author: Anton Yeromin
|
|
6
6
|
Author-email: anton_yeromin@epam.com
|
|
@@ -13,7 +13,7 @@ Requires-Dist: aws-assume-role-lib (>=2.10.0,<3.0.0)
|
|
|
13
13
|
Requires-Dist: boto3 (>=1.39.8,<2.0.0)
|
|
14
14
|
Requires-Dist: click (>=8.1.7,<9.0.0)
|
|
15
15
|
Requires-Dist: codemie-plugins (>=0.1.123,<0.2.0)
|
|
16
|
-
Requires-Dist: codemie-sdk-python (==0.1.
|
|
16
|
+
Requires-Dist: codemie-sdk-python (==0.1.163)
|
|
17
17
|
Requires-Dist: pytest (>=8.4.1,<9.0.0)
|
|
18
18
|
Requires-Dist: pytest-playwright (>=0.7.0,<0.8.0)
|
|
19
19
|
Requires-Dist: pytest-reportportal (>=5.5.2,<6.0.0)
|
|
@@ -34,7 +34,7 @@ codemie_test_harness/tests/assistant/tools/cloud/test_cloud_tools.py,sha256=gNbK
|
|
|
34
34
|
codemie_test_harness/tests/assistant/tools/codebase/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
35
35
|
codemie_test_harness/tests/assistant/tools/codebase/test_codebase_tools.py,sha256=-YlWMcdghXJWN_1iW05YvGHsauDEIv7IDGRl62UcZ9o,1627
|
|
36
36
|
codemie_test_harness/tests/assistant/tools/datamanagement/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
37
|
-
codemie_test_harness/tests/assistant/tools/datamanagement/test_assistant_with_data_management_tools.py,sha256=
|
|
37
|
+
codemie_test_harness/tests/assistant/tools/datamanagement/test_assistant_with_data_management_tools.py,sha256=FbbepKkvssKj1UjOB1EK9sRJ1KCdJ1HnGlPg_-SkYEo,2671
|
|
38
38
|
codemie_test_harness/tests/assistant/tools/filemanagement/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
39
39
|
codemie_test_harness/tests/assistant/tools/filemanagement/test_assistant_with_file_management_tools.py,sha256=Oy6CzPxMq8av2PdH5-Sxb5VUNUaKlJWppiKnK9jCQEQ,3912
|
|
40
40
|
codemie_test_harness/tests/assistant/tools/git/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
@@ -109,7 +109,7 @@ codemie_test_harness/tests/test_data/direct_tools/ado_wiki_tools_test_data.py,sh
|
|
|
109
109
|
codemie_test_harness/tests/test_data/direct_tools/ado_work_item_tools_test_data.py,sha256=L-MhuQyRxRbb1WDje1rONjIxc_QxkgzaM5ssMWglcp0,7417
|
|
110
110
|
codemie_test_harness/tests/test_data/direct_tools/cloud_tools_test_data.py,sha256=ed1nKfvH2DQbtoQcCUhang_QaJvUanOHC26IdUPItJ4,35805
|
|
111
111
|
codemie_test_harness/tests/test_data/direct_tools/codebase_tools_test_data.py,sha256=MJJ-elZibJkM5sAMpr2FGxfaO2QH6_jY0lO3bz4uvmE,6144
|
|
112
|
-
codemie_test_harness/tests/test_data/direct_tools/data_management_tools_test_data.py,sha256=
|
|
112
|
+
codemie_test_harness/tests/test_data/direct_tools/data_management_tools_test_data.py,sha256=ciCNxsTXnoIlghY0yb72Pd_ORTpDThB4x-kF7LwEYbk,1744
|
|
113
113
|
codemie_test_harness/tests/test_data/direct_tools/direct_tools_test_data.py,sha256=y9awl1IA6EXGXyz05QzcNdt5z7Rk9J5LzIbfi4CFE3s,3233
|
|
114
114
|
codemie_test_harness/tests/test_data/direct_tools/file_management_tools_test_data.py,sha256=qbc53ewxJQHf9tf3uF9aKdVBVLRc_CDCXAXwWhtS4Qg,1455
|
|
115
115
|
codemie_test_harness/tests/test_data/direct_tools/keycloak_tool_test_data.py,sha256=6lU1YC6DSV6e_3VNQEVvtA4o3_lSFgOQik4T0u-TF1g,2979
|
|
@@ -297,6 +297,7 @@ codemie_test_harness/tests/workflow/direct_tools_calling/test_workflow_with_ado_
|
|
|
297
297
|
codemie_test_harness/tests/workflow/direct_tools_calling/test_workflow_with_ado_work_item_tools.py,sha256=Owlau_ITGNxtgETP2QtHs7lNWpms-F-hxQWgoKZzoic,2991
|
|
298
298
|
codemie_test_harness/tests/workflow/direct_tools_calling/test_workflow_with_cloud_tools.py,sha256=aJQrcU3i1uI50fR4njK2GxYifG8K6Sg7VGpXRjIbJPc,3725
|
|
299
299
|
codemie_test_harness/tests/workflow/direct_tools_calling/test_workflow_with_codebase_tools.py,sha256=gQIZJp88EWCHZUSBCrhXgdf4egiOmtUvNjLtZJ4hWZI,3950
|
|
300
|
+
codemie_test_harness/tests/workflow/direct_tools_calling/test_workflow_with_data_management_tools_elastic.py,sha256=9EDL241K8ptjNLT3HuDCBsAt4HKDnCpyRRqXaF45QOA,3289
|
|
300
301
|
codemie_test_harness/tests/workflow/direct_tools_calling/test_workflow_with_data_management_tools_sql.py,sha256=-WXWet_uMrHhH8N46UXqsBaQT_tHzRFQiYjMOM5LWC4,4171
|
|
301
302
|
codemie_test_harness/tests/workflow/direct_tools_calling/test_workflow_with_file_management_tools.py,sha256=VnkTiPX2GiIoebMbproLRc8zwxpdkuALicUWr6EhEH4,2901
|
|
302
303
|
codemie_test_harness/tests/workflow/direct_tools_calling/test_workflow_with_notification_tools.py,sha256=qfrJxtySw0l_eLTATC6mjHv2ir14UVbY98nt2H0sI1w,3004
|
|
@@ -348,7 +349,7 @@ codemie_test_harness/tests/workflow/virtual_assistant_tools/servicenow/__init__.
|
|
|
348
349
|
codemie_test_harness/tests/workflow/virtual_assistant_tools/servicenow/test_workflow_with_servicenow_tools.py,sha256=vq6tucNBxiNIQSmIj_pYiiPm0lipU9X3kzeCd6xEbRM,966
|
|
349
350
|
codemie_test_harness/tests/workflow/virtual_assistant_tools/vcs/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
350
351
|
codemie_test_harness/tests/workflow/virtual_assistant_tools/vcs/test_workflow_with_vcs_tools.py,sha256=uD2qs361j6Egp4UumfoQ4gC24-NioXfiW0IF53N9hVA,1175
|
|
351
|
-
codemie_test_harness-0.1.
|
|
352
|
-
codemie_test_harness-0.1.
|
|
353
|
-
codemie_test_harness-0.1.
|
|
354
|
-
codemie_test_harness-0.1.
|
|
352
|
+
codemie_test_harness-0.1.163.dist-info/METADATA,sha256=6syrnGiNH7yrNI2Wurp4Bs6TCpCZ7G2yWxAehWtS7ss,8998
|
|
353
|
+
codemie_test_harness-0.1.163.dist-info/WHEEL,sha256=fGIA9gx4Qxk2KDKeNJCbOEwSrmLtjWCwzBz351GyrPQ,88
|
|
354
|
+
codemie_test_harness-0.1.163.dist-info/entry_points.txt,sha256=n98t-EOM5M1mnMl_j2X4siyeO9zr0WD9a5LF7JyElIM,73
|
|
355
|
+
codemie_test_harness-0.1.163.dist-info/RECORD,,
|
|
File without changes
|
{codemie_test_harness-0.1.162.dist-info → codemie_test_harness-0.1.163.dist-info}/entry_points.txt
RENAMED
|
File without changes
|