gherkin.ast.Feature.getLocation()方法的使用及代码示例

x33g5p2x  于2022-01-19 转载在 其他  
字(1.6k)|赞(0)|评价(0)|浏览(126)

本文整理了Java中gherkin.ast.Feature.getLocation()方法的一些代码示例,展示了Feature.getLocation()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Feature.getLocation()方法的具体详情如下:
包路径:gherkin.ast.Feature
类名称:Feature
方法名:getLocation

Feature.getLocation介绍

暂无

代码示例

代码示例来源:origin: cucumber/cucumber-jvm

private Map<String, Object> createFeatureMap(TestCase testCase) {
  Map<String, Object> featureMap = new HashMap<String, Object>();
  featureMap.put("uri", testCase.getUri());
  featureMap.put("elements", new ArrayList<Map<String, Object>>());
  Feature feature = testSources.getFeature(testCase.getUri());
  if (feature != null) {
    featureMap.put("keyword", feature.getKeyword());
    featureMap.put("name", feature.getName());
    featureMap.put("description", feature.getDescription() != null ? feature.getDescription() : "");
    featureMap.put("line", feature.getLocation().getLine());
    featureMap.put("id", TestSourcesModel.convertToId(feature.getName()));
    featureMap.put("tags", feature.getTags());
  }
  return featureMap;
}

代码示例来源:origin: net.serenity-bdd/serenity-cucumber

private Feature featureWithDefaultName(Feature feature, String defaultName) {
  return new Feature(feature.getTags(),
      feature.getLocation(),
      feature.getLanguage(),
      feature.getKeyword(),
      defaultName,
      feature.getDescription(),
      feature.getChildren());
}

代码示例来源:origin: serenity-bdd/serenity-cucumber

private Feature featureWithDefaultName(Feature feature, String defaultName) {
  return new Feature(feature.getTags(),
      feature.getLocation(),
      feature.getLanguage(),
      feature.getKeyword(),
      defaultName,
      feature.getDescription(),
      feature.getChildren());
}

相关文章