Exemplo n.º 1
0
 def testLocalhostExpandUser(self):
     urlparser = URLParser()
     logname = os.environ.get('LOGNAME')
     home = os.environ.get('HOME')
     self.assertEqual(
         urlparser.abspath('file://localhost/~%s/public' % logname),
         'file://localhost%s/public' % home)
Exemplo n.º 2
0
 def testNonFile(self):
     urlparser = URLParser()
     self.assertEqual(urlparser.abspath('svn://jarn.com/public'),
                      'svn://jarn.com/public')
Exemplo n.º 3
0
 def testLocalhostExpandUser(self):
     urlparser = URLParser()
     logname = os.environ.get('LOGNAME')
     home = os.environ.get('HOME')
     self.assertEqual(urlparser.abspath('file://localhost/~%s/public' % logname),
                      'file://localhost%s/public' % home)
Exemplo n.º 4
0
 def testLocalhost(self):
     urlparser = URLParser()
     cwd = os.getcwd()
     self.assertEqual(urlparser.abspath('file://localhost%s/var/dist/public' % cwd),
                      'file://localhost%s/var/dist/public' % cwd)
Exemplo n.º 5
0
 def testRelativeFile(self):
     urlparser = URLParser()
     cwd = os.getcwd()
     self.assertEqual(urlparser.abspath('file:var/dist/public'),
                      'file://%s/var/dist/public' % cwd)
Exemplo n.º 6
0
 def testNonFile(self):
     urlparser = URLParser()
     self.assertEqual(urlparser.abspath('svn://jarn.com/public'),
                      'svn://jarn.com/public')
Exemplo n.º 7
0
 def testLocalhost(self):
     urlparser = URLParser()
     cwd = os.getcwd()
     self.assertEqual(
         urlparser.abspath('file://localhost%s/var/dist/public' % cwd),
         'file://localhost%s/var/dist/public' % cwd)
Exemplo n.º 8
0
 def testRelativeFile(self):
     urlparser = URLParser()
     cwd = os.getcwd()
     self.assertEqual(urlparser.abspath('file:var/dist/public'),
                      'file://%s/var/dist/public' % cwd)