diff --git a/tests/notificationPosition.test.js b/tests/notificationPosition.test.js index b196700d..8ebe2456 100644 --- a/tests/notificationPosition.test.js +++ b/tests/notificationPosition.test.js @@ -1,5 +1,6 @@ const Application = require('./spectron/spectronSetup'); const path = require('path'); +const {isMac} = require('../js/utils/misc'); let app = new Application({}); describe('Tests for Notification position', () => { @@ -77,7 +78,11 @@ describe('Tests for Notification position', () => { it('should check notification position', () => { return app.browserWindow.getBounds().then((bounds) => { expect(bounds.x === 0).toBeTruthy(); - expect(bounds.y > 0).toBeTruthy(); + if (isMac) { + expect(bounds.y > 0).toBeTruthy(); + } else { + expect(bounds.y === 0).toBeTruthy(); + } }).catch((err) => { expect(err).toBeNull(); }); @@ -157,7 +162,11 @@ describe('Tests for Notification position', () => { it('should check notification position and equal to upper-right', () => { return app.browserWindow.getBounds().then((bounds) => { expect(bounds.x > 0).toBeTruthy(); - expect(bounds.y > 0).toBeTruthy(); + if (isMac) { + expect(bounds.y > 0).toBeTruthy(); + } else { + expect(bounds.y === 0).toBeTruthy(); + } }).catch((err) => { expect(err).toBeNull(); });