Exemplo n.º 1
0
 def test_target_frame_blank(self):
     h = Hyperlink(xmlnode=None)
     h.target_frame = '_blank'
     self.assertEqual(h.target_frame, '_blank')
     self.assertEqual(h.get_attr(CN('xlink:show')), 'new')
Exemplo n.º 2
0
 def test_href(self):
     h = Hyperlink(xmlnode=None)
     h.href = 'http://x.html'
     self.assertEqual(h.href, 'http://x.html')
Exemplo n.º 3
0
 def test_target_frame(self):
     h = Hyperlink(xmlnode=None)
     h.target_frame = 'xtarget'
     self.assertEqual(h.target_frame, 'xtarget')
     self.assertEqual(h.get_attr(CN('xlink:show')), 'replace')
Exemplo n.º 4
0
 def test_target_frame_blank(self):
     h = Hyperlink(xmlnode=None)
     h.target_frame = '_blank'
     self.assertEqual(h.target_frame, '_blank')
     self.assertEqual(h.get_attr(CN('xlink:show')), 'new')
Exemplo n.º 5
0
 def test_name(self):
     h = Hyperlink(xmlnode=None)
     h.name = 'test'
     self.assertEqual(h.name, 'test')
Exemplo n.º 6
0
 def test_href(self):
     h = Hyperlink(xmlnode=None)
     h.href = 'http://x.html'
     self.assertEqual(h.href, 'http://x.html')
Exemplo n.º 7
0
 def test_target_frame(self):
     h = Hyperlink(xmlnode=None)
     h.target_frame = 'xtarget'
     self.assertEqual(h.target_frame, 'xtarget')
     self.assertEqual(h.get_attr(CN('xlink:show')), 'replace')
Exemplo n.º 8
0
 def test_name(self):
     h = Hyperlink(xmlnode=None)
     h.name = 'test'
     self.assertEqual(h.name, 'test')
Exemplo n.º 9
0
 def test_unset_href(self):
     h = Hyperlink(xmlnode=None)
     self.assertIsNone(h.href)
Exemplo n.º 10
0
 def test_unset_name(self):
     h = Hyperlink(xmlnode=None)
     self.assertIsNone(h.name)
Exemplo n.º 11
0
 def test_init(self):
     h = Hyperlink(xmlnode=None)
     self.assertIsNotNone(h)
Exemplo n.º 12
0
 def test_target_frame_blank(self):
     h = Hyperlink(xmlnode=None)
     h.target_frame = "_blank"
     self.assertEqual(h.target_frame, "_blank")
     self.assertEqual(h.get_attr(CN("xlink:show")), "new")
Exemplo n.º 13
0
 def test_target_frame(self):
     h = Hyperlink(xmlnode=None)
     h.target_frame = "xtarget"
     self.assertEqual(h.target_frame, "xtarget")
     self.assertEqual(h.get_attr(CN("xlink:show")), "replace")
Exemplo n.º 14
0
 def test_name(self):
     h = Hyperlink(xmlnode=None)
     h.name = "test"
     self.assertEqual(h.name, "test")