public static void Initialize(TestContext testContext) //https://docs.microsoft.com/en-us/visualstudio/test/configure-unit-tests-by-using-a-dot-runsettings-file?view=vs-2017 { bestbuyApiConfig = new BestbuyApiConfig() { API_KEY = testContext.Properties["BESTBUY_API_KEY"].ToString(), BASE_API_URI = testContext.Properties["BESTBUY_BASE_API_URI"].ToString() }; }
public BestbuyService(IOptions <BestbuyApiConfig> bestbuyApiConfig) { this.bestbuyApiConfig = bestbuyApiConfig.Value; }