diff options
author | Robert Speicher <rspeicher@gmail.com> | 2019-07-25 11:10:31 -0500 |
---|---|---|
committer | Robert Speicher <rspeicher@gmail.com> | 2019-07-25 11:10:31 -0500 |
commit | 148df25638aa77d3b066788ada47d74005100c51 (patch) | |
tree | d4fad49eabdc50ef58b996e08ca4264a8a66953d /spec/support | |
parent | d5c10813955651d9129b30446a1419ab124dcc61 (diff) | |
download | gitlab-ce-rs-resource-label-events-api.tar.gz |
Simplify resource_label_events API shared examplers-resource-label-events-api
We don't need a repository, and we only need a private user in one
example, so we can scope it locally there.
Diffstat (limited to 'spec/support')
-rw-r--r-- | spec/support/shared_examples/resource_label_events_api.rb | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/spec/support/shared_examples/resource_label_events_api.rb b/spec/support/shared_examples/resource_label_events_api.rb index 6e317172823..945cb8d9f2c 100644 --- a/spec/support/shared_examples/resource_label_events_api.rb +++ b/spec/support/shared_examples/resource_label_events_api.rb @@ -19,6 +19,7 @@ shared_examples 'resource_label_events API' do |parent_type, eventable_type, id_ it "returns 404 when not authorized" do parent.update!(visibility_level: Gitlab::VisibilityLevel::PRIVATE) + private_user = create(:user) get api("/#{parent_type}/#{parent.id}/#{eventable_type}/#{eventable[id_name]}/resource_label_events", private_user) |