Sha256: fe345b7b977a29974a6e220fa1c1ee50adebdf10c4560d85361707d4edc73fc8
Contents?: true
Size: 727 Bytes
Versions: 1
Compression:
Stored size: 727 Bytes
Contents
require "spec_helper" describe Selector::NGram do it_behaves_like 'a selector' let(:ngram) { Selector::NGram.new(gram_size: 3) } context "#extract_words_from_data" do it "should generate a list of words from the data" do words = ngram.extract_words_from_data(FactoryGirl.build(:data)) words.should have(4).things end it "should remove words with 3 characters or less" do words = ngram.extract_words_from_data(FactoryGirl.build(:data_w_short_words)) words.should have(2).things end it "should process multiple sections in the data" do words = ngram.extract_words_from_data(FactoryGirl.build(:data_w_multiple_sections)) words.should have(2).things end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
svm_helper-0.1.0 | spec/selectors/n_gram_spec.rb |