diff options
author | John Firebaugh <john.firebaugh@gmail.com> | 2015-11-18 15:26:43 -0800 |
---|---|---|
committer | John Firebaugh <john.firebaugh@gmail.com> | 2015-11-18 16:53:11 -0800 |
commit | 46a6b03582e465ef90e72f61eee5c97580ea1042 (patch) | |
tree | 76f33255385596c5efbff046f814d04150361325 /platform/node/test | |
parent | f2772309feb394b7caeaea436e13ef45ba86a4e7 (diff) | |
download | qtlocation-mapboxgl-46a6b03582e465ef90e72f61eee5c97580ea1042.tar.gz |
[node] Fix race condition in tests
The message callback races with the rest of this test. We already have
tests for errors being emitted from mbgl, so just remove it.
Diffstat (limited to 'platform/node/test')
-rw-r--r-- | platform/node/test/js/map.test.js | 8 |
1 files changed, 0 insertions, 8 deletions
diff --git a/platform/node/test/js/map.test.js b/platform/node/test/js/map.test.js index 0ccaa4b55e..9c983828ff 100644 --- a/platform/node/test/js/map.test.js +++ b/platform/node/test/js/map.test.js @@ -218,17 +218,9 @@ test('Map', function(t) { }); t.test('returns an error', function(t) { - mbgl.on('message', function(msg) { - t.ok(msg, 'emits error'); - t.equal(msg.class, 'Style'); - t.equal(msg.severity, 'ERROR'); - t.ok(msg.text.match(/Failed to load/), 'error text matches'); - }); - var map = new mbgl.Map(options); map.load(style); map.render({ zoom: 1 }, function(err, data) { - mbgl.removeAllListeners('message'); map.release(); t.ok(err, 'returns error'); |