Skip to content

[tests] migrate to unittest.assertEqual #10670

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

Merged
merged 1 commit into from
Jul 4, 2025

Conversation

emmanuel-ferdman
Copy link
Contributor

Before submitting

  • Lint code. If there are lint issues, please format the code first.
# Install and register `pre-commit` in the project folder
pip install pre-commit && pre-commit install

# Process previous code files separately
pre-commit run --file XXXX.py
  • Add test cases into tests folder. If there are codecov issues, please add tests cases first.

PR types

Refactoring

PR changes

Tests

Description

This small PR migrates from unittest.assertEquals to unittest.assertEqual which is deprecated from Python2.7:

DeprecationWarning: Please use assertEqual instead.

Copy link

paddle-bot bot commented May 28, 2025

Thanks for your contribution!

@luotao1 luotao1 added the HappyOpenSource 快乐开源活动issue与PR label May 29, 2025
@luotao1 luotao1 assigned luotao1 and ZHUI and unassigned wawltor May 29, 2025
Copy link
Collaborator

@ZHUI ZHUI left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link

codecov bot commented Jun 29, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 46.77%. Comparing base (c309aa7) to head (42a7825).
Report is 58 commits behind head on develop.

❌ Your project status has failed because the head coverage (46.77%) is below the target coverage (58.00%). You can increase the head coverage or adjust the target coverage.

Additional details and impacted files
@@             Coverage Diff             @@
##           develop   #10670      +/-   ##
===========================================
- Coverage    46.91%   46.77%   -0.14%     
===========================================
  Files          799      802       +3     
  Lines       132457   133646    +1189     
===========================================
+ Hits         62136    62508     +372     
- Misses       70321    71138     +817     

☔ 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.

@luotao1 luotao1 merged commit 9db95ee into PaddlePaddle:develop Jul 4, 2025
11 of 15 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
contributor HappyOpenSource 快乐开源活动issue与PR
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants