Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
OpenHarmony
Xts Acts
提交
d9ec4c6a
X
Xts Acts
项目概览
OpenHarmony
/
Xts Acts
1 年多 前同步成功
通知
9
Star
22
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
X
Xts Acts
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
提交
d9ec4c6a
编写于
3月 14, 2022
作者:
U
unknown
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
add user
Signed-off-by:
N
unknown
<
sijunjie@huawei.com
>
上级
1c5a2cb3
变更
2
隐藏空白更改
内联
并排
Showing
2 changed file
with
41 addition
and
19 deletion
+41
-19
aafwk/aafwk_standard/amsabilitymanager/amsMissionSnapshotTest/entry/src/main/js/test/amsMissionSnapshotTest.test.js
...est/entry/src/main/js/test/amsMissionSnapshotTest.test.js
+2
-2
aafwk/aafwk_standard/featureability/actsfeatureabilitytest/entry/src/main/js/test/FeatureAbilityJsunit.test.js
...ytest/entry/src/main/js/test/FeatureAbilityJsunit.test.js
+39
-17
未找到文件。
aafwk/aafwk_standard/amsabilitymanager/amsMissionSnapshotTest/entry/src/main/js/test/amsMissionSnapshotTest.test.js
浏览文件 @
d9ec4c6a
...
...
@@ -38,7 +38,7 @@ describe('ActsMissionSnapshotTest', function () {
console
.
debug
(
'
ACTS_MissionSnapshot_0100====<begin
'
);
try
{
await
missionManager
.
getMissionSnapShot
(
""
,
-
1
,
(
err
,
data
)
=>
{
expect
(
err
.
code
).
assertEqual
(
2097172
);
expect
(
err
.
code
!=
0
).
assertTrue
(
);
console
.
debug
(
"
=ACTS_MissionSnapshot_0100 err.code,data=======>
"
+
err
.
code
+
(
"
json data【
"
)
+
JSON
.
stringify
(
data
)
+
(
"
】
"
)
+
"
,
"
+
data
);
console
.
debug
(
'
ACTS_MissionSnapshot_0100====<end
'
)
...
...
@@ -213,7 +213,7 @@ describe('ActsMissionSnapshotTest', function () {
}).
catch
(
function
(
err
)
{
console
.
debug
(
"
=ACTS_MissionSnapshot_0400 catch err ====>
"
+
(
"
json err 【
"
)
+
JSON
.
stringify
(
err
)
+
(
"
】
"
));
expect
(
err
.
code
).
assertEqual
(
2097172
);
expect
(
err
.
code
!=
0
).
assertTrue
(
);
console
.
debug
(
'
ACTS_MissionSnapshot_0400====<end .catch(err)
'
);
done
();
});
...
...
aafwk/aafwk_standard/featureability/actsfeatureabilitytest/entry/src/main/js/test/FeatureAbilityJsunit.test.js
浏览文件 @
d9ec4c6a
...
...
@@ -1515,14 +1515,25 @@ describe('ActsFeatureAbilityTest', function () {
* @tc.desc: Check the return value of the interface (by Promise)
*/
it
(
'
ACTS_HasWindowFocus_0200
'
,
0
,
async
function
(
done
)
{
var
promise
=
featureAbility
.
hasWindowFocus
();
expect
(
typeof
(
promise
)).
assertEqual
(
"
object
"
);
var
info
=
await
featureAbility
.
hasWindowFocus
();
expect
(
info
).
assertEqual
(
false
);
done
();
setTimeout
(
function
()
{
console
.
info
(
'
====> ACTS_HasWindowFocus_0200 =====>
'
)
},
TIMEOUT
)
console
.
info
(
'
====>ACTS_HasWindowFocus_0200 start=====>
'
)
featureAbility
.
startAbility
(
{
want
:
{
bundleName
:
"
com.example.getcallingbundlepromisetest
"
,
abilityName
:
"
com.example.getcallingbundlepromisetest.MainAbility
"
,
},
},
(
err
,
data
)
=>
{
console
.
info
(
'
====>ACTS_HasWindowFocus_0200 startAbility err:
'
+
JSON
.
stringify
(
err
))
setTimeout
(
async
function
()
{
console
.
info
(
'
====>ACTS_HasWindowFocus_0200 =====>
'
)
var
info
=
await
featureAbility
.
hasWindowFocus
();
console
.
info
(
'
====>ACTS_HasWindowFocus_0200 info
'
+
info
);
expect
(
info
).
assertEqual
(
false
);
done
();
},
TIMEOUT
)
}
);
})
/**
...
...
@@ -1531,17 +1542,28 @@ describe('ActsFeatureAbilityTest', function () {
* @tc.desc: Check the return value of the interface (by AsyncCallback)
*/
it
(
'
ACTS_HasWindowFocus_0400
'
,
0
,
async
function
(
done
)
{
var
result
=
featureAbility
.
hasWindowFocus
(
(
error
,
data
)
=>
{
console
.
log
(
"
ACTS_HasWindowFocus_0400 asyncCallback code:
"
+
error
.
code
+
"
data:
"
+
data
)
expect
(
error
.
code
).
assertEqual
(
0
);
expect
(
data
).
assertEqual
(
false
);
done
();
console
.
info
(
'
====>ACTS_HasWindowFocus_0400 start=====>
'
)
featureAbility
.
startAbility
(
{
want
:
{
bundleName
:
"
com.example.getcallingbundlepromisetest
"
,
abilityName
:
"
com.example.getcallingbundlepromisetest.MainAbility
"
,
},
},
(
err
,
data
)
=>
{
console
.
info
(
'
====>ACTS_HasWindowFocus_0400 startAbility err:
'
+
JSON
.
stringify
(
err
))
setTimeout
(
async
function
()
{
console
.
info
(
'
====> ACTS_HasWindowFocus_0400 =====>
'
)
featureAbility
.
hasWindowFocus
(
(
error
,
data
)
=>
{
console
.
log
(
"
ACTS_HasWindowFocus_0400 asyncCallback code:
"
+
error
.
code
+
"
data:
"
+
data
)
expect
(
error
.
code
).
assertEqual
(
0
);
expect
(
data
).
assertEqual
(
false
);
done
();
});
},
TIMEOUT
)
}
);
setTimeout
(
function
()
{
console
.
info
(
'
====> ACTS_HasWindowFocus_0400 =====>
'
)
},
TIMEOUT
)
})
/**
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录