Permalink
Browse files

Merge pull request #1198 from slick/tmp/osgi-conf

Fix OSGi tests and add a test for resolving GlobalConfig options
  • Loading branch information...
szeiger committed Jul 13, 2015
2 parents 3cd8617 + 4b7262e commit 98de1c903ea6b5a1ab1487b60c9ca2df66b5ba68
Showing with 9 additions and 3 deletions.
  1. +6 −1 osgi-tests/src/test/scala/slick/osgi/test/BasicTest.scala
  2. +3 −2 project/Build.scala
@@ -8,6 +8,7 @@ import org.ops4j.pax.exam.junit.{Configuration, ExamReactorStrategy, JUnit4TestR
import org.ops4j.pax.exam.spi.reactors.AllConfinedStagedReactorFactory
import slick.SlickException
import slick.osgi.testutil._
import slick.util.GlobalConfig
@RunWith(classOf[JUnit4TestRunner])
@ExamReactorStrategy(Array(classOf[AllConfinedStagedReactorFactory]))
@@ -26,4 +27,8 @@ class BasicTest extends SlickOsgiHelper {
assertEquals("TEST-OSGI", sql"select {fn database()}".as[String].first)
}
}
}
@Test
def testConfig: Unit = {
assertFalse(GlobalConfig.driverConfig("MySQL").isEmpty)
}
}
View
@@ -29,7 +29,7 @@ object SlickBuild extends Build {
val slf4j = "org.slf4j" % "slf4j-api" % "1.6.4"
val logback = "ch.qos.logback" % "logback-classic" % "1.1.3"
val typesafeConfig = "com.typesafe" % "config" % "1.2.1"
val reactiveStreamsVersion = "1.0.0.RC4"
val reactiveStreamsVersion = "1.0.0"
val reactiveStreams = "org.reactivestreams" % "reactive-streams" % reactiveStreamsVersion
val reactiveStreamsTCK = "org.reactivestreams" % "reactive-streams-tck" % reactiveStreamsVersion
val pools = Seq(
@@ -209,7 +209,8 @@ object SlickBuild extends Build {
ProblemFilters.exclude[MissingClassProblem]("slick.util.MacroSupportInterpolationImpl")
),
ivyConfigurations += config("macro").hide.extend(Compile),
unmanagedClasspath in Compile <++= fullClasspath in config("macro"),
unmanagedClasspath in Compile <++= products in config("macro"),
libraryDependencies <+= scalaVersion("org.scala-lang" % "scala-compiler" % _ % "provided"),
mappings in (Compile, packageSrc) <++= mappings in (config("macro"), packageSrc),
mappings in (Compile, packageBin) <++= mappings in (config("macro"), packageBin),
OsgiKeys.exportPackage := Seq("slick", "slick.*", "scala.slick", "scala.slick.*"),

0 comments on commit 98de1c9

Please sign in to comment.