Turbo87 / utm

Bidirectional UTM-WGS84 converter for python
http://pypi.python.org/pypi/utm
MIT License
486 stars 101 forks source link

Add zone checking when forced #32

Closed paulhovey closed 6 years ago

paulhovey commented 6 years ago

When using force_zone_number or force_zone_letter in from_latlon(), there is no check to make sure the inputs are valid. I broke that into a separate function and added unit tests for that function individually, and in failing cases to from_latlon(). No other tests broke, so it should be working as expected.

codecov[bot] commented 6 years ago

Codecov Report

Merging #32 into master will increase coverage by 1.49%. The diff coverage is 100%.

Impacted file tree graph

@@           Coverage Diff           @@
##           master   #32      +/-   ##
=======================================
+ Coverage    93.5%   95%   +1.49%     
=======================================
  Files           3     3              
  Lines         154   160       +6     
=======================================
+ Hits          144   152       +8     
+ Misses         10     8       -2
Impacted Files Coverage Δ
utm/__init__.py 100% <100%> (ø) :arrow_up:
utm/conversion.py 94.87% <100%> (+1.53%) :arrow_up:

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 81883cc...3ae04b2. Read the comment docs.

Turbo87 commented 6 years ago

Nice work, thanks @paulhovey!