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

Implement $avg operator and integration tests #4617

Open
wants to merge 1 commit into
base: main-v1
Choose a base branch
from

Conversation

sayedppqq
Copy link

Description

Closes #2891

Readiness checklist

  • I added/updated unit tests (and they pass).
  • I added/updated integration/compatibility tests (and they pass).
  • I added/updated comments and checked rendering.
  • I made spot refactorings.
  • I updated user documentation.
  • I ran task all, and it passed.
  • I ensured that PR title is good enough for the changelog.
  • (for maintainers only) I set Reviewers (@FerretDB/core), Milestone (Next), Labels, Project and project's Sprint fields.
  • I marked all done items in this checklist.

@sayedppqq sayedppqq requested review from a team and AlekSi as code owners November 1, 2024 19:38
@sayedppqq sayedppqq requested a review from chilagrow November 1, 2024 19:38
@CLAassistant
Copy link

CLAassistant commented Nov 1, 2024

CLA assistant check
All committers have signed the CLA.

Signed-off-by: sayedppqq <sayedmmnn0@gmail.com>
@sayedppqq
Copy link
Author

sayedppqq commented Nov 1, 2024

Hello, do I need to setup anything before running tests? when I'm running task test-integration1 , its failing all the tests. I'm kinda new in FerretDB for making PR

Copy link

codecov bot commented Nov 1, 2024

Codecov Report

Attention: Patch coverage is 8.38323% with 153 lines in your changes missing coverage. Please review.

Project coverage is 69.97%. Comparing base (e090e53) to head (e6db2e9).

Files with missing lines Patch % Lines
.../common/aggregations/operators/accumulators/avg.go 0.00% 75 Missing ⚠️
...ernal/handler/common/aggregations/operators/avg.go 19.44% 57 Missing and 1 partial ⚠️
internal/handler/common/aggregations/number.go 0.00% 20 Missing ⚠️

❗ There is a different number of reports uploaded between BASE (e090e53) and HEAD (e6db2e9). Click for more details.

HEAD has 407 uploads less than BASE
Flag BASE (e090e53) HEAD (e6db2e9)
integration 145 11
filter-true 106 11
mongodb-1 6 1
unit 6 1
sqlite-3 14 1
postgresql-3 14 1
postgresql-1 15 1
sqlite-1 14 1
sqlite-2 15 1
postgresql-2 15 1
sqlite-5 5 1
postgresql-5 6 1
postgresql-4 6 1
sqlite-4 6 1
hana-1 5 0
filter-false 39 0
mysql-3 8 0
mysql-2 8 0
mysql-1 8 0
Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #4617      +/-   ##
==========================================
- Coverage   75.93%   69.97%   -5.97%     
==========================================
  Files         303      305       +2     
  Lines       21575    27343    +5768     
==========================================
+ Hits        16384    19132    +2748     
- Misses       4052     7068    +3016     
- Partials     1139     1143       +4     
Files with missing lines Coverage Δ
...ggregations/operators/accumulators/accumulators.go 67.39% <ø> (-16.82%) ⬇️
...handler/common/aggregations/operators/operators.go 81.25% <ø> (+2.00%) ⬆️
internal/handler/common/aggregations/number.go 64.28% <0.00%> (-35.72%) ⬇️
...ernal/handler/common/aggregations/operators/avg.go 19.44% <19.44%> (ø)
.../common/aggregations/operators/accumulators/avg.go 0.00% <0.00%> (ø)

... and 284 files with indirect coverage changes

Flag Coverage Δ
filter-false ?
filter-true 63.40% <8.38%> (-8.35%) ⬇️
hana-1 ?
integration 63.40% <8.38%> (-8.40%) ⬇️
mongodb-1 5.87% <0.00%> (+0.10%) ⬆️
mysql-1 ?
mysql-2 ?
mysql-3 ?
postgresql-1 44.59% <8.38%> (-9.39%) ⬇️
postgresql-2 43.01% <0.00%> (-9.39%) ⬇️
postgresql-3 39.49% <0.00%> (-13.68%) ⬇️
postgresql-4 41.84% <0.00%> (-0.73%) ⬇️
postgresql-5 21.41% <0.00%> (-21.14%) ⬇️
sqlite-1 43.31% <8.38%> (-9.42%) ⬇️
sqlite-2 41.85% <0.00%> (-9.38%) ⬇️
sqlite-3 38.38% <0.00%> (-13.54%) ⬇️
sqlite-4 40.69% <0.00%> (-0.87%) ⬇️
sqlite-5 20.18% <0.00%> (-21.17%) ⬇️
unit 30.94% <0.00%> (-0.14%) ⬇️

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

@chilagrow
Copy link
Member

Hello, do I need to setup anything before running tests? when I'm running task test-integration1 , its failing all the tests. I'm kinda new in FerretDB for making PR

Hi @sayedppqq, did you follow https://github.com/FerretDB/FerretDB/blob/main/CONTRIBUTING.md#setting-up-the-environment for setting up?

Running test can be done https://github.com/FerretDB/FerretDB/blob/main/CONTRIBUTING.md#running-tests.

@chilagrow
Copy link
Member

Sorry for not getting back to this earlier #2891 (comment) 🙏

@AlekSi AlekSi changed the base branch from main to main-v1 December 6, 2024 03:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: In progress
Development

Successfully merging this pull request may close these issues.

Implement $avg accumulator operator
3 participants