Sha256: d2e4f122fd1662c5bbd2ee6e69bd4d4c395e93fc26a8330478deaa95b442187d

Contents?: true

Size: 713 Bytes

Versions: 45

Compression:

Stored size: 713 Bytes

Contents

describe Rubicure::Concerns::Gengou do
  using Rubicure::Concerns::Gengou

  describe "Date#heisei?" do
    subject { date(str).heisei? }

    using RSpec::Parameterized::TableSyntax

    where(:str, :expected) do
      "1989-01-07" | false
      "1989-01-08" | true
      "2019-04-30" | true
      "2019-05-01" | false
    end

    with_them do
      it { should eq expected }
    end
  end

  describe "Date#reiwa?" do
    subject { date(str).reiwa? }

    using RSpec::Parameterized::TableSyntax

    where(:str, :expected) do
      "1989-01-07" | false
      "1989-01-08" | false
      "2019-04-30" | false
      "2019-05-01" | true
    end

    with_them do
      it { should eq expected }
    end
  end
end

Version data entries

45 entries across 45 versions & 1 rubygems

Version Path
rubicure-4.0.1 spec/rubicure/concerns/gengou_spec.rb
rubicure-4.0.0 spec/rubicure/concerns/gengou_spec.rb
rubicure-3.3.4 spec/rubicure/concerns/gengou_spec.rb
rubicure-3.3.3 spec/rubicure/concerns/gengou_spec.rb
rubicure-3.3.2 spec/rubicure/concerns/gengou_spec.rb
rubicure-3.3.1 spec/rubicure/concerns/gengou_spec.rb
rubicure-3.3.0 spec/rubicure/concerns/gengou_spec.rb
rubicure-3.3.0.rc2 spec/rubicure/concerns/gengou_spec.rb
rubicure-3.3.0.rc1 spec/rubicure/concerns/gengou_spec.rb
rubicure-3.2.6 spec/rubicure/concerns/gengou_spec.rb
rubicure-3.2.5 spec/rubicure/concerns/gengou_spec.rb
rubicure-3.2.4 spec/rubicure/concerns/gengou_spec.rb
rubicure-3.2.3 spec/rubicure/concerns/gengou_spec.rb
rubicure-3.2.2 spec/rubicure/concerns/gengou_spec.rb
rubicure-3.2.1 spec/rubicure/concerns/gengou_spec.rb
rubicure-3.2.0 spec/rubicure/concerns/gengou_spec.rb
rubicure-3.2.0.rc1 spec/rubicure/concerns/gengou_spec.rb
rubicure-3.1.5 spec/rubicure/concerns/gengou_spec.rb
rubicure-3.1.4 spec/rubicure/concerns/gengou_spec.rb
rubicure-3.1.3 spec/rubicure/concerns/gengou_spec.rb