-
Notifications
You must be signed in to change notification settings - Fork 47
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
Overhaul stats: add E2E tests for the global metrics #1407
Labels
- Developer -
Torrust Improvement Experience
Quality & Assurance
Relates to QA, Testing, and CI
Testing
Checking Torrust
Comments
Open
5 tasks
josecelano
added a commit
to josecelano/torrust-tracker
that referenced
this issue
Mar 24, 2025
Loading
Loading status checks…
A new integration test that checks that the global metrics are udapted when you run 2 HTTP trackers. Ony one metric is checked in this test. It uses fixed port that migth conflict with other running instances in the future. We should use a random free port if we run more integration tests like this in the future.
josecelano
added a commit
to josecelano/torrust-tracker
that referenced
this issue
Mar 24, 2025
josecelano
added a commit
that referenced
this issue
Mar 24, 2025
Loading
Loading status checks…
b53da07 refactor: [#1407] remove duplicate code (Jose Celano) aff065c fix: [#1407] docker build after adding new integration test (Jose Celano) 4e59dd7 refactor: [#1407] rename (Jose Celano) 398ad9b refactor: remove duplicate code (Jose Celano) eeea77a chore: remove sample integration test (Jose Celano) 8510990 test: [#1407] add test for global metrics with 2 http trackers (Jose Celano) Pull request description: A new integration test that checks that the global metrics are updated when you run 2 HTTP trackers. Only one metric is checked in this test. It uses fixed ports that might conflict with other running instances in the future. We should use a random free port if we run more integration tests like this in the future. The rest of the functionality is already tested at the package level with only one tracker. I've added to make sure nothing is broken while working on the [stats overhaul](#1327). ACKs for top commit: josecelano: ACK b53da07 Tree-SHA512: 2b3a5758532a42c595497b506e8c861f8a3a499f20fa6515a36de76949a6850bc65c767a8c6d8bd2c20eb58a808b6cff7276359faec6268438a30bbbb995a818
4 tasks
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
- Developer -
Torrust Improvement Experience
Quality & Assurance
Relates to QA, Testing, and CI
Testing
Checking Torrust
Before implementing the segregate metrics I want to add some integration tests for the global metrics.
While I was working on #1404 I realized we don't have integration tests for that. There are tests for a single server. For example:
The tests use the test environment to create a single instance of the HTTP or UDP trackers.
We need to add a new tests at the application level at least with one test for each tracker type:
announce
request.Same for UDP tracker.
I don't know yet if we can use an E2E test:
https://github.com/torrust/torrust-tracker/blob/develop/src/console/ci/e2e/runner.rs
Or maybe we can create a new integration tests running the whole app.
I think the first option is faster to implement but slower to execute (it's using docker). I would prefer the second option. If it takes too long I would do it with E2E tests for now. Global metrics is something we are going to remove in future versions and the main app bootstrapping (containers and jobs) is not changed very often.
cc @da2ce7
The text was updated successfully, but these errors were encountered: