def test_text_element_to_html(self): r = Render() obj = type("SubSubCls", (TextElement,), {"tagname": "subsub", "children_classes": []})() attrs = [("class", "test")] value = "Hello world" res = r.text_element_to_html(obj, attrs, value) expected = '<textarea class="form-control test">' "Hello world</textarea>" self.assertEqual(res, expected)
def test_text_element_to_html(self): r = Render() obj = type('SubSubCls', (TextElement, ), {'tagname': 'subsub', 'children_classes': []})() attrs = [('class', 'test')] value = 'Hello world' res = r.text_element_to_html(obj, attrs, value) expected = ('<textarea class="form-control test">' 'Hello world</textarea>') self.assertEqual(res, expected)
def test_text_element_to_html(self): r = Render() obj = type('SubSubCls', (TextElement, ), { 'tagname': 'subsub', 'children_classes': [] })() attrs = [('class', 'test')] value = 'Hello world' res = r.text_element_to_html(obj, attrs, value) expected = ('<textarea class="form-control test">' 'Hello world</textarea>') self.assertEqual(res, expected)
def test_add_comment(self): r = Render() self.assertEqual(r.add_comment(), True)
def test_add_delete_button(self): r = Render() self.assertEqual(r.add_delete_button(), True)