From 85582ebfbc633df026027cf767a3607f3d685727 Mon Sep 17 00:00:00 2001 From: Magnus Date: Fri, 20 Oct 2023 20:00:53 +0200 Subject: [PATCH] ci: Add Elixir v1.15 to the build matrix (#571) * ci: Add Elixir v1.15 to the build matrix * Bump more versions, fix latest being present twice, remove exception --------- Co-authored-by: Benedikt Reinartz --- .github/workflows/main.yml | 12 ++++-------- rustler_tests/lib/rustler_test.ex | 2 +- rustler_tests/test/codegen_test.exs | 2 +- 3 files changed, 6 insertions(+), 10 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index e219c29b..d08e1698 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -23,8 +23,8 @@ jobs: - name: Install Erlang/Elixir uses: erlef/setup-beam@v1 with: - otp-version: "25" - elixir-version: "1.14" + otp-version: "26" + elixir-version: "1.15" - name: Check cargo fmt run: cargo fmt --all -- --check @@ -85,7 +85,8 @@ jobs: strategy: matrix: pair: - - { erlang: "26", elixir: "1.14", latest: true } + - { erlang: "26", elixir: "1.15", latest: true } + - { erlang: "26", elixir: "1.14" } - { erlang: "25", elixir: "1.14" } - { erlang: "24", elixir: "1.13" } rust: @@ -95,11 +96,6 @@ jobs: - macos - windows - ubuntu - exclude: - # TODO Remove this once setup-beam is fixed to work around OTP26's - # regression - - os: windows - pair: { erlang: "26", elixir: "1.14", latest: true } runs-on: ${{matrix.os}}-latest steps: diff --git a/rustler_tests/lib/rustler_test.ex b/rustler_tests/lib/rustler_test.ex index 52950aa6..e6776d04 100644 --- a/rustler_tests/lib/rustler_test.ex +++ b/rustler_tests/lib/rustler_test.ex @@ -35,7 +35,7 @@ defmodule RustlerTest do def term_debug_and_reparse(term) do with debug_str <- term_debug(term), - debug_str <- :erlang.binary_to_list(debug_str) ++ '.', + debug_str <- :erlang.binary_to_list(debug_str) ++ ~c".", {:ok, tokens, _} <- :erl_scan.string(debug_str), {:ok, ast} <- :erl_parse.parse_exprs(tokens), {:value, res, _} <- :erl_eval.exprs(ast, %{}) do diff --git a/rustler_tests/test/codegen_test.exs b/rustler_tests/test/codegen_test.exs index 722891d8..1ea7fef9 100644 --- a/rustler_tests/test/codegen_test.exs +++ b/rustler_tests/test/codegen_test.exs @@ -96,7 +96,7 @@ defmodule RustlerTest.CodegenTest do end test "with invalid struct" do - value = %AddException{message: 'this is a charlist', loc: {106, 15}} + value = %AddException{message: ~c"this is a charlist", loc: {106, 15}} assert_raise ErlangError, "Erlang error: \"Could not decode field :message on %AddException{}\"",