From 489dbbfc4f1cdbd493112504407b8302bad94489 Mon Sep 17 00:00:00 2001 From: vinicvaz Date: Thu, 15 Feb 2024 07:31:49 -0300 Subject: [PATCH] update piece repo test version --- rest/routers/workflow_router.py | 2 +- rest/services/auth_service.py | 4 ++-- rest/tests/conftest.py | 2 +- rest/tests/piece/fixtures.py | 2 +- rest/tests/workflow/create_workflow_request_model.py | 2 +- rest/tests/workflow/fixtures.py | 1 + rest/tests/workspace/fixtures.py | 8 ++++---- 7 files changed, 11 insertions(+), 10 deletions(-) diff --git a/rest/routers/workflow_router.py b/rest/routers/workflow_router.py index 04ddf78f1..e86259875 100644 --- a/rest/routers/workflow_router.py +++ b/rest/routers/workflow_router.py @@ -216,7 +216,7 @@ def list_run_tasks( ) except (BaseException, ForbiddenException, ResourceNotFoundException) as e: raise HTTPException(status_code=e.status_code, detail=e.message) - + @router.get( "/{workflow_id}/runs/{workflow_run_id}/tasks/report", status_code=200, diff --git a/rest/services/auth_service.py b/rest/services/auth_service.py index 57cad67fd..9aa6c2611 100644 --- a/rest/services/auth_service.py +++ b/rest/services/auth_service.py @@ -131,8 +131,8 @@ def workspace_access_authorizer( ) if not workspace_associative_data: raise HTTPException( - status_code=400,#ResourceNotFoundError().status_code, - detail="error test",#ResourceNotFoundError(message='Workspace not found').message + status_code=ResourceNotFoundError().status_code, + detail=ResourceNotFoundError(message='Workspace not found').message ) if workspace_associative_data and not workspace_associative_data.permission: raise HTTPException(status_code=ForbiddenError().status_code, detail=ForbiddenError().message) diff --git a/rest/tests/conftest.py b/rest/tests/conftest.py index 8e45f8bf8..a5137d6e2 100644 --- a/rest/tests/conftest.py +++ b/rest/tests/conftest.py @@ -55,7 +55,7 @@ def piece_repository(): id=1, source="github", path="Tauffer-Consulting/default_domino_pieces_tests", - version="0.0.3", + version="0.0.4", workspace_id=1, url='https://github.com/Tauffer-Consulting/default_domino_pieces_tests' ) diff --git a/rest/tests/piece/fixtures.py b/rest/tests/piece/fixtures.py index 405cd93bf..3f2914e8e 100644 --- a/rest/tests/piece/fixtures.py +++ b/rest/tests/piece/fixtures.py @@ -47,7 +47,7 @@ def get_pieces_mock_response(piece_repository: PieceRepository): }, repository_url='https://github.com/Tauffer-Consulting/default_domino_pieces_tests', source_url='https://github.com/Tauffer-Consulting/default_domino_pieces_tests/tree/main/pieces/SimpleLogPiece', - source_image = "ghcr.io/tauffer-consulting/default_domino_pieces_tests:0.0.3-group0", + source_image = "ghcr.io/tauffer-consulting/default_domino_pieces_tests:0.0.4-group0", input_schema = { "title": "SimpleLogPiece", "description": "Example Operator", diff --git a/rest/tests/workflow/create_workflow_request_model.py b/rest/tests/workflow/create_workflow_request_model.py index 07e7755a6..99f36ffa9 100644 --- a/rest/tests/workflow/create_workflow_request_model.py +++ b/rest/tests/workflow/create_workflow_request_model.py @@ -393,7 +393,7 @@ "task_id": "SimpleLogP_0298c1669d404e08b631ebe1490e1c45", "piece": { "name": "SimpleLogPiece", - "source_image": "ghcr.io/tauffer-consulting/default_domino_pieces_tests:0.0.3-group0" + "source_image": "ghcr.io/tauffer-consulting/default_domino_pieces_tests:0.0.4-group0" }, "workflow_shared_storage": { "source": "None", diff --git a/rest/tests/workflow/fixtures.py b/rest/tests/workflow/fixtures.py index da45584d7..ee9c23c69 100644 --- a/rest/tests/workflow/fixtures.py +++ b/rest/tests/workflow/fixtures.py @@ -17,6 +17,7 @@ @pytest.fixture(scope="class") def create_workflow(client: ApiTestClient, authorization_token: Dict, edit_workflow_request_model: Dict, workflow: Workflow, default_workspace: Workspace): workflow_request_model = edit_workflow_request_model + print('Using workspace_id', default_workspace.id) body = workflow_request_model response = client.post( f"/workspaces/{default_workspace.id}/workflows", diff --git a/rest/tests/workspace/fixtures.py b/rest/tests/workspace/fixtures.py index a5128dd43..a444849dc 100644 --- a/rest/tests/workspace/fixtures.py +++ b/rest/tests/workspace/fixtures.py @@ -90,9 +90,9 @@ def invite_user(client: ApiTestClient, authorization_token: Dict, workspace: Wor @pytest.fixture(scope='function') def accept_invite( - client: ApiTestClient, + client: ApiTestClient, login_user_extra: Response, - authorization_token_user_extra: Dict, + authorization_token_user_extra: Dict, workspace: Workspace, ): return client.post( @@ -103,9 +103,9 @@ def accept_invite( @pytest.fixture(scope='function') def reject_invite( - client: ApiTestClient, + client: ApiTestClient, login_user_extra: Response, - authorization_token_user_extra: Dict, + authorization_token_user_extra: Dict, workspace: Workspace ): return client.post(