179 Commits

Author SHA1 Message Date
Quincy Morgan
9510578107 Merge branch 'mapillary-update' into develop
# Conflicts:
#	modules/services/mapillary.js
#	modules/svg/mapillary_map_features.js
#	modules/svg/mapillary_signs.js
2020-09-13 16:34:25 -04:00
Quincy Morgan
03ca12741f Make imageryBlocklists return regex objects instead of strings
Fix performance bug due to checking background source blocks too often
2020-09-04 10:09:47 -04:00
Quincy Morgan
a72a2bb860 Hide background sources from the list if they're blocked (close #7905) 2020-09-03 12:30:59 -04:00
Nikola Plesa
8993cd2a29 fix: update unit tests 2020-08-07 12:48:51 +02:00
Nikola Plesa
fe1aabbf31 fix: unit tests 2020-08-03 14:08:10 +02:00
Nikola Plesa
6a8215d43e Fix unit tests 2020-07-27 10:05:03 +02:00
Nikola Plesa
22bc5121a4 feat: date and username filtering for photo overlay layers 2020-07-27 09:42:59 +02:00
Nikola Plesa
d106dee0c6 feat: date and username filtering for photo overlay layers 2020-07-23 13:28:19 +02:00
Peter Newman
2c47a11008 Fix the seemingly safe spellings found by codespell
Untested, only checked by inspection.
2020-06-28 23:06:44 +01:00
Quincy Morgan
a7ce956e1f Don't use global selectors in street-level photo services (re: #7445) 2020-03-29 11:04:38 -07:00
Quincy Morgan
1e820b6980 Convert OSM API tests to simulate JSON responses (re: #7188) 2020-03-12 16:45:08 -07:00
Bryan Housel
dc7fba4bf8 Have utilStringQs advance past any leading '?' or '#' characters
This lets us remove a bunch of substring(1) and +1 from the code.
2020-02-20 17:09:54 -05:00
Bryan Housel
0fe766d9a4 WIP on external presets
- preset data is no longer bundled into iD.js
- some code pathways commented out re: external presets
- many changes so that tests can run without presets at start, or async
- still need to make sure fallbacks are always there (point, line, area, etc)
2020-02-05 09:38:26 -05:00
Bryan Housel
e19bcb77d5 Require init() call before coreContext starts doing things
(closes #7304)
2020-01-29 19:27:12 -05:00
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