예제 #1
0
        private DirectoryMock GivenDirectory(string directoryName)
        {
            var directoryMock = DirectoryMock.CreateDirectory(directoryName);

            fileSystem.Add(directoryName, directoryMock);

            return(directoryMock);
        }
예제 #2
0
        private Folder CreateFolder(DirectoryMock folderMock)
        {
            var folder = new Folder
            {
                NumberOfFiles = folderMock.Files.Count
            };

            if (Progress != null)
            {
                Progress(folder);
            }

            return(folder);
        }
예제 #3
0
파일: Tests.cs 프로젝트: peitor/CodeKatas
 private static void StartAndWait(IFolderStats folderStats, DirectoryMock root, int millisecondsTimeout)
 {
     folderStats.Connect(root.Name);
     folderStats.Start();
     Thread.Sleep(millisecondsTimeout);
 }
예제 #4
0
 private static void StartAndWait(IFolderStats folderStats, DirectoryMock root, int millisecondsTimeout)
 {
     folderStats.Connect(root.Name);
     folderStats.Start();
     Thread.Sleep(millisecondsTimeout);
 }
예제 #5
0
        private Folder CreateFolder(DirectoryMock folderMock)
        {
            var folder = new Folder
                         {
                             NumberOfFiles = folderMock.Files.Count
                         };

            if (Progress != null)
            {
                Progress(folder);
            }

            return folder;
        }