def test_get_default_helper_set_returns_default_values(self): application = Application() application.set_auto_exit(False) application.set_catch_exceptions(False) helper_set = application.get_helper_set() self.assertTrue(helper_set.has('formatter')) self.assertTrue(helper_set.has('question'))
def test_get_default_helper_set_returns_default_values(self): application = Application() application.set_auto_exit(False) application.set_catch_exceptions(False) helper_set = application.get_helper_set() self.assertTrue(helper_set.has("formatter")) self.assertTrue(helper_set.has("dialog")) self.assertTrue(helper_set.has("progress"))
def test_adding_single_helper_set_overwrites_default_values(self): application = Application() application.set_auto_exit(False) application.set_catch_exceptions(False) application.set_helper_set(HelperSet([FormatterHelper()])) helper_set = application.get_helper_set() self.assertTrue(helper_set.has('formatter')) self.assertFalse(helper_set.has('question'))
def test_adding_single_helper_set_overwrites_default_values(self): application = Application() application.set_auto_exit(False) application.set_catch_exceptions(False) application.set_helper_set(HelperSet({"formatter": FormatterHelper()})) helper_set = application.get_helper_set() self.assertTrue(helper_set.has("formatter")) self.assertFalse(helper_set.has("dialog")) self.assertFalse(helper_set.has("progress"))