diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2022-02-24 09:14:06 +0000 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2022-02-24 09:14:06 +0000 |
commit | 563c8efdee39233f80f4dc7b20b38d417b26f055 (patch) | |
tree | 7b86eec1a8205b63c358f1004f20e5fbb52f1b4a /spec/frontend/protected_branches | |
parent | 89bfc148f90c410512f9c470ca1e50485b7000b2 (diff) | |
download | gitlab-ce-563c8efdee39233f80f4dc7b20b38d417b26f055.tar.gz |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/frontend/protected_branches')
-rw-r--r-- | spec/frontend/protected_branches/protected_branch_edit_spec.js | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/spec/frontend/protected_branches/protected_branch_edit_spec.js b/spec/frontend/protected_branches/protected_branch_edit_spec.js index 13e0388979d..959ca6ecde2 100644 --- a/spec/frontend/protected_branches/protected_branch_edit_spec.js +++ b/spec/frontend/protected_branches/protected_branch_edit_spec.js @@ -73,6 +73,21 @@ describe('ProtectedBranchEdit', () => { }); }); + describe('when toggles are not available in the DOM on page load', () => { + beforeEach(() => { + create({ hasLicense: true }); + setFixtures(''); + }); + + it('does not instantiate the force push toggle', () => { + expect(findForcePushToggle()).toBe(null); + }); + + it('does not instantiate the code owner toggle', () => { + expect(findCodeOwnerToggle()).toBe(null); + }); + }); + describe.each` description | checkedOption | patchParam | finder ${'force push'} | ${'forcePushToggleChecked'} | ${'allow_force_push'} | ${findForcePushToggle} |