Skip to content

Commit

Permalink
Merge pull request #393 from AdamTheisen/crop
Browse files Browse the repository at this point in the history
ENH: Updating for the latest crop information/returns
  • Loading branch information
AdamTheisen authored Feb 18, 2022
2 parents b334aa4 + 9815934 commit eb209ed
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions act/tests/test_discovery.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,18 +11,19 @@

def test_cropType():
year = 2018
lat = 37.1509
lat = 37.15
lon = -98.362
# Try for when the cropscape API is not working
try:
crop = act.discovery.get_cropscape.croptype(lat, lon, year)
crop2 = act.discovery.get_cropscape.croptype(lat, lon)
except Exception:
return

if crop is not None:
assert crop == 'Grass/Pasture'
assert crop == 'Dbl Crop WinWht/Sorghum'
if crop2 is not None:
assert crop2 == 'Soybeans'
assert crop2 == 'Sorghum'


def test_get_ord():
Expand Down

0 comments on commit eb209ed

Please sign in to comment.