2 require File.dirname(__FILE__) + '/../../spec_helper'
4 describe "Date constants" do
6 it "should define ITALY" do
7 Date::ITALY.should == 2299161 # 1582-10-15
10 it "should define ENGLAND" do
11 Date::ENGLAND.should == 2361222 # 1752-09-14
15 ruby_bug "#", "1.8.6" do
16 it "should define JULIAN" do
17 (Date::JULIAN <=> Date::Infinity.new).should == 0
22 ruby_bug "#", "1.8.6" do
23 it "should define GREGORIAN" do
24 (Date::GREGORIAN <=> -Date::Infinity.new).should == 0
28 it "should define MONTHNAMES" do
29 Date::MONTHNAMES.should == [nil] + %w(January February March April May June July
30 August September October November December)
33 it "should define DAYNAMES" do
34 Date::DAYNAMES.should == %w(Sunday Monday Tuesday Wednesday Thursday Friday Saturday)
37 it "should define ABBR_MONTHNAMES" do
38 Date::ABBR_DAYNAMES.should == %w(Sun Mon Tue Wed Thu Fri Sat)