Ejemplo n.º 1
0
 def test_rejects_local_path_containing_url(self):
     self.assertFalse(base_utils.is_url("somedir/http://path/file"))
Ejemplo n.º 2
0
 def test_rejects_local_filename(self):
     self.assertFalse(base_utils.is_url("filename"))
Ejemplo n.º 3
0
 def test_rejects_relative_local_path(self):
     self.assertFalse(base_utils.is_url("somedir/somesubdir/file"))
Ejemplo n.º 4
0
 def test_accepts_ftp(self):
     self.assertTrue(base_utils.is_url("ftp://ftp.example.com"))
Ejemplo n.º 5
0
 def test_rejects_local_path(self):
     self.assertFalse(base_utils.is_url("/home/username/file"))
Ejemplo n.º 6
0
 def test_rejects_local_path_containing_url(self):
     self.assertFalse(base_utils.is_url("somedir/http://path/file"))
Ejemplo n.º 7
0
 def test_accepts_http(self):
     self.assertTrue(base_utils.is_url("http://example.com"))
Ejemplo n.º 8
0
 def test_rejects_relative_local_path(self):
     self.assertFalse(base_utils.is_url("somedir/somesubdir/file"))
Ejemplo n.º 9
0
 def test_rejects_local_filename(self):
     self.assertFalse(base_utils.is_url("filename"))
Ejemplo n.º 10
0
 def test_rejects_local_path(self):
     self.assertFalse(base_utils.is_url("/home/username/file"))
Ejemplo n.º 11
0
 def test_accepts_ftp(self):
     self.assertTrue(base_utils.is_url("ftp://ftp.example.com"))
Ejemplo n.º 12
0
 def test_accepts_http(self):
     self.assertTrue(base_utils.is_url("http://example.com"))