diff --git a/x-pack/test/fleet_api_integration/apis/epm/install_prerelease.ts b/x-pack/test/fleet_api_integration/apis/epm/install_prerelease.ts
index 3231b9d9a438a..928a168cc9042 100644
--- a/x-pack/test/fleet_api_integration/apis/epm/install_prerelease.ts
+++ b/x-pack/test/fleet_api_integration/apis/epm/install_prerelease.ts
@@ -22,7 +22,8 @@ export default function (providerContext: FtrProviderContext) {
await supertest.delete(`/api/fleet/epm/packages/${pkg}/${version}`).set('kbn-xsrf', 'xxxx');
};
- describe('installs package that has a prerelease version', async () => {
+ // Failing: See https://github.com/elastic/kibana/issues/150343
+ describe.skip('installs package that has a prerelease version', async () => {
skipIfNoDockerRegistry(providerContext);
setupFleetAndAgents(providerContext);
@@ -37,21 +38,21 @@ export default function (providerContext: FtrProviderContext) {
await supertest
.post(`/api/fleet/epm/packages/${testPackage}/${testPackageVersion}`)
.set('kbn-xsrf', 'xxxx')
+ .send({ force: true })
.expect(200);
});
- const pkg = 'endpoint';
- const gaVersion = '8.6.1';
- const betaVersion = '8.7.0-next';
+ const gaVersion = '1.0.0';
+ const betaVersion = '1.0.1-next';
afterEach(async () => {
- await deletePackage(pkg, gaVersion);
- await deletePackage(pkg, betaVersion);
+ await deletePackage(testPackage, gaVersion);
+ await deletePackage(testPackage, betaVersion);
});
it('should install the GA package correctly', async function () {
const response = await supertest
- .post(`/api/fleet/epm/packages/${pkg}/${gaVersion}`)
+ .post(`/api/fleet/epm/packages/${testPackage}/${gaVersion}`)
.set('kbn-xsrf', 'xxxx')
.send({ force: true })
.expect(200);
@@ -61,7 +62,7 @@ export default function (providerContext: FtrProviderContext) {
it('should install the GA package when no version is provided', async function () {
const response = await supertest
- .post(`/api/fleet/epm/packages/${pkg}`)
+ .post(`/api/fleet/epm/packages/${testPackage}`)
.set('kbn-xsrf', 'xxxx')
.send({ force: true })
.expect(200);
@@ -71,7 +72,7 @@ export default function (providerContext: FtrProviderContext) {
it('should install the beta package when no version is provided and prerelease is true', async function () {
const response = await supertest
- .post(`/api/fleet/epm/packages/${pkg}?prerelease=true`)
+ .post(`/api/fleet/epm/packages/${testPackage}?prerelease=true`)
.set('kbn-xsrf', 'xxxx')
.send({ force: true }) // using force to ignore package verification error
.expect(200);
@@ -83,7 +84,7 @@ export default function (providerContext: FtrProviderContext) {
const response = await supertest
.post(`/api/fleet/epm/packages/_bulk?prerelease=true`)
.set('kbn-xsrf', 'xxxx')
- .send({ packages: ['endpoint'], force: true })
+ .send({ packages: ['prerelease'], force: true })
.expect(200);
expect(response.body.items[0].version).equal(betaVersion);
@@ -93,7 +94,7 @@ export default function (providerContext: FtrProviderContext) {
const response = await supertest
.post(`/api/fleet/epm/packages/_bulk`)
.set('kbn-xsrf', 'xxxx')
- .send({ packages: ['endpoint'], force: true })
+ .send({ packages: ['prerelease'], force: true })
.expect(200);
expect(response.body.items[0].version).equal(gaVersion);
diff --git a/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/endpoint/endpoint-8.7.0-next.zip b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/endpoint/endpoint-8.7.0-next.zip
deleted file mode 100644
index 2002c1c8c2002..0000000000000
Binary files a/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/endpoint/endpoint-8.7.0-next.zip and /dev/null differ
diff --git a/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/prerelease/1.0.0/data_stream/test/fields/fields.yml b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/prerelease/1.0.0/data_stream/test/fields/fields.yml
new file mode 100644
index 0000000000000..6e003ed0ad147
--- /dev/null
+++ b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/prerelease/1.0.0/data_stream/test/fields/fields.yml
@@ -0,0 +1,16 @@
+- name: data_stream.type
+ type: constant_keyword
+ description: >
+ Data stream type.
+- name: data_stream.dataset
+ type: constant_keyword
+ description: >
+ Data stream dataset.
+- name: data_stream.namespace
+ type: constant_keyword
+ description: >
+ Data stream namespace.
+- name: '@timestamp'
+ type: date
+ description: >
+ Event timestamp.
diff --git a/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/prerelease/1.0.0/data_stream/test/manifest.yml b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/prerelease/1.0.0/data_stream/test/manifest.yml
new file mode 100644
index 0000000000000..17c33c745ce74
--- /dev/null
+++ b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/prerelease/1.0.0/data_stream/test/manifest.yml
@@ -0,0 +1,3 @@
+title: Test Dataset
+
+type: logs
diff --git a/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/prerelease/1.0.0/docs/README.md b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/prerelease/1.0.0/docs/README.md
new file mode 100644
index 0000000000000..0002afd9cdfc0
--- /dev/null
+++ b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/prerelease/1.0.0/docs/README.md
@@ -0,0 +1,3 @@
+# Test package
+
+For testing a prerelease package
diff --git a/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/prerelease/1.0.0/img/logo_prerelease_64_color.svg b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/prerelease/1.0.0/img/logo_prerelease_64_color.svg
new file mode 100644
index 0000000000000..b03007a76ffcc
--- /dev/null
+++ b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/prerelease/1.0.0/img/logo_prerelease_64_color.svg
@@ -0,0 +1,7 @@
+
diff --git a/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/prerelease/1.0.0/manifest.yml b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/prerelease/1.0.0/manifest.yml
new file mode 100644
index 0000000000000..231cf1ed668b7
--- /dev/null
+++ b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/prerelease/1.0.0/manifest.yml
@@ -0,0 +1,21 @@
+format_version: 1.0.0
+name: prerelease
+title: Prerelease package
+description: This is a test package for testing that parsing a prerelease version works
+version: 1.0.0
+categories: ['security']
+type: integration
+license: basic
+owner:
+ github: elastic/fleet
+
+requirement:
+ elasticsearch:
+ versions: '>7.7.0'
+ kibana:
+ versions: '>7.7.0'
+
+icons:
+ - src: '/img/logo_prerelease_64_color.svg'
+ size: '16x16'
+ type: 'image/svg+xml'
diff --git a/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/prerelease/1.0.1-next/data_stream/test/fields/fields.yml b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/prerelease/1.0.1-next/data_stream/test/fields/fields.yml
new file mode 100644
index 0000000000000..6e003ed0ad147
--- /dev/null
+++ b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/prerelease/1.0.1-next/data_stream/test/fields/fields.yml
@@ -0,0 +1,16 @@
+- name: data_stream.type
+ type: constant_keyword
+ description: >
+ Data stream type.
+- name: data_stream.dataset
+ type: constant_keyword
+ description: >
+ Data stream dataset.
+- name: data_stream.namespace
+ type: constant_keyword
+ description: >
+ Data stream namespace.
+- name: '@timestamp'
+ type: date
+ description: >
+ Event timestamp.
diff --git a/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/prerelease/1.0.1-next/data_stream/test/manifest.yml b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/prerelease/1.0.1-next/data_stream/test/manifest.yml
new file mode 100644
index 0000000000000..17c33c745ce74
--- /dev/null
+++ b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/prerelease/1.0.1-next/data_stream/test/manifest.yml
@@ -0,0 +1,3 @@
+title: Test Dataset
+
+type: logs
diff --git a/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/prerelease/1.0.1-next/docs/README.md b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/prerelease/1.0.1-next/docs/README.md
new file mode 100644
index 0000000000000..0002afd9cdfc0
--- /dev/null
+++ b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/prerelease/1.0.1-next/docs/README.md
@@ -0,0 +1,3 @@
+# Test package
+
+For testing a prerelease package
diff --git a/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/prerelease/1.0.1-next/img/logo_prerelease_64_color.svg b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/prerelease/1.0.1-next/img/logo_prerelease_64_color.svg
new file mode 100644
index 0000000000000..b03007a76ffcc
--- /dev/null
+++ b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/prerelease/1.0.1-next/img/logo_prerelease_64_color.svg
@@ -0,0 +1,7 @@
+
diff --git a/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/prerelease/1.0.1-next/manifest.yml b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/prerelease/1.0.1-next/manifest.yml
new file mode 100644
index 0000000000000..1bc273ccaa4a3
--- /dev/null
+++ b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/prerelease/1.0.1-next/manifest.yml
@@ -0,0 +1,21 @@
+format_version: 1.0.0
+name: prerelease
+title: Prerelease package
+description: This is a test package for testing that parsing a prerelease version works
+version: 1.0.1-next
+categories: ['security']
+type: integration
+license: basic
+owner:
+ github: elastic/fleet
+
+requirement:
+ elasticsearch:
+ versions: '>7.7.0'
+ kibana:
+ versions: '>7.7.0'
+
+icons:
+ - src: '/img/logo_prerelease_64_color.svg'
+ size: '16x16'
+ type: 'image/svg+xml'