diff options
author | Zeger-Jan van de Weg <mail@zjvandeweg.nl> | 2016-02-09 12:02:52 +0100 |
---|---|---|
committer | Zeger-Jan van de Weg <zegerjan@gitlab.com> | 2016-02-22 12:10:56 +0100 |
commit | df27b3a1742048358674733d9cb3392348d5e964 (patch) | |
tree | fd16fca8cf559793360141b21549ad3053a11178 /spec/controllers/autocomplete_controller_spec.rb | |
parent | 04d1b412587028260ac219a32bdf3b03ac022308 (diff) | |
download | gitlab-ce-df27b3a1742048358674733d9cb3392348d5e964.tar.gz |
Issuable can be assigned to author
Closes #9014
The only difference with #9014 is that I thoughed the author should also be
able to assign the issue. If this is unwanted behavior Ill revert it.
Diffstat (limited to 'spec/controllers/autocomplete_controller_spec.rb')
-rw-r--r-- | spec/controllers/autocomplete_controller_spec.rb | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/spec/controllers/autocomplete_controller_spec.rb b/spec/controllers/autocomplete_controller_spec.rb index 85379a8e984..0754a2889fc 100644 --- a/spec/controllers/autocomplete_controller_spec.rb +++ b/spec/controllers/autocomplete_controller_spec.rb @@ -143,4 +143,17 @@ describe AutocompleteController do it { expect(body.size).to eq 0 } end end + + context 'author of issuable included' do + before do + sign_in(user) + get(:users, author_id: non_member.id) + end + + let(:body) { JSON.parse(response.body) } + + it 'should also return the author' do + expect(body.first["username"]).to eq non_member.username + end + end end |