Skip to content
Snippets Groups Projects
Commit acb504ee authored by Nathan Hertz's avatar Nathan Hertz
Browse files

Added test for creating and submitting workflow requests

parent 6b0b3cdf
No related branches found
No related tags found
No related merge requests found
from typing import Dict, List
import json
import requests
from pycapo import CapoConfig
from workspaces.schema import (
Workflow,
WorkflowTemplate,
......@@ -82,3 +84,14 @@ def test_workflow_creation():
# execute the null workflow
# service.execute(request, [])
def test_workflow_request_execution():
"""
Test whether a null workflow request can properly be executed
"""
settings = CapoConfig().settings("edu.nrao.archive.workspaces.WorkflowSettings")
r1 = requests.post(f"{settings.serviceUrl}/workflows/null/requests/create?args=-g")
print(r1.json())
r2 = requests.post(f"{settings.serviceUrl}/workflows/requests/{r1.json()['workflow_request_id']}/submit")
print(r2.json())
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment