def test_joinRoot(self): deploy.remoteSep = "/" self.assertEqual(deploy.remoteJoin("/", "spain"), "/spain") self.assertEqual(deploy.remoteJoin("", "spain"), "/spain") self.assertEqual(deploy.remoteJoin("/", "/spain"), "/spain") self.assertEqual(deploy.remoteJoin("", "/spain"), "/spain")
def test_join(self): deploy.remoteSep = "/" self.assertEqual(deploy.remoteJoin("/path/to", "spain"), "/path/to/spain") self.assertEqual(deploy.remoteJoin("/path/to/", "spain"), "/path/to/spain") self.assertEqual(deploy.remoteJoin("/path/to", "/spain"), "/path/to/spain") self.assertEqual(deploy.remoteJoin("/path/to/", "/spain"), "/path/to/spain")