@onekeyfe/hd-transport-web-device 1.2.0-alpha.29 → 1.2.0-alpha.30

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -183,7 +183,7 @@ describe('ElectronBleTransport protocol detection', () => {
183
183
  });
184
184
  });
185
185
 
186
- test('uses the Protocol V2 BLE writer without changing the Protocol V1 packet path', async () => {
186
+ test('uses the Protocol V2 BLE writer with the Electron packet size', async () => {
187
187
  const device = { id: 'chunked-pro2-id', name: 'OneKey Pro 2' };
188
188
  const nobleBle = createNobleBle(device);
189
189
  const bleTransport = configureTransport(nobleBle) as any;
@@ -257,6 +257,7 @@ describe('ElectronBleTransport protocol detection', () => {
257
257
  return Promise.resolve();
258
258
  });
259
259
  const transport = configureTransport(nobleBle);
260
+ const protocolV2Writer = jest.spyOn(transport as any, 'writeProtocolV2Frame');
260
261
 
261
262
  try {
262
263
  await expect(transport.acquire({ uuid: device.id })).resolves.toEqual(
@@ -265,6 +266,7 @@ describe('ElectronBleTransport protocol detection', () => {
265
266
  })
266
267
  );
267
268
  expect(transport.getProtocolType(device.id)).toBe('V1');
269
+ expect(protocolV2Writer).not.toHaveBeenCalled();
268
270
  } finally {
269
271
  await transport.release(device.id);
270
272
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@onekeyfe/hd-transport-web-device",
3
- "version": "1.2.0-alpha.29",
3
+ "version": "1.2.0-alpha.30",
4
4
  "author": "OneKey",
5
5
  "homepage": "https://github.com/OneKeyHQ/hardware-js-sdk#readme",
6
6
  "license": "MIT",
@@ -21,13 +21,13 @@
21
21
  "lint:fix": "eslint . --fix"
22
22
  },
23
23
  "dependencies": {
24
- "@onekeyfe/hd-shared": "1.2.0-alpha.29",
25
- "@onekeyfe/hd-transport": "1.2.0-alpha.29"
24
+ "@onekeyfe/hd-shared": "1.2.0-alpha.30",
25
+ "@onekeyfe/hd-transport": "1.2.0-alpha.30"
26
26
  },
27
27
  "devDependencies": {
28
- "@onekeyfe/hd-transport-electron": "1.2.0-alpha.29",
28
+ "@onekeyfe/hd-transport-electron": "1.2.0-alpha.30",
29
29
  "@types/w3c-web-usb": "^1.0.6",
30
30
  "@types/web-bluetooth": "^0.0.17"
31
31
  },
32
- "gitHead": "4a4019e439cc472f89fd15ab47e84ef0ed43166a"
32
+ "gitHead": "07405d2e3dcdd0ba351ae98b7cf4f61690ef2913"
33
33
  }