# Path: mistralclient/api/v2/executions.py
# class Execution(base.Resource):
# class ExecutionManager(base.ResourceManager):
#     def create(self, wf_identifier='', namespace='',
#                workflow_input=None, description='', source_execution_id=None,
#                **params):
#     def update(self, id, state, description=None, env=None):
#     def list(self, task=None, marker='', limit=None, sort_keys='',
#              sort_dirs='', fields='', **filters):
#     def get(self, id):
#     def get_ex_sub_executions(self, id, errors_only='', max_depth=-1):
#     def delete(self, id, force=None):
#     def get_report(self, id, errors_only=True, max_depth=None,
#                    statistics_only=False):
# 
# Path: mistralclient/commands/v2/executions.py
# LOG = logging.getLogger(__name__)
#     COLUMNS = [
#         ('id', 'ID'),
#         ('workflow_id', 'Workflow ID'),
#         ('workflow_name', 'Workflow name'),
#         ('workflow_namespace', 'Workflow namespace'),
#         ('description', 'Description'),
#         ('task_execution_id', 'Task Execution ID'),
#         ('root_execution_id', 'Root Execution ID'),
#         ('state', 'State'),
#         ('state_info', 'State info'),
#         ('created_at', 'Created at'),
#         ('updated_at', 'Updated at'),
#         ('duration', 'Duration', True),
#     ]
# REPORT_ENTRY_INDENT = 4
# class ExecutionFormatter(base.MistralFormatter):
# class List(base.MistralExecutionLister):
# class Get(command.ShowOne):
# class Create(command.ShowOne):
# class Delete(command.Command):
# class Update(command.ShowOne):
# class GetInput(command.Command):
# class GetOutput(command.Command):
# class GetReport(command.Command):
# class GetPublished(command.Command):
# class SubExecutionsBaseLister(cliff_lister):
# class SubExecutionsLister(SubExecutionsBaseLister):
#     def format(wf_ex=None, lister=False):
#     def _get_format_function(self):
#     def get_parser(self, parsed_args):
#     def _get_resources(self, parsed_args):
#     def get_parser(self, prog_name):
#     def take_action(self, parsed_args):
#     def get_parser(self, prog_name):
#     def take_action(self, parsed_args):
#     def get_parser(self, prog_name):
#     def take_action(self, parsed_args):
#     def get_parser(self, prog_name):
#     def take_action(self, parsed_args):
#     def get_parser(self, prog_name):
#     def take_action(self, parsed_args):
#     def get_parser(self, prog_name):
#     def take_action(self, parsed_args):
#     def get_parser(self, prog_name):
#     def print_line(self, line, level=0):
#     def print_workflow_execution_entry(self, wf_ex, level):
#     def print_task_execution_entry(self, t_ex, level):
#     def print_action_execution_entry(self, a_ex, level):
#     def print_statistics(self, stat):
#     def print_report(self, report_json):
#     def take_action(self, parsed_args):
#     def get_parser(self, prog_name):
#     def take_action(self, parsed_args):
#     def _get_format_function(self):
#     def _get_resources_function(self):
#     def get_parser(self, prog_name):
#     def _get_resources(self, parsed_args):
#     def take_action(self, parsed_args):
#     def _get_format_function(self):
#     def _get_resources_function(self):
# 
# Path: mistralclient/tests/unit/base.py
# class BaseClientTest(base.BaseTestCase):
# class BaseCommandTest(base.BaseTestCase):
#     def setUp(self):
#     def setUp(self):
#     def call(self, command, app_args=(), prog_name=''):


import pkg_resources as pkg
from unittest import mock
from oslo_serialization import jsonutils
from mistralclient.api.v2 import executions
from mistralclient.commands.v2 import executions as execution_cmd
from mistralclient.tests.unit import base
    '',
    '',
    'abc',
    'ROOT_EXECUTION_ID',
    'ERROR',
    None,
    '2020-02-07 08:10:32',
    '2020-02-07 08:10:41',
    '0:00:09'
)

EXECS_LIST = [EXEC, SUB_WF_EXEC]
EXEC_PUBLISHED = {"bar1": "val1", "var2": 2}
EXEC_WITH_PUBLISHED_DICT = EXEC_DICT.copy()
EXEC_WITH_PUBLISHED_DICT.update(
    {'published_global': jsonutils.dumps(EXEC_PUBLISHED)})
EXEC_WITH_PUBLISHED = executions.Execution(mock, EXEC_WITH_PUBLISHED_DICT)


class TestCLIExecutionsV2(base.BaseCommandTest):
    def setUp(self):
        super(TestCLIExecutionsV2, self).setUp()

    def tearDown(self):
        super(TestCLIExecutionsV2, self).tearDown()

    def test_create_wf_input_string(self):
        self.client.executions.create.return_value = EXEC

        result = self.call(

# Path: mistralclient/api/v2/executions.py
# class Execution(base.Resource):
# class ExecutionManager(base.ResourceManager):
#     def create(self, wf_identifier='', namespace='',
#                workflow_input=None, description='', source_execution_id=None,
#                **params):
#     def update(self, id, state, description=None, env=None):
#     def list(self, task=None, marker='', limit=None, sort_keys='',
#              sort_dirs='', fields='', **filters):
#     def get(self, id):
#     def get_ex_sub_executions(self, id, errors_only='', max_depth=-1):
#     def delete(self, id, force=None):
#     def get_report(self, id, errors_only=True, max_depth=None,
#                    statistics_only=False):
# 
# Path: mistralclient/commands/v2/executions.py
# LOG = logging.getLogger(__name__)
#     COLUMNS = [
#         ('id', 'ID'),
#         ('workflow_id', 'Workflow ID'),
#         ('workflow_name', 'Workflow name'),
#         ('workflow_namespace', 'Workflow namespace'),
#         ('description', 'Description'),
#         ('task_execution_id', 'Task Execution ID'),
#         ('root_execution_id', 'Root Execution ID'),
#         ('state', 'State'),
#         ('state_info', 'State info'),
#         ('created_at', 'Created at'),
#         ('updated_at', 'Updated at'),
#         ('duration', 'Duration', True),
#     ]
# REPORT_ENTRY_INDENT = 4
# class ExecutionFormatter(base.MistralFormatter):
# class List(base.MistralExecutionLister):
# class Get(command.ShowOne):
# class Create(command.ShowOne):
# class Delete(command.Command):
# class Update(command.ShowOne):
# class GetInput(command.Command):
# class GetOutput(command.Command):
# class GetReport(command.Command):
# class GetPublished(command.Command):
# class SubExecutionsBaseLister(cliff_lister):
# class SubExecutionsLister(SubExecutionsBaseLister):
#     def format(wf_ex=None, lister=False):
#     def _get_format_function(self):
#     def get_parser(self, parsed_args):
#     def _get_resources(self, parsed_args):
#     def get_parser(self, prog_name):
#     def take_action(self, parsed_args):
#     def get_parser(self, prog_name):
#     def take_action(self, parsed_args):
#     def get_parser(self, prog_name):
#     def take_action(self, parsed_args):
#     def get_parser(self, prog_name):
#     def take_action(self, parsed_args):
#     def get_parser(self, prog_name):
#     def take_action(self, parsed_args):
#     def get_parser(self, prog_name):
#     def take_action(self, parsed_args):
#     def get_parser(self, prog_name):
#     def print_line(self, line, level=0):
#     def print_workflow_execution_entry(self, wf_ex, level):
#     def print_task_execution_entry(self, t_ex, level):
#     def print_action_execution_entry(self, a_ex, level):
#     def print_statistics(self, stat):
#     def print_report(self, report_json):
#     def take_action(self, parsed_args):
#     def get_parser(self, prog_name):
#     def take_action(self, parsed_args):
#     def _get_format_function(self):
#     def _get_resources_function(self):
#     def get_parser(self, prog_name):
#     def _get_resources(self, parsed_args):
#     def take_action(self, parsed_args):
#     def _get_format_function(self):
#     def _get_resources_function(self):
# 
# Path: mistralclient/tests/unit/base.py
# class BaseClientTest(base.BaseTestCase):
# class BaseCommandTest(base.BaseTestCase):
#     def setUp(self):
#     def setUp(self):
#     def call(self, command, app_args=(), prog_name=''):


# Path: mistralclient/tests/unit/v2/test_cli_executions.py
import pkg_resources as pkg
from unittest import mock
from oslo_serialization import jsonutils
from mistralclient.api.v2 import executions
from mistralclient.commands.v2 import executions as execution_cmd
from mistralclient.tests.unit import base

    '',
    '',
    'abc',
    'ROOT_EXECUTION_ID',
    'ERROR',
    None,
    '2020-02-07 08:10:32',
    '2020-02-07 08:10:41',
    '0:00:09'
)

EXECS_LIST = [EXEC, SUB_WF_EXEC]
EXEC_PUBLISHED = {"bar1": "val1", "var2": 2}
EXEC_WITH_PUBLISHED_DICT = EXEC_DICT.copy()
EXEC_WITH_PUBLISHED_DICT.update(
    {'published_global': jsonutils.dumps(EXEC_PUBLISHED)})
EXEC_WITH_PUBLISHED = executions.Execution(mock, EXEC_WITH_PUBLISHED_DICT)


class TestCLIExecutionsV2(base.BaseCommandTest):
    def setUp(self):
        super(TestCLIExecutionsV2, self).setUp()

    def tearDown(self):
        super(TestCLIExecutionsV2, self).tearDown()

    def test_create_wf_input_string(self):
        self.client.executions.create.return_value = EXEC

        result = self.call(

            execution_cmd.Create,