Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add delivery module tests #2692

Merged
merged 9 commits into from
Jun 21, 2023
Merged

add delivery module tests #2692

merged 9 commits into from
Jun 21, 2023

Conversation

pzl
Copy link
Member

@pzl pzl commented Jun 13, 2023

What is the problem this PR solves?

Adds additional tests for the file delivery feature (#2666 )

makes minor change to the file query to only query for active (status = READY) files

How does this PR solve the problem?

Adds tests to the delivery module, handler

How to test this PR locally

go test!

Design Checklist

  • I have ensured my design is stateless and will work when multiple fleet-server instances are behind a load balancer.
  • I have or intend to scale test my changes, ensuring it will work reliably with 100K+ agents connected.
  • I have included fail safe mechanisms to limit the load on fleet-server: rate limiting, circuit breakers, caching, load shedding, etc.

Checklist

  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • I have made corresponding change to the default configuration files
  • I have added tests that prove my fix is effective or that my feature works
  • I have added an entry in ./changelog/fragments using the changelog tool
    ( fragment was added in File delivery #2666 )

@pzl pzl added the cleanup label Jun 13, 2023
@elasticmachine
Copy link
Collaborator

elasticmachine commented Jun 13, 2023

💚 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 preview

Expand to view the summary

Build stats

  • Start Time: 2023-06-21T17:06:42.147+0000

  • Duration: 46 min 4 sec

Test stats 🧪

Test Results
Failed 0
Passed 742
Skipped 1
Total 743

💚 Flaky test report

Tests succeeded.

🤖 GitHub comments

Expand to view the GitHub comments

To re-run your PR in the CI, just comment with:

  • /test : Re-trigger the build.

@pzl pzl marked this pull request as ready for review June 21, 2023 13:46
@pzl pzl requested a review from a team as a code owner June 21, 2023 13:46
})
)

func TestFileDeliveryRouteDisallowedMethods(t *testing.T) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

useful tests! 👍

@pzl pzl enabled auto-merge (squash) June 21, 2023 17:18
@pzl pzl merged commit 336e3e9 into elastic:main Jun 21, 2023
17 of 18 checks passed
pzl added a commit to pzl/fleet-server that referenced this pull request Jun 22, 2023
juliaElastic pushed a commit that referenced this pull request Jun 30, 2023
…NAPSHOT (#2732)

* Adds delivery module tests (#2692)

* [Release] add-backport-next (#2721)

* [Release] update version (#2720)

Co-authored-by: Anderson Queiroz <anderson.queiroz@elastic.co>

* Revert "[Release] update version (#2720)" (#2730)

This reverts commit 331112b.

* add the trigger package-registry pipeline (#2729)

* package step (#2651)

* test the trigger step

* test condition for trigger step

* revert test condition for trigger step and add comment with TODO step for the future

* fix condition

* matrix test

* matrix test2

* matrix test3

* fix the version path

* platform and matrix test

* platform and matrix test

* platform and matrix test

* platform and matrix test

* update script permissions

* fix values

* fix platform type and add debug info

* add package part

* fix package part add publish part

* add add_bin_path

* add variable SETUP_GVM_VERSION

* fix go module names

* fix for loop for install packages

* add ubuntu images

* fix step keys

* fix images

* delete provider setting

* change the image options

* change the image options

* change the image options

* change gvm version

* try to debug make error

* add debur info into the package script

* troubleshoot the script

* troubleshoot the script

* troubleshoot the script

* troubleshoot the image

* troubleshoot the image

* revert the image

* change the gcp image

* change the gcp image

* change the gcp image

* add GO_VERSION

* add debug to the comman.bash script

* add debug to the comman.bash script

* debug comman.bash script

* debug comman.bash script

* debug comman.bash script

* debug comman.bash script

* debug comman.bash script

* revert common.bash and run_with_go_ver

* revert common.bash and run_with_go_ver

* change image

* correct path

* add google_cloud_auth

* test

* Update .buildkite/scripts/common.sh

Co-authored-by: Mario Rodriguez Molins <marrodmo@gmail.com>

* Update .buildkite/scripts/common.sh

Co-authored-by: Mario Rodriguez Molins <marrodmo@gmail.com>

* Update .buildkite/scripts/common.sh

Co-authored-by: Mario Rodriguez Molins <marrodmo@gmail.com>

* optimize the package.sh

* Update .buildkite/scripts/package.sh

Co-authored-by: Mario Rodriguez Molins <marrodmo@gmail.com>

* change the getting the bucket name

* change the condition and dependency to run the stage

* add '--no-pager' to the 'git log' command

---------

Co-authored-by: Mario Rodriguez Molins <marrodmo@gmail.com>

* chore: Updated to content "" in file "dev-tools/integration/.env"

Made with ❤️️ by updatecli

* chore: Updated to content "" in file "dev-tools/integration/.env"

Made with ❤️️ by updatecli

* chore: Updated to content "" in file "dev-tools/integration/.env"

Made with ❤️️ by updatecli

* chore: Updated to content "" in file "dev-tools/integration/.env"

Made with ❤️️ by updatecli

* chore: Updated to content "" in file "dev-tools/integration/.env"

Made with ❤️️ by updatecli

---------

Co-authored-by: Dan Panzarella <pzl@users.noreply.github.com>
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
Co-authored-by: Anderson Queiroz <anderson.queiroz@elastic.co>
Co-authored-by: Jaime Soriano Pastor <jaime.soriano@elastic.co>
Co-authored-by: sharbuz <87968844+sharbuz@users.noreply.github.com>
Co-authored-by: Mario Rodriguez Molins <marrodmo@gmail.com>
Co-authored-by: apmmachine <apmmachine@users.noreply.github.com>
Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants