AdrianFerJ / v2go-api

V2go web app's repo contains client and server apps (django and angular), and infastructure setup for both apps, postgres, redis, and nginx using docker
0 stars 0 forks source link

Hard coded value in test should be dynamic #5

Closed AdrianFerJ closed 5 years ago

AdrianFerJ commented 5 years ago

I hard coded the duration_value (time it takes to get to from A to B) in test_get_top_5_cs_near_poi Class, but this value changes depending on traffic! pretty obvious now that I think about it.

Either make a separate call to Google distance matrix to get the value or remove test

AdrianFerJ commented 5 years ago

Fixed. I removed the test case and created new one. Instead now i checks whether first item has shorter duration_val than second (we expect an ordered list of CS based on duration_val)