How do you share classes between test configurations using SBT

后端 未结 4 1858
野的像风
野的像风 2021-01-01 18:05

I have followed the instructions on SBT\'s documentation for setting up test configurations. I have three test configurations Test, IntegrationTest, and AcceptanceTest. So m

4条回答
  •  耶瑟儿~
    2021-01-01 18:20

    A configuration can extend another configuration to use that configuration's dependencies and classes. For example, the custom test configuration section shows this definition for the custom configuration:

    lazy val FunTest = config("fun") extend(Test)
    

    The extend part means that the compiled normal test sources will be on the classpath for fun sources. In your case, declare the acceptance configuration to extend the it configuration:

    lazy val AcceptanceTest = config("acceptance") extend(IntegrationTest)
    

提交回复
热议问题