codeforamerica / OpenTrails

OpenTrails (Open Trail System Specification) Converter & Validator
http://open-trails.herokuapp.com/
39 stars 9 forks source link

Fix for issue 92 #96

Closed jmoe closed 10 years ago

jmoe commented 10 years ago

Added a few tests for Boulder County data that surfaces the bug reported in issue #92. Tests proved issue was in make_name_trails (renamed to make_named_trails). Read up on groupby (https://docs.python.org/2/library/itertools.html#itertools.groupby) and saw "Generally, the iterable needs to already be sorted on the same key function." so added a sort to make_named_trails. Viola. All better now.

alanjosephwilliams commented 10 years ago

Tests pass, all references to the updated function named updated. :thumbsup: