Search in sources :

Example 6 with I18n

use of gherkin.I18n in project cucumber-jvm by cucumber.

the class UndefinedStepsTrackerTest method snippets_are_generated_for_correct_locale.

@Test
public void snippets_are_generated_for_correct_locale() throws Exception {
    Backend backend = new TestBackend();
    UndefinedStepsTracker tracker = new UndefinedStepsTracker();
    tracker.addUndefinedStep(new Step(null, "Если ", "Б", 1, null, null), new I18n("ru"));
    assertEquals("[Если ^Б$]", tracker.getSnippets(asList(backend), functionNameGenerator).toString());
}
Also used : Step(gherkin.formatter.model.Step) I18n(gherkin.I18n) Test(org.junit.Test)

Aggregations

I18n (gherkin.I18n)6 Step (gherkin.formatter.model.Step)5 LocalizedXStreams (cucumber.runtime.xstream.LocalizedXStreams)3 Test (org.junit.Test)3 Argument (gherkin.formatter.Argument)2 StepDefinition (cucumber.runtime.StepDefinition)1 StepDefinitionMatch (cucumber.runtime.StepDefinitionMatch)1 StubStepDefinition (cucumber.runtime.StubStepDefinition)1 FilterFormatter (gherkin.formatter.FilterFormatter)1 Formatter (gherkin.formatter.Formatter)1 DataTableRow (gherkin.formatter.model.DataTableRow)1 Parser (gherkin.parser.Parser)1 IOException (java.io.IOException)1 NoSuchAlgorithmException (java.security.NoSuchAlgorithmException)1 ArrayList (java.util.ArrayList)1 Arrays.asList (java.util.Arrays.asList)1 List (java.util.List)1