catalog-backend: fix usage of optional locations in tests
Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
This commit is contained in:
@@ -167,7 +167,6 @@ describe('AzureDevOpsDiscoveryProcessor', () => {
|
||||
'https://dev.azure.com/shopify/engineering/_git/backstage?path=/catalog-info.yaml',
|
||||
presence: 'optional',
|
||||
},
|
||||
optional: true,
|
||||
});
|
||||
expect(emitter).toHaveBeenCalledWith({
|
||||
type: 'location',
|
||||
@@ -177,7 +176,6 @@ describe('AzureDevOpsDiscoveryProcessor', () => {
|
||||
'https://dev.azure.com/shopify/engineering/_git/ios-app?path=/src/catalog-info.yaml',
|
||||
presence: 'optional',
|
||||
},
|
||||
optional: true,
|
||||
});
|
||||
});
|
||||
|
||||
@@ -215,7 +213,6 @@ describe('AzureDevOpsDiscoveryProcessor', () => {
|
||||
'https://dev.azure.com/shopify/engineering/_git/backstage?path=/catalog-info.yaml',
|
||||
presence: 'optional',
|
||||
},
|
||||
optional: true,
|
||||
});
|
||||
});
|
||||
|
||||
@@ -254,7 +251,6 @@ describe('AzureDevOpsDiscoveryProcessor', () => {
|
||||
'https://dev.azure.com/shopify/engineering/_git/backstage?path=/src/main/catalog.yaml',
|
||||
presence: 'optional',
|
||||
},
|
||||
optional: true,
|
||||
});
|
||||
});
|
||||
|
||||
|
||||
+1
-23
@@ -210,7 +210,6 @@ describe('BitbucketDiscoveryProcessor', () => {
|
||||
'https://bitbucket.mycompany.com/projects/backstage/repos/backstage/browse/catalog.yaml',
|
||||
presence: 'optional',
|
||||
},
|
||||
optional: true,
|
||||
});
|
||||
expect(emitter).toHaveBeenCalledWith({
|
||||
type: 'location',
|
||||
@@ -220,7 +219,6 @@ describe('BitbucketDiscoveryProcessor', () => {
|
||||
'https://bitbucket.mycompany.com/projects/demo/repos/demo/browse/catalog.yaml',
|
||||
presence: 'optional',
|
||||
},
|
||||
optional: true,
|
||||
});
|
||||
});
|
||||
|
||||
@@ -246,7 +244,6 @@ describe('BitbucketDiscoveryProcessor', () => {
|
||||
'https://bitbucket.mycompany.com/projects/backstage/repos/techdocs-cli/browse/catalog.yaml',
|
||||
presence: 'optional',
|
||||
},
|
||||
optional: true,
|
||||
});
|
||||
});
|
||||
|
||||
@@ -269,7 +266,6 @@ describe('BitbucketDiscoveryProcessor', () => {
|
||||
'https://bitbucket.mycompany.com/projects/demo/repos/demo/browse/catalog.yaml?ref=branch-name',
|
||||
presence: 'optional',
|
||||
},
|
||||
optional: true,
|
||||
});
|
||||
});
|
||||
|
||||
@@ -292,7 +288,6 @@ describe('BitbucketDiscoveryProcessor', () => {
|
||||
'https://bitbucket.mycompany.com/projects/backstage/repos/test/browse/catalog.yaml',
|
||||
presence: 'optional',
|
||||
},
|
||||
optional: true,
|
||||
});
|
||||
});
|
||||
|
||||
@@ -321,7 +316,6 @@ describe('BitbucketDiscoveryProcessor', () => {
|
||||
'https://bitbucket.mycompany.com/projects/backstage/repos/techdocs-cli/browse/catalog-info.yaml',
|
||||
presence: 'optional',
|
||||
},
|
||||
optional: true,
|
||||
});
|
||||
});
|
||||
});
|
||||
@@ -369,7 +363,6 @@ describe('BitbucketDiscoveryProcessor', () => {
|
||||
'https://bitbucket.mycompany.com/custom-path/projects/backstage/repos/backstage/browse/catalog.yaml',
|
||||
presence: 'optional',
|
||||
},
|
||||
optional: true,
|
||||
});
|
||||
expect(emitter).toHaveBeenCalledWith({
|
||||
type: 'location',
|
||||
@@ -379,7 +372,6 @@ describe('BitbucketDiscoveryProcessor', () => {
|
||||
'https://bitbucket.mycompany.com/custom-path/projects/demo/repos/demo/browse/catalog.yaml',
|
||||
presence: 'optional',
|
||||
},
|
||||
optional: true,
|
||||
});
|
||||
});
|
||||
|
||||
@@ -408,7 +400,6 @@ describe('BitbucketDiscoveryProcessor', () => {
|
||||
'https://bitbucket.mycompany.com/custom-path/projects/backstage/repos/techdocs-cli/browse/catalog.yaml',
|
||||
presence: 'optional',
|
||||
},
|
||||
optional: true,
|
||||
});
|
||||
});
|
||||
|
||||
@@ -434,7 +425,6 @@ describe('BitbucketDiscoveryProcessor', () => {
|
||||
'https://bitbucket.mycompany.com/custom-path/projects/demo/repos/demo/browse/catalog.yaml?ref=branch-name',
|
||||
presence: 'optional',
|
||||
},
|
||||
optional: true,
|
||||
});
|
||||
});
|
||||
|
||||
@@ -460,7 +450,6 @@ describe('BitbucketDiscoveryProcessor', () => {
|
||||
'https://bitbucket.mycompany.com/custom-path/projects/backstage/repos/test/browse/catalog.yaml',
|
||||
presence: 'optional',
|
||||
},
|
||||
optional: true,
|
||||
});
|
||||
});
|
||||
|
||||
@@ -492,7 +481,6 @@ describe('BitbucketDiscoveryProcessor', () => {
|
||||
'https://bitbucket.mycompany.com/custom-path/projects/backstage/repos/techdocs-cli/browse/catalog-info.yaml',
|
||||
presence: 'optional',
|
||||
},
|
||||
optional: true,
|
||||
});
|
||||
});
|
||||
});
|
||||
@@ -536,7 +524,6 @@ describe('BitbucketDiscoveryProcessor', () => {
|
||||
'https://bitbucket.org/myworkspace/repository-one/src/master/catalog-info.yaml',
|
||||
presence: 'optional',
|
||||
},
|
||||
optional: true,
|
||||
});
|
||||
expect(emitter).toHaveBeenCalledWith({
|
||||
type: 'location',
|
||||
@@ -546,7 +533,6 @@ describe('BitbucketDiscoveryProcessor', () => {
|
||||
'https://bitbucket.org/myworkspace/repository-two/src/master/catalog-info.yaml',
|
||||
presence: 'optional',
|
||||
},
|
||||
optional: true,
|
||||
});
|
||||
});
|
||||
|
||||
@@ -574,7 +560,6 @@ describe('BitbucketDiscoveryProcessor', () => {
|
||||
'https://bitbucket.org/myworkspace/repository-one/src/master/my/nested/path/catalog.yaml',
|
||||
presence: 'optional',
|
||||
},
|
||||
optional: true,
|
||||
});
|
||||
expect(emitter).toHaveBeenCalledWith({
|
||||
type: 'location',
|
||||
@@ -584,7 +569,6 @@ describe('BitbucketDiscoveryProcessor', () => {
|
||||
'https://bitbucket.org/myworkspace/repository-two/src/master/my/nested/path/catalog.yaml',
|
||||
presence: 'optional',
|
||||
},
|
||||
optional: true,
|
||||
});
|
||||
});
|
||||
|
||||
@@ -612,7 +596,6 @@ describe('BitbucketDiscoveryProcessor', () => {
|
||||
'https://bitbucket.org/myworkspace/repository-one/src/master/catalog.yaml',
|
||||
presence: 'optional',
|
||||
},
|
||||
optional: true,
|
||||
});
|
||||
expect(emitter).toHaveBeenCalledWith({
|
||||
type: 'location',
|
||||
@@ -622,7 +605,6 @@ describe('BitbucketDiscoveryProcessor', () => {
|
||||
'https://bitbucket.org/myworkspace/repository-two/src/master/catalog.yaml',
|
||||
presence: 'optional',
|
||||
},
|
||||
optional: true,
|
||||
});
|
||||
});
|
||||
|
||||
@@ -649,7 +631,6 @@ describe('BitbucketDiscoveryProcessor', () => {
|
||||
'https://bitbucket.org/myworkspace/repository-one/src/master/catalog.yaml',
|
||||
presence: 'optional',
|
||||
},
|
||||
optional: true,
|
||||
});
|
||||
});
|
||||
|
||||
@@ -677,7 +658,6 @@ describe('BitbucketDiscoveryProcessor', () => {
|
||||
'https://bitbucket.org/myworkspace/repository-three/src/master/catalog.yaml',
|
||||
presence: 'optional',
|
||||
},
|
||||
optional: true,
|
||||
});
|
||||
});
|
||||
|
||||
@@ -703,7 +683,6 @@ describe('BitbucketDiscoveryProcessor', () => {
|
||||
'https://bitbucket.org/myworkspace/repository-one/src/master/catalog-info.yaml',
|
||||
presence: 'optional',
|
||||
},
|
||||
optional: true,
|
||||
});
|
||||
expect(mockCall).toBeCalledTimes(1);
|
||||
// it should be possible to do this via an `expect.objectContaining` check but seems to fail with some encoding issue.
|
||||
@@ -739,7 +718,6 @@ describe('BitbucketDiscoveryProcessor', () => {
|
||||
'https://bitbucket.org/myworkspace/repository-one/src/master/catalog-info.yaml',
|
||||
presence: 'optional',
|
||||
},
|
||||
optional: true,
|
||||
});
|
||||
});
|
||||
|
||||
@@ -806,8 +784,8 @@ describe('BitbucketDiscoveryProcessor', () => {
|
||||
location: {
|
||||
type: 'custom-location-type',
|
||||
target: 'custom-target',
|
||||
presence: 'optional',
|
||||
},
|
||||
optional: true,
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
@@ -210,7 +210,6 @@ describe('GitlabDiscoveryProcessor', () => {
|
||||
target: 'https://gitlab.fake/1/-/blob/main/catalog-info.yaml',
|
||||
presence: 'optional',
|
||||
},
|
||||
optional: true,
|
||||
},
|
||||
{
|
||||
type: 'location',
|
||||
@@ -219,7 +218,6 @@ describe('GitlabDiscoveryProcessor', () => {
|
||||
target: 'https://gitlab.fake/2/-/blob/master/catalog-info.yaml',
|
||||
presence: 'optional',
|
||||
},
|
||||
optional: true,
|
||||
},
|
||||
]);
|
||||
});
|
||||
@@ -257,7 +255,6 @@ describe('GitlabDiscoveryProcessor', () => {
|
||||
target: 'https://gitlab.fake/1/-/blob/master/catalog-info.yaml',
|
||||
presence: 'optional',
|
||||
},
|
||||
optional: true,
|
||||
},
|
||||
]);
|
||||
});
|
||||
|
||||
@@ -175,7 +175,6 @@ describe('GithubDiscoveryProcessor', () => {
|
||||
'https://github.com/backstage/backstage/blob/master/catalog.yaml',
|
||||
presence: 'optional',
|
||||
},
|
||||
optional: true,
|
||||
});
|
||||
expect(emitter).toHaveBeenCalledWith({
|
||||
type: 'location',
|
||||
@@ -184,7 +183,6 @@ describe('GithubDiscoveryProcessor', () => {
|
||||
target: 'https://github.com/backstage/demo/blob/master/catalog.yaml',
|
||||
presence: 'optional',
|
||||
},
|
||||
optional: true,
|
||||
});
|
||||
});
|
||||
|
||||
@@ -217,7 +215,6 @@ describe('GithubDiscoveryProcessor', () => {
|
||||
'https://github.com/backstage/tech-docs/blob/main/catalog.yaml',
|
||||
presence: 'optional',
|
||||
},
|
||||
optional: true,
|
||||
});
|
||||
});
|
||||
|
||||
@@ -272,7 +269,6 @@ describe('GithubDiscoveryProcessor', () => {
|
||||
'https://github.com/backstage/backstage/blob/master/catalog-info.yaml',
|
||||
presence: 'optional',
|
||||
},
|
||||
optional: true,
|
||||
});
|
||||
});
|
||||
|
||||
@@ -328,7 +324,6 @@ describe('GithubDiscoveryProcessor', () => {
|
||||
'https://github.com/backstage/techdocs-cli/blob/master/catalog.yaml',
|
||||
presence: 'optional',
|
||||
},
|
||||
optional: true,
|
||||
});
|
||||
expect(emitter).toHaveBeenCalledWith({
|
||||
type: 'location',
|
||||
@@ -338,7 +333,6 @@ describe('GithubDiscoveryProcessor', () => {
|
||||
'https://github.com/backstage/techdocs-container/blob/master/catalog.yaml',
|
||||
presence: 'optional',
|
||||
},
|
||||
optional: true,
|
||||
});
|
||||
});
|
||||
|
||||
@@ -394,7 +388,6 @@ describe('GithubDiscoveryProcessor', () => {
|
||||
target: 'https://github.com/backstage/test/blob/master/catalog.yaml',
|
||||
presence: 'optional',
|
||||
},
|
||||
optional: true,
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user