diff --git a/Runtime/FeatureInfo.cs b/Runtime/FeatureInfo.cs index a610abd58..e4d3979c7 100644 --- a/Runtime/FeatureInfo.cs +++ b/Runtime/FeatureInfo.cs @@ -11,11 +11,8 @@ public class FeatureInfo public string Title { get; private set; } public string Description { get; private set; } public CultureInfo Language { get; private set; } - [Obsolete("Use Language property that is now ensured to be a specific culture.")] - public CultureInfo CultureInfo - { - get { return Language; } - } + [Obsolete("Use Language property that is now ensured to be a specific culture.", true)] + public CultureInfo CultureInfo { get { throw new NotSupportedException(); } } public FeatureInfo(CultureInfo language, string title, string description, params string[] tags) { diff --git a/Runtime/TestRunner.cs b/Runtime/TestRunner.cs index 88a832e3d..019a321cc 100644 --- a/Runtime/TestRunner.cs +++ b/Runtime/TestRunner.cs @@ -235,7 +235,7 @@ private BindingMatch Match(StepBinding stepBinding, StepArgs stepArgs, bool useP return null; // Check if regex arguments can be converted to the method parameters - CultureInfo cultureInfo = FeatureContext.Current.FeatureInfo.CultureInfo; + CultureInfo cultureInfo = FeatureContext.Current.FeatureInfo.Language; for (int regexArgIndex = 0; regexArgIndex < regexArgs.Length; regexArgIndex++) { Type parameterType = stepBinding.ParameterTypes[regexArgIndex]; @@ -432,7 +432,7 @@ private object[] GetExecuteArguments(BindingMatch match) if (regexArgs.Length + match.ExtraArguments.Length != match.StepBinding.ParameterTypes.Length) throw errorProvider.GetParameterCountError(match, regexArgs.Length + match.ExtraArguments.Length); - CultureInfo cultureInfo = FeatureContext.Current.FeatureInfo.CultureInfo; + CultureInfo cultureInfo = FeatureContext.Current.FeatureInfo.Language; for (int regexArgIndex = 0; regexArgIndex < regexArgs.Length; regexArgIndex++) { Type parameterType = match.StepBinding.ParameterTypes[regexArgIndex];