Handle DI changes in tests.
This commit is contained in:
parent
781615a29b
commit
5243789dd2
|
|
@ -19,7 +19,7 @@ namespace Microsoft.AspNet.StaticFiles
|
|||
[Fact]
|
||||
public async Task NullArguments()
|
||||
{
|
||||
Assert.Throws<TargetInvocationException>(() => TestServer.Create(app => app.UseDirectoryBrowser(new DirectoryBrowserOptions() { Formatter = null })));
|
||||
Assert.Throws<ArgumentException>(() => TestServer.Create(app => app.UseDirectoryBrowser(new DirectoryBrowserOptions() { Formatter = null })));
|
||||
|
||||
// No exception, default provided
|
||||
TestServer.Create(app => app.UseDirectoryBrowser(new DirectoryBrowserOptions() { FileSystem = null }));
|
||||
|
|
|
|||
|
|
@ -19,7 +19,7 @@ namespace Microsoft.AspNet.StaticFiles
|
|||
[Fact]
|
||||
public async Task NullArguments()
|
||||
{
|
||||
Assert.Throws<TargetInvocationException>(() => TestServer.Create(app => app.UseStaticFiles(new StaticFileOptions() { ContentTypeProvider = null })));
|
||||
Assert.Throws<ArgumentException>(() => TestServer.Create(app => app.UseStaticFiles(new StaticFileOptions() { ContentTypeProvider = null })));
|
||||
|
||||
// No exception, default provided
|
||||
TestServer.Create(app => app.UseStaticFiles(new StaticFileOptions() { FileSystem = null }));
|
||||
|
|
|
|||
Loading…
Reference in New Issue