comparison tests/test_externals.py @ 869:db3a651494f9

test_util: pass repo_path to svnls(), turn it into a function
author Patrick Mezard <patrick@mezard.eu>
date Thu, 19 Apr 2012 18:29:30 +0200
parents 04729f3a3d17
children 1eb2a4428c42
comparison
equal deleted inserted replaced
868:cc1c870f1758 869:db3a651494f9
327 327
328 def test_push_hgsub(self, stupid=False): 328 def test_push_hgsub(self, stupid=False):
329 if subrepo is None: 329 if subrepo is None:
330 return 330 return
331 331
332 self._load_fixture_and_fetch('pushexternals.svndump', 332 repo, repo_path = self.load_and_fetch('pushexternals.svndump',
333 externals='subrepos') 333 externals='subrepos')
334 # Add a new reference on an existing and non-existing directory 334 # Add a new reference on an existing and non-existing directory
335 changes = [ 335 changes = [
336 ('.hgsub', '.hgsub', """\ 336 ('.hgsub', '.hgsub', """\
337 dir/deps/project2 = [hgsubversion] dir:^/externals/project2 deps/project2 337 dir/deps/project2 = [hgsubversion] dir:^/externals/project2 deps/project2
338 subdir1/deps/project1 = [hgsubversion] subdir1:^/externals/project1 deps/project1 338 subdir1/deps/project1 = [hgsubversion] subdir1:^/externals/project1 deps/project1
353 self.pushrevisions(stupid) 353 self.pushrevisions(stupid)
354 self.assertchanges(changes, self.repo['tip']) 354 self.assertchanges(changes, self.repo['tip'])
355 355
356 # Check .hgsub and .hgsubstate were not pushed 356 # Check .hgsub and .hgsubstate were not pushed
357 self.assertEqual(['dir', 'subdir1', 'subdir1/a', 'subdir2', 357 self.assertEqual(['dir', 'subdir1', 'subdir1/a', 'subdir2',
358 'subdir2/a'], self.svnls('trunk')) 358 'subdir2/a'], test_util.svnls(repo_path, 'trunk'))
359 359
360 # Remove all references from one directory, add a new one 360 # Remove all references from one directory, add a new one
361 # to the other (test multiline entries) 361 # to the other (test multiline entries)
362 changes = [ 362 changes = [
363 ('.hgsub', '.hgsub', """\ 363 ('.hgsub', '.hgsub', """\