Skip to content

Commit

Permalink
Merge pull request #6 from jherdman/support-travis
Browse files Browse the repository at this point in the history
Support Travis
  • Loading branch information
railsmechanic authored Apr 7, 2018
2 parents 8da7b47 + 9ae4d0e commit 8c2b061
Show file tree
Hide file tree
Showing 4 changed files with 23 additions and 9 deletions.
13 changes: 13 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
language: elixir

elixir:
- 1.4.0
- 1.5.0
- 1.6.0

otp_release:
- 18.0

script:
- mix dialyzer --halt-exit-status
- mix test
6 changes: 3 additions & 3 deletions lib/sidewalk/client.ex
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ defmodule Sidewalk.Client do
"""

@type job :: Sidewalk.Job.t
@type enqueue_delay :: Integer.t
@type enqueue_time :: Integer.t
@type enqueue_delay :: integer()
@type enqueue_time :: float()
@type response :: {:ok, String.t} | {:error, String.t}

@doc """
Expand Down Expand Up @@ -140,7 +140,7 @@ defmodule Sidewalk.Client do
end
end

@spec current_unix_timestamp :: Float.t
@spec current_unix_timestamp :: float()
defp current_unix_timestamp do
{mega_seconds, seconds, microseconds} = :os.timestamp
String.to_float("#{mega_seconds}#{seconds}.#{microseconds}")
Expand Down
10 changes: 5 additions & 5 deletions lib/sidewalk/job.ex
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ defmodule Sidewalk.Job do
jid: "",
class: "",
args: [],
created_at: 0,
enqueued_at: 0,
created_at: 0.0,
enqueued_at: 0.0,
queue: "default",
retry: true,
wrapped: ""
Expand All @@ -29,9 +29,9 @@ defmodule Sidewalk.Job do
@type t :: %Sidewalk.Job{
jid: String.t,
class: String.t,
args: List.t,
created_at: Float.t,
enqueued_at: Float.t,
args: list(),
created_at: float(),
enqueued_at: float(),
queue: String.t,
retry: boolean,
wrapped: String.t
Expand Down
3 changes: 2 additions & 1 deletion mix.exs
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,8 @@ defmodule Sidewalk.Mixfile do
{:poolboy, "~> 1.5.1"},
{:poison, "~> 3.1.0"},
{:ex_doc, "~> 0.16.0", only: [:dev]},
{:earmark, "~> 1.2.0", only: [:dev]}
{:earmark, "~> 1.2.0", only: [:dev]},
{:dialyxir, "~> 0.5", only: [:dev], runtime: false}
]
end

Expand Down

0 comments on commit 8c2b061

Please sign in to comment.