def test_rejects_local_path_containing_url(self):
     self.assertFalse(base_utils.is_url("somedir/http://path/file"))
 def test_rejects_local_filename(self):
     self.assertFalse(base_utils.is_url("filename"))
 def test_rejects_relative_local_path(self):
     self.assertFalse(base_utils.is_url("somedir/somesubdir/file"))
 def test_accepts_ftp(self):
     self.assertTrue(base_utils.is_url("ftp://ftp.example.com"))
 def test_rejects_local_path(self):
     self.assertFalse(base_utils.is_url("/home/username/file"))
Example #6
0
 def test_rejects_local_path_containing_url(self):
     self.assertFalse(base_utils.is_url("somedir/http://path/file"))
 def test_accepts_http(self):
     self.assertTrue(base_utils.is_url("http://example.com"))
Example #8
0
 def test_rejects_relative_local_path(self):
     self.assertFalse(base_utils.is_url("somedir/somesubdir/file"))
Example #9
0
 def test_rejects_local_filename(self):
     self.assertFalse(base_utils.is_url("filename"))
Example #10
0
 def test_rejects_local_path(self):
     self.assertFalse(base_utils.is_url("/home/username/file"))
Example #11
0
 def test_accepts_ftp(self):
     self.assertTrue(base_utils.is_url("ftp://ftp.example.com"))
Example #12
0
 def test_accepts_http(self):
     self.assertTrue(base_utils.is_url("http://example.com"))