Sha256: f9c1d8a01af6253f7dad13fe360563a44de54c895391fec5f872e6959fc07212
Contents?: true
Size: 647 Bytes
Versions: 1
Compression:
Stored size: 647 Bytes
Contents
require 'java' require 'models/data_types' require 'arjdbc' require 'test/unit' class TypeConversionTest < Test::Unit::TestCase TEST_INT = 987654321 TEST_TIME = Time.at(1169964202).gmtime def self.startup DbTypeMigration.up end def self.shutdown DbTypeMigration.down end def setup DbType.create( :sample_timestamp => TEST_TIME, :sample_decimal => TEST_INT) # DECIMAL(9,0) end def test_timestamp type = DbType.first assert_equal TEST_TIME, type.sample_timestamp.getutc end def test_decimal type = DbType.first assert_equal TEST_INT, type.sample_decimal end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
activerecord-jdbc-adapter-1.3.0.beta1 | test/activerecord/connection_adapters/type_conversion_test.rb |