gitlab-org--gitlab-foss/spec/features/admin/admin_projects_spec.rb
Vinnie Okada 76aad9b76e Upgrade to Rails 4.1.9
Make the following changes to deal with new behavior in Rails 4.1.2:

* Use nested resources to avoid slashes in arguments to path helpers.
2015-02-14 11:09:23 -07:00

34 lines
741 B
Ruby

require 'spec_helper'
describe "Admin::Projects", feature: true do
before do
@project = create(:project)
login_as :admin
end
describe "GET /admin/projects" do
before do
visit admin_namespaces_projects_path
end
it "should be ok" do
expect(current_path).to eq(admin_namespaces_projects_path)
end
it "should have projects list" do
expect(page).to have_content(@project.name)
end
end
describe "GET /admin/projects/:id" do
before do
visit admin_namespaces_projects_path
click_link "#{@project.name}"
end
it "should have project info" do
expect(page).to have_content(@project.path)
expect(page).to have_content(@project.name)
end
end
end