Skip to content

Commit e13ae88

Browse files
authored
Merge pull request #46 from Atry/scalatest-3.1.0
Migrate to ScalaTest 3.1.0
2 parents be47ec3 + b1403eb commit e13ae88

File tree

7 files changed

+19
-12
lines changed

7 files changed

+19
-12
lines changed

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
11
target/
22
local.sbt
33
secret/
4+
.metals/
5+
.bloop/

.gitpod.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
image: igeolise/scalajs-test-runner:latest
2+
vscode:
3+
extensions:
4+
- [email protected]:wQBBM+lKILHBqOqlqW60xA==
5+
- [email protected]:pVVu91DEAijx+sPKu8fgHA==

.scalafmt.conf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
version = "1.5.1"
1+
version = "2.2.2"
22
maxColumn = 120

.travis.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ before_deploy:
2929

3030
deploy:
3131
- provider: script
32-
script: sbt ++$TRAVIS_SCALA_VERSION "sonatypeOpen \"Travis Job $TRAVIS_JOB_NAME $TRAVIS_JOB_NUMBER ($TRAVIS_JOB_WEB_URL)\"" publishSigned sonatypeRelease
32+
script: sbt ++$TRAVIS_SCALA_VERSION "set every Seq(sonatypeSessionName := \"Travis Job $TRAVIS_JOB_NAME $TRAVIS_JOB_NUMBER ($TRAVIS_JOB_WEB_URL)\", publishTo := sonatypePublishToBundle.value)" publishSigned sonatypeBundleRelease
3333
skip_cleanup: true
3434
on:
3535
all_branches: true

project/build.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
sbt.version=1.3.4
1+
sbt.version=1.3.4

project/plugins.sbt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
addSbtPlugin("com.thoughtworks.sbt-best-practice" % "sbt-best-practice" % "7.1.1")
22

3-
addSbtPlugin("org.xerial.sbt" % "sbt-sonatype" % "2.5")
3+
addSbtPlugin("org.xerial.sbt" % "sbt-sonatype" % "3.8")
44

55
addSbtPlugin("com.dwijnand" % "sbt-dynver" % "4.0.0")
66

src/main/scala/com/thoughtworks/Example.scala

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ import scala.reflect.NameTransformer
4646
* Code blocks before any Scaladoc tag are shared by all test cases. For example:
4747
*
4848
* {{{
49-
* import org.scalatest.FreeSpec
49+
* import org.scalatest.freespec.AnyFreeSpec
5050
* }}}
5151
*
5252
* Then the name `FreeSpec` will be available for all test cases.
@@ -74,10 +74,10 @@ import scala.reflect.NameTransformer
7474
* }}}
7575
* @example A code block under a Scaladoc tag is a test case.
7676
*
77-
* The test case is inside an [[org.scalatest.FreeSpec]]
77+
* The test case is inside an [[org.scalatest.freespec.AnyFreeSpec]]
7878
*
7979
* {{{
80-
* this should be(a[FreeSpec])
80+
* this should be(an[AnyFreeSpec])
8181
* }}}
8282
* @author 杨博 (Yang Bo) <[email protected]>
8383
* @see [[https://github.com/ThoughtWorksInc/sbt-example sbt-example on Github]]
@@ -262,16 +262,16 @@ object Example extends AutoPlugin {
262262
/** Super types of the generated unit test suite class for examples in Scaladoc.
263263
*
264264
* @example The default value of this [[exampleSuperTypes]] settings are
265-
* [[org.scalatest.FreeSpec]] and [[org.scalatest.Matchers]].
265+
* [[org.scalatest.freespec.AnyFreeSpec]] and [[org.scalatest.matchers.should.Matchers]].
266266
*
267-
* You may want to replace [[org.scalatest.FreeSpec]] to [[org.scalatest.AsyncFreeSpec]]
267+
* You may want to replace [[org.scalatest.freespec.AnyFreeSpec]] to [[org.scalatest.freespec.AsyncFreeSpec]]
268268
* for asynchronous tests:
269269
*
270270
* {{{
271271
* import scala.meta._
272272
* exampleSuperTypes := exampleSuperTypes.value.map {
273-
* case ctor"_root_.org.scalatest.FreeSpec" =>
274-
* ctor"_root_.org.scalatest.AsyncFreeSpec"
273+
* case ctor"_root_.org.scalatest.freespec.AnyFreeSpec" =>
274+
* ctor"_root_.org.scalatest.freespec.AsyncFreeSpec"
275275
* case otherTrait =>
276276
* otherTrait
277277
* }
@@ -325,7 +325,7 @@ object Example extends AutoPlugin {
325325
import autoImport._
326326

327327
override def globalSettings: Seq[Def.Setting[_]] = Seq(
328-
exampleSuperTypes := List(ctor"_root_.org.scalatest.FreeSpec", ctor"_root_.org.scalatest.Matchers")
328+
exampleSuperTypes := List(ctor"_root_.org.scalatest.freespec.AnyFreeSpec", ctor"_root_.org.scalatest.matchers.should.Matchers")
329329
)
330330

331331
override def projectSettings: Seq[Def.Setting[_]] = Seq(

0 commit comments

Comments
 (0)