From f56e0f3e4eaba0d92ceb60956e4e7a876502f71d Mon Sep 17 00:00:00 2001 From: Donavan Becker Date: Tue, 31 Oct 2023 16:30:28 -0500 Subject: [PATCH] fix tests --- test/e2e/config-editor.e2e-spec.ts | 4 ++-- test/e2e/server.e2e-spec.ts | 2 +- test/mocks/config.json | 2 +- test/mocks/persist/AccessoryInfo.67E41F0EA05D.json | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/test/e2e/config-editor.e2e-spec.ts b/test/e2e/config-editor.e2e-spec.ts index 6108806ec..675987a87 100644 --- a/test/e2e/config-editor.e2e-spec.ts +++ b/test/e2e/config-editor.e2e-spec.ts @@ -351,7 +351,7 @@ describe('ConfigEditorController (e2e)', () => { it('POST /config-editor (accept bridge.pin if a valid value is provided)', async () => { const currentConfig = await fs.readJson(configFilePath); - currentConfig.bridge.pin = '111-11-111'; + currentConfig.bridge.pin = '1111-1111'; const res = await app.inject({ method: 'POST', @@ -366,7 +366,7 @@ describe('ConfigEditorController (e2e)', () => { // check the updates were saved to disk and mistakes corrected const savedConfig: HomebridgeConfig = await fs.readJson(configFilePath); - expect(savedConfig.bridge.pin).toBe('111-11-111'); + expect(savedConfig.bridge.pin).toBe('1111-1111'); }); it('POST /config-editor (correct bridge.name if an invalid value is provided)', async () => { diff --git a/test/e2e/server.e2e-spec.ts b/test/e2e/server.e2e-spec.ts index a2e608930..674cb5d91 100644 --- a/test/e2e/server.e2e-spec.ts +++ b/test/e2e/server.e2e-spec.ts @@ -106,7 +106,7 @@ describe('ServerController (e2e)', () => { expect(res.json()).toEqual({ displayName: 'Homebridge Test', isPaired: false, - pincode: '874-99-441', + pincode: '8749-9441', setupCode: 'X-HM://0024X0Z3L1FAP', }); }); diff --git a/test/mocks/config.json b/test/mocks/config.json index a0efc63ed..7af1d1abc 100644 --- a/test/mocks/config.json +++ b/test/mocks/config.json @@ -2,7 +2,7 @@ "bridge": { "name": "Homebridge Test", "port": 51826, - "pin": "874-99-441", + "pin": "8749-9441", "username": "67:E4:1F:0E:A0:5D" }, "accessories": [], diff --git a/test/mocks/persist/AccessoryInfo.67E41F0EA05D.json b/test/mocks/persist/AccessoryInfo.67E41F0EA05D.json index efea7ea10..97ea2bdeb 100644 --- a/test/mocks/persist/AccessoryInfo.67E41F0EA05D.json +++ b/test/mocks/persist/AccessoryInfo.67E41F0EA05D.json @@ -1,7 +1,7 @@ { "displayName": "Homebridge Test", "category": 2, - "pincode": "874-99-441", + "pincode": "8749-9441", "signSk": "fb7ecc3daa9b495d5867b49268af7568d52c4ab708e334809932976340d7a11f25e05221aa6ad3dbf4d7213e112db08752e6d94820e49038c58bc564b688626f", "signPk": "25e05221aa6ad3dbf4d7213e112db08752e6d94820e49038c58bc564b688626f", "pairedClients": {},