Sha256: f91d900891c663a5b74c24b048b8ed6ca281a0ea8a1397ee1dd60462243b9b5c

Contents?: true

Size: 702 Bytes

Versions: 48

Compression:

Stored size: 702 Bytes

Contents

# -*- coding: utf-8 -*-

$:.unshift(File.dirname(__FILE__))
require 'spec_helper'
require 'time'

describe "jmonth plugin" do
  {
    '2007/01/01' => '睦月',
    '2007/02/01' => '如月',
    '2007/03/01' => '弥生',
    '2007/04/01' => '卯月',
    '2007/05/01' => '皐月',
    '2007/06/01' => '水無月',
    '2007/07/01' => '文月',
    '2007/08/01' => '葉月',
    '2007/09/01' => '長月',
    '2007/10/01' => '神無月',
    '2007/11/01' => '霜月',
    '2007/12/01' => '師走'
  }.each do |k,v|
    it { expect(setup_jmonth_plugin(Time.parse(k)).date.strftime('%i')).to eq(v) }
  end

  def setup_jmonth_plugin(date)
    fake_plugin(:jmonth) { |plugin| plugin.date = date }
  end
end

Version data entries

48 entries across 42 versions & 2 rubygems

Version Path
tdiary-contrib-5.3.0 spec/jmonth_spec.rb
tdiary-contrib-5.2.4 spec/jmonth_spec.rb
tdiary-contrib-5.2.3 spec/jmonth_spec.rb
tdiary-contrib-5.2.2 spec/jmonth_spec.rb
tdiary-contrib-5.2.1 spec/jmonth_spec.rb
tdiary-contrib-5.2.0 spec/jmonth_spec.rb
tdiary-contrib-5.1.7 spec/jmonth_spec.rb
tdiary-contrib-5.1.6 spec/jmonth_spec.rb
tdiary-5.1.6 vendor/bundle/ruby/2.7.0/gems/tdiary-5.1.5/vendor/bundle/ruby/3.0.0/gems/tdiary-contrib-5.1.4/spec/jmonth_spec.rb
tdiary-5.1.6 vendor/bundle/ruby/2.7.0/bundler/gems/tdiary-contrib-d1e41204db13/spec/jmonth_spec.rb
tdiary-contrib-5.1.5 spec/jmonth_spec.rb
tdiary-5.1.5 vendor/bundle/ruby/3.0.0/gems/tdiary-contrib-5.1.4/spec/jmonth_spec.rb
tdiary-contrib-5.1.4 spec/jmonth_spec.rb
tdiary-contrib-5.1.3 spec/jmonth_spec.rb
tdiary-contrib-5.1.2 spec/jmonth_spec.rb
tdiary-contrib-5.1.1 spec/jmonth_spec.rb
tdiary-contrib-5.1.0 spec/jmonth_spec.rb
tdiary-contrib-5.0.13 spec/jmonth_spec.rb
tdiary-contrib-5.0.12 spec/jmonth_spec.rb
tdiary-contrib-5.0.11 spec/jmonth_spec.rb