1 | |
package org.jbehave.mojo; |
2 | |
|
3 | |
import org.apache.maven.plugin.MojoExecutionException; |
4 | |
import org.apache.maven.plugin.MojoFailureException; |
5 | |
import org.jbehave.core.Embeddable; |
6 | |
import org.jbehave.core.configuration.Configuration; |
7 | |
import org.jbehave.core.embedder.Embedder; |
8 | |
import org.jbehave.core.steps.CandidateSteps; |
9 | |
|
10 | |
|
11 | |
|
12 | |
|
13 | |
|
14 | |
|
15 | |
|
16 | |
|
17 | 0 | public class ReportStepdocsAsEmbeddables extends AbstractEmbedderMojo { |
18 | |
|
19 | |
public void execute() throws MojoExecutionException, MojoFailureException { |
20 | 0 | Embedder embedder = newEmbedder(); |
21 | 0 | getLog().info("Reporting stepdocs as embeddables using embedder " + embedder); |
22 | |
try { |
23 | 0 | embedder.reportStepdocsAsEmbeddables(classNames()); |
24 | 0 | } catch (RuntimeException e) { |
25 | 0 | throw new MojoFailureException("Failed to report stepdocs as embeddables", e); |
26 | 0 | } |
27 | 0 | } |
28 | |
|
29 | |
} |