mirror of
https://github.com/nsnail/Ocelot.git
synced 2025-12-17 11:45:47 +08:00
#296 merged develop into this branch
This commit is contained in:
@@ -12,13 +12,17 @@ using Ocelot.Configuration.Repository;
|
||||
|
||||
namespace Ocelot.UnitTests.Configuration
|
||||
{
|
||||
public class FileConfigurationRepositoryTests
|
||||
public class FileConfigurationRepositoryTests : IDisposable
|
||||
{
|
||||
private readonly Mock<IHostingEnvironment> _hostingEnvironment = new Mock<IHostingEnvironment>();
|
||||
private IFileConfigurationRepository _repo;
|
||||
private FileConfiguration _result;
|
||||
private FileConfiguration _fileConfiguration;
|
||||
private string _environmentName = "DEV";
|
||||
|
||||
// This is a bit dirty and it is dev.dev so that the configuration tests
|
||||
// cant pick it up if they run in parralel..sigh these are not really unit
|
||||
// tests but whatever...
|
||||
private string _environmentName = "DEV.DEV";
|
||||
|
||||
public FileConfigurationRepositoryTests()
|
||||
{
|
||||
@@ -221,5 +225,10 @@ namespace Ocelot.UnitTests.Configuration
|
||||
ReRoutes = reRoutes
|
||||
};
|
||||
}
|
||||
|
||||
public void Dispose()
|
||||
{
|
||||
File.Delete($"./ocelot.{_environmentName}.json");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user