Skip to content

Commit dde453c

Browse files
quark-zjufacebook-github-bot
authored andcommitted
tests: scope SL_DEBUG_DISABLE_SYMLINKS to Windows only
Summary: The `SL_DEBUG_DISABLE_SYMLINKS` was changed to be Windows-only in D71445977. Update tests to only set it on Windows. `test-no-symlinks.t` now uses `#require no-symlinks` to cover non-symlink filesystems. I chose this instead of respecting `SL_DEBUG_DISABLE_SYMLINKS` on non-Windows platforms because: - Setting this environment variable on non-Windows can be a footgun for users. - This environment variable can be deleted once our Windows users are all using symlinks. This diff makes it slightly easier to delete. Reviewed By: muirdm Differential Revision: D71666114 fbshipit-source-id: 67dd72b4eed768d8d4a9ab43a1a22a4894af59b7
1 parent fd2f770 commit dde453c

4 files changed

Lines changed: 5 additions & 5 deletions

File tree

eden/scm/tests/test-no-symlinks.t

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,9 @@
11
#modern-config-incompatible
22

3-
#require no-eden
3+
#require no-eden no-symlinks
44

55
TODO(debugruntest): this test fails on Mac
66
#chg-compatible
7-
$ export SL_DEBUG_DISABLE_SYMLINKS=1
8-
97

108
# The following (test) script was used to create the bundle:
119
#

eden/scm/tests/test-status.t

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -593,7 +593,7 @@ Make sure we expand env vars in ignore file path.
593593

594594
$ cd ..
595595

596-
#if symlink
596+
#if symlink windows
597597
Ignore suspiciously modified symlinks.
598598

599599
$ newclientrepo suspicious-symlink

eden/scm/tests/test-symlink-placeholder.t

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
#require symlink no-eden
1+
#require symlink no-eden windows
22

33
$ hg init unix-repo
44
$ cd unix-repo

eden/scm/tests/test-symlinks.t

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -325,8 +325,10 @@ Issue995: hg copy -A incorrectly handles symbolic links
325325

326326
$ cd ..
327327

328+
#if windows
328329
Don't treat symlinks as untrackable if symlinks aren't supported.
329330
$ newclientrepo
330331
$ ln -s foo bar
331332
$ SL_DEBUG_DISABLE_SYMLINKS=1 hg status
332333
? bar
334+
#endif

0 commit comments

Comments
 (0)