Fix bug that was causing google validation warnings to appear over changesets with the approved google africa building dataset.

This commit is contained in:
Benjamin Clark
2021-12-09 12:33:27 -05:00
parent ab8a07fb45
commit 9bfcd56c35
2 changed files with 6 additions and 1 deletions

View File

@@ -17,7 +17,7 @@ export function validationIncompatibleSource() {
{
id: 'google',
regex: /google/i,
exceptRegex: /((books|drive)\.google|google\s?(books|drive|plus))/i
exceptRegex: /((books|drive)\.google|google\s?(books|drive|plus))|(esri\/Google_Africa_Buildings)/i
}
];

View File

@@ -63,4 +63,9 @@ describe('iD.validations.incompatible_source', function () {
expect(issue.entityIds[0]).to.eql('w-1');
});
it('does not flag buildings in the google-africa-buildings dataset', function() {
createWay({ building: 'yes', source: 'esri/Google_Africa_Buildings' });
var issues = validate();
expect(issues).to.have.lengthOf(0);
});
});