This is an archive of the discontinued Mercurial Phabricator instance.

tests: test-pathconflicts-merge.t requires symlinks
ClosedPublic

Authored by durin42 on Dec 15 2017, 5:53 PM.

Details

Summary

Once we're ready to turn this functionality on more widely, we might
want to write a symlink-free version of the test that can run on
Windows, but for now we'll just leave it disabled there.

Diff Detail

Repository
rHG Mercurial
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

durin42 created this revision.Dec 15 2017, 5:53 PM
krbullock accepted this revision.Dec 15 2017, 6:05 PM
krbullock added a subscriber: krbullock.

LGTM, thanks.

This revision is now accepted and ready to land.Dec 15 2017, 6:05 PM
This revision was automatically updated to reflect the committed changes.

It might be easier to use the hg import --bypass trick instead of making it symlink free, and have some testing around this corner case on Windows? (I haven't done anything with symlinks on Windows. I'm assuming it's just a flags thing, and should work.)

FWIW, I haven't done anything on this because I suspect it has the same problems at test-pathconflicts-basic.t. These problems magically go away if -C is passed to update, but that's clearly not the intention. It's good to see the Windows tests closer to green.

diff --git a/tests/test-pathconflicts-basic.t b/tests/test-pathconflicts-basic.t
--- a/tests/test-pathconflicts-basic.t
+++ b/tests/test-pathconflicts-basic.t
@@ -29,7 +29,7 @@

 Basic merge - local file conflicts with remote directory

-  $ hg up -q file
+  $ hg up -Cq file
   $ hg bookmark -i
   $ hg merge --verbose dir
   resolving manifests
@@ -83,12 +83,12 @@

 Basic clean update - local directory conflicts with changed remote file

-  $ hg up -q file
+  $ hg up -Cq file
   $ rm a
   $ mkdir a
   $ echo 4 > a/b
   $ hg up file2
-  abort: *: '$TESTTMP/repo/a' (glob)
+  abort: Unlinking directory not permitted: '$TESTTMP\repo\a'
   [255]
   $ hg up --clean file2
   1 files updated, 0 files merged, 0 files removed, 0 files unresolved