io.qameta.allure.ConfigurationBuilder Java Examples
The following examples show how to use
io.qameta.allure.ConfigurationBuilder.
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: Allure1EnvironmentPluginTest.java From allure2 with Apache License 2.0 | 6 votes |
@SafeVarargs private final List<EnvironmentItem> process(List<String>... results) throws IOException { List<LaunchResults> launches = new ArrayList<>(); final Configuration configuration = new ConfigurationBuilder().useDefault().build(); Allure1Plugin reader = new Allure1Plugin(); for (List<String> result : results) { Path resultsDirectory = Files.createTempDirectory(temp, "results"); Iterator<String> iterator = result.iterator(); while (iterator.hasNext()) { String first = iterator.next(); String second = iterator.next(); copyFile(resultsDirectory, first, second); } final DefaultResultsVisitor resultsVisitor = new DefaultResultsVisitor(configuration); reader.readResults(configuration, resultsVisitor, resultsDirectory); launches.add(resultsVisitor.getLaunchResults()); } Allure1EnvironmentPlugin envPlugin = new Allure1EnvironmentPlugin(); return envPlugin.getData(launches); }
Example #2
Source File: AllureReportGenerator.java From vividus with Apache License 2.0 | 5 votes |
private void generateData() throws IOException { List<Extension> plugins = List.of( new SummaryPlugin(), new HistoryTrendPlugin(), new DurationTrendPlugin(), new ExecutorPlugin() ); Configuration configuration = new ConfigurationBuilder().useDefault().fromExtensions(plugins).build(); new ReportGenerator(configuration).generate(reportDirectory.toPath(), List.of(resultsDirectory.toPath())); }
Example #3
Source File: AllureReportGenerator.java From AuTe-Framework with Apache License 2.0 | 5 votes |
private Configuration createConfiguration() { ConfigurationBuilder configurationBuilder = new ConfigurationBuilder().fromExtensions(Arrays.asList( new JacksonContext(), new MarkdownContext(), new FreemarkerContext(), new RandomUidContext(), new ProjectContext(), new MarkdownDescriptionsPlugin(), new TagsPlugin(), new SeverityPlugin(), new OwnerPlugin(), new DefaultCategoriesPlugin(), new CategoriesPlugin(), new HistoryRestorePlugin(), new HistoryPlugin(), new HistoryTrendPlugin(), new DurationPlugin(), new DurationTrendPlugin(), new StatusChartPlugin(), new TimelinePlugin(), new SuitesPlugin(), new ReportWebPlugin(), new TestsResultsPlugin(), new AttachmentsPlugin(), new SummaryPlugin(), new ExecutorPlugin(), new LaunchPlugin(), new Allure1Plugin(), new Allure1EnvironmentPlugin(), new Allure2Plugin() )); List<Plugin> plugins = loadPlugins(); if (!plugins.isEmpty()) { configurationBuilder = configurationBuilder.fromPlugins(plugins); } return configurationBuilder.build(); }
Example #4
Source File: Allure2PluginTest.java From allure2 with Apache License 2.0 | 5 votes |
private LaunchResults process(String... strings) throws IOException { Iterator<String> iterator = Arrays.asList(strings).iterator(); while (iterator.hasNext()) { String first = iterator.next(); String second = iterator.next(); copyFile(directory, first, second); } Allure2Plugin reader = new Allure2Plugin(); final Configuration configuration = new ConfigurationBuilder().useDefault().build(); final DefaultResultsVisitor resultsVisitor = new DefaultResultsVisitor(configuration); reader.readResults(configuration, resultsVisitor, directory); return resultsVisitor.getLaunchResults(); }
Example #5
Source File: Allure1PluginTest.java From allure2 with Apache License 2.0 | 5 votes |
private LaunchResults process(String... strings) throws IOException { Iterator<String> iterator = Arrays.asList(strings).iterator(); while (iterator.hasNext()) { String first = iterator.next(); String second = iterator.next(); copyFile(directory, first, second); } Allure1Plugin reader = new Allure1Plugin(); final Configuration configuration = new ConfigurationBuilder().useDefault().build(); final DefaultResultsVisitor resultsVisitor = new DefaultResultsVisitor(configuration); reader.readResults(configuration, resultsVisitor, directory); return resultsVisitor.getLaunchResults(); }
Example #6
Source File: SuitesPluginTest.java From allure2 with Apache License 2.0 | 4 votes |
@BeforeEach void setUp(@TempDir final Path temp) { reportPath = temp.resolve("report"); configuration = new ConfigurationBuilder().useDefault().build(); }
Example #7
Source File: CategoriesPluginTest.java From allure2 with Apache License 2.0 | 4 votes |
@BeforeEach void setUp(@TempDir final Path temp) { reportPath = temp.resolve("report"); configuration = new ConfigurationBuilder().useDefault().build(); }