diff --git a/src/renderer/pages/torrent-list-page.js b/src/renderer/pages/torrent-list-page.js index 102f9fb2..82933702 100644 --- a/src/renderer/pages/torrent-list-page.js +++ b/src/renderer/pages/torrent-list-page.js @@ -14,7 +14,7 @@ module.exports = class TorrentList extends React.Component { if (state.downloadPathStatus === 'missing') { contents.push(
Download path missing: {state.saved.prefs.downloadPath}
+Download path missing: {state.saved.prefs.downloadPath}
Check that all drives are connected?
Alternatively, choose a new download path in Preferences diff --git a/test/index.js b/test/index.js index c8a4a361..e4ae8af3 100644 --- a/test/index.js +++ b/test/index.js @@ -32,10 +32,12 @@ test('show download path missing', function (t) { .then((text) => console.log('Title ' + text)) .then(() => app.client.waitUntilTextExists('.torrent-list', 'Download path missing')) .then((err) => t.notOk(err)) + .then(() => setup.screenshotCreateOrCompare(app, t, 'torrent-list-download-path-missing')) .then(() => app.client.click('a')) .then(() => setup.wait()) .then(() => app.browserWindow.getTitle()) - .then((windowTitle) => t.equal(windowTitle, 'Preferences')) + .then((windowTitle) => t.equal(windowTitle, 'Preferences', 'window title')) + .then(() => setup.screenshotCreateOrCompare(app, t, 'prefs-basic')) .then(() => setup.endTest(app, t), (err) => setup.endTest(app, t, err || 'error')) }) diff --git a/test/screenshots/darwin/prefs-basic.png b/test/screenshots/darwin/prefs-basic.png new file mode 100644 index 00000000..cf8d4e79 Binary files /dev/null and b/test/screenshots/darwin/prefs-basic.png differ diff --git a/test/screenshots/darwin/torrent-list-download-path-missing.png b/test/screenshots/darwin/torrent-list-download-path-missing.png new file mode 100644 index 00000000..dc01b9d8 Binary files /dev/null and b/test/screenshots/darwin/torrent-list-download-path-missing.png differ diff --git a/test/setup.js b/test/setup.js index 31e5e9b2..e3da57f6 100644 --- a/test/setup.js +++ b/test/setup.js @@ -28,16 +28,19 @@ function createApp (t) { // Starts the app, waits for it to load, returns a promise function waitForLoad (app, t) { return app.start().then(function () { + // Switch to the main window. Index 0 is apparently the hidden webtorrent window... return app.client.windowByIndex(1) }).then(function () { return app.client.waitUntilWindowLoaded() }).then(function () { return app.webContents.getTitle() }).then(function (title) { - t.equal(title, 'WebTorrent Desktop', 'app title') + // Note the window title is WebTorrent (BETA), this is the HTML