Sha256: 6098219c472d04357ca0e1e87fe9f24630f475c11e6964ba8a62a09237fc0fd6

Contents?: true

Size: 569 Bytes

Versions: 3

Compression:

Stored size: 569 Bytes

Contents

# encoding: utf-8
require 'abstract_unit'

class MultibyteUnicodeDatabaseTest < Test::Unit::TestCase
  def setup
    @ucd = ActiveSupport::Multibyte::UnicodeDatabase.new
  end

  ActiveSupport::Multibyte::UnicodeDatabase::ATTRIBUTES.each do |attribute|
    define_method "test_lazy_loading_on_attribute_access_of_#{attribute}" do
      @ucd.expects(:load)
      @ucd.send(attribute)
    end
  end

  def test_load
    @ucd.load
    ActiveSupport::Multibyte::UnicodeDatabase::ATTRIBUTES.each do |attribute|
      assert @ucd.send(attribute).length > 1
    end
  end
end

Version data entries

3 entries across 3 versions & 2 rubygems

Version Path
kajam-1.0.3.rc2 vendor/rails/activesupport/test/multibyte_unicode_database_test.rb
radiant-1.0.0.rc2 vendor/rails/activesupport/test/multibyte_unicode_database_test.rb
radiant-1.0.0.rc1 vendor/rails/activesupport/test/multibyte_unicode_database_test.rb