summaryrefslogtreecommitdiff
path: root/spec/ruby/library/date/wday_spec.rb
diff options
context:
space:
mode:
Diffstat (limited to 'spec/ruby/library/date/wday_spec.rb')
-rw-r--r--spec/ruby/library/date/wday_spec.rb9
1 files changed, 9 insertions, 0 deletions
diff --git a/spec/ruby/library/date/wday_spec.rb b/spec/ruby/library/date/wday_spec.rb
new file mode 100644
index 0000000000..303905ed35
--- /dev/null
+++ b/spec/ruby/library/date/wday_spec.rb
@@ -0,0 +1,9 @@
+require_relative '../../spec_helper'
+require 'date'
+
+describe "Date#wday" do
+ it "returns the week day as a number starting with Sunday as 0" do
+ w = Date.new(2000, 1, 1).wday
+ w.should == 6
+ end
+end