require 'spec_helper'

describe "Isp Scores", :type => :api do

  it "valid score" do
    post "/api/users/isp_scoring", { :some_data => 100} .to_json
    last_response.status.should == 200
    last_response.body.should == "scoring recorded"
  end

  it "invalid score - not json" do
    post "/api/users/isp_scoring", "some data = 100"
    last_response.status.should == 422
    last_response.body.include?("score invalid").should be true
  end
end
