# Path: mistralclient/api/v2/cron_triggers.py
# class CronTrigger(base.Resource):
# class CronTriggerManager(base.ResourceManager):
#     def create(self, name, workflow_identifier, workflow_input=None,
#                workflow_params=None, pattern=None,
#                first_time=None, count=None):
#     def list(self, marker='', limit=None, sort_keys='', fields='',
#              sort_dirs='', **filters):
#     def get(self, name):
#     def delete(self, name):
# 
# Path: mistralclient/commands/v2/cron_triggers.py
# class CronTriggerFormatter(base.MistralFormatter):
# class List(base.MistralLister):
# class Get(command.ShowOne):
# class Create(command.ShowOne):
# class Delete(command.Command):
#     COLUMNS = [
#         ('name', 'Name'),
#         ('workflow_name', 'Workflow'),
#         ('workflow_params', 'Params'),
#         ('pattern', 'Pattern'),
#         # TODO(rakhmerov): Uncomment when passwords are handled properly.
#         # TODO(rakhmerov): Add 'Workflow input' column.
#         ('next_execution_time', 'Next execution time'),
#         ('remaining_executions', 'Remaining executions'),
#         ('created_at', 'Created at'),
#         ('updated_at', 'Updated at')
#     ]
#     def format(trigger=None, lister=False):
#     def _get_format_function(self):
#     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 _get_file_content_or_dict(string):
#     def _convert_time_string_to_utc(time_string):
#     def take_action(self, parsed_args):
#     def get_parser(self, prog_name):
#     def take_action(self, parsed_args):
# 
# 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=''):


from unittest import mock
from mistralclient.api.v2 import cron_triggers
from mistralclient.commands.v2 import cron_triggers as cron_triggers_cmd
from mistralclient.tests.unit import base
#    not use this file except in compliance with the License. You may obtain
#    a copy of the License at
#
#         http://www.apache.org/licenses/LICENSE-2.0
#
#    Unless required by applicable law or agreed to in writing, software
#    distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
#    WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
#    License for the specific language governing permissions and limitations
#    under the License.
#




TRIGGER_DICT = {
    'name': 'my_trigger',
    'workflow_name': 'flow1',
    'workflow_input': {},
    'workflow_params': {},
    'pattern': '* * * * *',
    'next_execution_time': '4242-12-20 13:37',
    'remaining_executions': 5,
    'created_at': '1',
    'updated_at': '1'
}

TRIGGER = cron_triggers.CronTrigger(mock, TRIGGER_DICT)



# Path: mistralclient/api/v2/cron_triggers.py
# class CronTrigger(base.Resource):
# class CronTriggerManager(base.ResourceManager):
#     def create(self, name, workflow_identifier, workflow_input=None,
#                workflow_params=None, pattern=None,
#                first_time=None, count=None):
#     def list(self, marker='', limit=None, sort_keys='', fields='',
#              sort_dirs='', **filters):
#     def get(self, name):
#     def delete(self, name):
# 
# Path: mistralclient/commands/v2/cron_triggers.py
# class CronTriggerFormatter(base.MistralFormatter):
# class List(base.MistralLister):
# class Get(command.ShowOne):
# class Create(command.ShowOne):
# class Delete(command.Command):
#     COLUMNS = [
#         ('name', 'Name'),
#         ('workflow_name', 'Workflow'),
#         ('workflow_params', 'Params'),
#         ('pattern', 'Pattern'),
#         # TODO(rakhmerov): Uncomment when passwords are handled properly.
#         # TODO(rakhmerov): Add 'Workflow input' column.
#         ('next_execution_time', 'Next execution time'),
#         ('remaining_executions', 'Remaining executions'),
#         ('created_at', 'Created at'),
#         ('updated_at', 'Updated at')
#     ]
#     def format(trigger=None, lister=False):
#     def _get_format_function(self):
#     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 _get_file_content_or_dict(string):
#     def _convert_time_string_to_utc(time_string):
#     def take_action(self, parsed_args):
#     def get_parser(self, prog_name):
#     def take_action(self, parsed_args):
# 
# 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_cron_triggers.py
from unittest import mock
from mistralclient.api.v2 import cron_triggers
from mistralclient.commands.v2 import cron_triggers as cron_triggers_cmd
from mistralclient.tests.unit import base

#    not use this file except in compliance with the License. You may obtain
#    a copy of the License at
#
#         http://www.apache.org/licenses/LICENSE-2.0
#
#    Unless required by applicable law or agreed to in writing, software
#    distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
#    WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
#    License for the specific language governing permissions and limitations
#    under the License.
#




TRIGGER_DICT = {
    'name': 'my_trigger',
    'workflow_name': 'flow1',
    'workflow_input': {},
    'workflow_params': {},
    'pattern': '* * * * *',
    'next_execution_time': '4242-12-20 13:37',
    'remaining_executions': 5,
    'created_at': '1',
    'updated_at': '1'
}

TRIGGER = cron_triggers.CronTrigger(mock, TRIGGER_DICT)



class TestCLITriggersV2(base.BaseCommandTest):