-
Notifications
You must be signed in to change notification settings - Fork 261
/
Copy pathMockFileSystemWatcherFactory.cs
41 lines (33 loc) · 1.28 KB
/
MockFileSystemWatcherFactory.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
namespace System.IO.Abstractions.TestingHelpers;
/// <inheritdoc />
#if FEATURE_SERIALIZABLE
[Serializable]
#endif
public class MockFileSystemWatcherFactory : IFileSystemWatcherFactory
{
///
public MockFileSystemWatcherFactory(MockFileSystem mockFileSystem)
{
FileSystem = mockFileSystem;
}
/// <inheritdoc />
public IFileSystem FileSystem { get; }
/// <inheritdoc />
public IFileSystemWatcher New()
=> throw new NotImplementedException(StringResources.Manager.GetString("FILE_SYSTEM_WATCHER_NOT_IMPLEMENTED_EXCEPTION"));
/// <inheritdoc />
public IFileSystemWatcher New(string path)
=> throw new NotImplementedException(StringResources.Manager.GetString("FILE_SYSTEM_WATCHER_NOT_IMPLEMENTED_EXCEPTION"));
/// <inheritdoc />
public IFileSystemWatcher New(string path, string filter)
=> throw new NotImplementedException(StringResources.Manager.GetString("FILE_SYSTEM_WATCHER_NOT_IMPLEMENTED_EXCEPTION"));
/// <inheritdoc />
public IFileSystemWatcher Wrap(FileSystemWatcher fileSystemWatcher)
{
if (fileSystemWatcher == null)
{
return null;
}
throw new NotImplementedException(StringResources.Manager.GetString("FILE_SYSTEM_WATCHER_NOT_IMPLEMENTED_EXCEPTION"));
}
}