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

Build: split integration tests into a separate subproject #588

Merged
merged 2 commits into from
Nov 19, 2023
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
13 changes: 9 additions & 4 deletions Taskfile.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ tasks:
jvmCompile:
desc: Compile Scala and Java code using SBT
cmds:
- sbt -client "compile; Test/compile; IntegrationTest/compile"
- sbt -client "compile; Test/compile"

jvmAssemble:
desc: Build the plugin bundle using SBT
Expand All @@ -169,17 +169,22 @@ tasks:
jvmIntegrationTest:
desc: Run JVM tests using SBT
cmds:
- sbt -client IntegrationTest/test
- sbt -client elastiknn-plugin-integration-tests/test

jvmIntegrationTestQuick:
desc: Run JVM tests using SBT, but only the ones that were recompiled
cmds:
- sbt -client IntegrationTest/testQuick
- sbt -client elastiknn-plugin-integration-tests/testQuick

jvmUnitTest:
desc: Run JVM tests using SBT
cmds:
- sbt -client test
- sbt -client elastiknn-api4s/test
- sbt -client elastiknn-client-elastic4s/test
- sbt -client elastiknn-lucene/test
- sbt -client elastiknn-models/test
- sbt -client elastiknn-models-benchmarks/test
- sbt -client elastiknn-plugin/test

jvmUnitTestQuick:
desc: Run JVM tests using SBT, but only the ones that were recompiled
Expand Down
13 changes: 10 additions & 3 deletions build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,8 @@ lazy val `elastiknn-root` = project
`elastiknn-lucene`,
`elastiknn-models`,
`elastiknn-models-benchmarks`,
`elastiknn-plugin`
`elastiknn-plugin`,
`elastiknn-plugin-integration-tests`
)

lazy val `elastiknn-api4s` = project
Expand Down Expand Up @@ -104,7 +105,6 @@ lazy val `elastiknn-plugin` = project
`elastiknn-lucene` % "compile->compile;test->test",
`elastiknn-client-elastic4s` % "test->compile"
)
.configs(IntegrationTest.extend(Test))
.settings(
name := "elastiknn",
version := ElastiknnVersion,
Expand All @@ -125,6 +125,13 @@ lazy val `elastiknn-plugin` = project
"com.klibisz.futil" %% "futil" % "0.1.2" % Test
),
scalacOptions ++= ScalacOptions,
Defaults.itSettings,
TestSettings
)

lazy val `elastiknn-plugin-integration-tests` = project
.in(file("elastiknn-plugin-integration-tests"))
.dependsOn(`elastiknn-plugin` % "test->test")
.settings(
scalacOptions ++= ScalacOptions,
TestSettings
)