def test_insert_base_addbase(self):
        """add base tag when not present"""
        html_in = '<html><head><meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">\
<body></body></html>'
        html_target = '<html><head><base href="http://localhost:8000/" />\
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">\
<body></body></html>'
        html_out = insert_base_url(html_in, "http://localhost:8000/")
        self.assertEqual(html_out, html_target)
add base tag when not present
slybot/slybot/tests/test_baseurl.py