2011-11-05 13:57:40 +01:00
|
|
|
require 'spec_helper'
|
|
|
|
|
|
|
|
describe "Tags" do
|
|
|
|
before { login_as :user }
|
|
|
|
|
|
|
|
# describe "GET 'tags/index'" do
|
|
|
|
# it "should be successful" do
|
|
|
|
# get 'tags/index'
|
|
|
|
# response.should be_success
|
|
|
|
# end
|
|
|
|
# end
|
|
|
|
|
2011-11-05 20:00:05 +01:00
|
|
|
describe "GET '/tags.json'" do
|
2011-11-05 13:57:40 +01:00
|
|
|
before do
|
|
|
|
@project = Factory :project
|
|
|
|
@project.add_access(@user, :read)
|
|
|
|
@project.tag_list = 'demo1'
|
|
|
|
@project.save
|
2011-11-05 20:00:05 +01:00
|
|
|
visit '/tags.json'
|
2011-11-05 13:57:40 +01:00
|
|
|
end
|
|
|
|
|
|
|
|
it "should contains tags" do
|
|
|
|
page.should have_content('demo1')
|
|
|
|
end
|
|
|
|
end
|
|
|
|
|
|
|
|
end
|