Spec Www-Authenticate

This commit is contained in:
Jacob Vosmaer 2016-03-24 17:44:10 +01:00
parent ccf5b21f28
commit 57145483fc
1 changed files with 6 additions and 0 deletions

View File

@ -4,6 +4,12 @@ describe 'Git HTTP requests', lib: true do
let(:user) { create(:user) }
let(:project) { create(:project) }
it "gives WWW-Authenticate hints" do
clone_get('doesnt/exist.git')
expect(response.header['WWW-Authenticate']).to start_with('Basic ')
end
context "when the project doesn't exist" do
context "when no authentication is provided" do
it "responds with status 401" do