Skip to content

Commit 29adc48

Browse files
Copilotgaeljw
andcommitted
Add cucumber-scalatest module and integration tests structure
Co-authored-by: gaeljw <[email protected]>
1 parent a98b740 commit 29adc48

37 files changed

+2273
-0
lines changed

build.sbt

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@ val jacksonVersion = "2.20.0"
4545
val jackson3Version = "3.0.0"
4646
val mockitoScalaVersion = "2.0.0"
4747
val junit4Version = "4.13.2"
48+
val scalatestVersion = "3.2.19"
4849

4950
// BOMs
5051

@@ -75,6 +76,9 @@ lazy val junit4SbtSupport = Seq(
7576
lazy val junit5SbtSupport = Seq(
7677
libraryDependencies += "com.github.sbt.junit" % "jupiter-interface" % JupiterKeys.jupiterVersion.value % Test
7778
)
79+
lazy val scalatestSbtSupport = Seq(
80+
libraryDependencies += "org.scalatest" %% "scalatest" % scalatestVersion % Test
81+
)
7882

7983
lazy val root = (project in file("."))
8084
.settings(commonSettings)
@@ -83,10 +87,12 @@ lazy val root = (project in file("."))
8387
)
8488
.aggregate(
8589
cucumberScala.projectRefs ++
90+
cucumberScalatest.projectRefs ++
8691
integrationTestsCommon.projectRefs ++
8792
integrationTestsJackson2.projectRefs ++
8893
integrationTestsJackson3.projectRefs ++
8994
integrationTestsPicoContainer.projectRefs ++
95+
integrationTestsScalatest.projectRefs ++
9096
examplesJunit4.projectRefs ++
9197
examplesJunit5.projectRefs: _*
9298
)
@@ -145,6 +151,21 @@ lazy val cucumberScala = (projectMatrix in file("cucumber-scala"))
145151
)
146152
.jvmPlatform(scalaVersions = Seq(scala3, scala213, scala212))
147153

154+
// Scalatest integration
155+
lazy val cucumberScalatest = (projectMatrix in file("cucumber-scalatest"))
156+
.settings(commonSettings)
157+
.settings(scalatestSbtSupport)
158+
.settings(
159+
name := "cucumber-scalatest",
160+
libraryDependencies ++= Seq(
161+
"io.cucumber" % "cucumber-core" % cucumberVersion,
162+
"org.scalatest" %% "scalatest-core" % scalatestVersion
163+
),
164+
publishArtifact := true
165+
)
166+
.dependsOn(cucumberScala)
167+
.jvmPlatform(scalaVersions = Seq(scala3, scala213, scala212))
168+
148169
// Integration tests
149170
lazy val integrationTestsCommon =
150171
(projectMatrix in file("integration-tests/common"))
@@ -209,6 +230,21 @@ lazy val integrationTestsPicoContainer =
209230
.dependsOn(cucumberScala % Test)
210231
.jvmPlatform(scalaVersions = Seq(scala3, scala213, scala212))
211232

233+
lazy val integrationTestsScalatest =
234+
(projectMatrix in file("integration-tests/scalatest"))
235+
.settings(commonSettings)
236+
.settings(scalatestSbtSupport)
237+
.settings(
238+
name := "integration-tests-scalatest",
239+
libraryDependencies ++= Seq(
240+
"org.scalatest" %% "scalatest" % scalatestVersion % Test
241+
),
242+
publishArtifact := false
243+
)
244+
.dependsOn(cucumberScala % Test)
245+
.dependsOn(cucumberScalatest % Test)
246+
.jvmPlatform(scalaVersions = Seq(scala3, scala213, scala212))
247+
212248
// Examples project
213249
lazy val examplesJunit4 = (projectMatrix in file("examples/examples-junit4"))
214250
.settings(commonSettings)

0 commit comments

Comments
 (0)