Sha256: f419b478243a5b12e2b7d33e9e99d0e99e57110583e58566648736e74af7bc67

Contents?: true

Size: 559 Bytes

Versions: 6

Compression:

Stored size: 559 Bytes

Contents

require "test/helper"
require 'osheet/format/datetime'

module Osheet::Format

  class DatetimeTest < Test::Unit::TestCase
    context "Datetime format" do
      should "generate a basic style string and key" do
        f = Datetime.new 'mm/dd/yyyy'
        assert_equal "mm/dd/yyyy", f.style
        assert_equal "datetime_mm/dd/yyyy", f.key
      end

      should "generate a more complex style string and key" do
        f = Datetime.new 'yy-m'
        assert_equal 'yy-m', f.style
        assert_equal "datetime_yy-m", f.key
      end
    end
  end

end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
osheet-0.7.0 test/format/datetime_test.rb
osheet-0.6.0 test/format/datetime_test.rb
osheet-0.5.0 test/format/datetime_test.rb
osheet-0.4.0 test/format/datetime_test.rb
osheet-0.3.0 test/format/datetime_test.rb
osheet-0.2.0 test/format/datetime_test.rb