Bryan Housel
a85bad8c8c
Restructure lane data (cherry pick)
2016-07-31 23:53:07 -04:00
Bryan Housel
7ca6d06254
Replace iD global with iD.Context() module ( #3254 )
2016-07-19 10:15:32 -04:00
Kushan Joshi
d130456393
make lane test lint free
2016-06-22 16:11:47 -04:00
Kushan Joshi
aa829ddf4d
Lanes forward backward tests
2016-06-22 16:11:47 -04:00
Kushan Joshi
07827e5a2d
Adding test case for lanes().default
2016-06-22 16:11:47 -04:00
Bryan Housel
9f1fff0828
Eliminate unused var lint warnings from tests
2016-06-15 10:30:06 -04:00
Kushan Joshi
6c542505a4
Add linting to spec/core
2016-06-15 18:26:11 +05:30
Bryan Housel
9c1e9c9b11
Explicitly test all the highway types for onewayness
2016-06-13 10:56:52 -04:00
Kushan Joshi
6ef52256f3
Migrating to lodash v4
2016-05-17 12:37:25 +05:30
Bryan Housel
c79c65fb39
Reinsert parentRelations of modified parentWays
...
(closes #3008 )
2016-02-29 23:09:24 -05:00
John Firebaugh
a85361545d
Preserve connectivity when pasting
...
Fixes #2584
2016-02-29 12:09:14 -05:00
John Firebaugh
0d2a742e18
Autocomplete changeset comments from previous changeset comments
...
Fixes #2002
2016-01-24 12:46:26 -08:00
Gregor MacLennan
facffcfc39
Correct iD.Way test to use Way() not Entity()
2015-10-27 12:18:05 -06:00
Martin Raifer
d7d3bb4cf8
update tests to reflect changes in dd32ec39
...
(The version attribute of the osmChange XML should read `0.6`)
2015-09-05 16:50:13 +02:00
Corey Farwell
56708858fb
Use HTTPS if location protocol is HTTPS in iD.Connection
...
Relevant to https://github.com/strava/iD/issues/5#issuecomment-109800372
2015-06-27 14:06:58 -07:00
Bryan Housel
728036be51
Don't write unsavable changes to localStorage ( closes #2705 )
2015-06-20 12:21:29 -04:00
Bryan Housel
f4d93c442e
Add connection#loadEntityVersion to fetch specific version
2015-06-18 11:46:43 -04:00
John Firebaugh
f8a68c879f
Adjust tree for force-rebased entities
...
Previously, entities that already existed in the rtree prior to the rebase
option would end up duplicated in the tree afterward.
Fixes #2637
2015-05-09 14:38:41 -07:00
Bryan Housel
7adb0ddbfb
Smarter revert of new entities, more tests
...
re: #2611 , #537
2015-04-29 22:47:07 -04:00
Bryan Housel
ca02cf4b96
Graph#revert accept id instead of entity ref
...
trivial test cases (revert across create/update/delete) all pass
2015-04-28 11:22:46 -04:00
Bryan Housel
587d1451be
More tests for Graph#revert (reverting new things should remove them)
2015-04-27 12:02:59 -04:00
Bryan Housel
6b18066dd6
Graph#revert (see #537 )
2015-04-26 01:07:48 -04:00
Bryan Housel
55c4fce55f
Merge pull request #2516 from bhousel/zorrofix
...
Avoid zorroing connected ways when moving a way
2015-03-20 22:30:34 -04:00
Bryan Housel
56449bc589
Pend some failing tests
...
They should work but they don't. No idea why. PhantomJS issue?
2015-03-03 21:06:28 -05:00
Bryan Housel
cb0e8ab66c
Initial support for Multi Fetch GET
...
It will also be much faster to fetch the remote entities in batches
rather than one at a time through LoadEntity.
One bonus/hazard with Multi Fetch GET is that it will get deleted entities
with `visible=false`, rather than returning a HTTP Status Code 410 (Gone).
This will be the only way that we can really do proper undeletion
(Incrementing the current version by 1 is not guaranteed to work. And
if a way is moved, fetching way/full will tell us whether the childnodes
are part of the way, but not necessarily whether they exist or not.)
We must be careful never to merge deleted entities into the real graph.
e.g, a deleted node will not have a 'loc' attribute, so code that assumes
every node must have a `loc` will be broken.
So because deleted entities are very special, the output from `loadMultiple`
should only be used for conflict resolution for now.
2015-03-03 20:54:09 -05:00
samanpwbb
d141827c3e
Merge branch 'master' into conflict-resolution-ui
2015-02-06 19:08:50 -05:00
Bryan Housel
147e369c3b
Add graph#overwrite (same as pop followed by perform)
...
to remove some of the overhead in creating difference and dispatching
change event multiple times..
2015-02-02 22:01:49 -05:00
Bryan Housel
ed4929273d
Return entities from iD.Connection via callbacks
...
(instead of dispatching `load` event to merge them into `history`)
This is cleaner becuase now `context` doesn't need to keep an
`altGraph` state used only for Conflict Resolution.
The conflict resolution code calls the `iD.Connection` methods directly,
and other places in the code call `loadEntity` and `loadTiles` wrappers
that merge the entities into the main history.
2015-01-08 14:44:58 -05:00
Bryan Housel
d9f204cf45
Remove Graph#freeze
2015-01-07 11:52:17 -05:00
Bryan Housel
90147b23db
Make copy handle circular and other degenerate Relations
2015-01-04 23:15:47 -05:00
Bryan Housel
f6d144c151
Improvements, and simplify code
...
* don't worry about deep copying, because immutability
* don't need `attrs` parameter which is usually empty
* don't worry about resetting `v` entity version
2015-01-01 22:49:44 -05:00
Bryan Housel
dae0d2d55e
Add entity copy methods
2014-12-28 22:00:55 -05:00
Bryan Housel
d85da08cfe
fix "inherits entities from base prototypally" test
2014-12-10 00:11:09 -05:00
Bryan Housel
1c3d198b96
add force option for rebase to overwrite existing entities
...
related: openstreetmap/iD#2467
2014-12-04 19:50:32 -05:00
Bryan Housel
1f544e883b
bump chai to 1.9.2 and fix tests affected by change in equality testing
...
re #2388
2014-10-28 21:37:04 -04:00
John Firebaugh
e0020c37e2
Add test for #2421
2014-10-24 10:34:39 -07:00
John Firebaugh
a7fb35663c
Optimize Way#area
2014-10-13 16:46:32 -07:00
Bryan Housel
0c5f563a26
add test for iD.Entity.layer(), fix spelling of man_made.
2014-06-09 23:39:16 -04:00
John Firebaugh
0c09871c4a
Don’t show turn restriction editor for non-highways ( fixes #2240 )
2014-05-27 14:35:57 -07:00
Bryan Housel
b8501bcf89
iD.Way.isOneWay should return false if oneway=no #2220
...
i.e. overrides implied oneway tag like `highway=motorway` or `junction=roundabout`
2014-05-20 00:14:23 -04:00
Bryan Housel
d245121b19
Fix isConvex() to correctly test the angle that closes the way.
2014-04-23 14:12:20 -04:00
Bryan Housel
a2331f8c93
Add tests for iD.geo.cross and iD.way.isConvex
2014-04-15 00:26:53 -04:00
John Firebaugh
2ab9239a9f
More accurate modification tests
2014-02-25 10:12:34 -08:00
tyr
efd3223e0c
extend history loading fix to deletions
...
Deleted objects need to be kept in the base of the history stack, too.
This also improves the respective unit tests.
2014-02-22 14:09:17 +01:00
tyr
86c4bc9105
add tests for "restoring from v3 JSON" (core/history.js)
2014-02-21 10:19:36 +01:00
tyr
fc0a15e6c4
fix duplicate objects after restoring data from localStorage
...
This makes sure that the originals of changed entities get merged
into the base of the stack after restoring the data from JSON.
This is necessary, because the stack will only have elements for
the current viewport after a restart and previously *modified*
objects will now be falsely detected as *created* ones.
Also removed some ineffective code.
2014-02-21 10:01:26 +01:00
tyr
b71c98cfca
protect against relation loops, part 2. fixes #2096
2014-01-10 11:12:10 +01:00
John Firebaugh
1561c366be
Update OSM.org links
2014-01-08 16:29:00 -08:00
John Firebaugh
ab8a4ffd7b
Update GitHub links
2014-01-08 16:14:28 -08:00
John Firebaugh
4bf21cbc8a
Restore deleted nodes that are discovered to have extant parents
...
This bug has existed since 1.0!
Fixes #2085
2014-01-06 16:23:15 -08:00