Commit fc75b95b authored by Martin Wortschack's avatar Martin Wortschack

Merge branch 'ph/fixReviewersOnIssuesFilter' into 'master'

Fixes reviewers filter being visible on issues page

See merge request gitlab-org/gitlab!49826
parents 85703cee 40134d09
import { __ } from '~/locale';
export default (IssuableTokenKeys, disableTargetBranchFilter = false) => {
const reviewerToken = {
formattedKey: __('Reviewer'),
key: 'reviewer',
type: 'string',
param: 'username',
symbol: '@',
icon: 'user',
tag: '@reviewer',
};
IssuableTokenKeys.tokenKeys.splice(2, 0, reviewerToken);
IssuableTokenKeys.tokenKeysWithAlternative.splice(2, 0, reviewerToken);
const draftToken = {
token: {
formattedKey: __('Draft'),
......
......@@ -21,15 +21,6 @@ export const tokenKeys = [
icon: 'user',
tag: '@assignee',
},
{
formattedKey: __('Reviewer'),
key: 'reviewer',
type: 'string',
param: 'username',
symbol: '@',
icon: 'user',
tag: '@reviewer',
},
{
formattedKey: __('Milestone'),
key: 'milestone',
......
......@@ -153,6 +153,14 @@ RSpec.describe 'Filter issues', :js do
end
end
describe 'filter by reviewer' do
it 'does not allow filtering by reviewer' do
find('.filtered-search').click
expect(page).not_to have_button('Reviewer')
end
end
describe 'filter issues by label' do
context 'only label' do
it 'filters issues by searched label' do
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment