As part of sbt-assembly I want to include both src and test class files in jar. Sbt-assembly includes only src files with dependencies. Is there any way through which I can include test classes also in same jar?
The following commands will make sbt watch for source changes in the Test and Compile (default) configurations respectively and re-run the compile command. Note that because Test / compile depends on Compile / compile , source changes in the main source directory will trigger recompilation of the test sources.
The sbt-assembly plugin is an SBT plugin for building a single independent fat JAR file with all dependencies included. This is inspired by the popular Maven assembly plugin, which is used to build fat JARs in Maven.
The serum bactericidal test (SBT) has been used for almost 40 years to monitor therapy in patients with bacterial endocarditis, osteomyelitis, and other serious infections.
I wrote sbt-assembly so that the settings can be loaded into other configurations than the default Runtime
. Put the following in assembly.sbt
and it should add test:assembly
task:
import AssemblyKeys._
Project.inConfig(Test)(baseAssemblySettings)
jarName in (Test, assembly) := s"${name.value}-test-${version.value}.jar"
Like the way jarName
setting is scoped, substitute xxx in assembly
in README with xxx in (Test, assembly)
to customize the setting.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With