提交 d66859f6 编写于 作者: lizhongyi_'s avatar lizhongyi_

调整部分uts 测试例

(cherry picked from commit ddf58715)
上级 a97536ac
...@@ -407,12 +407,15 @@ export function testJSON() : Result { ...@@ -407,12 +407,15 @@ export function testJSON() : Result {
test('parse generic type', () => { test('parse generic type', () => {
type A = { type A = {
num: number, num: number,
} }
function test<T>(json: string): T { function test<T>(json: string): T {
return JSON.parse<T>(json)! return JSON.parse<T>(json)!
} }
// #ifndef APP-IOS
const a = test<A>(`{"num": 1}`) const a = test<A>(`{"num": 1}`)
expect(a.num).toEqual(1) expect(a.num).toEqual(1)
// #endif
}) })
}) })
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册