mirror of
https://github.com/gnustep/libs-base.git
synced 2025-04-22 16:33:29 +00:00
fix test of expansion of relative symlinks
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@32695 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
37d3a7c31a
commit
dfd42af94f
1 changed files with 4 additions and 1 deletions
|
@ -273,8 +273,10 @@ int main()
|
|||
[fm createDirectoryAtPath: tmpdst attributes: nil];
|
||||
[fm createSymbolicLinkAtPath: tmpsrc pathContent: @"bar"];
|
||||
|
||||
[fm changeCurrentDirectoryPath: tmpdir];
|
||||
PASS_EQUAL([@"foo" stringByResolvingSymlinksInPath], @"foo",
|
||||
"foo->bar relative symlink not expanded by stringByResolvingSymlinksInPath")
|
||||
[fm changeCurrentDirectoryPath: cwd];
|
||||
|
||||
[fm removeFileAtPath: tmpsrc handler: nil];
|
||||
[fm createSymbolicLinkAtPath: tmpsrc pathContent: tmpdst];
|
||||
|
@ -283,13 +285,14 @@ int main()
|
|||
"foo->bar symlink not expanded by stringByStandardizingPath")
|
||||
PASS_EQUAL([tmpsrc stringByResolvingSymlinksInPath], tmpdst,
|
||||
"foo->bar absolute symlink expanded by stringByResolvingSymlinksInPath")
|
||||
|
||||
[fm changeCurrentDirectoryPath: tmpdir];
|
||||
PASS_EQUAL([@"foo" stringByResolvingSymlinksInPath], tmpdst,
|
||||
"foo->bar relative symlink expanded by stringByResolvingSymlinksInPath")
|
||||
PASS(NO == [[@"~" stringByResolvingSymlinksInPath] isEqual: @"~"],
|
||||
"tilde is expanded by stringByResolvingSymlinksInPath")
|
||||
|
||||
[fm changeCurrentDirectoryPath: cwd];
|
||||
|
||||
[fm removeFileAtPath: tmpdst handler: nil];
|
||||
[fm removeFileAtPath: tmpsrc handler: nil];
|
||||
|
||||
|
|
Loading…
Reference in a new issue