From a1b5766a71aa64abe7ec2c98a5fd88db255eae8e Mon Sep 17 00:00:00 2001 From: Benedict Aas Date: Mon, 16 Apr 2018 20:11:44 +0100 Subject: [PATCH] minifeat(GUI): prefix multiple devices label with quantity (#2204) Change the `Multiple Devices (n)` label on selected devices to a quantity-prefixed form `n Devices`. Change-Type: patch --- lib/gui/app/pages/main/controllers/drive-selection.js | 2 +- tests/gui/pages/main.spec.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/gui/app/pages/main/controllers/drive-selection.js b/lib/gui/app/pages/main/controllers/drive-selection.js index f4b039cc..fae90cf6 100644 --- a/lib/gui/app/pages/main/controllers/drive-selection.js +++ b/lib/gui/app/pages/main/controllers/drive-selection.js @@ -42,7 +42,7 @@ module.exports = function (DriveSelectorService) { return _.head(drives).description } - return `Multiple Devices (${drives.length})` + return `${drives.length} Devices` } /** diff --git a/tests/gui/pages/main.spec.js b/tests/gui/pages/main.spec.js index 131e492d..3abc9a2e 100644 --- a/tests/gui/pages/main.spec.js +++ b/tests/gui/pages/main.spec.js @@ -305,7 +305,7 @@ describe('Browser: MainPage', function () { it('should return a consolidated title with quantity when there are multiple drives', function () { selectionState.selectDrive(drives[0].device) selectionState.selectDrive(drives[1].device) - m.chai.expect(DriveSelectionController.getDrivesTitle()).to.equal('Multiple Devices (2)') + m.chai.expect(DriveSelectionController.getDrivesTitle()).to.equal('2 Devices') }) })