diff --git a/lib/postgrex/protocol.ex b/lib/postgrex/protocol.ex index 28dd2867..78162427 100644 --- a/lib/postgrex/protocol.ex +++ b/lib/postgrex/protocol.ex @@ -13,7 +13,8 @@ defmodule Postgrex.Protocol do @max_rows 500 @text_type_oid 25 @commit_comment_validation_error Postgrex.Error.exception( - message: "`:commit_comment` option cannot contain sequence \"*/\"" + message: + "`:commit_comment` option cannot contain sequence \"*/\"" ) defstruct sock: nil, diff --git a/test/query_test.exs b/test/query_test.exs index 98ad9dcd..312d2f38 100644 --- a/test/query_test.exs +++ b/test/query_test.exs @@ -17,7 +17,7 @@ defmodule QueryTest do end test "iodata", context do - assert [[123]] = query(["S", ?E, ["LEC" | "T"], " ", '123'], []) + assert [[123]] = query(["S", ?E, ["LEC" | "T"], " ", ~c"123"], []) end test "decode basic types", context do diff --git a/test/transaction_test.exs b/test/transaction_test.exs index 54b0a95f..219825bd 100644 --- a/test/transaction_test.exs +++ b/test/transaction_test.exs @@ -553,7 +553,9 @@ defmodule TransactionTest do assert transaction( fn conn -> assert {:error, %Postgrex.Error{postgres: %{code: :unique_violation}}} = - P.query(conn, "insert into uniques values (1), (1);", [], mode: :savepoint) + P.query(conn, "insert into uniques values (1), (1);", [], + mode: :savepoint + ) assert {:ok, %Postgrex.Result{rows: [[42]]}} = P.query(conn, "SELECT 42", []) :hi @@ -593,7 +595,9 @@ defmodule TransactionTest do assert transaction( fn conn -> assert {:error, %Postgrex.Error{postgres: %{code: :unique_violation}}} = - P.query(conn, "insert into uniques values (1), (1);", [], mode: :savepoint) + P.query(conn, "insert into uniques values (1), (1);", [], + mode: :savepoint + ) assert {:ok, %Postgrex.Result{rows: [[42]]}} = P.query(conn, "SELECT 42", []) :hi