From 67f33cdb60fa09e9a1373419df4ec8a5e7fe089b Mon Sep 17 00:00:00 2001 From: Samuel Attard Date: Tue, 22 Nov 2016 15:49:47 +1100 Subject: [PATCH] Add failing spec for window size after restore --- spec/api-browser-window-spec.js | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/spec/api-browser-window-spec.js b/spec/api-browser-window-spec.js index a0425d7ffc..83a9ed8d49 100644 --- a/spec/api-browser-window-spec.js +++ b/spec/api-browser-window-spec.js @@ -1754,6 +1754,25 @@ describe('browser-window module', function () { }) }) }) + + describe.only('minWidth', function () { + beforeEach(function () { + if (w != null) w.destroy() + w = new BrowserWindow({ + minWidth: 800, + width: 800 + }) + }) + + it('should persist when restoring the window', function (done) { + w.minimize(); + setTimeout(() => { + w.restore(); + assert.equal(w.getSize()[0], 800); + done(); + }, 200); + }) + }) }) const assertBoundsEqual = (actual, expect) => {