-
I need to get a valid I was thinking about using the [Test]
public void Test()
{
var fixture = new Fixture();
var validCultures = new[]
{
CultureInfo.GetCultureInfo("en-us"),
CultureInfo.GetCultureInfo("en-es"),
CultureInfo.GetCultureInfo("se-sv"),
CultureInfo.GetCultureInfo("it-it"),
};
fixture.Customizations.Add(new ElementsBuilder<CultureInfo>(validCultures));
var ci = fixture.Create<CultureInfo>();
Assert.That(validCultures.Select(c => c.Name), Contains.Item(ci.Name));
} Did I misundertand the purpose of Years ago I used it to handle a similar scenario (see here) |
Beta Was this translation helpful? Give feedback.
Answered by
aivascu
Nov 29, 2023
Replies: 1 comment 1 reply
-
@Kralizek the request never reaches the |
Beta Was this translation helpful? Give feedback.
1 reply
Answer selected by
aivascu
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
@Kralizek the request never reaches the
ElementsBuilder
sinceAdd
appends it to the end of the collection.Use
.Insert(0, new ElementsBuilder...