Class: TestString
- Inherits:
-
Test::Unit::TestCase
- Object
- Test::Unit::TestCase
- TestString
- Defined in:
- lib/test/unit/string_test.rb
Instance Method Summary collapse
Instance Method Details
#test_omnicat_tokenize ⇒ Object
4 5 6 7 8 9 |
# File 'lib/test/unit/string_test.rb', line 4 def test_omnicat_tokenize assert_equal( ["mustafa", "turan", "omni-cat-v0", "1986"], "mustafa turan omni-cat-v0 1986 1 a s d".omnicat_tokenize ) end |
#test_tokenize_with_counts ⇒ Object
11 12 13 14 15 16 |
# File 'lib/test/unit/string_test.rb', line 11 def test_tokenize_with_counts assert_equal( {"omnicat" => 2, "written" => 1, "at" => 1, "2011" => 1}, "omnicat written at 2011, omnicat".tokenize_with_counts ) end |