access project feeds via private token
This commit is contained in:
parent
003bf61258
commit
7b36b8d130
4 changed files with 23 additions and 2 deletions
|
@ -34,6 +34,16 @@ describe "Commits" do
|
|||
page.body.should have_selector("author email", :text => commit.author_email)
|
||||
page.body.should have_selector("entry summary", :text => commit.message)
|
||||
end
|
||||
|
||||
it "should render atom feed via private token" do
|
||||
logout
|
||||
visit project_commits_path(project, :atom, :private_token => @user.private_token)
|
||||
|
||||
page.response_headers['Content-Type'].should have_content("application/atom+xml")
|
||||
page.body.should have_selector("title", :text => "Recent commits to #{project.name}")
|
||||
page.body.should have_selector("author email", :text => commit.author_email)
|
||||
page.body.should have_selector("entry summary", :text => commit.message)
|
||||
end
|
||||
end
|
||||
|
||||
describe "GET /commits/:id" do
|
||||
|
|
|
@ -36,6 +36,16 @@ describe "Issues" do
|
|||
page.body.should have_selector("entry summary", :text => @issue.title)
|
||||
end
|
||||
|
||||
it "should render atom feed via private token" do
|
||||
logout
|
||||
visit project_issues_path(project, :atom, :private_token => @user.private_token)
|
||||
|
||||
page.response_headers['Content-Type'].should have_content("application/atom+xml")
|
||||
page.body.should have_selector("title", :text => "#{project.name} issues")
|
||||
page.body.should have_selector("author email", :text => @issue.author_email)
|
||||
page.body.should have_selector("entry summary", :text => @issue.title)
|
||||
end
|
||||
|
||||
describe "Destroy" do
|
||||
before do
|
||||
# admin access to remove issue
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue