require_relative '../test_config' require 'auth' describe Auth::App do include Rack::Test::Methods def app HELIX_WEB_SERVICES_APP end context 'POST /auth/v1/login' do it 'should generate and return the p4 ticket' do post '/auth/v1/login', {:user => JDOE_USER, :password => JDOE_PASSWORD} expect(last_response.status).to eq(200) expect(last_response.body).to satisfy { |x| Auth.p4_ticket?(x) } end end end