Skip to content
This repository has been archived by the owner on Sep 17, 2024. It is now read-only.

chore: refactor Fleet upgrade tests (#671) | chore: refactor build artifacts methods (#689) backport for 6.8.x #713

Merged
merged 2 commits into from
Feb 8, 2021

Conversation

mdelapenya
Copy link
Contributor

Backports the following commits to 6.8.x:

* chore: use nightly annotation for the Upgrade tests

* chore: add two make goals for the nightly use cases

- e2e-fleet-nightly: run the nightly tests not using CI snapshots.
It should download the binaries from the official artifactory.
- e2e-fleet-nightly-ci-snapshots: run the nightly tests using the CI
snapshots for a specific SHA commit from Beats, downloading them from
a GCP bucket

* chore: bump elastic-agent stale version

* chore: pass version and state state when creating an installer

This will allow selecting the proper binary, depending if we are using
a stale agent or a regular one.

* fix: append snapshot to the stale version when using CI snapshots

* fix: check for version aliases with non-stale versions

* chore: store current agent version in the test suite struct

* chore: make sure the layout is properly created for TAR installer

* chore: add make goals for testing fleet use cases

* chore: move Make goals to the e2e Makefile
* feat: use local beats directory for elastic-agent installers

* docs: document BEATS_LOCAL_PATH variable

* chore: check that the local file exists

* chore: add unit tests for the BEATS_LOCAL_PATH variable

* chore: simplify logic after test coverage

* chore: enrich test name

* chore: rename test

* chore: move default values to the end of the descriptions

* chore: add a helper method to build artifact names

* chore: build artifact name only once

* chore: pass the entire filename to calculate the GCP bucket coordinates

* chore: simplify method signature, as the file name is not changed within the method

* chore: use buildArtifactName method

* chore: pass filename to helper methods to avoid unnecessary calculations

* chore: rename variable for consistency

* chore: add license headers

* chore: use lowercase comparison for artifact name

* chore: build artifact changes from Beats CI to Elastic's artifactory

* fix: support building artifact names from local

Local builds uses the same as the CI

* WIP

* fix: rename docker-ubi8 installer key

* chore: pass a fallback version when building artifact name

In the case we are using a PR , where the version is "pr-12345", then we
need to use the base version of the product

* chore: remove log

* fix: do not override artifact name in Docker installer

* feat: support consuming the docker images from snapshots or local in standalone mode

* chore: add unit tests for fetching docker images from local Beats repo

* chore: apply version to Docker installer

* chore: support loading metricbeat image from local repository

* chore: exrtact loadImage method to docker helper

* feat: support consuming CI artifacts in metricbeat

* fix: remove non-existent field from logrus log

* chore: extract download logic to helper methods

We are discarding the stale parameter, because the stale version is set
when the installer is required, so we simply download what is requested

* chore: fix typo

* chore: check agent version before setting it

* chore: use the docker client to load the image instead of the docker binary

* chore: add unit tests for check method

* chore: pass fallback version to check method

* fix: properly calculate version for PRs

* chore: move PR check logic to a method

* chore: make test independent of maintenance branch
# Conflicts:
#	e2e/_suites/fleet/services_test.go
@mdelapenya mdelapenya self-assigned this Feb 8, 2021
@elasticmachine
Copy link
Contributor

💚 Build Succeeded

the below badges are clickable and redirect to their specific view in the CI or DOCS
Pipeline View Test View Changes Artifacts preview

Expand to view the summary

Build stats

  • Build Cause: Pull request #713 opened

  • Start Time: 2021-02-08T17:09:26.129+0000

  • Duration: 25 min 48 sec

  • Commit: f695d29

Test stats 🧪

Test Results
Failed 0
Passed 104
Skipped 9
Total 113

Trends 🧪

Image of Build Times

Image of Tests

💚 Flaky test report

Tests succeeded.

Expand to view the summary

Test stats 🧪

Test Results
Failed 0
Passed 104
Skipped 9
Total 113

@mdelapenya mdelapenya merged commit eabc001 into elastic:6.8.x Feb 8, 2021
@mdelapenya mdelapenya deleted the backport/6.8.x/pr-671_pr-689 branch June 2, 2021 05:38
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants