Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
OpenHarmony
Xts Acts
提交
b53a42ca
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看板
未验证
提交
b53a42ca
编写于
11月 24, 2022
作者:
O
openharmony_ci
提交者:
Gitee
11月 24, 2022
浏览文件
操作
浏览文件
下载
差异文件
!6660 Solve XTS Singlehap_LifeCycleTest_2100 Fail Problem
Merge pull request !6660 from zhoujun62/my_xts_acts
上级
6294d978
bdb0683f
变更
15
隐藏空白更改
内联
并排
Showing
15 changed file
with
61 addition
and
62 deletion
+61
-62
ability/ability_runtime/stage/actslifecyclesinglehaptest/entry/src/main/ets/Hap1MainAbility1/Hap1MainAbility1.ts
...t/entry/src/main/ets/Hap1MainAbility1/Hap1MainAbility1.ts
+1
-1
ability/ability_runtime/stage/actslifecyclesinglehaptest/entry/src/main/ets/Hap1MainAbility2/Hap1MainAbility2.ts
...t/entry/src/main/ets/Hap1MainAbility2/Hap1MainAbility2.ts
+1
-2
ability/ability_runtime/stage/actslifecyclesinglehaptest/entry/src/main/ets/MainAbility1/MainAbility1.ts
...lehaptest/entry/src/main/ets/MainAbility1/MainAbility1.ts
+1
-1
ability/ability_runtime/stage/actslifecyclesinglehaptest/entry/src/main/ets/MainAbility10/MainAbility10.ts
...haptest/entry/src/main/ets/MainAbility10/MainAbility10.ts
+1
-1
ability/ability_runtime/stage/actslifecyclesinglehaptest/entry/src/main/ets/MainAbility11/MainAbility11.ts
...haptest/entry/src/main/ets/MainAbility11/MainAbility11.ts
+1
-1
ability/ability_runtime/stage/actslifecyclesinglehaptest/entry/src/main/ets/MainAbility12/MainAbility12.ts
...haptest/entry/src/main/ets/MainAbility12/MainAbility12.ts
+1
-1
ability/ability_runtime/stage/actslifecyclesinglehaptest/entry/src/main/ets/MainAbility2/MainAbility2.ts
...lehaptest/entry/src/main/ets/MainAbility2/MainAbility2.ts
+1
-1
ability/ability_runtime/stage/actslifecyclesinglehaptest/entry/src/main/ets/MainAbility3/MainAbility3.ts
...lehaptest/entry/src/main/ets/MainAbility3/MainAbility3.ts
+1
-1
ability/ability_runtime/stage/actslifecyclesinglehaptest/entry/src/main/ets/MainAbility4/MainAbility4.ts
...lehaptest/entry/src/main/ets/MainAbility4/MainAbility4.ts
+1
-1
ability/ability_runtime/stage/actslifecyclesinglehaptest/entry/src/main/ets/MainAbility5/MainAbility5.ts
...lehaptest/entry/src/main/ets/MainAbility5/MainAbility5.ts
+1
-1
ability/ability_runtime/stage/actslifecyclesinglehaptest/entry/src/main/ets/MainAbility6/MainAbility6.ts
...lehaptest/entry/src/main/ets/MainAbility6/MainAbility6.ts
+1
-1
ability/ability_runtime/stage/actslifecyclesinglehaptest/entry/src/main/ets/MainAbility7/MainAbility7.ts
...lehaptest/entry/src/main/ets/MainAbility7/MainAbility7.ts
+1
-1
ability/ability_runtime/stage/actslifecyclesinglehaptest/entry/src/main/ets/MainAbility8/MainAbility8.ts
...lehaptest/entry/src/main/ets/MainAbility8/MainAbility8.ts
+1
-1
ability/ability_runtime/stage/actslifecyclesinglehaptest/entry/src/main/ets/MainAbility9/MainAbility9.ts
...lehaptest/entry/src/main/ets/MainAbility9/MainAbility9.ts
+1
-1
ability/ability_runtime/stage/actslifecyclesinglehaptest/entry/src/main/ets/test/LifeCycleTest.ets
...lesinglehaptest/entry/src/main/ets/test/LifeCycleTest.ets
+47
-47
未找到文件。
ability/ability_runtime/stage/actslifecyclesinglehaptest/entry/src/main/ets/Hap1MainAbility1/Hap1MainAbility1.ts
浏览文件 @
b53a42ca
...
...
@@ -17,7 +17,7 @@ import Ability from '@ohos.app.ability.UIAbility'
export
default
class
Hap1MainAbility1
extends
Ability
{
onCreate
(
want
,
launchParam
)
{
console
.
log
(
"
[Demo] Hap1MainAbility1 onCreate
"
)
globalThis
.
abilityWant
=
want
;
globalThis
.
ability
1Hap1
Want
=
want
;
setTimeout
(()
=>
{
this
.
context
.
terminateSelf
().
then
((
data
)
=>
{
console
.
log
(
"
Hap1MainAbility1 EventTest terminateSelf data:
"
+
JSON
.
stringify
(
data
));
...
...
ability/ability_runtime/stage/actslifecyclesinglehaptest/entry/src/main/ets/Hap1MainAbility2/Hap1MainAbility2.ts
浏览文件 @
b53a42ca
...
...
@@ -17,8 +17,7 @@ import Ability from '@ohos.app.ability.UIAbility'
export
default
class
Hap1MainAbility2
extends
Ability
{
onCreate
(
want
,
launchParam
)
{
console
.
log
(
"
[Demo] Hap1MainAbility2 onCreate
"
)
globalThis
.
abilityWant
=
want
;
globalThis
.
ability2Hap1Want
=
want
;
setTimeout
(()
=>
{
this
.
context
.
terminateSelf
().
then
((
data
)
=>
{
console
.
log
(
"
Hap1MainAbility2 EventTest terminateSelf data:
"
+
JSON
.
stringify
(
data
));
...
...
ability/ability_runtime/stage/actslifecyclesinglehaptest/entry/src/main/ets/MainAbility1/MainAbility1.ts
浏览文件 @
b53a42ca
...
...
@@ -17,7 +17,7 @@ import Ability from '@ohos.app.ability.UIAbility'
export
default
class
MainAbility1
extends
Ability
{
onCreate
(
want
,
launchParam
)
{
console
.
log
(
"
[Demo] MainAbility1 onCreate
"
)
globalThis
.
abilityWant
=
want
;
globalThis
.
abilityWant
1
=
want
;
console
.
log
(
"
[Demo] MainAbility1 context:
"
+
JSON
.
stringify
(
this
.
context
));
var
listKey1
=
[];
let
AbilityLifecycleCallback
=
{
...
...
ability/ability_runtime/stage/actslifecyclesinglehaptest/entry/src/main/ets/MainAbility10/MainAbility10.ts
浏览文件 @
b53a42ca
...
...
@@ -17,7 +17,7 @@ import Ability from '@ohos.app.ability.UIAbility'
export
default
class
MainAbility10
extends
Ability
{
onCreate
(
want
,
launchParam
)
{
console
.
log
(
"
[Demo] MainAbility10 onCreate
"
)
globalThis
.
abilityWant
=
want
;
globalThis
.
abilityWant
10
=
want
;
var
listKey10
=
[];
let
AbilityLifecycleCallback
=
{
onAbilityCreate
(
ability
)
{
...
...
ability/ability_runtime/stage/actslifecyclesinglehaptest/entry/src/main/ets/MainAbility11/MainAbility11.ts
浏览文件 @
b53a42ca
...
...
@@ -17,7 +17,7 @@ import Ability from '@ohos.app.ability.UIAbility'
export
default
class
MainAbility11
extends
Ability
{
onCreate
(
want
,
launchParam
)
{
console
.
log
(
"
[Demo] MainAbility11 onCreate
"
)
globalThis
.
abilityWant
=
want
;
globalThis
.
abilityWant
11
=
want
;
globalThis
.
ability11
=
this
.
context
;
var
listKey11
=
[];
let
AbilityLifecycleCallback
=
{
...
...
ability/ability_runtime/stage/actslifecyclesinglehaptest/entry/src/main/ets/MainAbility12/MainAbility12.ts
浏览文件 @
b53a42ca
...
...
@@ -17,7 +17,7 @@ import Ability from '@ohos.app.ability.UIAbility'
export
default
class
MainAbility12
extends
Ability
{
onCreate
(
want
,
launchParam
)
{
console
.
log
(
"
[Demo] MainAbility12 onCreate
"
)
globalThis
.
abilityWant
=
want
;
globalThis
.
abilityWant
12
=
want
;
var
listKey12
=
[];
let
AbilityLifecycleCallback
=
{
onAbilityCreate
(
ability
)
{
...
...
ability/ability_runtime/stage/actslifecyclesinglehaptest/entry/src/main/ets/MainAbility2/MainAbility2.ts
浏览文件 @
b53a42ca
...
...
@@ -17,7 +17,7 @@ import Ability from '@ohos.app.ability.UIAbility'
export
default
class
MainAbility2
extends
Ability
{
onCreate
(
want
,
launchParam
)
{
console
.
log
(
"
[Demo] MainAbility2 onCreate
"
)
globalThis
.
abilityWant
=
want
;
globalThis
.
abilityWant
2
=
want
;
}
onDestroy
()
{
...
...
ability/ability_runtime/stage/actslifecyclesinglehaptest/entry/src/main/ets/MainAbility3/MainAbility3.ts
浏览文件 @
b53a42ca
...
...
@@ -17,7 +17,7 @@ import Ability from '@ohos.app.ability.UIAbility'
export
default
class
MainAbility3
extends
Ability
{
onCreate
(
want
,
launchParam
)
{
console
.
log
(
"
[Demo] MainAbility3 onCreate
"
)
globalThis
.
abilityWant
=
want
;
globalThis
.
abilityWant
3
=
want
;
console
.
log
(
"
[Demo] MainAbility3 context:
"
+
JSON
.
stringify
(
this
.
context
));
var
listKey3
=
[];
...
...
ability/ability_runtime/stage/actslifecyclesinglehaptest/entry/src/main/ets/MainAbility4/MainAbility4.ts
浏览文件 @
b53a42ca
...
...
@@ -17,7 +17,7 @@ import Ability from '@ohos.app.ability.UIAbility'
export
default
class
MainAbility4
extends
Ability
{
onCreate
(
want
,
launchParam
)
{
console
.
log
(
"
[Demo] MainAbility4 onCreate
"
)
globalThis
.
abilityWant
=
want
;
globalThis
.
abilityWant
4
=
want
;
console
.
log
(
"
[Demo] MainAbility4 context:
"
+
JSON
.
stringify
(
this
.
context
));
var
listKey4
=
[];
...
...
ability/ability_runtime/stage/actslifecyclesinglehaptest/entry/src/main/ets/MainAbility5/MainAbility5.ts
浏览文件 @
b53a42ca
...
...
@@ -17,7 +17,7 @@ import Ability from '@ohos.app.ability.UIAbility'
export
default
class
MainAbility5
extends
Ability
{
onCreate
(
want
,
launchParam
)
{
console
.
log
(
"
[Demo] MainAbility5 onCreate
"
)
globalThis
.
abilityWant
=
want
;
globalThis
.
abilityWant
5
=
want
;
}
onDestroy
()
{
...
...
ability/ability_runtime/stage/actslifecyclesinglehaptest/entry/src/main/ets/MainAbility6/MainAbility6.ts
浏览文件 @
b53a42ca
...
...
@@ -17,7 +17,7 @@ import Ability from '@ohos.app.ability.UIAbility'
export
default
class
MainAbility6
extends
Ability
{
onCreate
(
want
,
launchParam
)
{
console
.
log
(
"
[Demo] MainAbility6 onCreate
"
)
globalThis
.
abilityWant
=
want
;
globalThis
.
abilityWant
6
=
want
;
}
onDestroy
()
{
...
...
ability/ability_runtime/stage/actslifecyclesinglehaptest/entry/src/main/ets/MainAbility7/MainAbility7.ts
浏览文件 @
b53a42ca
...
...
@@ -17,7 +17,7 @@ import Ability from '@ohos.app.ability.UIAbility'
export
default
class
MainAbility7
extends
Ability
{
onCreate
(
want
,
launchParam
)
{
console
.
log
(
"
[Demo] MainAbility7 onCreate
"
)
globalThis
.
abilityWant
=
want
;
globalThis
.
abilityWant
7
=
want
;
}
onDestroy
()
{
...
...
ability/ability_runtime/stage/actslifecyclesinglehaptest/entry/src/main/ets/MainAbility8/MainAbility8.ts
浏览文件 @
b53a42ca
...
...
@@ -17,7 +17,7 @@ import Ability from '@ohos.app.ability.UIAbility'
export
default
class
MainAbility8
extends
Ability
{
onCreate
(
want
,
launchParam
)
{
console
.
log
(
"
[Demo] MainAbility8 onCreate
"
)
globalThis
.
abilityWant
=
want
;
globalThis
.
abilityWant
8
=
want
;
}
onDestroy
()
{
...
...
ability/ability_runtime/stage/actslifecyclesinglehaptest/entry/src/main/ets/MainAbility9/MainAbility9.ts
浏览文件 @
b53a42ca
...
...
@@ -17,7 +17,7 @@ import Ability from '@ohos.app.ability.UIAbility'
export
default
class
MainAbility9
extends
Ability
{
onCreate
(
want
,
launchParam
)
{
console
.
log
(
"
[Demo] MainAbility9 onCreate
"
)
globalThis
.
abilityWant
=
want
;
globalThis
.
abilityWant
9
=
want
;
}
onDestroy
()
{
...
...
ability/ability_runtime/stage/actslifecyclesinglehaptest/entry/src/main/ets/test/LifeCycleTest.ets
浏览文件 @
b53a42ca
...
...
@@ -82,7 +82,7 @@ export default function lifecycleTest() {
"bundleName": "com.example.lifecycle_xts",
"abilityName": "MainAbility2",
}
globalThis.
globalThis.
abilityContext.startAbility(str)
globalThis.abilityContext.startAbility(str)
.then((data) => {
console.info(TAG + ' start successful. Data: ' + data);
}).catch((error) => {
...
...
@@ -137,7 +137,7 @@ export default function lifecycleTest() {
"bundleName": "com.example.lifecycle_xts",
"abilityName": "MainAbility1",
}
globalThis.
globalThis.
abilityContext.startAbility(str)
globalThis.abilityContext.startAbility(str)
.then((data) => {
console.info(TAG + ' start successful. Data: ' + data);
}).catch((error) => {
...
...
@@ -148,7 +148,7 @@ export default function lifecycleTest() {
"bundleName": "com.example.lifecycle_xts",
"abilityName": "MainAbility2",
}
globalThis.
globalThis.
abilityContext.startAbility(str1)
globalThis.abilityContext.startAbility(str1)
.then((data) => {
console.info(TAG + ' start successful. Data: ' + data);
}).catch((error) => {
...
...
@@ -211,7 +211,7 @@ export default function lifecycleTest() {
"bundleName": "com.example.lifecycle_xts",
"abilityName": "MainAbility1",
}
globalThis.
globalThis.
abilityContext.startAbility(str)
globalThis.abilityContext.startAbility(str)
.then((data) => {
console.info(TAG + ' start successful. Data: ' + data);
}).catch((error) => {
...
...
@@ -222,7 +222,7 @@ export default function lifecycleTest() {
"bundleName": "com.example.lifecycle_xts",
"abilityName": "MainAbility2",
}
globalThis.
globalThis.
abilityContext.startAbility(str1)
globalThis.abilityContext.startAbility(str1)
.then((data) => {
console.info(TAG + ' start successful. Data: ' + data);
}).catch((error) => {
...
...
@@ -296,7 +296,7 @@ export default function lifecycleTest() {
"bundleName": "com.example.lifecycle_xts",
"abilityName": "MainAbility3",
}
globalThis.
globalThis.
abilityContext.startAbility(str)
globalThis.abilityContext.startAbility(str)
.then((data) => {
console.info(TAG + ' start3 successful. Data: ' + data);
}).catch((error) => {
...
...
@@ -307,7 +307,7 @@ export default function lifecycleTest() {
"bundleName": "com.example.lifecycle_xts",
"abilityName": "MainAbility2",
}
globalThis.
globalThis.
abilityContext.startAbility(str1)
globalThis.abilityContext.startAbility(str1)
.then((data) => {
console.info(TAG + ' start2 successful. Data: ' + data);
}).catch((error) => {
...
...
@@ -385,7 +385,7 @@ export default function lifecycleTest() {
"bundleName": "com.example.lifecycle_xts",
"abilityName": "MainAbility1",
}
globalThis.
globalThis.
abilityContext.startAbility(str)
globalThis.abilityContext.startAbility(str)
.then((data) => {
console.info(TAG + ' start1 successful. Data: ' + data);
}).catch((error) => {
...
...
@@ -396,7 +396,7 @@ export default function lifecycleTest() {
"bundleName": "com.example.lifecycle_xts",
"abilityName": "MainAbility3",
}
globalThis.
globalThis.
abilityContext.startAbility(str1)
globalThis.abilityContext.startAbility(str1)
.then((data) => {
console.info(TAG + ' start3 successful. Data: ' + data);
}).catch((error) => {
...
...
@@ -417,7 +417,7 @@ export default function lifecycleTest() {
"bundleName": "com.example.lifecycle_xts",
"abilityName": "MainAbility4",
}
globalThis.
globalThis.
abilityContext.startAbility(str2)
globalThis.abilityContext.startAbility(str2)
.then((data) => {
console.info(TAG + ' start4 successful. Data: ' + data);
}).catch((error) => {
...
...
@@ -462,7 +462,7 @@ export default function lifecycleTest() {
"bundleName": "com.example.lifecycle_xts",
"abilityName": "MainAbility1",
}
globalThis.
globalThis.
abilityContext.startAbility(str)
globalThis.abilityContext.startAbility(str)
.then((data) => {
console.info(TAG + ' start1 successful. Data: ' + data);
}).catch((error) => {
...
...
@@ -473,7 +473,7 @@ export default function lifecycleTest() {
"bundleName": "com.example.lifecycle_xts",
"abilityName": "MainAbility5",
}
globalThis.
globalThis.
abilityContext.startAbility(str1)
globalThis.abilityContext.startAbility(str1)
.then((data) => {
console.info(TAG + ' start5 successful. Data: ' + data);
}).catch((error) => {
...
...
@@ -485,7 +485,7 @@ export default function lifecycleTest() {
"bundleName": "com.example.lifecycle_xts",
"abilityName": "MainAbility2",
}
globalThis.
globalThis.
abilityContext.startAbility(str2)
globalThis.abilityContext.startAbility(str2)
.then((data) => {
console.info(TAG + ' start2 successful. Data: ' + data);
}).catch((error) => {
...
...
@@ -618,7 +618,7 @@ export default function lifecycleTest() {
listKey8.push(abilityname + " onAbilityContinue");
}
}
let applicationContext = globalThis.
globalThis.
abilityContext.getApplicationContext();
let applicationContext = globalThis.abilityContext.getApplicationContext();
id1 = applicationContext.registerAbilityLifecycleCallback(AbilityLifecycleCallback);
console.log(TAG + " registerAbilityLifecycleCallback1 number: " + JSON.stringify(id1));
applicationContext.unregisterAbilityLifecycleCallback(id1, (error, data) => {
...
...
@@ -667,7 +667,7 @@ export default function lifecycleTest() {
"bundleName": "com.example.lifecycle_xts",
"abilityName": "MainAbility1",
}
globalThis.
globalThis.
abilityContext.startAbility(str)
globalThis.abilityContext.startAbility(str)
.then((data) => {
console.info(TAG + ' start successful. Data: ' + data);
}).catch((error) => {
...
...
@@ -678,7 +678,7 @@ export default function lifecycleTest() {
"bundleName": "com.example.lifecycle_xts",
"abilityName": "MainAbility2",
}
globalThis.
globalThis.
abilityContext.startAbility(str1)
globalThis.abilityContext.startAbility(str1)
.then((data) => {
console.info(TAG + ' start successful. Data: ' + data);
}).catch((error) => {
...
...
@@ -690,7 +690,7 @@ export default function lifecycleTest() {
"bundleName": "com.example.lifecycle_xts",
"abilityName": "MainAbility2",
}
globalThis.
globalThis.
abilityContext.startAbility(str1)
globalThis.abilityContext.startAbility(str1)
.then((data) => {
console.info(TAG + ' start successful. Data: ' + data);
}).catch((error) => {
...
...
@@ -703,7 +703,7 @@ export default function lifecycleTest() {
"bundleName": "com.example.lifecycle_xts",
"abilityName": "MainAbility2",
}
globalThis.
globalThis.
abilityContext.startAbility(str1)
globalThis.abilityContext.startAbility(str1)
.then((data) => {
console.info(TAG + ' start successful. Data: ' + data);
}).catch((error) => {
...
...
@@ -774,7 +774,7 @@ export default function lifecycleTest() {
"bundleName": "com.example.lifecycle_xts",
"abilityName": "MainAbility1",
}
globalThis.
globalThis.
abilityContext.startAbility(str)
globalThis.abilityContext.startAbility(str)
.then((data) => {
console.info(TAG + ' start successful. Data: ' + data);
}).catch((error) => {
...
...
@@ -785,7 +785,7 @@ export default function lifecycleTest() {
"bundleName": "com.example.lifecycle_xts",
"abilityName": "MainAbility2",
}
globalThis.
globalThis.
abilityContext.startAbility(str1)
globalThis.abilityContext.startAbility(str1)
.then((data) => {
console.info(TAG + ' start successful. Data: ' + data);
}).catch((error) => {
...
...
@@ -797,7 +797,7 @@ export default function lifecycleTest() {
"bundleName": "com.example.lifecycle_xts",
"abilityName": "MainAbility2",
}
globalThis.
globalThis.
abilityContext.startAbility(str1)
globalThis.abilityContext.startAbility(str1)
.then((data) => {
console.info(TAG + ' start successful. Data: ' + data);
}).catch((error) => {
...
...
@@ -865,7 +865,7 @@ export default function lifecycleTest() {
"bundleName": "com.example.lifecycle_xts",
"abilityName": "MainAbility6",
}
globalThis.
globalThis.
abilityContext.startAbility(str)
globalThis.abilityContext.startAbility(str)
.then((data) => {
console.info(TAG + ' start successful. Data: ' + data);
}).catch((error) => {
...
...
@@ -880,7 +880,7 @@ export default function lifecycleTest() {
"bundleName": "com.example.lifecycle_xts",
"abilityName": "MainAbility2",
}
globalThis.
globalThis.
abilityContext.startAbility(str1)
globalThis.abilityContext.startAbility(str1)
.then((data) => {
console.info(TAG + ' start successful. Data: ' + data);
}).catch((error) => {
...
...
@@ -918,7 +918,7 @@ export default function lifecycleTest() {
"bundleName": "com.example.lifecycle_xts",
"abilityName": "MainAbility7",
}
globalThis.
globalThis.
abilityContext.startAbility(str)
globalThis.abilityContext.startAbility(str)
.then((data) => {
console.info(TAG + ' start successful. Data: ' + data);
}).catch((error) => {
...
...
@@ -933,7 +933,7 @@ export default function lifecycleTest() {
"bundleName": "com.example.lifecycle_xts",
"abilityName": "MainAbility7",
}
globalThis.
globalThis.
abilityContext.startAbility(str)
globalThis.abilityContext.startAbility(str)
.then((data) => {
console.info(TAG + ' start successful. Data: ' + data);
}).catch((error) => {
...
...
@@ -982,7 +982,7 @@ export default function lifecycleTest() {
"bundleName": "com.example.lifecycle_xts",
"abilityName": "MainAbility8",
}
globalThis.
globalThis.
abilityContext.startAbility(str)
globalThis.abilityContext.startAbility(str)
.then((data) => {
console.info(TAG + ' start successful. Data: ' + data);
}).catch((error) => {
...
...
@@ -997,7 +997,7 @@ export default function lifecycleTest() {
"bundleName": "com.example.lifecycle_xts",
"abilityName": "MainAbility8",
}
globalThis.
globalThis.
abilityContext.startAbility(str)
globalThis.abilityContext.startAbility(str)
.then((data) => {
console.info(TAG + ' start successful. Data: ' + data);
}).catch((error) => {
...
...
@@ -1166,7 +1166,7 @@ export default function lifecycleTest() {
"bundleName": "com.example.lifecycle_xts",
"abilityName": "MainAbility11",
}
globalThis.
globalThis.
abilityContext.startAbility(str)
globalThis.abilityContext.startAbility(str)
.then((data) => {
console.info(TAG + ' start successful. Data: ' + data);
}).catch((error) => {
...
...
@@ -1177,7 +1177,7 @@ export default function lifecycleTest() {
"bundleName": "com.example.lifecycle_xts",
"abilityName": "MainAbility2",
}
globalThis.
globalThis.
abilityContext.startAbility(str1)
globalThis.abilityContext.startAbility(str1)
.then((data) => {
console.info(TAG + ' start successful. Data: ' + data);
}).catch((error) => {
...
...
@@ -1193,7 +1193,7 @@ export default function lifecycleTest() {
"bundleName": "com.example.lifecycle_xts",
"abilityName": "MainAbility11",
}
globalThis.
globalThis.
abilityContext.startAbility(str)
globalThis.abilityContext.startAbility(str)
.then((data) => {
console.info(TAG + ' start successful. Data: ' + data);
}).catch((error) => {
...
...
@@ -1204,7 +1204,7 @@ export default function lifecycleTest() {
"bundleName": "com.example.lifecycle_xts",
"abilityName": "MainAbility2",
}
globalThis.
globalThis.
abilityContext.startAbility(str1)
globalThis.abilityContext.startAbility(str1)
.then((data) => {
console.info(TAG + ' start successful. Data: ' + data);
}).catch((error) => {
...
...
@@ -1346,7 +1346,7 @@ export default function lifecycleTest() {
"bundleName": "com.example.lifecycle_xts",
"abilityName": "MainAbility12",
}
globalThis.
globalThis.
abilityContext.startAbility(str)
globalThis.abilityContext.startAbility(str)
.then((data) => {
console.info(TAG + ' start successful. Data: ' + data);
}).catch((error) => {
...
...
@@ -1357,7 +1357,7 @@ export default function lifecycleTest() {
"bundleName": "com.example.lifecycle_xts",
"abilityName": "MainAbility2",
}
globalThis.
globalThis.
abilityContext.startAbility(str1)
globalThis.abilityContext.startAbility(str1)
.then((data) => {
console.info(TAG + ' start successful. Data: ' + data);
}).catch((error) => {
...
...
@@ -1389,7 +1389,7 @@ export default function lifecycleTest() {
"bundleName": "com.example.lifecycle_xts",
"abilityName": "MainAbility12",
}
globalThis.
globalThis.
abilityContext.startAbility(str)
globalThis.abilityContext.startAbility(str)
.then((data) => {
console.info(TAG + ' start successful. Data: ' + data);
}).catch((error) => {
...
...
@@ -1400,7 +1400,7 @@ export default function lifecycleTest() {
"bundleName": "com.example.lifecycle_xts",
"abilityName": "MainAbility2",
}
globalThis.
globalThis.
abilityContext.startAbility(str1)
globalThis.abilityContext.startAbility(str1)
.then((data) => {
console.info(TAG + ' start successful. Data: ' + data);
}).catch((error) => {
...
...
@@ -1458,7 +1458,7 @@ export default function lifecycleTest() {
"bundleName": "com.example.lifecycle_xts",
"abilityName": "MainAbility1",
}
globalThis.
globalThis.
abilityContext.startAbility(str)
globalThis.abilityContext.startAbility(str)
.then((data) => {
console.info(TAG + ' start successful. Data: ' + data);
}).catch((error) => {
...
...
@@ -1469,7 +1469,7 @@ export default function lifecycleTest() {
"bundleName": "com.example.lifecycle_xts",
"abilityName": "MainAbility12",
}
globalThis.
globalThis.
abilityContext.startAbility(str1)
globalThis.abilityContext.startAbility(str1)
.then((data) => {
console.info(TAG + ' start successful. Data: ' + data);
}).catch((error) => {
...
...
@@ -1480,7 +1480,7 @@ export default function lifecycleTest() {
"bundleName": "com.example.lifecycle_xts",
"abilityName": "MainAbility2",
}
globalThis.
globalThis.
abilityContext.startAbility(str2)
globalThis.abilityContext.startAbility(str2)
.then((data) => {
console.info(TAG + ' start successful. Data: ' + data);
}).catch((error) => {
...
...
@@ -1533,7 +1533,7 @@ export default function lifecycleTest() {
"bundleName": "com.example.lifecycle_xts",
"abilityName": "MainAbility1",
}
globalThis.
globalThis.
abilityContext.startAbility(str)
globalThis.abilityContext.startAbility(str)
.then((data) => {
console.info(TAG + ' start successful. Data: ' + data);
}).catch((error) => {
...
...
@@ -1544,7 +1544,7 @@ export default function lifecycleTest() {
"bundleName": "com.example.lifecycle_xts",
"abilityName": "MainAbility12",
}
globalThis.
globalThis.
abilityContext.startAbility(str1)
globalThis.abilityContext.startAbility(str1)
.then((data) => {
console.info(TAG + ' start successful. Data: ' + data);
}).catch((error) => {
...
...
@@ -1555,7 +1555,7 @@ export default function lifecycleTest() {
"bundleName": "com.example.lifecycle_xts",
"abilityName": "MainAbility2",
}
globalThis.
globalThis.
abilityContext.startAbility(str2)
globalThis.abilityContext.startAbility(str2)
.then((data) => {
console.info(TAG + ' start successful. Data: ' + data);
}).catch((error) => {
...
...
@@ -1608,12 +1608,12 @@ export default function lifecycleTest() {
expect(exlist[2]).assertEqual("MainAbility2 onAbilityForeground");
expect(exlist[3]).assertEqual("MainAbility2 onAbilityBackground");
expect(exlist[4]).assertEqual("MainAbility2 onWindowStageDestroy");
expect(exlist
12[0
]).assertEqual("MainAbility2 onAbilityDestroy");
expect(exlist12[
1
]).assertEqual("MainAbility12 onAbilityCreate");
expect(exlist12[
2
]).assertEqual("MainAbility12 onWindowStageCreate");
expect(exlist12[
3
]).assertEqual("MainAbility12 onAbilityForeground");
expect(exlist12[
4
]).assertEqual("MainAbility12 onAbilityBackground");
expect(exlist12[
5
]).assertEqual("MainAbility12 onAbilityForeground");
expect(exlist
[5
]).assertEqual("MainAbility2 onAbilityDestroy");
expect(exlist12[
0
]).assertEqual("MainAbility12 onAbilityCreate");
expect(exlist12[
1
]).assertEqual("MainAbility12 onWindowStageCreate");
expect(exlist12[
2
]).assertEqual("MainAbility12 onAbilityForeground");
expect(exlist12[
3
]).assertEqual("MainAbility12 onAbilityBackground");
expect(exlist12[
4
]).assertEqual("MainAbility12 onAbilityForeground");
expect(exlist1[0]).assertEqual("MainAbility2 onAbilityCreate");
expect(exlist1[1]).assertEqual("MainAbility2 onWindowStageCreate");
expect(exlist1[2]).assertEqual("MainAbility2 onAbilityForeground");
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录