From 26b3c84619458e02f26455d82f29e09ee0a0c3f1 Mon Sep 17 00:00:00 2001 From: Mads Kiilerich Date: Wed, 12 Dec 2012 02:38:14 +0100 Subject: [PATCH] localrepo: store requirements sorted --- mercurial/localrepo.py | 2 +- tests/test-init.t | 26 +++++++++++++------------- tests/test-lfconvert.t | 4 ++-- 3 files changed, 16 insertions(+), 16 deletions(-) diff --git a/mercurial/localrepo.py b/mercurial/localrepo.py index e56d54ced4..04f195e1ee 100644 --- a/mercurial/localrepo.py +++ b/mercurial/localrepo.py @@ -262,7 +262,7 @@ class localrepository(object): def _writerequirements(self): reqfile = self.opener("requires", "w") - for r in self.requirements: + for r in sorted(self.requirements): reqfile.write("%s\n" % r) reqfile.close() diff --git a/tests/test-init.t b/tests/test-init.t index aa4610b8e6..d52dd962d5 100644 --- a/tests/test-init.t +++ b/tests/test-init.t @@ -18,10 +18,10 @@ creating 'local' $ checknewrepo local store created 00changelog.i created - revlogv1 - fncache - store dotencode + fncache + revlogv1 + store $ echo this > local/foo $ hg ci --cwd local -A -m "init" adding foo @@ -47,8 +47,8 @@ creating repo with format.dotencode=false $ checknewrepo old3 store created 00changelog.i created - revlogv1 fncache + revlogv1 store test failure @@ -149,10 +149,10 @@ creating 'local/sub/repo' $ checknewrepo local/sub/repo store created 00changelog.i created - revlogv1 - fncache - store dotencode + fncache + revlogv1 + store prepare test of init of url configured from paths @@ -166,10 +166,10 @@ init should (for consistency with clone) expand the url $ checknewrepo "url from paths" store created 00changelog.i created - revlogv1 - fncache - store dotencode + fncache + revlogv1 + store verify that clone also expand urls @@ -179,10 +179,10 @@ verify that clone also expand urls $ checknewrepo "another paths url" store created 00changelog.i created - revlogv1 - fncache - store dotencode + fncache + revlogv1 + store clone bookmarks diff --git a/tests/test-lfconvert.t b/tests/test-lfconvert.t index 2a7f24382c..e21fb69f97 100644 --- a/tests/test-lfconvert.t +++ b/tests/test-lfconvert.t @@ -96,11 +96,11 @@ Test link+rename largefile codepath "lfconvert" adds 'largefiles' to .hg/requires. $ cat .hg/requires + dotencode + fncache largefiles revlogv1 - fncache store - dotencode "lfconvert" includes a newline at the end of the standin files. $ cat .hglf/large .hglf/sub/maybelarge.dat