Browse Source

Fix low hanging fruit in ciao tests

Quite a few of our tests simply had old error messages as expectations,
or expected output in an array that was correct but in the wrong order.
Those are all fixed.
pull/330/head
Julian Simioni 9 years ago
parent
commit
ab006054f8
  1. 4
      test/ciao/autocomplete/focus_point_missing_lat.coffee
  2. 4
      test/ciao/autocomplete/focus_point_missing_lon.coffee
  3. 4
      test/ciao/reverse/point_missing_lat.coffee
  4. 4
      test/ciao/reverse/point_missing_lon.coffee
  5. 2
      test/ciao/reverse/sources_multiple.coffee
  6. 2
      test/ciao/reverse/sources_single.coffee
  7. 4
      test/ciao/search/boundary_circle_missing_lat.coffee
  8. 4
      test/ciao/search/boundary_circle_missing_lon.coffee
  9. 4
      test/ciao/search/boundary_rect_partially_specified.coffee
  10. 4
      test/ciao/search/focus_point_missing_lat.coffee
  11. 4
      test/ciao/search/focus_point_missing_lon.coffee
  12. 2
      test/ciao/search/sources_multiple.coffee
  13. 2
      test/ciao/search/sources_single.coffee

4
test/ciao/autocomplete/focus_point_missing_lat.coffee

@ -24,7 +24,7 @@ json.features.should.be.instanceof Array
#? expected errors
should.exist json.geocoding.errors
json.geocoding.errors.should.eql [ 'missing point param \'focus.point\' requires all of: \'lat\',\'lon\' to be present' ]
json.geocoding.errors.should.eql [ 'parameters focus.point.lat and focus.point.lon must both be specified' ]
#? expected warnings
should.not.exist json.geocoding.warnings
@ -33,4 +33,4 @@ should.not.exist json.geocoding.warnings
json.geocoding.query['text'].should.eql 'a'
json.geocoding.query['size'].should.eql 10
should.not.exist json.geocoding.query['focus.point.lat']
should.not.exist json.geocoding.query['focus.point.lon']
should.not.exist json.geocoding.query['focus.point.lon']

4
test/ciao/autocomplete/focus_point_missing_lon.coffee

@ -24,7 +24,7 @@ json.features.should.be.instanceof Array
#? expected errors
should.exist json.geocoding.errors
json.geocoding.errors.should.eql [ 'missing point param \'focus.point\' requires all of: \'lat\',\'lon\' to be present' ]
json.geocoding.errors.should.eql [ 'parameters focus.point.lat and focus.point.lon must both be specified' ]
#? expected warnings
should.not.exist json.geocoding.warnings
@ -33,4 +33,4 @@ should.not.exist json.geocoding.warnings
json.geocoding.query['text'].should.eql 'a'
json.geocoding.query['size'].should.eql 10
should.not.exist json.geocoding.query['focus.point.lat']
should.not.exist json.geocoding.query['focus.point.lon']
should.not.exist json.geocoding.query['focus.point.lon']

4
test/ciao/reverse/point_missing_lat.coffee

@ -24,7 +24,7 @@ json.features.should.be.instanceof Array
#? expected errors
should.exist json.geocoding.errors
json.geocoding.errors.should.eql [ 'missing point param \'point\' requires all of: \'lat\',\'lon\' to be present' ]
json.geocoding.errors.should.eql [ 'parameters point.lat and point.lon must both be specified' ]
#? expected warnings
should.not.exist json.geocoding.warnings
@ -32,4 +32,4 @@ should.not.exist json.geocoding.warnings
#? inputs
json.geocoding.query['size'].should.eql 10
should.not.exist json.geocoding.query['point.lat']
should.not.exist json.geocoding.query['point.lon']
should.not.exist json.geocoding.query['point.lon']

4
test/ciao/reverse/point_missing_lon.coffee

@ -24,7 +24,7 @@ json.features.should.be.instanceof Array
#? expected errors
should.exist json.geocoding.errors
json.geocoding.errors.should.eql [ 'missing point param \'point\' requires all of: \'lat\',\'lon\' to be present' ]
json.geocoding.errors.should.eql [ 'parameters point.lat and point.lon must both be specified' ]
#? expected warnings
should.not.exist json.geocoding.warnings
@ -32,4 +32,4 @@ should.not.exist json.geocoding.warnings
#? inputs
json.geocoding.query['size'].should.eql 10
should.not.exist json.geocoding.query['point.lat']
should.not.exist json.geocoding.query['point.lon']
should.not.exist json.geocoding.query['point.lon']

2
test/ciao/reverse/sources_multiple.coffee

@ -31,4 +31,4 @@ should.not.exist json.geocoding.warnings
#? inputs
json.geocoding.query['size'].should.eql 10
json.geocoding.query.types['from_sources'].should.eql ["osmaddress","osmnode","osmway","geoname"]
json.geocoding.query['type'].should.eql ["osmaddress","osmnode","osmway","geoname"]
json.geocoding.query['type'].should.eql ["geoname","osmnode","osmway","osmaddress"]

2
test/ciao/reverse/sources_single.coffee

@ -31,4 +31,4 @@ should.not.exist json.geocoding.warnings
#? inputs
json.geocoding.query['size'].should.eql 10
json.geocoding.query.types['from_sources'].should.eql ["osmaddress","osmnode","osmway"]
json.geocoding.query['type'].should.eql ["osmaddress","osmnode","osmway"]
json.geocoding.query['type'].should.eql ["osmnode","osmway","osmaddress"]

4
test/ciao/search/boundary_circle_missing_lat.coffee

@ -24,7 +24,7 @@ json.features.should.be.instanceof Array
#? expected errors
should.exist json.geocoding.errors
json.geocoding.errors.should.eql [ 'missing circle param \'boundary.circle\' requires all of: \'lat\',\'lon\' to be present' ]
json.geocoding.errors.should.eql [ 'parameters boundary.circle.lat and boundary.circle.lon must both be specified' ]
#? expected warnings
should.not.exist json.geocoding.warnings
@ -34,4 +34,4 @@ json.geocoding.query['text'].should.eql 'a'
json.geocoding.query['size'].should.eql 10
should.not.exist json.geocoding.query['boundary.circle.lat']
should.not.exist json.geocoding.query['boundary.circle.lon']
should.not.exist json.geocoding.query['boundary.circle.radius']
should.not.exist json.geocoding.query['boundary.circle.radius']

4
test/ciao/search/boundary_circle_missing_lon.coffee

@ -24,7 +24,7 @@ json.features.should.be.instanceof Array
#? expected errors
should.exist json.geocoding.errors
json.geocoding.errors.should.eql [ 'missing circle param \'boundary.circle\' requires all of: \'lat\',\'lon\' to be present' ]
json.geocoding.errors.should.eql [ 'parameters boundary.circle.lat and boundary.circle.lon must both be specified' ]
#? expected warnings
should.not.exist json.geocoding.warnings
@ -34,4 +34,4 @@ json.geocoding.query['text'].should.eql 'a'
json.geocoding.query['size'].should.eql 10
should.not.exist json.geocoding.query['boundary.circle.lat']
should.not.exist json.geocoding.query['boundary.circle.lon']
should.not.exist json.geocoding.query['boundary.circle.radius']
should.not.exist json.geocoding.query['boundary.circle.radius']

4
test/ciao/search/boundary_rect_partially_specified.coffee

@ -24,7 +24,7 @@ json.features.should.be.instanceof Array
#? expected errors
should.exist json.geocoding.errors
json.geocoding.errors.should.eql [ 'missing rect param \'boundary.rect\' requires all of: \'min_lat\',\'max_lat\',\'min_lon\',\'max_lon\' to be present' ]
json.geocoding.errors.should.eql [ 'parameters boundary.rect.min_lat, boundary.rect.max_lat, boundary.rect.min_lon and boundary.rect.max_lon must all be specified' ]
#? expected warnings
should.not.exist json.geocoding.warnings
@ -35,4 +35,4 @@ json.geocoding.query['size'].should.eql 10
should.not.exist json.geocoding.query['boundary.rect.min_lat']
should.not.exist json.geocoding.query['boundary.rect.max_lat']
should.not.exist json.geocoding.query['boundary.rect.min_lon']
should.not.exist json.geocoding.query['boundary.rect.max_lon']
should.not.exist json.geocoding.query['boundary.rect.max_lon']

4
test/ciao/search/focus_point_missing_lat.coffee

@ -24,7 +24,7 @@ json.features.should.be.instanceof Array
#? expected errors
should.exist json.geocoding.errors
json.geocoding.errors.should.eql [ 'missing point param \'focus.point\' requires all of: \'lat\',\'lon\' to be present' ]
json.geocoding.errors.should.eql [ 'parameters focus.point.lat and focus.point.lon must both be specified' ]
#? expected warnings
should.not.exist json.geocoding.warnings
@ -33,4 +33,4 @@ should.not.exist json.geocoding.warnings
json.geocoding.query['text'].should.eql 'a'
json.geocoding.query['size'].should.eql 10
should.not.exist json.geocoding.query['focus.point.lat']
should.not.exist json.geocoding.query['focus.point.lon']
should.not.exist json.geocoding.query['focus.point.lon']

4
test/ciao/search/focus_point_missing_lon.coffee

@ -24,7 +24,7 @@ json.features.should.be.instanceof Array
#? expected errors
should.exist json.geocoding.errors
json.geocoding.errors.should.eql [ 'missing point param \'focus.point\' requires all of: \'lat\',\'lon\' to be present' ]
json.geocoding.errors.should.eql [ 'parameters focus.point.lat and focus.point.lon must both be specified' ]
#? expected warnings
should.not.exist json.geocoding.warnings
@ -33,4 +33,4 @@ should.not.exist json.geocoding.warnings
json.geocoding.query['text'].should.eql 'a'
json.geocoding.query['size'].should.eql 10
should.not.exist json.geocoding.query['focus.point.lat']
should.not.exist json.geocoding.query['focus.point.lon']
should.not.exist json.geocoding.query['focus.point.lon']

2
test/ciao/search/sources_multiple.coffee

@ -32,4 +32,4 @@ should.not.exist json.geocoding.warnings
json.geocoding.query['text'].should.eql 'a'
json.geocoding.query['size'].should.eql 10
json.geocoding.query.types['from_sources'].should.eql ["osmaddress","osmnode","osmway","geoname"]
json.geocoding.query['type'].should.eql ["osmaddress","osmnode","osmway","geoname"]
json.geocoding.query['type'].should.eql ["geoname","osmnode","osmway","osmaddress"]

2
test/ciao/search/sources_single.coffee

@ -32,4 +32,4 @@ should.not.exist json.geocoding.warnings
json.geocoding.query['text'].should.eql 'a'
json.geocoding.query['size'].should.eql 10
json.geocoding.query.types['from_sources'].should.eql ["osmaddress","osmnode","osmway"]
json.geocoding.query['type'].should.eql ["osmaddress","osmnode","osmway"]
json.geocoding.query['type'].should.eql ["osmnode","osmway","osmaddress"]

Loading…
Cancel
Save