mirror of
https://github.com/gnustep/libs-base.git
synced 2025-05-30 08:21:25 +00:00
fix for #292
This commit is contained in:
parent
41ad571889
commit
e8b67e3e0b
3 changed files with 42 additions and 3 deletions
|
@ -272,6 +272,28 @@ NSLog(@"%@\n%@", oa, na);
|
|||
PASS([mgr createDirectoryAtPath: @"subdir" attributes: nil],
|
||||
"NSFileManager can create a subdirectory");
|
||||
|
||||
{
|
||||
NSURL *u;
|
||||
NSDirectoryEnumerator *e;
|
||||
unsigned found = 0;
|
||||
|
||||
e = [mgr enumeratorAtURL: [NSURL fileURLWithPath: @"."]
|
||||
includingPropertiesForKeys: nil
|
||||
options: 0
|
||||
errorHandler: nil];
|
||||
|
||||
while (nil != (u = [e nextObject]))
|
||||
{
|
||||
NSString *c = [[u path] lastPathComponent];
|
||||
|
||||
if ([c isEqualToString: @"NSFMCopy"])
|
||||
found++;
|
||||
if ([c isEqualToString: @"subdir"])
|
||||
found++;
|
||||
}
|
||||
PASS(2 == found, "URL enumerator finds expected file and subdirectory")
|
||||
}
|
||||
|
||||
PASS([mgr changeCurrentDirectoryPath: @"subdir"],
|
||||
"NSFileManager can move into subdir");
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue