From 104cae8f689eddcfab6541f313a36c5731e656f5 Mon Sep 17 00:00:00 2001 From: Kevin Sawicki Date: Wed, 25 Jan 2017 13:52:18 -0800 Subject: [PATCH] Only call getNativeHandle on macOS --- spec/api-native-image-spec.js | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/spec/api-native-image-spec.js b/spec/api-native-image-spec.js index 5ad4946e700..e28b37bebfe 100644 --- a/spec/api-native-image-spec.js +++ b/spec/api-native-image-spec.js @@ -11,12 +11,15 @@ describe('nativeImage module', () => { assert.equal(empty.isEmpty(), true) assert.equal(empty.getAspectRatio(), 1) assert.equal(empty.toDataURL(), 'data:image/png;base64,') - assert.deepEqual(empty.getNativeHandle(), []) - assert.deepEqual(empty.getBitmap(), []) assert.deepEqual(empty.getSize(), {width: 0, height: 0}) + assert.deepEqual(empty.getBitmap(), []) assert.deepEqual(empty.toBitmap(), []) assert.deepEqual(empty.toJPEG(100), []) assert.deepEqual(empty.toPNG(), []) + + if (process.platform === 'darwin') { + assert.deepEqual(empty.getNativeHandle(), []) + } }) })