jazzband / tablib

Python Module for Tabular Datasets in XLS, CSV, JSON, YAML, &c.
https://tablib.readthedocs.io/
MIT License
4.58k stars 589 forks source link

Upgrade unit tests #520

Closed hugovk closed 2 years ago

hugovk commented 2 years ago

I used https://github.com/isidentical/teyit to upgrade the unit tests to use methods which give more useful error messages upon failure.

codecov[bot] commented 2 years ago

Codecov Report

Merging #520 (f6db2a4) into master (2952ec1) will not change coverage. The diff coverage is 100.00%.

@@           Coverage Diff           @@
##           master     #520   +/-   ##
=======================================
  Coverage   90.84%   90.84%           
=======================================
  Files          28       28           
  Lines        2664     2664           
=======================================
  Hits         2420     2420           
  Misses        244      244           
Impacted Files Coverage Δ
tests/test_tablib.py 98.62% <100.00%> (ø)

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 2952ec1...f6db2a4. Read the comment docs.

hugovk commented 2 years ago

The "pre-commit.ci - pr" check failed because the pre-commit is checking against master instead of a tag here: https://github.com/jazzband/tablib/pull/520/files#diff-63a9c44a44acf85fea213a857769990937107cf072831e1a26808cfde9d096b9R14

We need to use master because the latest tag doesn't have this fix: https://github.com/isidentical/teyit/pull/14

Let's just remove the pre-commit check for now, and can add it back when there's a release.

isidentical commented 2 years ago

I've released 0.4.2 with the changes in the pre-commit hook: https://github.com/isidentical/teyit/releases/tag/0.4.2

hugovk commented 2 years ago

Thanks for the new release!

"pre-commit.ci - pr" now errors because it seems it's running on Python 3.8. I've opened an issue to ask how we can set a Python version at pre-commit.ci: https://github.com/pre-commit-ci/issues/issues/117

hugovk commented 2 years ago

pre-commit.ci now defaults to Python 3.10 and passes: