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 build succeeds while botsing fails #72

Open
gibello opened this issue Apr 5, 2019 · 0 comments
Open

Maven build succeeds while botsing fails #72

gibello opened this issue Apr 5, 2019 · 0 comments
Assignees
Labels
bug Something isn't working maven-plugin This issue is related to the Maven plugin.

Comments

@gibello
Copy link

gibello commented Apr 5, 2019

Characteristics

  • Issue Type: [bug]
  • Reproducibility: [always]
  • Severity: [minor]
  • Tool/Service/Component: [Botsing maven plugin]
  • Execution Environment: [Ubuntu linux 18.04]
  • Reporter: [Pierre-Yves Gibello, [email protected]]

Description

When botsing maven plugin fails, the mvn build terminates with "BUILD SUCCESS" and a status code of 0.

Steps to reproduce

Tested on authzforce project (https://gitlab.ow2.org/authzforce), pom.xml in core/pdp-engine, with following exception stack:

java.lang.RuntimeException: Failed to load XML schemas: [classpath:pdp.xsd]
	at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:189)
	at org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver.java:588)

Maven output follows:

[INFO] Starting Botsing to generate tests with EvoSuite
[INFO] 14:32:03.906 [main] INFO  eu.stamp.botsing.StackTrace - Exception type is detected: java.lang.RuntimeException
[INFO] 14:32:03.914 [main] INFO  eu.stamp.botsing.StackTrace - Target frame is set to: org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy:189)
[INFO] 14:32:03.914 [main] INFO  eu.stamp.botsing.StackTrace - Target Class is set to: org.springframework.beans.factory.support.SimpleInstantiationStrategy
[INFO] java.lang.ClassNotFoundException: Class 'org/springframework/beans/factory/support/SimpleInstantiationStrategy.class' should be in target project, but could not be found!
[INFO] 	at org.evosuite.instrumentation.InstrumentingClassLoader.instrumentClass(InstrumentingClassLoader.java:203)
[INFO] 	at org.evosuite.instrumentation.InstrumentingClassLoader.loadClass(InstrumentingClassLoader.java:168)
[INFO] 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[INFO] 	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
[INFO] 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
[INFO] 	at java.lang.reflect.Method.invoke(Method.java:498)
[INFO] 	at org.evosuite.testcase.statements.MethodStatement$1.execute(MethodStatement.java:257)
[INFO] 	at org.evosuite.testcase.statements.AbstractStatement.exceptionHandler(AbstractStatement.java:169)
[INFO] 	at org.evosuite.testcase.statements.MethodStatement.execute(MethodStatement.java:220)
[INFO] 	at org.evosuite.testcase.execution.TestRunnable.executeStatements(TestRunnable.java:307)
[INFO] 	at org.evosuite.testcase.execution.TestRunnable.call(TestRunnable.java:213)
[INFO] 	at org.evosuite.testcase.execution.TestRunnable.call(TestRunnable.java:55)
[INFO] 	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
[INFO] 	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
[INFO] 	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
[INFO] 	at java.lang.Thread.run(Thread.java:748)
[INFO] Caused by: java.lang.ClassNotFoundException: Class 'org/springframework/beans/factory/support/SimpleInstantiationStrategy.class' should be in target project, but could not be found!
[INFO] 	at org.evosuite.instrumentation.InstrumentingClassLoader.instrumentClass(InstrumentingClassLoader.java:190)
[INFO] 	... 15 more
[INFO] 14:32:04.585 [main] INFO  e.s.b.reproduction.CrashReproduction - Starting the dependency analysis. The number of detected jar files is 25.
[INFO] 14:32:09.678 [main] ERROR e.s.b.reproduction.CrashReproduction - Error in target initialization:
[INFO] java.lang.ClassNotFoundException: Target class not found in inheritance tree
[INFO] 	at org.evosuite.setup.DependencyAnalysis.analyze(DependencyAnalysis.java:87)
[INFO] 	at org.evosuite.setup.DependencyAnalysis.analyzeClass(DependencyAnalysis.java:132)
[INFO] 	at eu.stamp.botsing.reproduction.CrashReproduction.initializeTargetClass(CrashReproduction.java:220)
[INFO] 	at eu.stamp.botsing.reproduction.CrashReproduction.generateCrashReproductionTests(CrashReproduction.java:109)
[INFO] 	at eu.stamp.botsing.reproduction.CrashReproduction.execute(CrashReproduction.java:80)
[INFO] 	at eu.stamp.botsing.Botsing.parseCommandLine(Botsing.java:78)
[INFO] 	at eu.stamp.botsing.Botsing.main(Botsing.java:163)
[INFO] Stopping Botsing
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 10.274 s
[INFO] Finished at: 2019-04-05T14:32:09+02:00
[INFO] Final Memory: 16M/298M
[INFO] ------------------------------------------------------------------------
@xdevroey xdevroey added bug Something isn't working maven-plugin This issue is related to the Maven plugin. labels May 17, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working maven-plugin This issue is related to the Maven plugin.
Projects
None yet
Development

No branches or pull requests

3 participants