diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2021-07-08 18:10:06 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2021-07-08 18:10:06 +0300 |
commit | 66a3180a3b9417cb5259ecca83934f22b136394b (patch) | |
tree | 5adbb98712fc46b082cff357fdcb85736f9e844b /spec/frontend/packages_and_registries | |
parent | dd18ae74af0dd661ca3a5ff5458feea925af5ab8 (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/frontend/packages_and_registries')
4 files changed, 15 insertions, 6 deletions
diff --git a/spec/frontend/packages_and_registries/settings/project/settings/__snapshots__/utils_spec.js.snap b/spec/frontend/packages_and_registries/settings/project/settings/__snapshots__/utils_spec.js.snap index 7062773b46b..cf554717127 100644 --- a/spec/frontend/packages_and_registries/settings/project/settings/__snapshots__/utils_spec.js.snap +++ b/spec/frontend/packages_and_registries/settings/project/settings/__snapshots__/utils_spec.js.snap @@ -33,6 +33,10 @@ Array [ exports[`Utils formOptionsGenerator returns an object containing keepN 1`] = ` Array [ Object { + "key": null, + "label": "", + }, + Object { "default": false, "key": "ONE_TAG", "label": "1 tag per image name", @@ -74,6 +78,10 @@ Array [ exports[`Utils formOptionsGenerator returns an object containing olderThan 1`] = ` Array [ Object { + "key": null, + "label": "", + }, + Object { "default": false, "key": "SEVEN_DAYS", "label": "7 days", diff --git a/spec/frontend/packages_and_registries/settings/project/settings/components/__snapshots__/settings_form_spec.js.snap b/spec/frontend/packages_and_registries/settings/project/settings/components/__snapshots__/settings_form_spec.js.snap index 7a52b4a5d0f..1009db46401 100644 --- a/spec/frontend/packages_and_registries/settings/project/settings/components/__snapshots__/settings_form_spec.js.snap +++ b/spec/frontend/packages_and_registries/settings/project/settings/components/__snapshots__/settings_form_spec.js.snap @@ -22,7 +22,7 @@ exports[`Settings Form Enable matches snapshot 1`] = ` exports[`Settings Form Keep N matches snapshot 1`] = ` <expiration-dropdown-stub data-testid="keep-n-dropdown" - formoptions="[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]" + formoptions="[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]" label="Keep the most recent:" name="keep-n" value="TEN_TAGS" @@ -44,7 +44,7 @@ exports[`Settings Form Keep Regex matches snapshot 1`] = ` exports[`Settings Form OlderThan matches snapshot 1`] = ` <expiration-dropdown-stub data-testid="older-than-dropdown" - formoptions="[object Object],[object Object],[object Object],[object Object]" + formoptions="[object Object],[object Object],[object Object],[object Object],[object Object]" label="Remove tags older than:" name="older-than" value="FOURTEEN_DAYS" diff --git a/spec/frontend/packages_and_registries/settings/project/settings/components/settings_form_spec.js b/spec/frontend/packages_and_registries/settings/project/settings/components/settings_form_spec.js index 9e4f61ff820..3a71af94d5a 100644 --- a/spec/frontend/packages_and_registries/settings/project/settings/components/settings_form_spec.js +++ b/spec/frontend/packages_and_registries/settings/project/settings/components/settings_form_spec.js @@ -132,9 +132,9 @@ describe('Settings Form', () => { model | finder | fieldName | type | defaultValue ${'enabled'} | ${findEnableToggle} | ${'Enable'} | ${'toggle'} | ${false} ${'cadence'} | ${findCadenceDropdown} | ${'Cadence'} | ${'dropdown'} | ${'EVERY_DAY'} - ${'keepN'} | ${findKeepNDropdown} | ${'Keep N'} | ${'dropdown'} | ${'TEN_TAGS'} + ${'keepN'} | ${findKeepNDropdown} | ${'Keep N'} | ${'dropdown'} | ${''} ${'nameRegexKeep'} | ${findKeepRegexInput} | ${'Keep Regex'} | ${'textarea'} | ${''} - ${'olderThan'} | ${findOlderThanDropdown} | ${'OlderThan'} | ${'dropdown'} | ${'NINETY_DAYS'} + ${'olderThan'} | ${findOlderThanDropdown} | ${'OlderThan'} | ${'dropdown'} | ${''} ${'nameRegex'} | ${findRemoveRegexInput} | ${'Remove regex'} | ${'textarea'} | ${''} `('$fieldName', ({ model, finder, type, defaultValue }) => { it('matches snapshot', () => { @@ -293,10 +293,10 @@ describe('Settings Form', () => { input: { cadence: 'EVERY_DAY', enabled: true, - keepN: 'TEN_TAGS', + keepN: null, nameRegex: 'asdasdssssdfdf', nameRegexKeep: 'sss', - olderThan: 'NINETY_DAYS', + olderThan: null, projectPath: 'path', }, }); diff --git a/spec/frontend/packages_and_registries/settings/project/settings/utils_spec.js b/spec/frontend/packages_and_registries/settings/project/settings/utils_spec.js index 4c81671cd46..ed126d87ae3 100644 --- a/spec/frontend/packages_and_registries/settings/project/settings/utils_spec.js +++ b/spec/frontend/packages_and_registries/settings/project/settings/utils_spec.js @@ -12,6 +12,7 @@ describe('Utils', () => { olderThanTranslationGenerator, ); expect(result).toEqual([ + { key: null, label: '' }, { variable: 1, label: '1 day' }, { variable: 2, label: '2 days' }, ]); |