Ejemplo n.º 1
0
 def setUp(self):
     CompatTestCase.setUp(self)
     DulwichClientTestBase.setUp(self)
     if check_for_daemon(limit=1):
         raise SkipTest("git-daemon was already running on port %s" %
                        protocol.TCP_GIT_PORT)
     fd, self.pidfile = tempfile.mkstemp(prefix="dulwich-test-git-client",
                                         suffix=".pid")
     os.fdopen(fd).close()
     args = [
         _DEFAULT_GIT,
         "daemon",
         "--verbose",
         "--export-all",
         "--pid-file=%s" % self.pidfile,
         "--base-path=%s" % self.gitroot,
         "--enable=receive-pack",
         "--enable=upload-archive",
         "--listen=localhost",
         "--reuseaddr",
         self.gitroot,
     ]
     self.process = subprocess.Popen(
         args,
         cwd=self.gitroot,
         stdout=subprocess.PIPE,
         stderr=subprocess.PIPE,
     )
     if not check_for_daemon():
         raise SkipTest("git-daemon failed to start")
Ejemplo n.º 2
0
 def setUp(self):
     CompatTestCase.setUp(self)
     DulwichClientTestBase.setUp(self)
     if check_for_daemon(limit=1):
         raise SkipTest("git-daemon was already running on port %s" % protocol.TCP_GIT_PORT)
     fd, self.pidfile = tempfile.mkstemp(prefix="dulwich-test-git-client", suffix=".pid")
     os.fdopen(fd).close()
     run_git_or_fail(
         [
             "daemon",
             "--verbose",
             "--export-all",
             "--pid-file=%s" % self.pidfile,
             "--base-path=%s" % self.gitroot,
             "--detach",
             "--reuseaddr",
             "--enable=receive-pack",
             "--enable=upload-archive",
             "--listen=localhost",
             self.gitroot,
         ],
         cwd=self.gitroot,
     )
     if not check_for_daemon():
         raise SkipTest("git-daemon failed to start")
Ejemplo n.º 3
0
 def setUp(self):
     CompatTestCase.setUp(self)
     DulwichClientTestBase.setUp(self)
     if check_for_daemon(limit=1):
         raise SkipTest('git-daemon was already running on port %s' %
                           protocol.TCP_GIT_PORT)
     fd, self.pidfile = tempfile.mkstemp(prefix='dulwich-test-git-client',
                                         suffix=".pid")
     os.fdopen(fd).close()
     run_git_or_fail(
         ['daemon', '--verbose', '--export-all',
          '--pid-file=%s' % self.pidfile, '--base-path=%s' % self.gitroot,
          '--detach', '--reuseaddr', '--enable=receive-pack',
          '--enable=upload-archive', '--listen=localhost', self.gitroot], cwd=self.gitroot)
     if not check_for_daemon():
         raise SkipTest('git-daemon failed to start')
Ejemplo n.º 4
0
 def setUp(self):
     CompatTestCase.setUp(self)
     DulwichClientTestBase.setUp(self)
     if check_for_daemon(limit=1):
         raise SkipTest('git-daemon was already running on port %s' %
                           protocol.TCP_GIT_PORT)
     fd, self.pidfile = tempfile.mkstemp(prefix='dulwich-test-git-client',
                                         suffix=".pid")
     os.fdopen(fd).close()
     run_git_or_fail(
         ['daemon', '--verbose', '--export-all',
          '--pid-file=%s' % self.pidfile, '--base-path=%s' % self.gitroot,
          '--detach', '--reuseaddr', '--enable=receive-pack',
          '--listen=localhost', self.gitroot], cwd=self.gitroot)
     if not check_for_daemon():
         raise SkipTest('git-daemon failed to start')
Ejemplo n.º 5
0
 def setUp(self):
     CompatTestCase.setUp(self)
     DulwichClientTestBase.setUp(self)
     if check_for_daemon(limit=1):
         raise SkipTest('git-daemon was already running on port %s' %
                        protocol.TCP_GIT_PORT)
     fd, self.pidfile = tempfile.mkstemp(prefix='dulwich-test-git-client',
                                         suffix=".pid")
     os.fdopen(fd).close()
     args = [_DEFAULT_GIT, 'daemon', '--verbose', '--export-all',
             '--pid-file=%s' % self.pidfile,
             '--base-path=%s' % self.gitroot,
             '--enable=receive-pack', '--enable=upload-archive',
             '--listen=localhost', '--reuseaddr',
             self.gitroot]
     self.process = subprocess.Popen(
         args, cwd=self.gitroot,
         stdout=subprocess.PIPE, stderr=subprocess.PIPE)
     if not check_for_daemon():
         raise SkipTest('git-daemon failed to start')
Ejemplo n.º 6
0
 def setUp(self):
     CompatTestCase.setUp(self)
     DulwichClientTestBase.setUp(self)
     if check_for_daemon(limit=1):
         raise SkipTest('git-daemon was already running on port %s' %
                        protocol.TCP_GIT_PORT)
     env = get_safe_env()
     fd, self.pidfile = tempfile.mkstemp(prefix='dulwich-test-git-client',
                                         suffix=".pid")
     os.fdopen(fd).close()
     args = [
         _DEFAULT_GIT, 'daemon', '--verbose', '--export-all',
         '--pid-file=%s' % self.pidfile,
         '--base-path=%s' % self.gitroot, '--enable=receive-pack',
         '--enable=upload-archive', '--listen=localhost', '--reuseaddr',
         self.gitroot
     ]
     self.process = subprocess.Popen(args,
                                     env=env,
                                     cwd=self.gitroot,
                                     stdout=subprocess.PIPE,
                                     stderr=subprocess.PIPE)
     if not check_for_daemon():
         raise SkipTest('git-daemon failed to start')
Ejemplo n.º 7
0
 def setUp(self):
     CompatTestCase.setUp(self)
     DulwichClientTestBase.setUp(self)
     if check_for_daemon(limit=1):
         raise SkipTest("git-daemon was already running on port %s" % protocol.TCP_GIT_PORT)
     env = get_safe_env()
     fd, self.pidfile = tempfile.mkstemp(prefix="dulwich-test-git-client", suffix=".pid")
     os.fdopen(fd).close()
     args = [
         _DEFAULT_GIT,
         "daemon",
         "--verbose",
         "--export-all",
         "--pid-file=%s" % self.pidfile,
         "--base-path=%s" % self.gitroot,
         "--enable=receive-pack",
         "--enable=upload-archive",
         "--listen=localhost",
         "--reuseaddr",
         self.gitroot,
     ]
     self.process = subprocess.Popen(args, env=env, cwd=self.gitroot, stdout=subprocess.PIPE, stderr=subprocess.PIPE)
     if not check_for_daemon():
         raise SkipTest("git-daemon failed to start")