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

[tests] Fix, removing deprecated function for future Python release compatibility. #8353

Conversation

MarcusSorealheis
Copy link
Contributor

@MarcusSorealheis MarcusSorealheis commented Oct 7, 2019

CATEGORY

Choose one

  • Bug Fix
  • Enhancement (new features, refinement)
  • Refactor
  • Add tests
  • Build / Development Environment
  • Documentation

SUMMARY

Here, I replaced all the occurrences of assertEquals with assertEqual in the test files in anticipation of its removal in future Python releases. The alias has been deprecated for sometime.

BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF

TEST PLAN

run tests.

ADDITIONAL INFORMATION

  • Has associated issue:
  • Changes UI
  • Requires DB Migration.
  • Confirm DB Migration upgrade and downgrade tested.
  • Introduces new feature or API
  • Removes existing feature or API

REVIEWERS

@betodealmeida or someone else that works on tests.

@dpgaspar
Copy link
Member

dpgaspar commented Oct 7, 2019

Extra info on this: https://docs.python.org/3/library/unittest.html#deprecated-aliases

@MarcusSorealheis while your at it, can I ask you to change assertNotEquals also? (found 2 lines)

@codecov-io
Copy link

Codecov Report

Merging #8353 into master will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master    #8353   +/-   ##
=======================================
  Coverage   67.57%   67.57%           
=======================================
  Files         448      448           
  Lines       22529    22529           
  Branches     2363     2363           
=======================================
  Hits        15223    15223           
  Misses       7168     7168           
  Partials      138      138

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 c09e3e7...41d61c8. Read the comment docs.

@MarcusSorealheis
Copy link
Contributor Author

thanks @dpgaspar

@MarcusSorealheis
Copy link
Contributor Author

@dpgaspar does this LGTM?

@MarcusSorealheis
Copy link
Contributor Author

MarcusSorealheis commented Oct 18, 2019

here is where CI failed (which is unrelated to the change):

      Spec                                    Tests  Pass…  Fail…  Pend…  Skip… 
  ┌────────────────────────────────────────────────────────────────────────────┐
  │ ✖ sqllab/index.test.js            00:20      5      2      1      2      - │
  └────────────────────────────────────────────────────────────────────────────┘
    1 of 1 failed (100%)              00:20      5      2      1      2      -  
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] cypress: `cypress "run" "--spec" "cypress/integration/sqllab/*" "--record" "false" "--config" "video=false"`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the [email protected] cypress script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR!     /home/travis/.npm/_logs/2019-10-07T17_16_10_188Z-debug.log
ERROR: InvocationError for command /home/travis/build/apache/incubator-superset/superset/assets/cypress_build.sh sqllab (exited with code 1)
___________________________________ summary ____________________________________
ERROR:   cypress-sqllab: commands failed
The command "tox" exited with 1.

Copy link
Member

@dpgaspar dpgaspar left a comment

Choose a reason for hiding this comment

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

LGTM

@dpgaspar dpgaspar changed the title removing deprecated function for future Python release compatibility. [tests] removing deprecated function for future Python release compatibility. Oct 21, 2019
@dpgaspar dpgaspar changed the title [tests] removing deprecated function for future Python release compatibility. [tests] Fix, removing deprecated function for future Python release compatibility. Oct 21, 2019
@dpgaspar dpgaspar merged commit 4cfd6b3 into apache:master Oct 21, 2019
graceguo-supercat pushed a commit that referenced this pull request Nov 13, 2019
…ompatibility. (#8353)

* removing deprecated function for future Python release compatibility.

* also removed assertNotEquals per @dpgaspar
@mistercrunch mistercrunch added 🏷️ bot A label used by `supersetbot` to keep track of which PR where auto-tagged with release labels 🚢 0.35.0 labels Feb 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🏷️ bot A label used by `supersetbot` to keep track of which PR where auto-tagged with release labels size/XL 🚢 0.35.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants