Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'spec/frontend/access_tokens/components/access_token_table_app_spec.js')
-rw-r--r--spec/frontend/access_tokens/components/access_token_table_app_spec.js15
1 files changed, 15 insertions, 0 deletions
diff --git a/spec/frontend/access_tokens/components/access_token_table_app_spec.js b/spec/frontend/access_tokens/components/access_token_table_app_spec.js
index 6013fa3ec39..aed3db4aa4c 100644
--- a/spec/frontend/access_tokens/components/access_token_table_app_spec.js
+++ b/spec/frontend/access_tokens/components/access_token_table_app_spec.js
@@ -190,6 +190,21 @@ describe('~/access_tokens/components/access_token_table_app', () => {
expect(button.props('category')).toBe('tertiary');
});
+ describe('revoke path', () => {
+ beforeEach(() => {
+ createComponent({ showRole: true });
+ });
+
+ it.each([{ revoke_path: null }, { revoke_path: undefined }])(
+ 'with %p, does not show revoke button',
+ async (input) => {
+ await triggerSuccess(defaultActiveAccessTokens.map((data) => ({ ...data, ...input })));
+
+ expect(findCells().at(6).findComponent(GlButton).exists()).toBe(false);
+ },
+ );
+ });
+
it('sorts rows alphabetically', async () => {
createComponent({ showRole: true });
await triggerSuccess();