Class: TestHash
- Inherits:
-
Test::Unit::TestCase
- Object
- Test::Unit::TestCase
- TestHash
- Defined in:
- lib/test/unit/hash_test.rb
Instance Method Summary collapse
Instance Method Details
#test_to_hash ⇒ Object
4 5 6 7 8 9 10 11 |
# File 'lib/test/unit/hash_test.rb', line 4 def test_to_hash categories_hash = { "pos" => { doc_count: 0, docs: {}, tokens: {}, token_count: 0 } } categories = OmniCat::Hash.new categories["pos"] = OmniCat::Classifiers::StrategyInternals::Category.new(categories_hash["pos"]) assert_equal(categories_hash, categories.to_hash) end |