public void OneTimeSetup() { ConfigurationHelper.ConfigurationRoot = new ConfigurationBuilder() .AddJsonFile("appsettings.json") .Build(); DataSeeder = new DataSeeder(); var configurations = ConfigurationHelper.GetValues(JwtEndpointKey, AuthenticationKey, ApiVersionKey); AuthenticationEndpoint = $"{configurations[0]}{configurations[1]}"; ApiVersion = configurations[2]; Client = CreateTestClient(); Client.DefaultRequestHeaders .Accept .Add(new MediaTypeWithQualityHeaderValue(ApplicationJson)); }
public async Task TearDown() { await DataSeeder.ResetDatabaseAsync(); Client.DefaultRequestHeaders.Remove(Authorization); }
public async Task Setup() { await DataSeeder.SeedDatabaseAsync(); }