Package org.jbehave.core.steps

Examples of org.jbehave.core.steps.ParameterConverters$EnumConverter


   @Override
   public Configuration configuration() {
      Class<? extends Embeddable> embeddableClass = this.getClass();
      // Start from default ParameterConverters instance
      ParameterConverters parameterConverters = new ParameterConverters();
      // factory to allow parameter conversion and loading from external resources (used by StoryParser too)
      ExamplesTableFactory examplesTableFactory = new ExamplesTableFactory(new LocalizedKeywords(), new LoadFromClasspath(embeddableClass),
            parameterConverters);
      // add custom coverters
      parameterConverters.addConverters(new DateConverter(new SimpleDateFormat("yyyy-MM-dd")), new ExamplesTableConverter(
            examplesTableFactory));
      return new MostUsefulConfiguration()
            .useStoryLoader(new LoadFromClasspath(embeddableClass))
            .useStoryParser(new RegexStoryParser(examplesTableFactory))
            .useStoryReporterBuilder(
View Full Code Here


                .withRelativeDirectory(".." + File.separator + Config.getLatestReportsDir())
        .withFormats(Format.XML, Format.CONSOLE, Format.HTML, Format.IDE_CONSOLE, Format.TXT)
        .withFailureTrace(Config.displayStackTrace());

    // Setup parameters
    ParameterConverters parameterConverters = new ParameterConverters()
        .addConverters(new ExamplesTableConverter(
            new ExamplesTableFactory(new LoadFromRelativeFile(
                codeLocation))));
    // factory to allow parameter conversion and loading from external
    // resources (used by StoryParser too)
    ExamplesTableFactory examplesTableFactory = new ExamplesTableFactory(
        new LocalizedKeywords(),
        new LoadFromRelativeFile(codeLocation), parameterConverters);
    // add custom coverters
    parameterConverters.addConverters(new ExamplesTableConverter(
        examplesTableFactory));
    viewResources.put("decorateNonHtml", "true");
    useStoryControls(
        new StoryControls().doDryRun(false)
            .doSkipScenariosAfterFailure(false)
View Full Code Here

    @Override
    public Configuration configuration() {
        Class<? extends Embeddable> embeddableClass = this.getClass();
        // Start from default ParameterConverters instance
        ParameterConverters parameterConverters = new ParameterConverters();
        // factory to allow parameter conversion and loading from external resources (used by StoryParser too)
        ExamplesTableFactory examplesTableFactory = new ExamplesTableFactory(new LocalizedKeywords(), new LoadFromClasspath(embeddableClass), parameterConverters);
        // add custom converters
        parameterConverters.addConverters(new DateConverter(new SimpleDateFormat("yyyy-MM-dd")),
                new ExamplesTableConverter(examplesTableFactory));
        return new MostUsefulConfiguration()
            .useStoryLoader(new LoadFromClasspath(embeddableClass))
            .useStoryParser(new RegexStoryParser(examplesTableFactory))
            .useStoryReporterBuilder(new StoryReporterBuilder()
View Full Code Here

  @Override
  public Configuration configuration() {
    Class<? extends Embeddable> embeddableClass = this.getClass();
    // Start from default ParameterConverters instance
    ParameterConverters parameterConverters = new ParameterConverters();
    // factory to allow parameter conversion and loading from external
    // resources (used by StoryParser too)
    ExamplesTableFactory examplesTableFactory = new ExamplesTableFactory(
        new LocalizedKeywords(),
        new LoadFromClasspath(embeddableClass), parameterConverters);
    // and add custom converters
    parameterConverters.addConverters(
        new ParameterConverters.DateConverter(new SimpleDateFormat(
            "dd-MM-yyyy")),
        new ParameterConverters.ExamplesTableConverter(
            examplesTableFactory), new ParameterConverters.BooleanConverter(),
            new NullAndEmptyStringConverter());
View Full Code Here

        // set Jira step doc reporter
        StepdocReporter stepDocReporter = new JiraStepDocReporter(jiraUrl, jiraProject, "admin", "admin");
//        StepdocReporter stepDocReporter = new GroovyStepDocReporter(jiraUrl, jiraProject, "admin", "admin");
        configuration.useStepdocReporter(stepDocReporter);

        ParameterConverters parameterConverters = configuration.parameterConverters();
        parameterConverters.addConverters(new ParameterConverters.ExamplesTableParametersConverter());
        configuration.useParameterConverters(parameterConverters);

        useConfiguration(configuration);

    }
View Full Code Here

TOP

Related Classes of org.jbehave.core.steps.ParameterConverters$EnumConverter

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.