From 42c1e36a4d8420ce05133dc8905cd3b178d79b24 Mon Sep 17 00:00:00 2001 From: Igor Kapkov Date: Thu, 7 Sep 2017 16:13:31 +1000 Subject: [PATCH] bump elixir versions (#106) --- .travis.yml | 9 +-------- lib/faker/datetime.ex | 2 ++ 2 files changed, 3 insertions(+), 8 deletions(-) diff --git a/.travis.yml b/.travis.yml index 89a5e6e2c..8258a33a8 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,19 +1,12 @@ language: elixir -sudo: false elixir: - 1.3.4 - 1.4.5 + - 1.5.1 otp_release: - 19.3 - - 20.0 -before_script: - - kerl list installations script: - mix test && mix credo --strict && mix dialyzer --halt-exit-status notifications: recipients: - igasgeek@me.com -matrix: - exclude: - - otp_release: 20.0 - elixir: 1.3.4 diff --git a/lib/faker/datetime.ex b/lib/faker/datetime.ex index 21fb86755..400ace88a 100644 --- a/lib/faker/datetime.ex +++ b/lib/faker/datetime.ex @@ -41,12 +41,14 @@ defmodule Faker.DateTime do # private + @spec date_to_datetime(Date.t) :: DateTime.t defp date_to_datetime(date) do %DateTime{calendar: Calendar.ISO, day: date.day, hour: 0, minute: 0, month: date.month, second: 0, time_zone: "Etc/UTC", utc_offset: 0, std_offset: 0, year: date.year, zone_abbr: "UTC"} end + @spec naivedatetime_to_datetime(NaiveDateTime.t) :: DateTime.t defp naivedatetime_to_datetime(naivedatetime) do %DateTime{calendar: naivedatetime.calendar, day: naivedatetime.day, hour: naivedatetime.hour, minute: naivedatetime.minute,