统一桌面壳宿主上下文补写
收敛 Tauri 配置为基础 H5 入口 由 Rust shell/url 统一补写桌面宿主上下文 增加桌面 HostBridge 协议常量漂移检查 增加微信壳 capability 共享白名单校验 更新原生壳方案和共享决策记录
This commit is contained in:
@@ -2,6 +2,7 @@ import path from 'node:path';
|
||||
|
||||
import { describe, expect, test } from 'vitest';
|
||||
|
||||
import { HOST_BRIDGE_CAPABILITIES } from '../../packages/shared/src/contracts/hostBridge.ts';
|
||||
import { loadCommonJsModule } from '../test-utils/loadCommonJsModule.js';
|
||||
|
||||
const protocolPath = path.resolve(
|
||||
@@ -39,6 +40,11 @@ describe('wechat mini program host bridge protocol index', () => {
|
||||
'share.setTarget',
|
||||
'share.open',
|
||||
]);
|
||||
expect(
|
||||
protocol.WECHAT_HOST_CAPABILITIES.filter(
|
||||
(capability) => !HOST_BRIDGE_CAPABILITIES.includes(capability),
|
||||
),
|
||||
).toEqual([]);
|
||||
expect(protocol.WECHAT_AUTH_PAGE_URL).toBe(
|
||||
'/pages/web-view/index?authAction=login&returnTo=previous',
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user