Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Maven Plugin #4

Closed
dodie opened this issue Sep 5, 2016 · 10 comments
Closed

Maven Plugin #4

dodie opened this issue Sep 5, 2016 · 10 comments

Comments

@dodie
Copy link
Owner

dodie commented Sep 5, 2016

Provide a Maven plugin that eases project configuration and ad-hoc usage. See the JaCoCo's maven plugin for inspiration.

@dodie dodie changed the title Maven Plugn Maven Plugin Sep 11, 2016
@dodie dodie added this to the Release 3.0.0 milestone Nov 29, 2016
@dodie dodie removed this from the Release 3.0.0 milestone May 19, 2017
@basalt79
Copy link

basalt79 commented Oct 7, 2017

@dodie, I will have a look on this.

@dodie
Copy link
Owner Author

dodie commented Oct 7, 2017

Awesome! 👍

@basalt79
Copy link

basalt79 commented Oct 8, 2017

i have a first draft version to be able to get rid of the "maven-dependency-plugin" completly, and also the surefire plugin will be reduced

<plugin>
	<groupId>org.apache.maven.plugins</groupId>
	<artifactId>maven-surefire-plugin</artifactId>
	<version>2.19.1</version>
	<configuration>
		<properties>
			<property>
				<name>listener</name>
				<value>hu.advancedweb.scott.runtime.ScottRunListener</value>
			</property>
		</properties>
	</configuration>
</plugin>

currently i see no way to define also the listener via the scott-mojo

@dodie
Copy link
Owner Author

dodie commented Oct 11, 2017

Awesome, it's already much shorter!
Is it necessary to use ScottRunListener? If the scott-agent jar is in place, the auto-instrumented ScottReportingRule should be sufficient.

@basalt79
Copy link

its working without in the junit 4 and 5 tests, but in cucumber is miss the last exception in the output

@dodie
Copy link
Owner Author

dodie commented Oct 11, 2017

It sounds nice:)
Could you push the code?

@basalt79
Copy link

i prepare the pull request, you will have it soon

@dodie
Copy link
Owner Author

dodie commented Oct 11, 2017

Thanks!

basalt79 pushed a commit to basalt79/scott that referenced this issue Oct 11, 2017
@dodie
Copy link
Owner Author

dodie commented Oct 13, 2017

I had some time in my hands so I've checked this out. This is seriously awesome, the configuration will be much easier with this plugin, and the maven plugin itself is simple and clean. Great great job!

I've fiddled a bit with the cucumber reporting and I think the problem is caused by a small glitch in the ScottCucumberEnricher.

Currently, when processing a Result object in its result method, it has an if-else branch to handle non-failing and failing steps:

  • For every non-failing step, it calls Scott to render the output.
  • For the failing step, it does not render anything but relies on the Exception object that it will contain the necessary information. For this to work, it requires the ScottRunListener to enhance the exception object before this code runs.

I think this can be fixed by calling Scott to render the report for the failing step as well, just with the additional exception object. (E.g.: FailureRenderer.render(null, null, result.getError());.)

basalt79 pushed a commit to basalt79/scott that referenced this issue Oct 13, 2017
dodie added a commit that referenced this issue Oct 13, 2017
@dodie
Copy link
Owner Author

dodie commented Oct 13, 2017

👍

@dodie dodie closed this as completed Oct 13, 2017
@dodie dodie modified the milestones: 3.0.1, Release 3.0.1 Oct 13, 2017
@dodie dodie mentioned this issue Sep 30, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants