Skip to content

Commit

Permalink
Update duration_spec.cr
Browse files Browse the repository at this point in the history
  • Loading branch information
RomainFranceschini committed Apr 25, 2020
1 parent 43403d6 commit f81b41c
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions spec/duration_spec.cr
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ describe "Duration" do

it "can be constructed from a float between 0 and 1" do
Duration.from(0.00000).should eq(Duration.new(0, Scale::BASE))
Duration.from(1.0 / 3.0).should eq(Duration.new(333, Scale::MILLI))
Duration.from(0.001).should eq(Duration.new(1, Scale::MILLI))
Duration.from(0.00001).should eq(Duration.new(10, Scale::MICRO))
Duration.from(0.000000752).should eq(Duration.new(752, Scale::NANO))
Expand Down

0 comments on commit f81b41c

Please sign in to comment.