Sha256: fdc3a02cab9601c7d94080c9b9f604cddcba807d7c319fc07287a9c8018f0d50

Contents?: true

Size: 426 Bytes

Versions: 1

Compression:

Stored size: 426 Bytes

Contents

require 'minitest/autorun'
require 'minitest/power_assert'

$LOAD_PATH.unshift File.expand_path('../lib', __FILE__)
require 'hashstruct'

class Test < Minitest::Test

  def setup
    @h = HashStruct.new(
      date1: '2017-11-01',
      'Date-Time' => '2023-12-23T13:20:00-05:00',
    )
  end

  def test_date
    d1 = @h.date1
    assert { d1.kind_of?(Date) }
    d2 = @h.date_time
    assert { d2.kind_of?(Date) }
  end

end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
hashstruct-1.5 test/test.rb