Skip to content

PMM-7 API tests rework#5299

Open
maxkondr wants to merge 9 commits intov3from
PMM-7-API-tests-rework
Open

PMM-7 API tests rework#5299
maxkondr wants to merge 9 commits intov3from
PMM-7-API-tests-rework

Conversation

@maxkondr
Copy link
Copy Markdown
Contributor

@maxkondr maxkondr commented Apr 28, 2026

PMM-7

Link to the Feature Build: Percona-Lab/pmm-submodules#4329

The tests flakiness was caused by several reasons:

  • tests didn't wait while Grafana inside PMM Server is fully up and running after all initializations and migrations
  • not all tests were idempotent
  • api-tests/server/settings tests update PMM Server configuration that triggers Grafana restart -> other tests fail while Grafata is unavailable.

Improvements:

  • Added test for RTA Mongodb Agent.
  • api-tests/server/settings has been separated from the rest of tests and is running at the end to avoid impact on the rest of tests
  • Make almost all tests running in parallel -> speedup test execution
  • Reworked Makefile - now there are targets to prepare and run tests.

Closes #2342.

The tests flakiness was caused by several reasons:
- tests didn't wait while Grafana inside PMM Server is fully up and running after all initializations and migrations
- not all tests were idempotent
- api-tests/server/settings tests update PMM Server configuration that triggers Grafana restart -> other tests fail while Grafata is unavailable.

Improvements:
- Added test for RTA Mongodb Agent.
- api-tests/server/settings has been separated from the rest of tests and is running at the end to avoid impact on the rest of tests
- Make almost all tests running in parallel -> speedup test execution
- Reworked Makefile - now there are targets to prepare and run tests.
reworked Makefile
@maxkondr maxkondr self-assigned this Apr 28, 2026
@maxkondr maxkondr requested a review from a team as a code owner April 28, 2026 14:16
@maxkondr maxkondr requested review from JiriCtvrtka and ademidoff and removed request for a team April 28, 2026 14:16
@maxkondr maxkondr changed the title Pmm 7 api tests rework PMM-7 API tests rework Apr 28, 2026
@codecov
Copy link
Copy Markdown

codecov Bot commented Apr 28, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 42.13%. Comparing base (4baae89) to head (111a8ca).
⚠️ Report is 1 commits behind head on v3.

Additional details and impacted files
@@            Coverage Diff             @@
##               v3    #5299      +/-   ##
==========================================
- Coverage   42.14%   42.13%   -0.01%     
==========================================
  Files         410      410              
  Lines       41992    41992              
==========================================
- Hits        17696    17695       -1     
- Misses      22512    22514       +2     
+ Partials     1784     1783       -1     
Flag Coverage Δ
admin 34.89% <ø> (ø)
agent 49.24% <ø> (ø)
managed 40.62% <ø> (-0.01%) ⬇️
vmproxy 72.09% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Comment thread api-tests/management/rds_test.go Outdated
Comment thread api-tests/Dockerfile
Comment thread api-tests/Makefile Outdated
Comment thread api-tests/Makefile Outdated
Comment thread api-tests/README.md Outdated
Comment thread api-tests/README.md Outdated
@ademidoff
Copy link
Copy Markdown
Member

@maxkondr The trouble is that the snooze tests are not passing. PTAL

@maxkondr
Copy link
Copy Markdown
Contributor Author

@maxkondr The trouble is that the snooze tests are not passing. PTAL

Now passing

Comment on lines -230 to -231
require.NotEmpty(t, genericNodeID)
defer pmmapitests.RemoveNodes(t, genericNodeID)
Copy link
Copy Markdown
Contributor

@JiriCtvrtka JiriCtvrtka May 1, 2026

Choose a reason for hiding this comment

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

Are we sure we don’t need this check anymore? Here and other places.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Enable paralleltest linter rule

3 participants