public void DuplicateMimeTypesAllowed_DuplicatesRemoved() { //Arrange PluginTypesBuilder builder = new PluginTypesBuilder(); //Act builder.AllowMimeType("img/png").AllowMimeType("img/png"); //Assert string result = builder.Build(); Assert.Equal("img/png", result); }
public void MimeTypeAllowed_MimeTypeReturned() { //Arrange PluginTypesBuilder builder = new PluginTypesBuilder(); //Act builder.AllowMimeType("img/png"); //Assert string result = builder.Build(); Assert.Equal("img/png", result); }
public void MimeTypesAllowed_MimeTypesIgnored() { //Arrange PluginTypesBuilder builder = new PluginTypesBuilder(); //Act builder.AllowMimeType("img/png").AllowMimeType("img/jpg"); builder.AllowAny(); //Assert string result = builder.Build(); Assert.Equal("*", result); }
public void SomethingElseCalled_OnlyNoneReturned() { //Arrange PluginTypesBuilder builder = new PluginTypesBuilder(); //Act builder.AllowMimeType("img/png"); builder.AllowNone(); builder.AllowAny(); //Assert string result = builder.Build(); Assert.Equal("'none'", result); }