You've already forked linux-packaging-mono
Imported Upstream version 3.12.0
Former-commit-id: cf92446697332992ec36726e78eb8703e1f259d7
This commit is contained in:
@@ -10,6 +10,7 @@
|
||||
|
||||
using System;
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Runtime.Serialization;
|
||||
using System.Runtime.Serialization.Formatters.Binary;
|
||||
@@ -1059,6 +1060,23 @@ namespace MonoTests.System.IO
|
||||
Assert.AreEqual (TempFolder + DSC + "ToString.Test", info.ToString ());
|
||||
}
|
||||
|
||||
#if NET_4_0
|
||||
[Test]
|
||||
public void EnumerateFileSystemInfosTest ()
|
||||
{
|
||||
var dirInfo = new DirectoryInfo (TempFolder);
|
||||
dirInfo.CreateSubdirectory ("1").CreateSubdirectory ("a");
|
||||
dirInfo.CreateSubdirectory ("2").CreateSubdirectory ("b");
|
||||
|
||||
var l = new List<string> ();
|
||||
foreach (var info in dirInfo.EnumerateFileSystemInfos ("*", SearchOption.AllDirectories))
|
||||
l.Add (info.Name);
|
||||
|
||||
l.Sort ();
|
||||
Assert.AreEqual ("1,2,a,b", string.Join (",", l), "#1");
|
||||
}
|
||||
#endif
|
||||
|
||||
#if !MOBILE
|
||||
[Test]
|
||||
public void Serialization ()
|
||||
@@ -1111,7 +1129,7 @@ namespace MonoTests.System.IO
|
||||
try {
|
||||
Directory.CreateDirectory (path);
|
||||
Directory.CreateDirectory (dir);
|
||||
Mono.Unix.UnixSymbolicLinkInfo li = new Mono.Unix.UnixSymbolicLinkInfo (link);
|
||||
global::Mono.Unix.UnixSymbolicLinkInfo li = new global::Mono.Unix.UnixSymbolicLinkInfo (link);
|
||||
li.CreateSymbolicLinkTo (dir);
|
||||
|
||||
DirectoryInfo info = new DirectoryInfo (path);
|
||||
|
@@ -374,11 +374,11 @@ public class DirectoryTest
|
||||
string path = TempFolder + DSC + "ExistsAccessDenied";
|
||||
|
||||
Directory.CreateDirectory (path);
|
||||
Mono.Posix.Syscall.chmod (path, 0);
|
||||
global::Mono.Posix.Syscall.chmod (path, 0);
|
||||
try {
|
||||
Assert.IsFalse (Directory.Exists(path + DSC + "b"));
|
||||
} finally {
|
||||
Mono.Posix.Syscall.chmod (path, (Mono.Posix.FileMode) 755);
|
||||
global::Mono.Posix.Syscall.chmod (path, (global::Mono.Posix.FileMode) 755);
|
||||
Directory.Delete (path);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user