OpenProject is the leading open source project management software.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
openproject/spec/api/query_resource_spec.rb

31 lines
840 B

require 'spec_helper'
require 'rack/test'
describe 'API v3 Query resource' do
include Rack::Test::Methods
let(:work_package) { FactoryGirl.create(:work_package, :project_id => project.id) }
let(:project) { FactoryGirl.create(:project, :identifier => 'test_project', :is_public => false) }
let(:current_user) { FactoryGirl.create(:user) }
let(:role) { FactoryGirl.create(:role, permissions: [:view_work_packages]) }
let(:unauthorize_user) { FactoryGirl.create(:user) }
let(:query) { FactoryGirl.create(:public_query) }
let(:private_query) { FactoryGirl.create(:private_query, project: project) }
describe '#star' do
context 'anonymous user' do
end
context 'user with permissions for the project' do
end
context 'user without permissions for the project'
end
describe '#unstar' do
end
end