Require init() call before coreContext starts doing things

(closes #7304)
This commit is contained in:
Bryan Housel
2020-01-29 19:27:12 -05:00
parent fb4d658860
commit e19bcb77d5
45 changed files with 182 additions and 178 deletions
+1 -1
View File
@@ -66,7 +66,7 @@ describe('uiCombobox', function() {
beforeEach(function() {
body = d3.select('body');
container = body.append('div').attr('class', 'id-container');
context = iD.coreContext().container(container);
context = iD.coreContext().container(container).init();
content = container.append('div');
input = content.append('input');
combobox = iD.uiCombobox(context);
+1 -1
View File
@@ -2,7 +2,7 @@ describe('iD.uiFieldAccess', function() {
var context, selection, field;
beforeEach(function() {
context = iD.coreContext();
context = iD.coreContext().init();
selection = d3.select(document.createElement('div'));
field = iD.presetField('access', {
keys: ['access', 'foot', 'motor_vehicle', 'bicycle', 'horse'],
+1 -1
View File
@@ -15,7 +15,7 @@ describe('iD.uiFieldLocalized', function() {
});
beforeEach(function() {
context = iD.coreContext();
context = iD.coreContext().init();
selection = d3.select(document.createElement('div'));
field = iD.presetField('name', { key: 'name', type: 'localized' });
field.locked = function() { return false; };
+1 -1
View File
@@ -51,7 +51,7 @@ describe('iD.uiFieldWikipedia', function() {
beforeEach(function() {
entity = iD.osmNode({id: 'n12345'});
context = iD.coreContext();
context = iD.coreContext().init();
context.history().merge([entity]);
selection = d3.select(document.createElement('div'));
field = iD.presetField('wikipedia', {
+1 -1
View File
@@ -16,7 +16,7 @@ describe('iD.uiRawTagEditor', function() {
beforeEach(function () {
entity = iD.osmNode({id: 'n12345'});
context = iD.coreContext();
context = iD.coreContext().init();
context.history().merge([entity]);
render({highway: 'residential'});
});