Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,10 @@ jobs:
java: 8
distribution: zulu
jobtype: 1
- os: ubuntu-latest
java: 25
distribution: zulu
jobtype: 1
- os: ubuntu-latest
java: 21
distribution: corretto
Expand Down
5 changes: 3 additions & 2 deletions build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,8 @@ lazy val integration = (project in file("integration"))
scalaVersion := scala212
publishArtifact := false
libraryDependencies ++= integrationDependencies(scalaVersion.value)
// fork in test := true,
Test / fork := true
Test / baseDirectory := (LocalRootProject / baseDirectory).value
// javaOptions in test ++= Seq("-Xmx2G", "-XX:MaxPermSize=512M")
Test / parallelExecution := false
Test / testOptions += Tests.Argument("sequential")
Expand All @@ -101,7 +102,7 @@ lazy val scalaxbPlugin = (project in file("sbt-scalaxb"))
description := """sbt plugin to run scalaxb"""
pluginCrossBuild / sbtVersion := {
scalaBinaryVersion.value match {
case "2.12" => "1.5.8" // set minimum sbt version
case "2.12" => "1.9.9" // set minimum sbt version
case _ => "2.0.1"
}
}
Expand Down
22 changes: 3 additions & 19 deletions integration/src/test/scala/CompilerMatcher.scala
Original file line number Diff line number Diff line change
Expand Up @@ -33,24 +33,8 @@ trait CompilerMatcher extends CompilerMatcherBase {
jarPathOfClass("scala.xml.Elem"),
jarPathOfClass("scala.util.parsing.combinator.Parsers"))

// For some reason, there's a `java.net.URLClassLoader` in the
// classloader hierarchy only for the first specs2 example in the suite.
// This is most probably due to the sequential order of test execution, see
// `testOptions in Test += Tests.Argument("sequential")` in `build.sbt`.
// We assume that the current classpath doesn't change from example to
// example in a single test suite.
private lazy val currentcp = {
val currentLoader = java.lang.Thread.currentThread.getContextClassLoader
currentLoader match {
case cl: java.net.URLClassLoader => cl.getURLs.toList map {_.toString}
case x =>
// sbt 0.13 wraps classloader with ClasspathFilter
x.getParent match {
case cl: java.net.URLClassLoader => cl.getURLs.toList map {_.toString}
case x => sys.error("classloader is not a URLClassLoader: " + x.getClass)
}
}
}
private lazy val currentcp: List[String] =
scala.util.Properties.javaClassPath.split(File.pathSeparator).toList.map("file:" + _)

/** evaluteTo matches a pair of code list and files against the expected value
* after evaluating the files and the given code list.
Expand All @@ -65,7 +49,7 @@ trait CompilerMatcher extends CompilerMatcherBase {
*/
def evaluateTo(expected: Any,
outdir: String = ".",
classpath: List[String] = Nil,
classpath: List[String] = currentcp.filter(_.contains("jaxb-api")),
usecurrentcp: Boolean = false,
unchecked: Boolean = true,
deprecation: Boolean = true,
Expand Down
1 change: 1 addition & 0 deletions project/dependencies.scala
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@ object Dependencies {
case x => Seq(scalaXml2, scalaParserCombinators2)
})
def integrationDependencies(sv: String) = Seq(
jaxb % "test",
dispatch(sv) % "test",
http4s % "test",
http4sEmber % "test",
Expand Down
Loading