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

chore: use gomega match assertion #1678

Merged
merged 6 commits into from
Apr 1, 2021

Conversation

Jaycean
Copy link
Member

@Jaycean Jaycean commented Mar 26, 2021

Please answer these questions before submitting a pull request, or your PR will get closed.

Why submit this pull request?

  • Bugfix
  • New feature provided
  • Improve performance
  • Backport patches

What changes will this PR take into?

e2e test use gomega match assertion.

Related issues

fix/resolve #1664

Checklist:

  • Did you explain what problem does this PR solve? Or what new features have been added?
  • Have you added corresponding test cases?
  • Have you modified the corresponding document?
  • Is this PR backward compatible? If it is not backward compatible, please discuss on the mailing list first

@codecov-io
Copy link

codecov-io commented Mar 26, 2021

Codecov Report

Merging #1678 (1f3a9c7) into master (88f3232) will increase coverage by 1.62%.
The diff coverage is n/a.

❗ Current head 1f3a9c7 differs from pull request most recent head 5315aad. Consider uploading reports for the commit 5315aad to get more accurate results
Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1678      +/-   ##
==========================================
+ Coverage   72.41%   74.04%   +1.62%     
==========================================
  Files         133       86      -47     
  Lines        5728     2612    -3116     
  Branches      666      666              
==========================================
- Hits         4148     1934    -2214     
+ Misses       1337      678     -659     
+ Partials      243        0     -243     
Flag Coverage Δ
backend-e2e-test ?
backend-e2e-test-ginkgo ?
backend-unit-test ?
frontend-e2e-test 74.04% <ø> (+0.07%) ⬆️

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

Impacted Files Coverage Δ
api/internal/handler/tool/tool.go
api/internal/handler/data_loader/route_import.go
api/internal/utils/runtime/runtime.go
api/internal/utils/consts/api_error.go
api/internal/core/store/storehub.go
api/internal/log/zap.go
api/internal/utils/pid.go
api/internal/core/store/store.go
api/internal/core/store/store_mock.go
api/internal/filter/ip_filter.go
... and 38 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 88f3232...5315aad. Read the comment docs.

Copy link
Member

@bisakhmondal bisakhmondal left a comment

Choose a reason for hiding this comment

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

Nice 👍

Comment on lines 140 to 142
gomega.Expect(res["1980"] == 3).Should(gomega.BeTrue())
gomega.Expect(res["1981"] == 6).Should(gomega.BeTrue())
gomega.Expect(res["1982"] == 9).Should(gomega.BeTrue())
Copy link
Member

@bisakhmondal bisakhmondal Mar 26, 2021

Choose a reason for hiding this comment

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

Just a suggestion, we could also use
gomega.Expect(res["1980"]).Should(gomega.Equal(3)) here :)

Copy link
Member Author

Choose a reason for hiding this comment

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

nice suggestions, Thks, fixed.

@Jaycean Jaycean requested a review from imjoey March 26, 2021 16:25
Copy link
Member

@bisakhmondal bisakhmondal left a comment

Choose a reason for hiding this comment

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

💯

Copy link
Member

@juzhiyuan juzhiyuan left a comment

Choose a reason for hiding this comment

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

LGTM

@juzhiyuan juzhiyuan requested a review from gxthrj March 29, 2021 15:10
Copy link
Contributor

@gxthrj gxthrj left a comment

Choose a reason for hiding this comment

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

LGTM

@juzhiyuan juzhiyuan merged commit f7df1b3 into apache:master Apr 1, 2021
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.

feat: use gomega match assertion
7 participants