summaryrefslogtreecommitdiff
path: root/spec
diff options
context:
space:
mode:
authorAki <please@ignore.pl>2023-08-31 23:16:59 +0200
committerAki <please@ignore.pl>2023-08-31 23:17:49 +0200
commitfb1297a0cd84fde95c565178d0d223258d1c2bee (patch)
tree0cddd8ca5ed6331d71821c805705a58c7c2030a8 /spec
parent2e4dc676034c7753c455e7018145e0a1891fe5c0 (diff)
downloadactivity-fb1297a0cd84fde95c565178d0d223258d1c2bee.zip
activity-fb1297a0cd84fde95c565178d0d223258d1c2bee.tar.gz
activity-fb1297a0cd84fde95c565178d0d223258d1c2bee.tar.bz2
Renamed activity.days_in(year)
Diffstat (limited to 'spec')
-rw-r--r--spec/activity_spec.lua18
1 files changed, 9 insertions, 9 deletions
diff --git a/spec/activity_spec.lua b/spec/activity_spec.lua
index 08160fa..074be22 100644
--- a/spec/activity_spec.lua
+++ b/spec/activity_spec.lua
@@ -2,21 +2,21 @@ local activity = require "activity"
describe("Days in a year", function()
it("should support regular years", function()
- assert.are.equal(365, activity.days(1970))
- assert.are.equal(365, activity.days(2001))
+ assert.are.equal(365, activity.days_in(1970))
+ assert.are.equal(365, activity.days_in(2001))
end)
it("should support lean years", function()
- assert.are.equal(366, activity.days(2004))
- assert.are.equal(366, activity.days(1980))
+ assert.are.equal(366, activity.days_in(2004))
+ assert.are.equal(366, activity.days_in(1980))
end)
it("should support *00 years", function()
- assert.are.equal(366, activity.days(2000))
- assert.are.equal(365, activity.days(2100))
- assert.are.equal(365, activity.days(2200))
- assert.are.equal(365, activity.days(2300))
- assert.are.equal(366, activity.days(2400))
+ assert.are.equal(366, activity.days_in(2000))
+ assert.are.equal(365, activity.days_in(2100))
+ assert.are.equal(365, activity.days_in(2200))
+ assert.are.equal(365, activity.days_in(2300))
+ assert.are.equal(366, activity.days_in(2400))
end)
end)