Sha256: b6ff5bafb5f8e5a4a6549861bdadddbfb3e2ab59d8593cf6a4bd3348cd7b7d7b

Contents?: true

Size: 470 Bytes

Versions: 15

Compression:

Stored size: 470 Bytes

Contents

# -*- encoding: utf-8 -*-

require 'minitest/autorun'
require 'webgen/core_ext'

class TestCoreExtensions < Minitest::Test

  def test_webgen_require
    assert_raises(Webgen::LoadError) { webgen_require('unknown_library_here') }
    webgen_require('webgen/core_ext') rescue flunk
  end

  def test_hash_symbolize_keys!
    h = {'a' => 'a', :b => 'b', 5 => 5}.symbolize_keys
    assert_equal('a', h[:a])
    assert_equal('b', h[:b])
    assert_equal(5, h[5])
  end

end

Version data entries

15 entries across 15 versions & 1 rubygems

Version Path
webgen-1.7.3 test/webgen/test_core_ext.rb
webgen-1.7.2 test/webgen/test_core_ext.rb
webgen-1.7.1 test/webgen/test_core_ext.rb
webgen-1.7.0 test/webgen/test_core_ext.rb
webgen-1.6.0 test/webgen/test_core_ext.rb
webgen-1.5.2 test/webgen/test_core_ext.rb
webgen-1.5.1 test/webgen/test_core_ext.rb
webgen-1.5.0 test/webgen/test_core_ext.rb
webgen-1.4.1 test/webgen/test_core_ext.rb
webgen-1.4.0 test/webgen/test_core_ext.rb
webgen-1.3.0 test/webgen/test_core_ext.rb
webgen-1.2.1 test/webgen/test_core_ext.rb
webgen-1.2.0 test/webgen/test_core_ext.rb
webgen-1.1.0 test/webgen/test_core_ext.rb
webgen-1.0.0 test/webgen/test_core_ext.rb