Skip to content

Commit 1d906ce

Browse files
authored
Fix warnings in 1.20 and require Elixir 1.15+ (#718)
1 parent d533039 commit 1d906ce

2 files changed

Lines changed: 7 additions & 3 deletions

File tree

lib/ecto/adapters/postgres/connection.ex

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1991,7 +1991,7 @@ if Code.ensure_loaded?(Postgrex) do
19911991

19921992
defp bitstring_literal(value) do
19931993
size = bit_size(value)
1994-
<<val::size(size)>> = value
1994+
<<val::size(^size)>> = value
19951995

19961996
[?b, ?', val |> Integer.to_string(2) |> String.pad_leading(size, ["0"]), ?']
19971997
end

mix.exs

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,10 @@ defmodule EctoSQL.MixProject do
99
[
1010
app: :ecto_sql,
1111
version: @version,
12-
elixir: "~> 1.14",
12+
elixir: "~> 1.15",
1313
deps: deps(),
1414
test_paths: test_paths(System.get_env("ECTO_ADAPTER")),
15+
test_ignore_filters: [&String.starts_with?(&1, "test/support/")],
1516
xref: [
1617
exclude: [
1718
MyXQL,
@@ -30,7 +31,6 @@ defmodule EctoSQL.MixProject do
3031
"test.adapters": &test_adapters/1,
3132
"test.as_a_dep": &test_as_a_dep/1
3233
],
33-
preferred_cli_env: ["test.all": :test, "test.adapters": :test],
3434

3535
# Hex
3636
description: "SQL-based adapters for Ecto and database migrations",
@@ -50,6 +50,10 @@ defmodule EctoSQL.MixProject do
5050
]
5151
end
5252

53+
def cli do
54+
[preferred_envs: ["test.all": :test, "test.adapters": :test]]
55+
end
56+
5357
defp deps do
5458
[
5559
ecto_dep(),

0 commit comments

Comments
 (0)