Skip to content

Commit 6d2f72d

Browse files
authored
Update .mill-version (#627)
1 parent 626e7a4 commit 6d2f72d

File tree

7 files changed

+21
-15
lines changed

7 files changed

+21
-15
lines changed

.github/workflows/actions.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ jobs:
1515
runs-on: ubuntu-latest
1616
strategy:
1717
matrix:
18-
java: ['8', '17']
18+
java: ['11', '17']
1919
env:
2020
JAVA_OPTS: "-Xss10M"
2121
steps:
@@ -34,7 +34,7 @@ jobs:
3434
runs-on: ubuntu-latest
3535
strategy:
3636
matrix:
37-
java: ['8', '17']
37+
java: ['11', '17']
3838
env:
3939
JAVA_OPTS: "-Xss10M"
4040
steps:
@@ -54,7 +54,7 @@ jobs:
5454
runs-on: ubuntu-latest
5555
strategy:
5656
matrix:
57-
java: ['8', '17']
57+
java: ['11', '17']
5858
env:
5959
JAVA_OPTS: "-Xss10M"
6060
steps:
@@ -78,7 +78,7 @@ jobs:
7878
- uses: actions/setup-java@v3
7979
with:
8080
distribution: 'temurin'
81-
java-version: 8
81+
java-version: 11
8282
- name: Check Binary Compatibility
8383
run: ./mill -i -k __.mimaReportBinaryIssues
8484

@@ -102,7 +102,7 @@ jobs:
102102
- uses: actions/setup-java@v3
103103
with:
104104
distribution: 'temurin'
105-
java-version: 8
105+
java-version: 11
106106
- name: Publish to Maven Central
107107
run: |
108108
if [[ $(git tag --points-at HEAD) != '' ]]; then

.mill-version

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
0.11.11
1+
0.12.0

build.sc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -153,6 +153,7 @@ object upack extends Module {
153153
def moduleDeps = Seq(upickle.core.jvm())
154154
object test extends CommonTestModule{
155155
def moduleDeps = super.moduleDeps ++ Seq(ujson.jvm().test, upickle.core.jvm().test)
156+
def forkEnv = super.forkEnv() ++ Map("EXAMPLE_JSON" -> exampleJson().path.toString)
156157
}
157158
}
158159

@@ -182,6 +183,7 @@ object ujson extends Module{
182183

183184
object test extends CommonTestModule{
184185
def moduleDeps = super.moduleDeps ++ Seq(upickle.core.jvm().test)
186+
def forkEnv = super.forkEnv() ++ Map("EXAMPLE_JSON" -> exampleJson().path.toString)
185187
}
186188
}
187189

mill

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
set -e
88

99
if [ -z "${DEFAULT_MILL_VERSION}" ] ; then
10-
DEFAULT_MILL_VERSION=0.11.2
10+
DEFAULT_MILL_VERSION=0.11.12
1111
fi
1212

1313
if [ -z "$MILL_VERSION" ] ; then
@@ -53,7 +53,9 @@ if [ -z "$MILL_MAIN_CLI" ] ; then
5353
fi
5454

5555
MILL_FIRST_ARG=""
56-
if [ "$1" = "--bsp" ] || [ "$1" = "-i" ] || [ "$1" = "--interactive" ] || [ "$1" = "--no-server" ] || [ "$1" = "--repl" ] || [ "$1" = "--help" ] ; then
56+
57+
# first arg is a long flag for "--interactive" or starts with "-i"
58+
if [ "$1" = "--bsp" ] || [ "${1#"-i"}" != "$1" ] || [ "$1" = "--interactive" ] || [ "$1" = "--no-server" ] || [ "$1" = "--repl" ] || [ "$1" = "--help" ] ; then
5759
# Need to preserve the first position of those listed options
5860
MILL_FIRST_ARG=$1
5961
shift

ujson/test/src-jvm/ujson/ExampleJsonTests.scala

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,10 @@ import java.nio.file.{Files, Paths}
55
import utest._
66

77
object ExampleJsonTests extends TestSuite {
8-
def check(name: String) = {
9-
TestUtil.checkParse(new String(Files.readAllBytes(Paths.get("exampleJson", name))), true)
10-
}
8+
def check(name: String) = TestUtil.checkParse(
9+
new String(Files.readAllBytes(Paths.get(sys.env("EXAMPLE_JSON"), name))),
10+
true
11+
)
1112
val tests = Tests {
1213
test - check("australia-abc.json")
1314
test - check("bitcoin.json")

upack/test/src-jvm/upack/ExampleJsonTests.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import utest._
77
object ExampleJsonTests extends TestSuite {
88
def check(name: String) = {
99
val msgPack = ujson
10-
.read(Files.readAllBytes(Paths.get("exampleJson", name)))
10+
.read(Files.readAllBytes(Paths.get(sys.env("EXAMPLE_JSON"), name)))
1111
.transform(new MsgPackWriter(new java.io.ByteArrayOutputStream))
1212
.toByteArray
1313
TestUtil.checkParse(msgPack, true)

upack/test/src-jvm/upack/MsgPackJvmTests.scala

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,10 @@ object MsgPackJvmTests extends TestSuite{
2222

2323
// Taken from:
2424
// https://github.com/msgpack/msgpack-ruby/tree/a22d8268f82e0f2ae95f038285af43ce5971810e/spec
25-
val casesJson = "upack/test/resources/cases.json"
26-
val casesMsg = "upack/test/resources/cases.msg"
27-
val casesCompactMsg = "upack/test/resources/cases_compact.msg"
25+
val resources = sys.env("MILL_TEST_RESOURCE_DIR")
26+
val casesJson = resources + "/cases.json"
27+
val casesMsg = resources + "/cases.msg"
28+
val casesCompactMsg = resources + "/cases_compact.msg"
2829
val expectedJson = ujson.read(readBytes(casesJson))
2930
// println("---msgs---")
3031
val msg = readMsgs(casesMsg)

0 commit comments

Comments
 (0)