Skip to content

Commit ca406e0

Browse files
authored
Merge pull request #2822 from Gedochao/update/scala-next-3.4.1
Bump Scala Next to 3.4.1
2 parents dd06963 + 8ed39c1 commit ca406e0

File tree

7 files changed

+62
-59
lines changed

7 files changed

+62
-59
lines changed

modules/integration/src/test/scala/scala/cli/integration/RunScalaJsTestDefinitions.scala

Lines changed: 27 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -441,31 +441,32 @@ trait RunScalaJsTestDefinitions { _: RunTestDefinitions =>
441441
}
442442
}
443443

444-
test("js defaults & toolkit default") {
445-
val msg = "Hello"
446-
TestInputs(
447-
os.rel / "toolkit.scala" ->
448-
s"""//> using toolkit default
449-
|//> using toolkit typelevel:default
450-
|
451-
|//> using platform "scala-js"
452-
|
453-
|import cats.effect.*
454-
|import scala.scalajs.js
455-
|
456-
|object Hello extends IOApp.Simple {
457-
|
458-
| def run = IO {
459-
| val console = js.Dynamic.global.console
460-
| val jsonString = "{\\"msg\\": \\"$msg\\"}"
461-
| val json: ujson.Value = ujson.read(jsonString)
462-
| console.log(json("msg").str)
463-
| }
464-
|}
465-
|""".stripMargin
466-
).fromRoot { root =>
467-
val result = os.proc(TestUtil.cli, "run", "toolkit.scala").call(cwd = root)
468-
expect(result.out.trim() == msg)
444+
if (!actualScalaVersion.startsWith("2.12"))
445+
test("js defaults & toolkit default") {
446+
val msg = "Hello"
447+
TestInputs(
448+
os.rel / "toolkit.scala" ->
449+
s"""//> using toolkit default
450+
|//> using toolkit typelevel:default
451+
|
452+
|//> using platform "scala-js"
453+
|
454+
|import cats.effect._
455+
|import scala.scalajs.js
456+
|
457+
|object Hello extends IOApp.Simple {
458+
|
459+
| def run = IO {
460+
| val console = js.Dynamic.global.console
461+
| val jsonString = "{\\"msg\\": \\"$msg\\"}"
462+
| val json: ujson.Value = ujson.read(jsonString)
463+
| console.log(json("msg").str)
464+
| }
465+
|}
466+
|""".stripMargin
467+
).fromRoot { root =>
468+
val result = os.proc(TestUtil.cli, "run", "toolkit.scala", extraOptions).call(cwd = root)
469+
expect(result.out.trim() == msg)
470+
}
469471
}
470-
}
471472
}

modules/integration/src/test/scala/scala/cli/integration/RunScalaNativeTestDefinitions.scala

Lines changed: 21 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -290,34 +290,35 @@ trait RunScalaNativeTestDefinitions { _: RunTestDefinitions =>
290290
val configEnv = Map("SCALA_CLI_CONFIG" -> (configDir / "config.json").toString)
291291
os.proc(TestUtil.cli, "config", "interactive", "true")
292292
.call(cwd = root, env = configEnv)
293-
val output1 = os.proc(TestUtil.cli, "run", "--native", ".")
293+
val output1 = os.proc(TestUtil.cli, "run", "--native", ".", extraOptions)
294294
.call(cwd = root, env = configEnv ++ Seq("SCALA_CLI_INTERACTIVE_INPUTS" -> "foo.Main1"))
295295
.out.lines().last
296296
expect(output1 == "Hello from Main1")
297-
val output2 = os.proc(TestUtil.cli, "run", "--native", ".")
297+
val output2 = os.proc(TestUtil.cli, "run", "--native", ".", extraOptions)
298298
.call(cwd = root, env = configEnv ++ Seq("SCALA_CLI_INTERACTIVE_INPUTS" -> "foo.Main2"))
299299
.out.lines().last
300300
expect(output2 == "Hello from Main2")
301301
}
302302
}
303303

304-
test("native defaults & toolkit default") {
305-
TestInputs(
306-
os.rel / "toolkit.scala" ->
307-
"""//> using toolkit default
308-
|//> using toolkit typelevel:default
309-
|
310-
|//> using platform native
311-
|
312-
|import cats.effect.*
313-
|
314-
|object Hello extends IOApp.Simple {
315-
| def run = IO.println(os.pwd)
316-
|}
317-
|""".stripMargin
318-
).fromRoot { root =>
319-
val result = os.proc(TestUtil.cli, "run", "toolkit.scala").call(cwd = root)
320-
expect(result.out.trim() == root.toString)
304+
if (!actualScalaVersion.startsWith("2.12"))
305+
test("native defaults & toolkit default") {
306+
TestInputs(
307+
os.rel / "toolkit.scala" ->
308+
"""//> using toolkit default
309+
|//> using toolkit typelevel:default
310+
|
311+
|//> using platform native
312+
|
313+
|import cats.effect._
314+
|
315+
|object Hello extends IOApp.Simple {
316+
| def run = IO.println(os.pwd)
317+
|}
318+
|""".stripMargin
319+
).fromRoot { root =>
320+
val result = os.proc(TestUtil.cli, "run", "toolkit.scala", extraOptions).call(cwd = root)
321+
expect(result.out.trim() == root.toString)
322+
}
321323
}
322-
}
323324
}

project/deps.sc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ object Scala {
66
def runnerScala3 = "3.0.2" // the newest version that is compatible with all Scala 3.x versions
77
def scala3LtsPrefix = "3.3" // used for the LTS version tags
88
def scala3Lts = s"$scala3LtsPrefix.3" // the LTS version currently used in the build
9-
def scala3Next = "3.4.0" // the newest/next version of Scala
9+
def scala3Next = "3.4.1" // the newest/next version of Scala
1010

1111
// The Scala version used to build the CLI itself.
1212
def defaultInternal = sys.props.get("scala.version.internal").getOrElse(scala3Lts)

website/docs/reference/cli-options.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1479,7 +1479,7 @@ Available in commands:
14791479

14801480
Aliases: `-S`, `--scala`
14811481

1482-
Set the Scala version (3.4.0 by default)
1482+
Set the Scala version (3.4.1 by default)
14831483

14841484
### `--scala-binary-version`
14851485

website/docs/reference/scala-command/cli-options.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -960,7 +960,7 @@ Aliases: `-S`, `--scala`
960960

961961
`MUST have` per Scala Runner specification
962962

963-
Set the Scala version (3.4.0 by default)
963+
Set the Scala version (3.4.1 by default)
964964

965965
### `--scala-binary-version`
966966

website/docs/reference/scala-command/runner-specification.md

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ Aliases: `-P` ,`--plugin`
9292

9393
**--scala-version**
9494

95-
Set the Scala version (3.4.0 by default)
95+
Set the Scala version (3.4.1 by default)
9696

9797
Aliases: `-S` ,`--scala`
9898

@@ -841,7 +841,7 @@ Aliases: `-P` ,`--plugin`
841841

842842
**--scala-version**
843843

844-
Set the Scala version (3.4.0 by default)
844+
Set the Scala version (3.4.1 by default)
845845

846846
Aliases: `-S` ,`--scala`
847847

@@ -1412,7 +1412,7 @@ Aliases: `-P` ,`--plugin`
14121412

14131413
**--scala-version**
14141414

1415-
Set the Scala version (3.4.0 by default)
1415+
Set the Scala version (3.4.1 by default)
14161416

14171417
Aliases: `-S` ,`--scala`
14181418

@@ -1997,7 +1997,7 @@ Aliases: `-P` ,`--plugin`
19971997

19981998
**--scala-version**
19991999

2000-
Set the Scala version (3.4.0 by default)
2000+
Set the Scala version (3.4.1 by default)
20012001

20022002
Aliases: `-S` ,`--scala`
20032003

@@ -2607,7 +2607,7 @@ Aliases: `-P` ,`--plugin`
26072607

26082608
**--scala-version**
26092609

2610-
Set the Scala version (3.4.0 by default)
2610+
Set the Scala version (3.4.1 by default)
26112611

26122612
Aliases: `-S` ,`--scala`
26132613

@@ -3205,7 +3205,7 @@ Aliases: `-P` ,`--plugin`
32053205

32063206
**--scala-version**
32073207

3208-
Set the Scala version (3.4.0 by default)
3208+
Set the Scala version (3.4.1 by default)
32093209

32103210
Aliases: `-S` ,`--scala`
32113211

@@ -3822,7 +3822,7 @@ Aliases: `-P` ,`--plugin`
38223822

38233823
**--scala-version**
38243824

3825-
Set the Scala version (3.4.0 by default)
3825+
Set the Scala version (3.4.1 by default)
38263826

38273827
Aliases: `-S` ,`--scala`
38283828

@@ -4502,7 +4502,7 @@ Aliases: `-P` ,`--plugin`
45024502

45034503
**--scala-version**
45044504

4505-
Set the Scala version (3.4.0 by default)
4505+
Set the Scala version (3.4.1 by default)
45064506

45074507
Aliases: `-S` ,`--scala`
45084508

@@ -5407,7 +5407,7 @@ Aliases: `-P` ,`--plugin`
54075407

54085408
**--scala-version**
54095409

5410-
Set the Scala version (3.4.0 by default)
5410+
Set the Scala version (3.4.1 by default)
54115411

54125412
Aliases: `-S` ,`--scala`
54135413

website/docs/reference/scala-versions.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,5 +21,6 @@ it is recommended to update scala-cli.
2121
| 1.0.0 - 1.0.1 | 3.3.0 | 2.13.10 | 2.12.17 |
2222
| 1.0.1 - 1.0.4 | 3.3.0 | 2.13.11 | 2.12.18 |
2323
| 1.0.5 - 1.1.3 | 3.3.1 | 2.13.12 | 2.12.18 |
24-
| 1.2.0 - current | 3.4.0 | 2.13.13 | 2.12.19 |
24+
| 1.2.0 - 1.2.1 | 3.4.0 | 2.13.13 | 2.12.19 |
25+
| 1.2.1 - current | 3.4.1 | 2.13.13 | 2.12.19 |
2526

0 commit comments

Comments
 (0)