2018-03-04 10:09:32 -05:00
|
|
|
require_relative '../../spec_helper'
|
|
|
|
require_relative 'shared/gm'
|
|
|
|
require_relative 'shared/gmtime'
|
|
|
|
require_relative 'shared/time_params'
|
2017-05-07 08:04:49 -04:00
|
|
|
|
|
|
|
describe "Time#utc?" do
|
|
|
|
it "returns true if time represents a time in UTC (GMT)" do
|
2020-05-03 06:28:29 -04:00
|
|
|
Time.now.should_not.utc?
|
2017-05-07 08:04:49 -04:00
|
|
|
end
|
|
|
|
end
|
|
|
|
|
|
|
|
describe "Time.utc" do
|
2018-01-29 11:08:16 -05:00
|
|
|
it_behaves_like :time_gm, :utc
|
|
|
|
it_behaves_like :time_params, :utc
|
|
|
|
it_behaves_like :time_params_10_arg, :utc
|
|
|
|
it_behaves_like :time_params_microseconds, :utc
|
2017-05-07 08:04:49 -04:00
|
|
|
end
|
|
|
|
|
|
|
|
describe "Time#utc" do
|
2018-01-29 11:08:16 -05:00
|
|
|
it_behaves_like :time_gmtime, :utc
|
2017-05-07 08:04:49 -04:00
|
|
|
end
|