System.IO.Tests.FileSystemWatcherTests_netstandard17.EndRaisingEventsDuringPause C# (CSharp) Méthode

EndRaisingEventsDuringPause() private méthode

private EndRaisingEventsDuringPause ( ) : void
Résultat void
        public void EndRaisingEventsDuringPause()
        {
            using (var testDirectory = new TempDirectory(GetTestFilePath()))
            using (var watcher = new TestFileSystemWatcher(testDirectory.Path, "*"))
            {
                watcher.EnableRaisingEvents = true;
                watcher.BeginInit();
                watcher.EnableRaisingEvents = false;
                watcher.EndInit();
                new TempFile(Path.Combine(testDirectory.Path, GetTestFileName())).Dispose();
                Thread.Sleep(WaitForExpectedEventTimeout);
            }
        }