Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update .mill-version #627

Merged
merged 7 commits into from
Oct 24, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions .github/workflows/actions.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
java: ['8', '17']
java: ['11', '17']
env:
JAVA_OPTS: "-Xss10M"
steps:
Expand All @@ -34,7 +34,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
java: ['8', '17']
java: ['11', '17']
env:
JAVA_OPTS: "-Xss10M"
steps:
Expand All @@ -54,7 +54,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
java: ['8', '17']
java: ['11', '17']
env:
JAVA_OPTS: "-Xss10M"
steps:
Expand All @@ -78,7 +78,7 @@ jobs:
- uses: actions/setup-java@v3
with:
distribution: 'temurin'
java-version: 8
java-version: 11
- name: Check Binary Compatibility
run: ./mill -i -k __.mimaReportBinaryIssues

Expand All @@ -102,7 +102,7 @@ jobs:
- uses: actions/setup-java@v3
with:
distribution: 'temurin'
java-version: 8
java-version: 11
- name: Publish to Maven Central
run: |
if [[ $(git tag --points-at HEAD) != '' ]]; then
Expand Down
2 changes: 1 addition & 1 deletion .mill-version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.11.11
0.12.0
2 changes: 2 additions & 0 deletions build.sc
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,7 @@ object upack extends Module {
def moduleDeps = Seq(upickle.core.jvm())
object test extends CommonTestModule{
def moduleDeps = super.moduleDeps ++ Seq(ujson.jvm().test, upickle.core.jvm().test)
def forkEnv = super.forkEnv() ++ Map("EXAMPLE_JSON" -> exampleJson().path.toString)
}
}

Expand Down Expand Up @@ -182,6 +183,7 @@ object ujson extends Module{

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

Expand Down
6 changes: 4 additions & 2 deletions mill
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
set -e

if [ -z "${DEFAULT_MILL_VERSION}" ] ; then
DEFAULT_MILL_VERSION=0.11.2
DEFAULT_MILL_VERSION=0.11.12
fi

if [ -z "$MILL_VERSION" ] ; then
Expand Down Expand Up @@ -53,7 +53,9 @@ if [ -z "$MILL_MAIN_CLI" ] ; then
fi

MILL_FIRST_ARG=""
if [ "$1" = "--bsp" ] || [ "$1" = "-i" ] || [ "$1" = "--interactive" ] || [ "$1" = "--no-server" ] || [ "$1" = "--repl" ] || [ "$1" = "--help" ] ; then

# first arg is a long flag for "--interactive" or starts with "-i"
if [ "$1" = "--bsp" ] || [ "${1#"-i"}" != "$1" ] || [ "$1" = "--interactive" ] || [ "$1" = "--no-server" ] || [ "$1" = "--repl" ] || [ "$1" = "--help" ] ; then
# Need to preserve the first position of those listed options
MILL_FIRST_ARG=$1
shift
Expand Down
7 changes: 4 additions & 3 deletions ujson/test/src-jvm/ujson/ExampleJsonTests.scala
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,10 @@ import java.nio.file.{Files, Paths}
import utest._

object ExampleJsonTests extends TestSuite {
def check(name: String) = {
TestUtil.checkParse(new String(Files.readAllBytes(Paths.get("exampleJson", name))), true)
}
def check(name: String) = TestUtil.checkParse(
new String(Files.readAllBytes(Paths.get(sys.env("EXAMPLE_JSON"), name))),
true
)
val tests = Tests {
test - check("australia-abc.json")
test - check("bitcoin.json")
Expand Down
2 changes: 1 addition & 1 deletion upack/test/src-jvm/upack/ExampleJsonTests.scala
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import utest._
object ExampleJsonTests extends TestSuite {
def check(name: String) = {
val msgPack = ujson
.read(Files.readAllBytes(Paths.get("exampleJson", name)))
.read(Files.readAllBytes(Paths.get(sys.env("EXAMPLE_JSON"), name)))
.transform(new MsgPackWriter(new java.io.ByteArrayOutputStream))
.toByteArray
TestUtil.checkParse(msgPack, true)
Expand Down
7 changes: 4 additions & 3 deletions upack/test/src-jvm/upack/MsgPackJvmTests.scala
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,10 @@ object MsgPackJvmTests extends TestSuite{

// Taken from:
// https://github.com/msgpack/msgpack-ruby/tree/a22d8268f82e0f2ae95f038285af43ce5971810e/spec
val casesJson = "upack/test/resources/cases.json"
val casesMsg = "upack/test/resources/cases.msg"
val casesCompactMsg = "upack/test/resources/cases_compact.msg"
val resources = sys.env("MILL_TEST_RESOURCE_DIR")
val casesJson = resources + "/cases.json"
val casesMsg = resources + "/cases.msg"
val casesCompactMsg = resources + "/cases_compact.msg"
val expectedJson = ujson.read(readBytes(casesJson))
// println("---msgs---")
val msg = readMsgs(casesMsg)
Expand Down
Loading