-
Notifications
You must be signed in to change notification settings - Fork 11
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
IT file changes- TestFramework.scala, Runner.scala, RunnerFactory.java #41
base: master
Are you sure you want to change the base?
Conversation
loader.loadClass(methodAnnotationStr).asInstanceOf[Class[_ <: Annotation]] | ||
|
||
try { | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove most empty lines please
val classFilePath = clz.getProtectionDomain.getCodeSource.getLocation.getPath | ||
val isIntegrationTestByDirectory = classFilePath.contains("/target/test-classes/") | ||
|
||
Logger.getGlobal().log(Level.INFO, s"Class $clzName integration test by name: $isIntegrationTestByName") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Instead of adding debug messages to INFO logging, please change the level to DEBUG or something equivalent.
|
||
val isIntegrationTestByName = clzName.endsWith("IT") | ||
val classFilePath = clz.getProtectionDomain.getCodeSource.getLocation.getPath | ||
val isIntegrationTestByDirectory = classFilePath.contains("/target/test-classes/") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are there other places in testrunner that hard codes paths? Looking specifically in /target/test-classes/ may be best to be hard coded with other paths in testrunner
Logger.getGlobal().log(Level.INFO, s"Class $clzName integration test by name: $isIntegrationTestByName") | ||
Logger.getGlobal().log(Level.INFO, s"Class $clzName integration test by directory: $isIntegrationTestByDirectory") | ||
|
||
Try(if (methods.exists(_.getAnnotation(annotation) != null) || |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should Try be try?
|
||
if (clz.getAnnotation(disabledAnnotation) != null) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should this be removed?
.asInstanceOf[Class[_ <: Annotation]] | ||
if (Modifier.isStatic(clz.getModifiers) || | ||
clz.getAnnotation(nestedAnnotation) == null) { | ||
// a nested test class should |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should keep these comments
@@ -16,6 +16,8 @@ import scala.collection.mutable.ListBuffer | |||
import scala.io.Source | |||
import scala.util.{Failure, Try} | |||
|
|||
import java.util.logging.{Level, Logger} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wrong line. put inbetween line 4-5
No description provided.