spec/lib/application_spec.rb in picky-2.0.0.pre1 vs spec/lib/application_spec.rb in picky-2.0.0.pre2

- old
+ new

@@ -45,13 +45,14 @@ similarity: Similarity::DoubleLevenshtone.new(3) # Up to three similar title word indexed. books_index.define_category :author books_index.define_category :isbn, partial: Partial::None.new # Partially searching on an ISBN makes not much sense. - geo_index = Index::Memory.new :geo, Sources::CSV.new(:location, :north, :east, file: 'data/ch.csv', col_sep: ',') - geo_index.define_category :location - geo_index.define_ranged_category(:north1, 1, precision: 3, from: :north) - .define_ranged_category(:east1, 1, precision: 3, from: :east) + geo_index = Index::Memory.new :geo, Sources::CSV.new(:location, :north, :east, file: 'data/ch.csv', col_sep: ',') do + category :location + ranged_category :north1, 1, precision: 3, from: :north + ranged_category :east1, 1, precision: 3, from: :east + end rack_adapter.stub! :exclaim # Stopping it from exclaiming. route %r{^/books} => Search.new(books_index) end \ No newline at end of file