From 1050b3618153708cf8de1adf3f1233964b305d94 Mon Sep 17 00:00:00 2001 From: Ferry Boender Date: Mon, 29 Jun 2015 17:55:01 +0200 Subject: [PATCH] Test FormConfig.callback for correct handling of missing stdout/err params. --- test/test.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/test/test.py b/test/test.py index e46290d..2e15c47 100644 --- a/test/test.py +++ b/test/test.py @@ -78,6 +78,13 @@ class FormConfigTestCase(unittest.TestCase): self.assertTrue(exitcode == 33) self.assertTrue('stdout' in stdout.read()) + def testCallbackMissingParams(self): + """ + """ + sf = scriptform.ScriptForm('test_formconfig_callback.json') + fc = sf.get_form_config() + self.assertRaises(ValueError, fc.callback, 'test_raw', {}) + class FormDefinitionTest(unittest.TestCase): """ Form Definition tests. Mostly directly testing if validations work.