

@mock.patch.object(workflows.WorkflowManager, 'validate', mock.MagicMock(return_value={
    'valid': True,
}))
def test_unexpected_action_params_failure(self):
    def_yaml = self._read_file_content(WF_UNEXP_PARAM_PATH)
    resp = self.__do_post(def_yaml)
    expected = [{
        'type': 'action',
        'path': None,
        'message': 'Unexpected parameters in "task1" for action "wolfpack.action-1": "foo"',
    }]
    self.assertEqual(200, resp.status_int)
    expected.assertListEqual(expected, resp.json)

dataset/ETHPy150Open StackStorm/st2/st2api/tests/unit/controllers/exp/test_validator_mistral.py MistralValidationControllerTest.test_unexpected_action_params_failure/VarMisuse@92/158 `self`->`expected`