-
Notifications
You must be signed in to change notification settings - Fork 8.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
d7aa024
commit c1f6919
Showing
2 changed files
with
34 additions
and
0 deletions.
There are no files selected for viewing
33 changes: 33 additions & 0 deletions
33
x-pack/test/ingest_manager_api_integration/apis/epm/get.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
/* | ||
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one | ||
* or more contributor license agreements. Licensed under the Elastic License; | ||
* you may not use this file except in compliance with the Elastic License. | ||
*/ | ||
|
||
import { FtrProviderContext } from '../../../api_integration/ftr_provider_context'; | ||
import { warnAndSkipTest } from '../../helpers'; | ||
|
||
export default function ({ getService }: FtrProviderContext) { | ||
const log = getService('log'); | ||
const supertest = getService('supertest'); | ||
const dockerServers = getService('dockerServers'); | ||
const server = dockerServers.get('registry'); | ||
|
||
describe('EPM - get', () => { | ||
it('returns a 500 for a package key without a proper name', async function () { | ||
if (server.enabled) { | ||
await supertest.get('/api/ingest_manager/epm/packages/-0.1.0').expect(500); | ||
} else { | ||
warnAndSkipTest(this, log); | ||
} | ||
}); | ||
|
||
it('returns a 500 for a package key without a proper semver version', async function () { | ||
if (server.enabled) { | ||
await supertest.get('/api/ingest_manager/epm/packages/endpoint-0.1.0.1.2.3').expect(500); | ||
} else { | ||
warnAndSkipTest(this, log); | ||
} | ||
}); | ||
}); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters