Skip to content

Commit

Permalink
- revert spark as provided dependency
Browse files Browse the repository at this point in the history
- add support spark 3.5
- drop 2.x support
  • Loading branch information
zeotuan committed Aug 7, 2024
1 parent e746652 commit 3a7a26d
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 13 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ jobs:
strategy:
fail-fast: false
matrix:
spark: ["3.1.3","3.2.1", "3.3.2", "3.4.2"]
spark: ["3.1.3","3.2.1", "3.3.2", "3.4.3", "3.5.1"]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
Expand Down
3 changes: 0 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,6 @@ Fetch the JAR file from Maven.
```scala
// for Spark 3
libraryDependencies += "com.github.mrpowers" %% "spark-fast-tests" % "1.1.0" % "test"

// for Spark 2
libraryDependencies += "com.github.mrpowers" %% "spark-fast-tests" % "0.23.0" % "test"
```

Here's a link to the releases for different Scala versions:
Expand Down
15 changes: 8 additions & 7 deletions build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -14,18 +14,19 @@ val scala2_13= "2.13.13"
val scala2_12= "2.12.15"
val scala2_11= "2.11.17"

sparkVersion := System.getProperty("spark.testVersion", "3.4.2")
crossScalaVersions := {sparkVersion.value match {
case versionRegex("3", m, _) if m.toInt >= 2 => Seq(scala2_12, scala2_13)
case versionRegex("3", _ , _) => Seq(scala2_12)
case versionRegex("2", _ , _) => Seq(scala2_11)
}
sparkVersion := System.getProperty("spark.testVersion", "3.5.1")
crossScalaVersions := {
sparkVersion.value match {
case versionRegex("3", m, _) if m.toInt >= 2 => Seq(scala2_12, scala2_13)
case versionRegex("3", _ , _) => Seq(scala2_12)
case versionRegex("2", _ , _) => Seq(scala2_11)
}
}

scalaVersion := crossScalaVersions.value.head
enablePlugins(JmhPlugin)

libraryDependencies += "org.apache.spark" %% "spark-sql" % sparkVersion.value % "compile"
libraryDependencies += "org.apache.spark" %% "spark-sql" % sparkVersion.value % "provided"
libraryDependencies += "org.scalatest" %% "scalatest" % "3.2.18" % "test"

credentials += Credentials(Path.userHome / ".sbt" / "sonatype_credentials")
Expand Down
2 changes: 0 additions & 2 deletions project/plugins.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,6 @@ resolvers += Resolver.typesafeRepo("releases")

addSbtPlugin("org.scalameta" % "sbt-scalafmt" % "2.5.2")

addSbtPlugin("pl.project13.scala" % "sbt-jmh" % "0.4.3")

addSbtPlugin("com.geirsson" % "sbt-ci-release" % "1.5.3")

addSbtPlugin("com.jsuereth" % "sbt-pgp" % "2.0.1")

0 comments on commit 3a7a26d

Please sign in to comment.