def test_is_allowed_when_text(self): res = _is_allowed('test1') self.assertFalse(res)
def test_is_allowed_when_none(self): res = _is_allowed(None) self.assertFalse(res)
def test_is_allowed_when_float(self): res = _is_allowed(10.0) self.assertFalse(res)
def test_is_allowed_when_complex(self): res = _is_allowed(2j) self.assertFalse(res)
def test_is_allowed_when_int(self): res = _is_allowed(1) self.assertFalse(res)
def test_is_allowed_when_bool(self): res = _is_allowed(True) self.assertFalse(res)
def test_is_allowed_when_obj(self): res = _is_allowed(CustomTestClass('name1', 'description1')) self.assertTrue(res)
def test_is_allowed_when_callable(self): res = _is_allowed(self.callable_x) self.assertTrue(res)
def test_is_allowed_when_tuple(self): res = _is_allowed((1, )) self.assertTrue(res)
def test_is_allowed_when_list(self): res = _is_allowed([]) self.assertTrue(res)
def test_is_allowed_when_dict(self): res = _is_allowed({}) self.assertTrue(res)