Commit Graph

115 Commits

Author SHA1 Message Date
Quincy Morgan
0d5bd8b277 Store selected mapillary image by its key rather than its object
Properly sort selected mapillary signs and features above unselected ones
2019-12-11 17:15:36 -05:00
Bryan Housel
392a242c02 Upgrade to eslint v6.0.0
(closes #6567)
2019-06-29 11:35:57 -04:00
Quincy Morgan
1ed73b6531 Convert validation rules to validate against a specific graph, not always the current graph (re: #6459) 2019-06-06 16:27:31 -04:00
Bryan Housel
1c97e29b5d No idea why this test keeps failing.. 2019-05-19 22:55:41 -04:00
Bryan Housel
d68c49e66d Async tests running on dodgy Travis containers are not my friends
(closes #6391)

Default timeout of 2000 regularly exceeded, causing spurious test failures.
Even a random garbage collection pause can take more than 2 seconds.
2019-05-19 21:35:16 -04:00
SilentSpike
5af7e86ef4 Fix findIssues test for dynamic issue messages 2019-05-07 20:43:27 +01:00
Quincy Morgan
26f1e29072 Merge branch 'master' into ignoring-issues
# Conflicts:
#	data/core.yaml
#	dist/locales/en.json
2019-04-30 13:05:07 -07:00
Bryan Housel
0a4e2c03a3 Extend timeouts on slow async mapillary tests
Trying to avoid false test failures.  Default timeout is 2sec, and we can't
be sure slow async tests will finish in that time esp. in a CI environment
2019-04-30 09:59:51 -04:00
Quincy Morgan
375779882d Add ability to ignore warnings
Replace issue's array of entities with array of entity IDs
Improve issue ID hashing
2019-04-29 17:52:32 -07:00
Bryan Housel
e981cd5dd5 Switch mapillary and openstreetcam tests to work async
- can't reliably use sinon.spy to tell whether a thing has been called,
  so we listen for events instead and check server.requests()
- make sure to request the next page before dispatching `loadedImages` so
  we can `server.respond()` to the request in the event handler if we want to
- also moves `localeDateString` in the openstreetcam service from parsing
  code to display code, because it's very slow (we can just do this for the
  images we look at, instead of all images we fetch)
2019-04-29 15:31:08 -04:00
Bryan Housel
452eb8b43a Bump timeouts on streetlevel loadimage-type tests
This isn't perfect but might avoid spurious test failures.
2019-04-27 17:41:58 -04:00
Bryan Housel
d0452e6be4 Convert fakeServer tests to use fakeFetch
- Many text expects are now wrapped in setTimeout, as the fetch
  promises settle async now.
- This makes the tests somewhat brittle, and we should maybe consider
  reworking some of them. For example it is very hard to perform
  a test like `expect(spy).to.have.not.been.called` in an async way.
  (We could instead inspect the fakeServer requests() to know this.)
- Also includes some trickery for osm.js, which uses d3-xml (fetch)
  now for unauthenticated calls and osmauth (xhr) for authenticated calls
2019-04-26 22:29:48 -04:00
Bryan Housel
36d1f3701f Allow osm service tests to work with deferred parsing 2019-04-12 12:11:35 -04:00
Bryan Housel
e30090996b Add loadTileAtLoc to fetch data tile for a specific location
(closes #4890)

This lets iD request needed tiles outside of the viewport, for example to
properly straighten lines or validate features that may have unloaded
connections.
2019-04-09 23:49:31 -04:00
Bryan Housel
2660a8554b Add isDataLoaded and tilecache rtree for testing
(re: #2248, #5938, maybe others)
2019-04-08 15:59:42 -04:00
Quincy Morgan
1564f73de6 Merge branch 'master' into validation 2019-02-07 20:51:21 -05:00
Bryan Housel
492bb5b37e Eliminate magic scale numbers from tests, add loadNotes test xml 2019-02-07 11:31:32 -05:00
Quincy Morgan
09bc2a6e6c Merge branch 'master' into validation 2019-01-30 16:44:14 -05:00
Bryan Housel
71b2d2c6b7 Upgrade legacy symbols in tests
- iD.Context -> iD.coreContext
- iD.Graph -> iD.coreGraph
- iD.Node -> iD.osmNode
- iD.Way -> iD.osmWay
- iD.Relation -> iD.osmRelation
2019-01-30 15:43:02 -05:00
Bryan Housel
7138acc652 Properly export areaKeys, fix preset and maprules tests 2019-01-30 15:29:37 -05:00
Quincy Morgan
e69f2a0389 Merge branch 'master' into validation 2019-01-23 13:15:33 -05:00
Yuri Astrakhan
d724677c9f Support extracting wiki info from tag and key 2019-01-15 21:50:57 -05:00
Quincy Morgan
11b2102761 Merge branch 'master' into validation
# Conflicts:
#	data/core.yaml
#	dist/locales/en.json
#	modules/ui/commit_warnings.js
#	modules/ui/entity_editor.js
#	modules/util/index.js
#	modules/util/util.js
#	modules/validations/index.js
#	modules/validations/many_deletions.js
#	modules/validations/missing_tag.js
2019-01-14 10:13:56 -05:00
Yuri Astrakhan
9f7f4aa3fc Fix language fallback processing, caching bug. 2018-12-23 01:57:26 -05:00
Yuri Astrakhan
aa78cd10a3 Data items - remove hardcoded locale IDs
Locale IDs are now fetched together with the other data
when the language code is provided.
2018-12-22 14:58:15 -05:00
Yuri Astrakhan
b2810105a5 Implement support for multilingual descriptions from wiki data items
* Takes data directly from the Wikibase data items (OSM Wiki)
     https://wiki.openstreetmap.org/wiki/OpenStreetMap:Data_Items
* Understands the difference in regions - e.g. will show different
  images depending on the local settings
* Perf: Single request will get both the tag and key description
2018-12-22 00:23:31 -05:00
Bryan Housel
22e36be4f2 WIP on replacing documentation with direct calls to OSM wikibase 2018-12-22 00:23:31 -05:00
Andrew Wong
0e34313d1d fixed maprules test 2018-12-19 13:38:21 -05:00
Andrew Wong
6ae25eada7 fixing tests around issues 2018-12-19 13:34:16 -05:00
Bryan Housel
5a2049b421 Drop extra whitespace, make sure service exists before using it 2018-12-18 15:38:53 -05:00
Max Grossman
6ba8bacb75 use severity in test 2018-12-18 10:27:15 -05:00
Max Grossman
64f2d913e8 remove unused entities from test 2018-12-17 17:39:47 -05:00
Max Grossman
8f33a85a12 make collection.index function to handle failing tests 2018-12-17 17:16:10 -05:00
Max Grossman
96e44be69c merge 2.12.2 2018-12-13 11:22:32 -05:00
J Guthrie
a23c975232 Fix specs 2018-11-24 21:27:20 +00:00
Bryan Housel
1731ce4651 Partition viewport by tiles, not by pixels
(closes #4297)

The previous approach split the viewport up by pixels, but each time the view
moved, the pixels would change, so it was not a stable selection of the
streetview data, and the markers would fight for position as the user moved
around.

This approach uses utilTiler to partition the view into stable tiles.
2018-11-14 14:48:42 -05:00
Bryan Housel
b7df3eda38 Use new Mapillary API calls for map_features, image_detections
(closes #5374)
2018-11-07 23:09:11 -05:00
Bryan Housel
a29af100df Remove test for unpopular values with a wiki page,
Restore test for unpopular keys with a wiki page
2018-11-07 11:06:48 -05:00
Mateusz Konieczny
e285066032 invert tests for inverted behavior 2018-11-03 15:07:37 +01:00
Mateusz Konieczny
bb054211c0 fix missing negation is specs 2018-11-03 14:26:52 +01:00
Bryan Housel
4cd442e09d Restore mapillary.js line endings back from CRLF -> CR, fix tests 2018-10-11 13:58:57 -04:00
Bryan Housel
0353b3110d Fix parse error in testing osm.js 2018-10-11 13:58:57 -04:00
Max Grossman
622b7b9e0c move validations to its own class
ref #remote-presets
2018-10-01 21:45:21 -04:00
Thomas Hervey
26f045b16c added/updated service/osm, osm/note, mode/add_note tests 2018-07-23 16:17:48 -04:00
Thomas Hervey
7ad765d408 added simple tests for loading and retrieving notes 2018-07-16 10:54:40 -04:00
Thomas Hervey
bd1586500e added tests for notes service 2018-07-13 15:01:43 -04:00
Bryan Housel
535208beb5 Move tests to spec/services/osm.js and remove old notes.js files 2018-07-01 23:35:10 -04:00
Bryan Housel
9517635d4d Merge branch 'master' into notes 2018-06-29 21:54:24 -04:00
Bryan Housel
3943364852 Merge pull request #5106 from openstreetmap/remove_test_user_mocks
removed: user mocks from image service test specs
2018-06-26 21:11:23 -04:00
Thomas Hervey
dab46d2778 updated: notes rendering 2018-06-22 17:43:07 -04:00