diff options
Diffstat (limited to 'spec/frontend/packages/shared/components')
-rw-r--r-- | spec/frontend/packages/shared/components/package_path_spec.js | 8 | ||||
-rw-r--r-- | spec/frontend/packages/shared/components/package_tags_spec.js | 12 |
2 files changed, 6 insertions, 14 deletions
diff --git a/spec/frontend/packages/shared/components/package_path_spec.js b/spec/frontend/packages/shared/components/package_path_spec.js index 40d455ac77c..3c9cd3387ba 100644 --- a/spec/frontend/packages/shared/components/package_path_spec.js +++ b/spec/frontend/packages/shared/components/package_path_spec.js @@ -21,8 +21,8 @@ describe('PackagePath', () => { const ELLIPSIS_CHEVRON = 'ellipsis-chevron'; const LEAF_LINK = 'leaf-link'; - const findItem = name => wrapper.find(`[data-testid="${name}"]`); - const findTooltip = w => getBinding(w.element, 'gl-tooltip'); + const findItem = (name) => wrapper.find(`[data-testid="${name}"]`); + const findTooltip = (w) => getBinding(w.element, 'gl-tooltip'); afterEach(() => { wrapper.destroy(); @@ -64,13 +64,13 @@ describe('PackagePath', () => { } if (shouldExist.length) { - it.each(shouldExist)(`should have %s`, element => { + it.each(shouldExist)(`should have %s`, (element) => { expect(findItem(element).exists()).toBe(true); }); } if (shouldNotExist.length) { - it.each(shouldNotExist)(`should not have %s`, element => { + it.each(shouldNotExist)(`should not have %s`, (element) => { expect(findItem(element).exists()).toBe(false); }); } diff --git a/spec/frontend/packages/shared/components/package_tags_spec.js b/spec/frontend/packages/shared/components/package_tags_spec.js index cc49a9a9244..d26e4e76b87 100644 --- a/spec/frontend/packages/shared/components/package_tags_spec.js +++ b/spec/frontend/packages/shared/components/package_tags_spec.js @@ -75,11 +75,7 @@ describe('PackageTags', () => { const expectedStyle = [...defaultStyle, 'gl-display-flex', 'gl-ml-3']; - expect( - tagBadges() - .at(0) - .classes(), - ).toEqual(expect.arrayContaining(expectedStyle)); + expect(tagBadges().at(0).classes()).toEqual(expect.arrayContaining(expectedStyle)); }); it('shows tag badge for medium or heigher resolutions', () => { @@ -87,11 +83,7 @@ describe('PackageTags', () => { const expectedStyle = [...defaultStyle, 'd-md-flex']; - expect( - tagBadges() - .at(1) - .classes(), - ).toEqual(expect.arrayContaining(expectedStyle)); + expect(tagBadges().at(1).classes()).toEqual(expect.arrayContaining(expectedStyle)); }); it('correctly prepends left and appends right when there is more than one tag', () => { |