Sha256: 6890ea27aa2043e27504bab8d5bedafa03459cd8d215a502851f65715b4a27ff

Contents?: true

Size: 511 Bytes

Versions: 6

Compression:

Stored size: 511 Bytes

Contents

require "test_helper"


class LeapYearTest < ActiveSupport::TestCase
  include Hiccup



  test "should correctly determine whether a year is a leap year or not" do
    enum = Enumerable::ScheduleEnumerator.new(Schedule.new, Date.today)

    assert enum.send(:leap_year?, 1988), "1988 is a leap year"
    assert enum.send(:leap_year?, 2000), "2000 is a leap year"
    refute enum.send(:leap_year?, 1998), "1998 is not a leap year"
    refute enum.send(:leap_year?, 1900), "1900 is not a leap year"
  end



end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
hiccup-0.5.20 test/leap_year_test.rb
hiccup-0.5.19 test/leap_year_test.rb
hiccup-0.5.18 test/leap_year_test.rb
hiccup-0.5.17 test/leap_year_test.rb
hiccup-0.5.16 test/leap_year_test.rb
hiccup-0.5.15 test/leap_year_test.rb