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:
authorGitLab Bot <gitlab-bot@gitlab.com>2020-11-11 21:09:10 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2020-11-11 21:09:10 +0300
commit6d5a18ac65db79f3a32fb06618a4c4b7a08e777b (patch)
tree08fa8a2fdcf6bd23ae3a19fce008dcc38629ef2d /spec/frontend/registry
parent5fc3c77e2b08746bd39bfffae0c5918d63178433 (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/frontend/registry')
-rw-r--r--spec/frontend/registry/explorer/utils_spec.js12
1 files changed, 12 insertions, 0 deletions
diff --git a/spec/frontend/registry/explorer/utils_spec.js b/spec/frontend/registry/explorer/utils_spec.js
index d26cf3e56da..365bfc9ea19 100644
--- a/spec/frontend/registry/explorer/utils_spec.js
+++ b/spec/frontend/registry/explorer/utils_spec.js
@@ -15,5 +15,17 @@ describe('Utils', () => {
it('returns the url with an ending when is passed', () => {
expect(pathGenerator(imageDetails, '/foo')).toBe('/foo/bar/registry/repository/1/tags/foo');
});
+
+ it('returns the url unchanged when imageDetails have no name', () => {
+ const imageDetailsWithoutName = {
+ path: 'foo/bar/baz',
+ name: '',
+ id: 1,
+ };
+
+ expect(pathGenerator(imageDetailsWithoutName)).toBe(
+ '/foo/bar/baz/registry/repository/1/tags?format=json',
+ );
+ });
});
});