Fix Elixir 1.4 warnings

This commit is contained in:
Martin Frost 2017-01-22 22:20:57 +01:00
parent 9ea1f173f7
commit c750f32c9f
3 changed files with 5 additions and 6 deletions

View File

@ -19,7 +19,7 @@ defmodule Mix.Tasks.Isn.Gen.Migration do
def run(args) do def run(args) do
Mix.Task.run "app.start", args Mix.Task.run "app.start", args
[repo] = parse_repo(args) [repo] = parse_repo(args)
filename = "#{timestamp}_create_isn_extension.exs" filename = "#{timestamp()}_create_isn_extension.exs"
path = Path.relative_to(migrations_path(repo), Mix.Project.app_path) path = Path.relative_to(migrations_path(repo), Mix.Project.app_path)
file = Path.join(path, filename) file = Path.join(path, filename)
create_directory(path) create_directory(path)

View File

@ -7,11 +7,11 @@ defmodule ISN.Mixfile do
[app: :isn, [app: :isn,
version: @version, version: @version,
elixir: "~> 1.0", elixir: "~> 1.0",
deps: deps, deps: deps(),
test_paths: ["test"], test_paths: ["test"],
# Hex # Hex
description: description, description: description(),
package: package, package: package(),
# Docs # Docs
name: "ISN", name: "ISN",
docs: [source_ref: "v#{@version}", docs: [source_ref: "v#{@version}",

View File

@ -4,7 +4,7 @@ defmodule ISNTest do
alias Postgrex, as: P alias Postgrex, as: P
setup do setup do
options = Keyword.merge(conn_options, [extensions: [{ISN, {}}]]) options = Keyword.merge(conn_options(), [extensions: [{ISN, {}}]])
{:ok, pid} = P.start_link(options) {:ok, pid} = P.start_link(options)
{:ok, [pid: pid]} {:ok, [pid: pid]}
end end
@ -49,4 +49,3 @@ defmodule ISNTest do
query(context[:pid], "SELECT $1::upc", ["220356483481"]) query(context[:pid], "SELECT $1::upc", ["220356483481"])
end end
end end