test/ofac_test.rb in kevintyll-ofac-1.1.5 vs test/ofac_test.rb in kevintyll-ofac-1.1.6

- old
+ new

@@ -23,9 +23,15 @@ assert_equal 0, Ofac.new({:name => 'Kevin', :address => '123 somewhere ln', :city => 'Clearwater'}).score end should "give a score of 60 if there is a name match and deduct scores for non matches on address and city" do assert_equal 60, Ofac.new({:name => 'Oscar Hernandez'}).score + assert_equal 60, Ofac.new({:name => {:first_name => 'Oscar', :last_name => 'Hernandez'}}).score + end + + should "give a score of 30 if there is only a partial match" do + assert_equal 30, Ofac.new({:name => 'Oscar de la Hernandez'}).score + assert_equal 30, Ofac.new({:name => {:first_name => 'Oscar', :last_name => 'de la Hernandez'}}).score end should "deduct scores for non matches on address and city if data is in the database" do #if there is data for address or city in the database, and that info is passed in, then 10% #of the weight will be deducted if there is not match or sounds like match