Skip to content

Commit

Permalink
Merge pull request #37 from xuwei-k/scala-3
Browse files Browse the repository at this point in the history
fix crossScalaVersions. enable Scala 3 build
  • Loading branch information
tsuyoshizawa authored Oct 7, 2023
2 parents 5371824 + d649bdf commit 3a3afdb
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 6 deletions.
8 changes: 4 additions & 4 deletions build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,14 @@ val commonDependenciesInTestScope = Seq(
)

def unusedWarnings(scalaVersion: String) =
Seq("-Ywarn-unused:-imports,_")
Seq("-Wunused:imports")

lazy val scalaOAuth2ProviderSettings =
Defaults.coreDefaultSettings ++
Seq(
organization := "com.nulab-inc",
scalaVersion := "3.3.0",
crossScalaVersions := Seq("2.13.12"),
scalaVersion := "3.3.1",
crossScalaVersions ++= Seq("2.13.12"),
scalacOptions ++= Seq("-deprecation", "-unchecked", "-feature"),
scalacOptions ++= unusedWarnings(scalaVersion.value),
publishTo := {
Expand Down Expand Up @@ -57,7 +57,7 @@ lazy val root = (project in file("."))
description := "Support scala-oauth2-core library on Play Framework Scala",
version := "1.5.1-SNAPSHOT",
libraryDependencies ++= Seq(
"com.nulab-inc" %% "scala-oauth2-core" % "1.5.0" % "provided",
"com.nulab-inc" %% "scala-oauth2-core" % "1.6.0" % "provided",
"com.typesafe.play" %% "play" % playVersion % "provided",
"com.typesafe.play" %% "play-test" % playVersion % "test"
) ++ commonDependenciesInTestScope
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import org.scalatest.matchers.should.Matchers._
import play.api.mvc.{AbstractController, ControllerComponents}
import play.api.test.Helpers._
import play.api.test.{FakeRequest, _}
import scala.concurrent.Future

import javax.inject.Inject

Expand All @@ -14,8 +15,8 @@ class OAuth2ProviderActionBuildersSpec extends AnyFlatSpec {
extends AbstractController(components)
with OAuth2ProviderActionBuilders {

val action = AuthorizedAction(new MockDataHandler) { request =>
Ok(request.authInfo.user.name)
val action = AuthorizedAction(new MockDataHandler).async { request =>
Future.successful(Ok(request.authInfo.user.name))
}

}
Expand Down

0 comments on commit 3a3afdb

Please sign in to comment.