public void SetRegion_ShouldSetCorrectlyTest() { var config = new ApiConfiguration(); config.SetRegion(Region.Taiwan); config.ApiRegion.Should().BeEquivalentTo(Region.Taiwan); }
public void SetRegion_ShouldNotOverrideLocaleWhenFalse() { var config = new ApiConfiguration(); config = config.SetRegion(Region.Korea); config.ApiRegion.Should().BeEquivalentTo(Region.Korea); config.ResultLocale.Should().BeEquivalentTo(default(Locale)); }
public void SetRegionWithDefaultLocaleTest() { var config = new ApiConfiguration(); config.SetRegion(Region.SoutheastAsia, true); config.ApiRegion.Should().BeEquivalentTo(Region.SoutheastAsia); config.ResultLocale.Should().BeEquivalentTo(Region.SoutheastAsia.GetDefaultLocale()); }
public void SetRegion_DoNotUseDefaultLocale_ExpectedLocale() { var config = new ApiConfiguration(Region.UnitedStates, Locale.AmericanEnglish, "anyapikey"); config = config.SetRegion(Region.Korea, false); config.ApiRegion.Should().BeEquivalentTo(Region.Korea); config.ResultLocale.Should().BeEquivalentTo(Locale.AmericanEnglish); }
public void SetRegion_RegionParameter_ExpectedRegion() { var config = new ApiConfiguration(Region.UnitedStates, Locale.AmericanEnglish, "anyapikey"); config = config.SetRegion(Region.Korea); config.ApiRegion.Should().BeEquivalentTo(Region.Korea); config.ResultLocale.Should().BeEquivalentTo(Locale.AmericanEnglish); }