-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Generate example test in test dialect (#185)
- Loading branch information
Showing
6 changed files
with
37 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
enablePlugins(Example) | ||
|
||
enablePlugins(ScalaJSPlugin) | ||
|
||
libraryDependencies += "org.scalatest" %% "scalatest" % "3.2.14" % Provided | ||
|
||
import scala.meta._ | ||
exampleSuperTypes += init"_root_.org.scalatest.Inside" | ||
|
||
scalaVersion := "3.2.1" |
1 change: 1 addition & 0 deletions
1
src/sbt-test/sbt-example/scala3-keyword-then/project/build.properties
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
sbt.version=1.7.3 |
10 changes: 10 additions & 0 deletions
10
src/sbt-test/sbt-example/scala3-keyword-then/project/plugins.sbt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
sys.props.get("plugin.version") match { | ||
case Some(x) => addSbtPlugin("com.thoughtworks.example" % "sbt-example" % x) | ||
case _ => | ||
sys.error( | ||
"""|The system property 'plugin.version' is not defined. | ||
|Specify this property using the scriptedLaunchOpts -D.""".stripMargin | ||
) | ||
} | ||
|
||
addSbtPlugin("org.scala-js" % "sbt-scalajs" % "1.12.0") |
11 changes: 11 additions & 0 deletions
11
...sbt-test/sbt-example/scala3-keyword-then/src/main/scala/mypackage/Scala3KeywordThen.scala
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
|
||
|
||
/** Testing Scala 3 keyword | ||
* @example | ||
* Call to `then` should compile | ||
* {{{ | ||
* import scala.scalajs.js | ||
* js.Promise.resolve(40).`then`(_ + 2) | ||
* }}} | ||
*/ | ||
object Scala3KeywordThen |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
> test | ||
$ exists target/scala-3.2.1/src_managed/test/sbt-example-generated.scala |