diff options
author | Benoit Daloze <eregontp@gmail.com> | 2022-11-07 20:05:30 +0100 |
---|---|---|
committer | Benoit Daloze <eregontp@gmail.com> | 2022-11-07 20:05:30 +0100 |
commit | 83decbb62b8b3f1638927033f12b55f9b11f78c6 (patch) | |
tree | 8995f5b5cdb615f3d19edded66c6a9a9e82f159c /spec/ruby/core/time/at_spec.rb | |
parent | c99e4c427897e82a3419abed894d28705f70fa13 (diff) |
Update to ruby/spec@740ccc8
Diffstat (limited to 'spec/ruby/core/time/at_spec.rb')
-rw-r--r-- | spec/ruby/core/time/at_spec.rb | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/spec/ruby/core/time/at_spec.rb b/spec/ruby/core/time/at_spec.rb index 2cc46ab8c9..74b1962a95 100644 --- a/spec/ruby/core/time/at_spec.rb +++ b/spec/ruby/core/time/at_spec.rb @@ -266,5 +266,10 @@ describe "Time.at" do time.zone.should == zone time.to_i.should == @epoch_time end + + it "raises ArgumentError if format is invalid" do + -> { Time.at(@epoch_time, in: "+09:99") }.should raise_error(ArgumentError) + -> { Time.at(@epoch_time, in: "ABC") }.should raise_error(ArgumentError) + end end end |