aboutsummaryrefslogtreecommitdiffstats
path: root/test/date/test_date_base.rb
diff options
context:
space:
mode:
Diffstat (limited to 'test/date/test_date_base.rb')
-rw-r--r--test/date/test_date_base.rb10
1 files changed, 1 insertions, 9 deletions
diff --git a/test/date/test_date_base.rb b/test/date/test_date_base.rb
index 8d53adf..c097eb0 100644
--- a/test/date/test_date_base.rb
+++ b/test/date/test_date_base.rb
@@ -54,7 +54,6 @@ class TestDateBase < Test::Unit::TestCase
end
def test_ordinal__julian
- skip unless defined?(Calendar)
for j in @from..@to
m, d, y = julian_from_absolute(absolute_from_julian_day_number(j))
j0 = julian_day_number_from_absolute(absolute_from_julian(12, 31, y - 1))
@@ -69,7 +68,6 @@ class TestDateBase < Test::Unit::TestCase
end
def test_ordinal__gregorian
- skip unless defined?(Calendar)
for j in @from..@to
m, d, y = gregorian_from_absolute(absolute_from_julian_day_number(j))
j0 =
@@ -85,7 +83,6 @@ class TestDateBase < Test::Unit::TestCase
end
def test_civil__julian
- skip unless defined?(Calendar)
for j in @from..@to
m, d, y = julian_from_absolute(absolute_from_julian_day_number(j))
j2 = julian_day_number_from_absolute(absolute_from_julian(m, d, y))
@@ -100,7 +97,6 @@ class TestDateBase < Test::Unit::TestCase
end
def test_civil__gregorian
- skip unless defined?(Calendar)
for j in @from..@to
m, d, y = gregorian_from_absolute(absolute_from_julian_day_number(j))
j2 = julian_day_number_from_absolute(absolute_from_gregorian(m, d, y))
@@ -115,7 +111,6 @@ class TestDateBase < Test::Unit::TestCase
end
def test_commercial__gregorian
- skip unless defined?(Calendar)
for j in @from..@to
w, d, y = iso_from_absolute(absolute_from_julian_day_number(j))
j2 = julian_day_number_from_absolute(absolute_from_iso(w, d, y))
@@ -130,7 +125,6 @@ class TestDateBase < Test::Unit::TestCase
end
def test_weeknum
- skip unless defined?(Calendar)
for j in @from..@to
for k in 0..1
wy, ww, wd = Date.__send__(:jd_to_weeknum, j, k, Date::GREGORIAN)
@@ -141,7 +135,6 @@ class TestDateBase < Test::Unit::TestCase
end
def test_weeknum__2
- skip unless defined?(Calendar)
for j in @from4t..@to4t
d = Date.jd(j)
t = Time.mktime(d.year, d.mon, d.mday)
@@ -159,7 +152,6 @@ class TestDateBase < Test::Unit::TestCase
end
def test_nth_kday
- skip unless defined?(Calendar)
skip unless (Date.respond_to?(:nth_kday_to_jd, true) &&
Date.respond_to?(:jd_to_nth_kday, true))
for y in 1601..2401
@@ -440,4 +432,4 @@ class TestDateBase < Test::Unit::TestCase
assert_nil(DateTime.__send__(valid_time_p, 24,1,1))
end
-end
+end if defined?(Calendar)