Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
OpenHarmony
Xts Acts
提交
232cbfd6
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看板
未验证
提交
232cbfd6
编写于
9月 06, 2022
作者:
O
openharmony_ci
提交者:
Gitee
9月 06, 2022
浏览文件
操作
浏览文件
下载
差异文件
!5356 XTS-master元能力代码上库-XTS_AACommandTest用例优化
Merge pull request !5356 from chengxingzhen/master
上级
1fc61227
f33ca160
变更
4
隐藏空白更改
内联
并排
Showing
4 changed file
with
519 addition
and
560 deletion
+519
-560
ability/ability_runtime/aacommand/AACommandPrintSyncTest/entry/src/main/ets/MainAbility/MainAbility.ts
...intSyncTest/entry/src/main/ets/MainAbility/MainAbility.ts
+60
-1
ability/ability_runtime/aacommand/AACommandPrintSyncTest/entry/src/main/ets/pages/index.ets
...AACommandPrintSyncTest/entry/src/main/ets/pages/index.ets
+0
-74
ability/ability_runtime/aacommand/AACommandtest/entry/src/main/ets/MainAbility/MainAbility.ts
...Commandtest/entry/src/main/ets/MainAbility/MainAbility.ts
+459
-1
ability/ability_runtime/aacommand/AACommandtest/entry/src/main/ets/pages/index.ets
...acommand/AACommandtest/entry/src/main/ets/pages/index.ets
+0
-484
未找到文件。
ability/ability_runtime/aacommand/AACommandPrintSyncTest/entry/src/main/ets/MainAbility/MainAbility.ts
浏览文件 @
232cbfd6
...
...
@@ -14,11 +14,70 @@
*/
import
Ability
from
'
@ohos.application.Ability
'
import
AbilityDelegatorRegistry
from
'
@ohos.application.abilityDelegatorRegistry
'
import
{
Hypium
}
from
'
@ohos/hypium
'
import
testsuite
from
'
../test/List.test
'
export
default
class
MainAbility
extends
Ability
{
onCreate
(
want
,
launchParam
)
{
async
onCreate
(
want
,
launchParam
)
{
globalThis
.
abilityContext
=
this
.
context
;
console
.
log
(
'
MainAbility onCreate
'
)
let
cmd
:
any
let
abilityDelegatorArguments
:
any
let
abilityDelegator
:
any
function
sleep
(
ms
)
{
return
new
Promise
(
resolve
=>
setTimeout
(
resolve
,
ms
));
}
abilityDelegator
=
AbilityDelegatorRegistry
.
getAbilityDelegator
()
abilityDelegatorArguments
=
AbilityDelegatorRegistry
.
getArguments
()
cmd
=
'
aa test -b com.example.aacommandprintsync -m entry_test -s class
'
+
'
ACTS_AACommand_01_3#ACTS_AACommand_printSync_01_0100 -s unittest OpenHarmonyTestRunner
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
log
(
'
ACTS_AACommand_printSync_01_0100 start err:
'
+
JSON
.
stringify
(
err
))
console
.
log
(
'
ACTS_AACommand_printSync_01_0100 stdResult =
'
+
data
.
stdResult
)
globalThis
.
stdResult1
=
data
.
stdResult
;
console
.
log
(
'
ACTS_AACommand_printSync_01_0100 - executeShellCommand: end
'
)
})
await
sleep
(
3000
)
cmd
=
'
aa test -m entry_test -b com.example.aacommandprintsync -s class
'
+
'
ACTS_AACommand_01_3#ACTS_AACommand_printSync_01_0200 -s unittest OpenHarmonyTestRunner
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
log
(
'
ACTS_AACommand_printSync_01_0200 start err:
'
+
JSON
.
stringify
(
err
))
console
.
log
(
'
ACTS_AACommand_printSync_01_0200 stdResult =
'
+
data
.
stdResult
)
globalThis
.
stdResult2
=
data
.
stdResult
;
console
.
log
(
'
ACTS_AACommand_printSync_01_0200 - executeShellCommand: end
'
)
})
await
sleep
(
3000
)
cmd
=
'
aa test -m entry_test -b com.example.aacommandprintsync -s class
'
+
'
ACTS_AACommand_01_3#ACTS_AACommand_printSync_01_0300 -s unittest OpenHarmonyTestRunner
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
log
(
'
ACTS_AACommand_printSync_01_0300 start err:
'
+
JSON
.
stringify
(
err
))
console
.
log
(
'
ACTS_AACommand_printSync_01_0300 stdResult =
'
+
data
.
stdResult
)
globalThis
.
stdResult3
=
data
.
stdResult
;
console
.
log
(
'
ACTS_AACommand_printSync_01_0300 - executeShellCommand: end
'
)
})
await
sleep
(
3000
)
cmd
=
'
aa test -m entry_test -b com.example.aacommandprintsync -s class
'
+
'
ACTS_AACommand_01_3#ACTS_AACommand_printSync_01_0400 -s unittest OpenHarmonyTestRunner
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
log
(
'
ACTS_AACommand_printSync_01_0400 start err:
'
+
JSON
.
stringify
(
err
))
console
.
log
(
'
ACTS_AACommand_printSync_01_0400 stdResult =
'
+
data
.
stdResult
)
globalThis
.
stdResult4
=
data
.
stdResult
;
console
.
log
(
'
ACTS_AACommand_printSync_01_0400 - executeShellCommand: end
'
)
})
setTimeout
(()
=>
{
Hypium
.
hypiumTest
(
abilityDelegator
,
abilityDelegatorArguments
,
testsuite
)
},
5000
)
}
onDestroy
()
{
...
...
ability/ability_runtime/aacommand/AACommandPrintSyncTest/entry/src/main/ets/pages/index.ets
浏览文件 @
232cbfd6
...
...
@@ -13,83 +13,9 @@
* limitations under the License.
*/
import AbilityDelegatorRegistry from '@ohos.application.abilityDelegatorRegistry'
import { Hypium } from '@ohos/hypium'
import testsuite from '../test/List.test'
@Entry
@Component
struct Index {
aboutToAppear() {
console.info('MainAbility index aboutToAppear')
console.info('start run testcase!!!')
let cmd: any
let abilityDelegatorArguments: any
let abilityDelegator: any
function sleep(delay) {
let start = (new Date()).getTime();
while ((new Date()).getTime() - start < delay) {
continue;
}
}
function test(time) {
sleep(time);
}
abilityDelegator = AbilityDelegatorRegistry.getAbilityDelegator()
abilityDelegatorArguments = AbilityDelegatorRegistry.getArguments()
cmd = 'aa test -b com.example.aacommandprintsync -m entry_test -s class ' +
'ACTS_AACommand_01_3#ACTS_AACommand_printSync_01_0100 -s unittest OpenHarmonyTestRunner'
globalThis.abilityDelegator.executeShellCommand(cmd, (err, data) => {
console.log('ACTS_AACommand_printSync_01_0100 start err: ' + JSON.stringify(err))
console.log('ACTS_AACommand_printSync_01_0100 stdResult = ' + data.stdResult)
globalThis.stdResult1 = data.stdResult;
console.log('ACTS_AACommand_printSync_01_0100 - executeShellCommand: end ')
})
test(3000)
cmd = 'aa test -m entry_test -b com.example.aacommandprintsync -s class ' +
'ACTS_AACommand_01_3#ACTS_AACommand_printSync_01_0200 -s unittest OpenHarmonyTestRunner'
globalThis.abilityDelegator.executeShellCommand(cmd, (err, data) => {
console.log('ACTS_AACommand_printSync_01_0200 start err: ' + JSON.stringify(err))
console.log('ACTS_AACommand_printSync_01_0200 stdResult = ' + data.stdResult)
globalThis.stdResult2 = data.stdResult;
console.log('ACTS_AACommand_printSync_01_0200 - executeShellCommand: end ')
})
test(3000)
cmd = 'aa test -m entry_test -b com.example.aacommandprintsync -s class ' +
'ACTS_AACommand_01_3#ACTS_AACommand_printSync_01_0300 -s unittest OpenHarmonyTestRunner'
globalThis.abilityDelegator.executeShellCommand(cmd, (err, data) => {
console.log('ACTS_AACommand_printSync_01_0300 start err: ' + JSON.stringify(err))
console.log('ACTS_AACommand_printSync_01_0300 stdResult = ' + data.stdResult)
globalThis.stdResult3 = data.stdResult;
console.log('ACTS_AACommand_printSync_01_0300 - executeShellCommand: end ')
})
test(3000)
cmd = 'aa test -m entry_test -b com.example.aacommandprintsync -s class ' +
'ACTS_AACommand_01_3#ACTS_AACommand_printSync_01_0400 -s unittest OpenHarmonyTestRunner'
globalThis.abilityDelegator.executeShellCommand(cmd, (err, data) => {
console.log('ACTS_AACommand_printSync_01_0400 start err: ' + JSON.stringify(err))
console.log('ACTS_AACommand_printSync_01_0400 stdResult = ' + data.stdResult)
globalThis.stdResult4 = data.stdResult;
console.log('ACTS_AACommand_printSync_01_0400 - executeShellCommand: end ')
})
test(3000)
setTimeout(() => {
Hypium.hypiumTest(abilityDelegator, abilityDelegatorArguments, testsuite)
}, 15000)
}
@State message: string = 'Hello World'
build() {
Row() {
...
...
ability/ability_runtime/aacommand/AACommandtest/entry/src/main/ets/MainAbility/MainAbility.ts
浏览文件 @
232cbfd6
...
...
@@ -14,10 +14,468 @@
*/
import
Ability
from
'
@ohos.application.Ability
'
import
AbilityDelegatorRegistry
from
'
@ohos.application.abilityDelegatorRegistry
'
import
{
Hypium
}
from
'
@ohos/hypium
'
import
testsuite
from
'
../test/List.test
'
export
default
class
MainAbility
extends
Ability
{
onCreate
(
want
,
launchParam
)
{
async
onCreate
(
want
,
launchParam
)
{
console
.
log
(
'
MainAbility onCreate
'
)
let
cmd
:
any
let
abilityDelegatorArguments
:
any
let
abilityDelegator
:
any
function
sleep
(
ms
)
{
return
new
Promise
(
resolve
=>
setTimeout
(
resolve
,
ms
));
}
abilityDelegator
=
AbilityDelegatorRegistry
.
getAbilityDelegator
()
abilityDelegatorArguments
=
AbilityDelegatorRegistry
.
getArguments
()
await
sleep
(
500
)
cmd
=
'
aa test -m entry_test -b com.example.aacommandrelyhap -s
'
+
'
class ACTS_AACommand_01_3#ACTS_AACommand_finish_01_0700 -s unittest OpenHarmonyTestRunner
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
log
(
'
ACTS_AACommand_finish_01_0700 start err:
'
+
JSON
.
stringify
(
err
))
console
.
log
(
'
ACTS_AACommand_finish_01_0700 stdResult =
'
+
data
.
stdResult
)
globalThis
.
stdResult1
=
data
.
stdResult
;
console
.
log
(
'
ACTS_AACommand_finish_01_0700 - executeShellCommand: end
'
)
})
await
sleep
(
3000
)
cmd
=
'
aa dump -a
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
info
(
'
ACTS_AACommand_finish_01_0700 : err :
'
+
JSON
.
stringify
(
err
));
console
.
info
(
'
ACTS_AACommand_finish_01_0700 : data :
'
+
JSON
.
stringify
(
data
));
globalThis
.
stdResult2
=
data
[
"
stdResult
"
];
console
.
info
(
'
ACTS_AACommand_finish_01_0700 end
'
);
})
await
sleep
(
2000
)
cmd
=
'
aa test -b com.example.aacommandrelyhap -m entry_test -s class ACTS_AACommand_01_3#ACTS_AACo
'
+
'
mmand_print_01_0100 -s unittest OpenHarmonyTestRunner
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
log
(
'
ACTS_AACommand_print_01_0100 - executeShellCommand: start
'
)
console
.
log
(
'
ACTS_AACommand_print_01_0100 start err:
'
+
JSON
.
stringify
(
err
))
console
.
log
(
'
ACTS_AACommand_print_01_0100 stdResult =
'
+
data
.
stdResult
)
globalThis
.
stdResult3
=
data
.
stdResult
;
console
.
log
(
'
ACTS_AACommand_print_01_0100 - executeShellCommand: end
'
)
})
await
sleep
(
3000
)
cmd
=
'
aa test -m entry_test -b com.example.aacommandrelyhap -s class ACTS_AACommand_01_3#ACTS_AAComm
'
+
'
and_print_01_0200 -s unittest OpenHarmonyTestRunner
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
log
(
'
ACTS_AACommand_print_01_0200 - executeShellCommand: start
'
)
console
.
log
(
'
ACTS_AACommand_print_01_0200 start err:
'
+
JSON
.
stringify
(
err
))
console
.
log
(
'
ACTS_AACommand_print_01_0200 stdResult =
'
+
data
.
stdResult
)
globalThis
.
stdResult4
=
data
.
stdResult
;
console
.
log
(
'
ACTS_AACommand_print_01_0200 - executeShellCommand: end
'
)
})
await
sleep
(
3000
)
cmd
=
'
aa test -m entry_test -b com.example.aacommandrelyhap -s class ACTS_AACommand_01_3#ACTS_
'
+
'
AACommand_print_01_0300 -s unittest OpenHarmonyTestRunner
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
log
(
'
ACTS_AACommand_print_01_0300 - executeShellCommand: start
'
)
console
.
log
(
'
ACTS_AACommand_print_01_0300 start err:
'
+
JSON
.
stringify
(
err
))
console
.
log
(
'
ACTS_AACommand_print_01_0300 stdResult =
'
+
data
.
stdResult
)
globalThis
.
stdResult5
=
data
.
stdResult
;
console
.
log
(
'
ACTS_AACommand_print_01_0300 - executeShellCommand: end
'
)
})
await
sleep
(
3000
)
cmd
=
'
aa test -m entry_test -b com.example.aacommandrelyhap -s class ACTS_AACommand_01_3#ACTS_AAComma
'
+
'
nd_print_01_0400 -s unittest OpenHarmonyTestRunner
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
log
(
'
ACTS_AACommand_print_01_0400 - executeShellCommand: start
'
)
console
.
log
(
'
ACTS_AACommand_print_01_0400 start err:
'
+
JSON
.
stringify
(
err
))
console
.
log
(
'
ACTS_AACommand_print_01_0400 stdResult =
'
+
data
.
stdResult
)
globalThis
.
stdResult6
=
data
.
stdResult
;
console
.
log
(
'
ACTS_AACommand_print_01_0400 - executeShellCommand: end
'
)
})
await
sleep
(
3000
)
cmd
=
'
aa test -m entry_test -b com.example.aacommandrelyhap -s class ACTS_AACommand_01_3#ACTS_AAComm
'
+
'
and_print_01_0500 -s unittest OpenHarmonyTestRunner
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
log
(
'
ACTS_AACommand_print_01_0500 - executeShellCommand: start
'
)
console
.
log
(
'
ACTS_AACommand_print_01_0500 start err:
'
+
JSON
.
stringify
(
err
))
console
.
log
(
'
ACTS_AACommand_print_01_0500 stdResult =
'
+
data
.
stdResult
)
globalThis
.
stdResult7
=
data
.
stdResult
;
console
.
log
(
'
ACTS_AACommand_print_01_0500 - executeShellCommand: end
'
)
})
await
sleep
(
3000
)
cmd
=
'
aa test -m entry_test -b com.example.aacommandrelyhap -s class ACTS_AACommand_01_3#ACTS_AA
'
+
'
Command_print_01_0600 -s unittest OpenHarmonyTestRunner
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
log
(
'
ACTS_AACommand_print_01_0600 - executeShellCommand: start
'
)
console
.
log
(
'
ACTS_AACommand_print_01_0600 start err:
'
+
JSON
.
stringify
(
err
))
console
.
log
(
'
ACTS_AACommand_print_01_0600 stdResult =
'
+
data
.
stdResult
)
globalThis
.
stdResult8
=
data
.
stdResult
;
console
.
log
(
'
ACTS_AACommand_print_01_0600 - executeShellCommand: end
'
)
})
await
sleep
(
3000
)
cmd
=
'
aa test -m entry_test -b com.example.aacommandrelyhap -s class
'
+
'
ACTS_AACommand_01_3#ACTS_AACommand_print_01_0700 -s unittest OpenHarmonyTestRunner
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
log
(
'
ACTS_AACommand_print_01_0700 - executeShellCommand: start
'
)
console
.
log
(
'
ACTS_AACommand_print_01_0700 start err:
'
+
JSON
.
stringify
(
err
))
console
.
log
(
'
ACTS_AACommand_print_01_0700 stdResult =
'
+
data
.
stdResult
)
globalThis
.
stdResult9
=
data
.
stdResult
;
console
.
log
(
'
ACTS_AACommand_print_01_0700 - executeShellCommand: end
'
)
})
await
sleep
(
3000
)
cmd
=
'
aa test -m entry_test -b com.example.aacommandrelyhap -s
'
+
'
class ACTS_AACommand_01_3#ACTS_AACommand_print_01_0800 -s unittest OpenHarmonyTestRunner
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
log
(
'
ACTS_AACommand_print_01_0800 - executeShellCommand: start
'
)
console
.
log
(
'
ACTS_AACommand_print_01_0800 start err:
'
+
JSON
.
stringify
(
err
))
console
.
log
(
'
ACTS_AACommand_print_01_0800 stdResult =
'
+
data
.
stdResult
)
globalThis
.
stdResult10
=
data
.
stdResult
;
console
.
log
(
'
ACTS_AACommand_print_01_0800 - executeShellCommand: end
'
)
})
await
sleep
(
3000
)
cmd
=
'
aa test -m entry_test -b com.example.aacommandrelyhap -s class
'
+
'
ACTS_AACommand_01_3#ACTS_AACommand_finish_01_0400 -s unittest OpenHarmonyTestRunner
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
log
(
'
ACTS_AACommand_finish_01_0400 - executeShellCommand: start
'
)
console
.
log
(
'
ACTS_AACommand_finish_01_0400 start err:
'
+
JSON
.
stringify
(
err
))
console
.
log
(
'
ACTS_AACommand_finish_01_0400 stdResult =
'
+
data
.
stdResult
)
globalThis
.
stdResult11
=
data
.
stdResult
;
console
.
log
(
'
ACTS_AACommand_finish_01_0400 - executeShellCommand: end
'
)
})
await
sleep
(
3000
)
cmd
=
'
aa dump -a
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
info
(
'
ACTS_AACommand_finish_01_0700 : err :
'
+
JSON
.
stringify
(
err
));
console
.
info
(
'
ACTS_AACommand_finish_01_0700 : data :
'
+
JSON
.
stringify
(
data
));
globalThis
.
stdResult12
=
data
[
"
stdResult
"
];
console
.
info
(
'
ACTS_AACommand_finish_01_0700 end
'
);
})
await
sleep
(
2000
)
cmd
=
'
aa test -m entry_test -b com.example.aacommandrelyhap -s
'
+
'
class ACTS_AACommand_01_3#ACTS_AACommand_finish_01_0100 -s unittest OpenHarmonyTestRunner
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
log
(
'
ACTS_AACommand_finish_01_0100 - executeShellCommand: start
'
)
console
.
log
(
'
ACTS_AACommand_finish_01_0100 start err:
'
+
JSON
.
stringify
(
err
))
console
.
log
(
'
ACTS_AACommand_finish_01_0100 stdResult =
'
+
data
.
stdResult
)
globalThis
.
stdResult13
=
data
.
stdResult
;
console
.
log
(
'
ACTS_AACommand_finish_01_0100 - executeShellCommand: end
'
)
})
await
sleep
(
3000
)
cmd
=
'
aa dump -a
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
info
(
'
ACTS_AACommand_finish_01_0700 : err :
'
+
JSON
.
stringify
(
err
));
console
.
info
(
'
ACTS_AACommand_finish_01_0700 : data :
'
+
JSON
.
stringify
(
data
));
globalThis
.
stdResult14
=
data
[
"
stdResult
"
];
console
.
info
(
'
ACTS_AACommand_finish_01_0700 end
'
);
})
await
sleep
(
2000
)
cmd
=
'
aa test -m entry_test -b com.example.aacommandrelyhap -s class
'
+
'
ACTS_AACommand_01_3#ACTS_AACommand_finish_01_0500 -s unittest OpenHarmonyTestRunner
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
log
(
'
ACTS_AACommand_finish_01_0500 - executeShellCommand: start
'
)
console
.
log
(
'
ACTS_AACommand_finish_01_0500 start err:
'
+
JSON
.
stringify
(
err
))
console
.
log
(
'
ACTS_AACommand_finish_01_0500 stdResult =
'
+
data
.
stdResult
)
globalThis
.
stdResult15
=
data
.
stdResult
;
console
.
log
(
'
ACTS_AACommand_finish_01_0500 - executeShellCommand: end
'
)
})
await
sleep
(
3000
)
cmd
=
'
aa dump -a
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
info
(
'
ACTS_AACommand_finish_01_0500 : err :
'
+
JSON
.
stringify
(
err
));
console
.
info
(
'
ACTS_AACommand_finish_01_0500 : data :
'
+
JSON
.
stringify
(
data
));
globalThis
.
stdResult16
=
data
[
"
stdResult
"
];
console
.
info
(
'
ACTS_AACommand_finish_01_0500 end
'
);
})
await
sleep
(
2000
)
cmd
=
'
aa test -m entry_test -b com.example.aacommandrelyhap -s
'
+
'
class ACTS_AACommand_01_3#ACTS_AACommand_finish_01_0600 -s unittest OpenHarmonyTestRunner
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
log
(
'
ACTS_AACommand_finish_01_0600 - executeShellCommand: start
'
)
console
.
log
(
'
ACTS_AACommand_finish_01_0600 start err:
'
+
JSON
.
stringify
(
err
))
console
.
log
(
'
ACTS_AACommand_finish_01_0600 stdResult =
'
+
data
.
stdResult
)
globalThis
.
stdResult17
=
data
.
stdResult
;
console
.
log
(
'
ACTS_AACommand_finish_01_0600 - executeShellCommand: end
'
)
})
await
sleep
(
3000
)
cmd
=
'
aa dump -a
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
info
(
'
ACTS_AACommand_finish_01_0600 : err :
'
+
JSON
.
stringify
(
err
));
console
.
info
(
'
ACTS_AACommand_finish_01_0600 : data :
'
+
JSON
.
stringify
(
data
));
globalThis
.
stdResult18
=
data
[
"
stdResult
"
];
console
.
info
(
'
ACTS_AACommand_finish_01_0600 end
'
);
})
await
sleep
(
2000
)
cmd
=
'
aa test -m entry_test -b com.example.aacommandrelyhap -s
'
+
'
class ACTS_AACommand_01_3#ACTS_AACommand_finish_01_0900 -s unittest OpenHarmonyTestRunner
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
log
(
'
ACTS_AACommand_finish_01_0900 - executeShellCommand: start
'
)
console
.
log
(
'
ACTS_AACommand_finish_01_0900 start err:
'
+
JSON
.
stringify
(
err
))
console
.
log
(
'
ACTS_AACommand_finish_01_0900 stdResult =
'
+
data
.
stdResult
)
globalThis
.
stdResult19
=
data
.
stdResult
;
console
.
log
(
'
ACTS_AACommand_finish_01_0900 - executeShellCommand: end
'
)
})
await
sleep
(
3000
)
cmd
=
'
aa dump -a
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
info
(
'
ACTS_AACommand_finish_01_0900 : err :
'
+
JSON
.
stringify
(
err
));
console
.
info
(
'
ACTS_AACommand_finish_01_0900 : data :
'
+
JSON
.
stringify
(
data
));
globalThis
.
stdResult20
=
data
[
"
stdResult
"
];
console
.
info
(
'
ACTS_AACommand_finish_01_0900 end
'
);
})
await
sleep
(
2000
)
cmd
=
'
aa test -m entry_test -b com.example.aacommandrelyhap
'
+
'
-s class ACTS_AACommand_01_3#ACTS_AACommand_finish_01_1200 -s unittest OpenHarmonyTestRunner
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
log
(
'
ACTS_AACommand_finish_01_1200 - executeShellCommand: start
'
)
console
.
log
(
'
ACTS_AACommand_finish_01_1200 start err:
'
+
JSON
.
stringify
(
err
))
console
.
log
(
'
ACTS_AACommand_finish_01_1200 stdResult =
'
+
data
.
stdResult
)
globalThis
.
stdResult21
=
data
.
stdResult
;
console
.
log
(
'
ACTS_AACommand_finish_01_1200 - executeShellCommand: end
'
)
})
await
sleep
(
3000
)
cmd
=
'
aa dump -a
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
info
(
'
ACTS_AACommand_finish_01_1200 : err :
'
+
JSON
.
stringify
(
err
));
console
.
info
(
'
ACTS_AACommand_finish_01_1200 : data :
'
+
JSON
.
stringify
(
data
));
globalThis
.
stdResult22
=
data
[
"
stdResult
"
];
console
.
info
(
'
ACTS_AACommand_finish_01_1200 end
'
);
})
await
sleep
(
2000
)
cmd
=
'
aa test -m entry_test -b com.example.aacommandrelyhap
'
+
'
-s class ACTS_AACommand_01_3#ACTS_AACommand_finish_01_1300 -s unittest OpenHarmonyTestRunner
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
log
(
'
ACTS_AACommand_finish_01_1300 - executeShellCommand: start
'
)
console
.
log
(
'
ACTS_AACommand_finish_01_1300 start err:
'
+
JSON
.
stringify
(
err
))
console
.
log
(
'
ACTS_AACommand_finish_01_1300 stdResult =
'
+
data
.
stdResult
)
globalThis
.
stdResult23
=
data
.
stdResult
;
console
.
log
(
'
ACTS_AACommand_finish_01_1300 - executeShellCommand: end
'
)
})
await
sleep
(
3000
)
cmd
=
'
aa dump -a
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
info
(
'
ACTS_AACommand_finish_01_1300 : err :
'
+
JSON
.
stringify
(
err
));
console
.
info
(
'
ACTS_AACommand_finish_01_1300 : data :
'
+
JSON
.
stringify
(
data
));
globalThis
.
stdResult24
=
data
[
"
stdResult
"
];
console
.
info
(
'
ACTS_AACommand_finish_01_1300 end
'
);
})
await
sleep
(
2000
)
cmd
=
'
aa test -m entry_test -b com.example.aacommandrelyhap
'
+
'
-s class ACTS_AACommand_01_3#ACTS_AACommand_finish_01_1400 -s unittest OpenHarmonyTestRunner
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
log
(
'
ACTS_AACommand_finish_01_1400 - executeShellCommand: start
'
)
console
.
log
(
'
ACTS_AACommand_finish_01_1400 start err:
'
+
JSON
.
stringify
(
err
))
console
.
log
(
'
ACTS_AACommand_finish_01_1400 stdResult =
'
+
data
.
stdResult
)
globalThis
.
stdResult25
=
data
.
stdResult
;
console
.
log
(
'
ACTS_AACommand_finish_01_1400 - executeShellCommand: end
'
)
})
await
sleep
(
3000
)
cmd
=
'
aa dump -a
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
info
(
'
ACTS_AACommand_finish_01_1400 : err :
'
+
JSON
.
stringify
(
err
));
console
.
info
(
'
ACTS_AACommand_finish_01_1400 : data :
'
+
JSON
.
stringify
(
data
));
globalThis
.
stdResult26
=
data
[
"
stdResult
"
];
console
.
info
(
'
ACTS_AACommand_finish_01_1400 end
'
);
})
await
sleep
(
2000
)
cmd
=
'
aa test -m entry_test -b com.example.aacommandrelyhap
'
+
'
-s class ACTS_AACommand_01_3#ACTS_AACommand_finish_01_1500 -s unittest OpenHarmonyTestRunner
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
log
(
'
ACTS_AACommand_finish_01_1500 - executeShellCommand: start
'
)
console
.
log
(
'
ACTS_AACommand_finish_01_1500 start err:
'
+
JSON
.
stringify
(
err
))
console
.
log
(
'
ACTS_AACommand_finish_01_1500 stdResult =
'
+
data
.
stdResult
)
globalThis
.
stdResult27
=
data
.
stdResult
;
console
.
log
(
'
ACTS_AACommand_finish_01_1500 - executeShellCommand: end
'
)
})
await
sleep
(
3000
)
cmd
=
'
aa dump -a
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
info
(
'
ACTS_AACommand_finish_01_1500 : err :
'
+
JSON
.
stringify
(
err
));
console
.
info
(
'
ACTS_AACommand_finish_01_1500 : data :
'
+
JSON
.
stringify
(
data
));
globalThis
.
stdResult28
=
data
[
"
stdResult
"
];
console
.
info
(
'
ACTS_AACommand_finish_01_1500 end
'
);
})
await
sleep
(
2000
)
cmd
=
'
aa test -m entry_test -b com.example.aacommandrelyhap
'
+
'
-s class ACTS_AACommand_01_3#ACTS_AACommand_finish_01_0200 -s unittest OpenHarmonyTestRunner
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
log
(
'
ACTS_AACommand_finish_01_0200 - executeShellCommand: start
'
)
console
.
log
(
'
ACTS_AACommand_finish_01_0200 start err:
'
+
JSON
.
stringify
(
err
))
console
.
log
(
'
ACTS_AACommand_finish_01_0200 stdResult =
'
+
data
.
stdResult
)
console
.
log
(
'
ACTS_AACommand_finish_01_0200 - executeShellCommand: end
'
)
})
await
sleep
(
3000
)
cmd
=
'
aa dump -a
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
info
(
'
ACTS_AACommand_finish_01_0200 : err :
'
+
JSON
.
stringify
(
err
));
console
.
info
(
'
ACTS_AACommand_finish_01_0200 : data :
'
+
JSON
.
stringify
(
data
));
globalThis
.
stdResult29
=
data
[
"
stdResult
"
];
console
.
info
(
'
ACTS_AACommand_finish_01_0200 end
'
);
})
await
sleep
(
2000
)
cmd
=
'
aa test -m entry_test -b com.example.aacommandrelyhap
'
+
'
-s class ACTS_AACommand_01_3#ACTS_AACommand_finish_01_0300 -s unittest OpenHarmonyTestRunner
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
log
(
'
ACTS_AACommand_finish_01_0300 - executeShellCommand: start
'
)
console
.
log
(
'
ACTS_AACommand_finish_01_0300 start err:
'
+
JSON
.
stringify
(
err
))
console
.
log
(
'
ACTS_AACommand_finish_01_0300 stdResult =
'
+
data
.
stdResult
)
console
.
log
(
'
ACTS_AACommand_finish_01_0300 - executeShellCommand: end
'
)
})
await
sleep
(
3000
)
cmd
=
'
aa dump -a
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
info
(
'
ACTS_AACommand_finish_01_0300 : err :
'
+
JSON
.
stringify
(
err
));
console
.
info
(
'
ACTS_AACommand_finish_01_0300 : data :
'
+
JSON
.
stringify
(
data
));
globalThis
.
stdResult30
=
data
[
"
stdResult
"
];
console
.
info
(
'
ACTS_AACommand_finish_01_0300 end
'
);
})
await
sleep
(
2000
)
cmd
=
'
aa test -m entry_test -b com.example.aacommandrelyhap -s
'
+
'
class ACTS_AACommand_01_3#ACTS_AACommand_finish_01_0800 -s unittest OpenHarmonyTestRunner
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
log
(
'
ACTS_AACommand_finish_01_0800 - executeShellCommand: start
'
)
console
.
log
(
'
ACTS_AACommand_finish_01_0800 start err:
'
+
JSON
.
stringify
(
err
))
console
.
log
(
'
ACTS_AACommand_finish_01_0800 stdResult =
'
+
data
.
stdResult
)
console
.
log
(
'
ACTS_AACommand_finish_01_0800 - executeShellCommand: end
'
)
})
await
sleep
(
3000
)
cmd
=
'
aa dump -a
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
info
(
'
ACTS_AACommand_finish_01_0800 : err :
'
+
JSON
.
stringify
(
err
));
console
.
info
(
'
ACTS_AACommand_finish_01_0800 : data :
'
+
JSON
.
stringify
(
data
));
globalThis
.
stdResult31
=
data
[
"
stdResult
"
];
console
.
info
(
'
ACTS_AACommand_finish_01_0800 end
'
);
})
await
sleep
(
2000
)
cmd
=
'
aa test -m entry_test -b com.example.aacommandrelyhap -s
'
+
'
class ACTS_AACommand_01_3#ACTS_AACommand_finish_01_1000 -s unittest OpenHarmonyTestRunner
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
log
(
'
ACTS_AACommand_finish_01_1000 - executeShellCommand: start
'
)
console
.
log
(
'
ACTS_AACommand_finish_01_1000 start err:
'
+
JSON
.
stringify
(
err
))
console
.
log
(
'
ACTS_AACommand_finish_01_1000 stdResult =
'
+
data
.
stdResult
)
console
.
log
(
'
ACTS_AACommand_finish_01_1000 - executeShellCommand: end
'
)
})
await
sleep
(
3000
)
cmd
=
'
aa dump -a
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
info
(
'
ACTS_AACommand_finish_01_1000 : err :
'
+
JSON
.
stringify
(
err
));
console
.
info
(
'
ACTS_AACommand_finish_01_1000 : data :
'
+
JSON
.
stringify
(
data
));
globalThis
.
stdResult32
=
data
[
"
stdResult
"
];
console
.
info
(
'
ACTS_AACommand_finish_01_1000 end
'
);
})
await
sleep
(
2000
)
cmd
=
'
aa test -m entry_test -b com.example.aacommandrelyhap
'
+
'
-s class ACTS_AACommand_01_3#ACTS_AACommand_finish_01_1100 -s unittest OpenHarmonyTestRunner
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
log
(
'
ACTS_AACommand_finish_01_1100 - executeShellCommand: start
'
)
console
.
log
(
'
ACTS_AACommand_finish_01_1100 start err:
'
+
JSON
.
stringify
(
err
))
console
.
log
(
'
ACTS_AACommand_finish_01_1100 stdResult =
'
+
data
.
stdResult
)
console
.
log
(
'
ACTS_AACommand_finish_01_1100 - executeShellCommand: end
'
)
})
await
sleep
(
3000
)
cmd
=
'
aa dump -a
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
info
(
'
ACTS_AACommand_finish_01_1100 : err :
'
+
JSON
.
stringify
(
err
));
console
.
info
(
'
ACTS_AACommand_finish_01_1100 : data :
'
+
JSON
.
stringify
(
data
));
globalThis
.
stdResult33
=
data
[
"
stdResult
"
];
console
.
info
(
'
ACTS_AACommand_finish_01_1100 end
'
);
})
await
sleep
(
2000
)
cmd
=
'
aa test -m entry_test -b com.example.aacommandrelyhap
'
+
'
-s class ACTS_AACommand_01_3#ACTS_AACommand_finish_01_1600 -s unittest OpenHarmonyTestRunner
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
log
(
'
ACTS_AACommand_finish_01_1600 - executeShellCommand: start
'
)
console
.
log
(
'
ACTS_AACommand_finish_01_1600 start err:
'
+
JSON
.
stringify
(
err
))
console
.
log
(
'
ACTS_AACommand_finish_01_1600 stdResult =
'
+
data
.
stdResult
)
console
.
log
(
'
ACTS_AACommand_finish_01_1600 - executeShellCommand: end
'
)
})
await
sleep
(
3000
)
cmd
=
'
aa dump -a
'
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
,
data
)
=>
{
console
.
info
(
'
ACTS_AACommand_finish_01_1600 : err :
'
+
JSON
.
stringify
(
err
));
console
.
info
(
'
ACTS_AACommand_finish_01_1600 : data :
'
+
JSON
.
stringify
(
data
));
globalThis
.
stdResult34
=
data
[
"
stdResult
"
];
console
.
info
(
'
ACTS_AACommand_finish_01_1600 end
'
);
})
setTimeout
(()
=>
{
Hypium
.
hypiumTest
(
abilityDelegator
,
abilityDelegatorArguments
,
testsuite
)
},
5000
)
}
onDestroy
()
{
...
...
ability/ability_runtime/aacommand/AACommandtest/entry/src/main/ets/pages/index.ets
浏览文件 @
232cbfd6
...
...
@@ -13,493 +13,9 @@
* limitations under the License.
*/
import AbilityDelegatorRegistry from '@ohos.application.abilityDelegatorRegistry'
import { Hypium } from '@ohos/hypium'
import testsuite from '../test/List.test'
@Entry
@Component
struct Index {
aboutToAppear() {
console.info('MainAbility index aboutToAppear')
console.info('start run testcase!!!')
let cmd: any
let abilityDelegatorArguments: any
let abilityDelegator: any
function sleep(delay) {
let start = (new Date()).getTime();
while ((new Date()).getTime() - start < delay) {
continue;
}
}
function test(time) {
sleep(time);
}
abilityDelegator = AbilityDelegatorRegistry.getAbilityDelegator()
abilityDelegatorArguments = AbilityDelegatorRegistry.getArguments()
cmd = 'aa test -m entry_test -b com.example.aacommandrelyhap -s ' +
'class ACTS_AACommand_01_3#ACTS_AACommand_finish_01_0700 -s unittest OpenHarmonyTestRunner'
globalThis.abilityDelegator.executeShellCommand(cmd, (err, data) => {
console.log('ACTS_AACommand_finish_01_0700 start err: ' + JSON.stringify(err))
console.log('ACTS_AACommand_finish_01_0700 stdResult = ' + data.stdResult)
globalThis.stdResult1 = data.stdResult;
console.log('ACTS_AACommand_finish_01_0700 - executeShellCommand: end ')
})
test(3000)
cmd = 'aa dump -a'
abilityDelegator.executeShellCommand(cmd,
(err, data) => {
console.info('ACTS_AACommand_finish_01_0700 : err : ' + JSON.stringify(err));
console.info('ACTS_AACommand_finish_01_0700 : data : ' + JSON.stringify(data));
globalThis.stdResult2 = data["stdResult"];
console.info('ACTS_AACommand_finish_01_0700 end');
})
test(3000)
cmd = 'aa test -b com.example.aacommandrelyhap -m entry_test -s class ACTS_AACommand_01_3#ACTS_AACo' +
'mmand_print_01_0100 -s unittest OpenHarmonyTestRunner'
globalThis.abilityDelegator.executeShellCommand(cmd, (err, data) => {
console.log('ACTS_AACommand_print_01_0100 - executeShellCommand: start ')
console.log('ACTS_AACommand_print_01_0100 start err: ' + JSON.stringify(err))
console.log('ACTS_AACommand_print_01_0100 stdResult = ' + data.stdResult)
globalThis.stdResult3 = data.stdResult;
console.log('ACTS_AACommand_print_01_0100 - executeShellCommand: end')
})
test(3000)
cmd = 'aa test -m entry_test -b com.example.aacommandrelyhap -s class ACTS_AACommand_01_3#ACTS_AAComm' +
'and_print_01_0200 -s unittest OpenHarmonyTestRunner'
globalThis.abilityDelegator.executeShellCommand(cmd, (err, data) => {
console.log('ACTS_AACommand_print_01_0200 - executeShellCommand: start ')
console.log('ACTS_AACommand_print_01_0200 start err: ' + JSON.stringify(err))
console.log('ACTS_AACommand_print_01_0200 stdResult = ' + data.stdResult)
globalThis.stdResult4 = data.stdResult;
console.log('ACTS_AACommand_print_01_0200 - executeShellCommand: end')
})
test(3000)
cmd = 'aa test -m entry_test -b com.example.aacommandrelyhap -s class ACTS_AACommand_01_3#ACTS_' +
'AACommand_print_01_0300 -s unittest OpenHarmonyTestRunner'
globalThis.abilityDelegator.executeShellCommand(cmd, (err, data) => {
console.log('ACTS_AACommand_print_01_0300 - executeShellCommand: start ')
console.log('ACTS_AACommand_print_01_0300 start err: ' + JSON.stringify(err))
console.log('ACTS_AACommand_print_01_0300 stdResult = ' + data.stdResult)
globalThis.stdResult5 = data.stdResult;
console.log('ACTS_AACommand_print_01_0300 - executeShellCommand: end')
})
test(3000)
cmd = 'aa test -m entry_test -b com.example.aacommandrelyhap -s class ACTS_AACommand_01_3#ACTS_AAComma' +
'nd_print_01_0400 -s unittest OpenHarmonyTestRunner'
globalThis.abilityDelegator.executeShellCommand(cmd, (err, data) => {
console.log('ACTS_AACommand_print_01_0400 - executeShellCommand: start ')
console.log('ACTS_AACommand_print_01_0400 start err: ' + JSON.stringify(err))
console.log('ACTS_AACommand_print_01_0400 stdResult = ' + data.stdResult)
globalThis.stdResult6 = data.stdResult;
console.log('ACTS_AACommand_print_01_0400 - executeShellCommand: end')
})
test(3000)
cmd = 'aa test -m entry_test -b com.example.aacommandrelyhap -s class ACTS_AACommand_01_3#ACTS_AAComm' +
'and_print_01_0500 -s unittest OpenHarmonyTestRunner'
globalThis.abilityDelegator.executeShellCommand(cmd, (err, data) => {
console.log('ACTS_AACommand_print_01_0500 - executeShellCommand: start ')
console.log('ACTS_AACommand_print_01_0500 start err: ' + JSON.stringify(err))
console.log('ACTS_AACommand_print_01_0500 stdResult = ' + data.stdResult)
globalThis.stdResult7 = data.stdResult;
console.log('ACTS_AACommand_print_01_0500 - executeShellCommand: end')
})
test(3000)
cmd = 'aa test -m entry_test -b com.example.aacommandrelyhap -s class ACTS_AACommand_01_3#ACTS_AA' +
'Command_print_01_0600 -s unittest OpenHarmonyTestRunner'
globalThis.abilityDelegator.executeShellCommand(cmd, (err, data) => {
console.log('ACTS_AACommand_print_01_0600 - executeShellCommand: start ')
console.log('ACTS_AACommand_print_01_0600 start err: ' + JSON.stringify(err))
console.log('ACTS_AACommand_print_01_0600 stdResult = ' + data.stdResult)
globalThis.stdResult8 = data.stdResult;
console.log('ACTS_AACommand_print_01_0600 - executeShellCommand: end')
})
test(3000)
cmd = 'aa test -m entry_test -b com.example.aacommandrelyhap -s class ' +
'ACTS_AACommand_01_3#ACTS_AACommand_print_01_0700 -s unittest OpenHarmonyTestRunner'
globalThis.abilityDelegator.executeShellCommand(cmd, (err, data) => {
console.log('ACTS_AACommand_print_01_0700 - executeShellCommand: start ')
console.log('ACTS_AACommand_print_01_0700 start err: ' + JSON.stringify(err))
console.log('ACTS_AACommand_print_01_0700 stdResult = ' + data.stdResult)
globalThis.stdResult9 = data.stdResult;
console.log('ACTS_AACommand_print_01_0700 - executeShellCommand: end')
})
test(3000)
cmd = 'aa test -m entry_test -b com.example.aacommandrelyhap -s ' +
'class ACTS_AACommand_01_3#ACTS_AACommand_print_01_0800 -s unittest OpenHarmonyTestRunner'
globalThis.abilityDelegator.executeShellCommand(cmd, (err, data) => {
console.log('ACTS_AACommand_print_01_0800 - executeShellCommand: start ')
console.log('ACTS_AACommand_print_01_0800 start err: ' + JSON.stringify(err))
console.log('ACTS_AACommand_print_01_0800 stdResult = ' + data.stdResult)
globalThis.stdResult10 = data.stdResult;
console.log('ACTS_AACommand_print_01_0800 - executeShellCommand: end')
})
test(3000)
cmd = 'aa test -m entry_test -b com.example.aacommandrelyhap -s class ' +
'ACTS_AACommand_01_3#ACTS_AACommand_finish_01_0400 -s unittest OpenHarmonyTestRunner'
globalThis.abilityDelegator.executeShellCommand(cmd, (err, data) => {
console.log('ACTS_AACommand_finish_01_0400 - executeShellCommand: start ')
console.log('ACTS_AACommand_finish_01_0400 start err: ' + JSON.stringify(err))
console.log('ACTS_AACommand_finish_01_0400 stdResult = ' + data.stdResult)
globalThis.stdResult11 = data.stdResult;
console.log('ACTS_AACommand_finish_01_0400 - executeShellCommand: end')
})
test(3000)
cmd = 'aa dump -a'
abilityDelegator.executeShellCommand(cmd,
(err, data) => {
console.info('ACTS_AACommand_finish_01_0700 : err : ' + JSON.stringify(err));
console.info('ACTS_AACommand_finish_01_0700 : data : ' + JSON.stringify(data));
globalThis.stdResult12 = data["stdResult"];
console.info('ACTS_AACommand_finish_01_0700 end');
})
test(3000)
cmd = 'aa test -m entry_test -b com.example.aacommandrelyhap -s ' +
'class ACTS_AACommand_01_3#ACTS_AACommand_finish_01_0100 -s unittest OpenHarmonyTestRunner'
globalThis.abilityDelegator.executeShellCommand(cmd, (err, data) => {
console.log('ACTS_AACommand_finish_01_0100 - executeShellCommand: start ')
console.log('ACTS_AACommand_finish_01_0100 start err: ' + JSON.stringify(err))
console.log('ACTS_AACommand_finish_01_0100 stdResult = ' + data.stdResult)
globalThis.stdResult13 = data.stdResult;
console.log('ACTS_AACommand_finish_01_0100 - executeShellCommand: end')
})
test(3000)
cmd = 'aa dump -a'
abilityDelegator.executeShellCommand(cmd,
(err, data) => {
console.info('ACTS_AACommand_finish_01_0700 : err : ' + JSON.stringify(err));
console.info('ACTS_AACommand_finish_01_0700 : data : ' + JSON.stringify(data));
globalThis.stdResult14 = data["stdResult"];
console.info('ACTS_AACommand_finish_01_0700 end');
})
test(3000)
cmd = 'aa test -m entry_test -b com.example.aacommandrelyhap -s class ' +
'ACTS_AACommand_01_3#ACTS_AACommand_finish_01_0500 -s unittest OpenHarmonyTestRunner'
globalThis.abilityDelegator.executeShellCommand(cmd, (err, data) => {
console.log('ACTS_AACommand_finish_01_0500 - executeShellCommand: start ')
console.log('ACTS_AACommand_finish_01_0500 start err: ' + JSON.stringify(err))
console.log('ACTS_AACommand_finish_01_0500 stdResult = ' + data.stdResult)
globalThis.stdResult15 = data.stdResult;
console.log('ACTS_AACommand_finish_01_0500 - executeShellCommand: end')
})
test(3000)
cmd = 'aa dump -a'
abilityDelegator.executeShellCommand(cmd,
(err, data) => {
console.info('ACTS_AACommand_finish_01_0500 : err : ' + JSON.stringify(err));
console.info('ACTS_AACommand_finish_01_0500 : data : ' + JSON.stringify(data));
globalThis.stdResult16 = data["stdResult"];
console.info('ACTS_AACommand_finish_01_0500 end');
})
test(3000)
cmd = 'aa test -m entry_test -b com.example.aacommandrelyhap -s ' +
'class ACTS_AACommand_01_3#ACTS_AACommand_finish_01_0600 -s unittest OpenHarmonyTestRunner'
globalThis.abilityDelegator.executeShellCommand(cmd, (err, data) => {
console.log('ACTS_AACommand_finish_01_0600 - executeShellCommand: start ')
console.log('ACTS_AACommand_finish_01_0600 start err: ' + JSON.stringify(err))
console.log('ACTS_AACommand_finish_01_0600 stdResult = ' + data.stdResult)
globalThis.stdResult17 = data.stdResult;
console.log('ACTS_AACommand_finish_01_0600 - executeShellCommand: end')
})
test(3000)
cmd = 'aa dump -a'
abilityDelegator.executeShellCommand(cmd,
(err, data) => {
console.info('ACTS_AACommand_finish_01_0600 : err : ' + JSON.stringify(err));
console.info('ACTS_AACommand_finish_01_0600 : data : ' + JSON.stringify(data));
globalThis.stdResult18 = data["stdResult"];
console.info('ACTS_AACommand_finish_01_0600 end');
})
test(3000)
cmd = 'aa test -m entry_test -b com.example.aacommandrelyhap -s ' +
'class ACTS_AACommand_01_3#ACTS_AACommand_finish_01_0900 -s unittest OpenHarmonyTestRunner'
globalThis.abilityDelegator.executeShellCommand(cmd, (err, data) => {
console.log('ACTS_AACommand_finish_01_0900 - executeShellCommand: start ')
console.log('ACTS_AACommand_finish_01_0900 start err: ' + JSON.stringify(err))
console.log('ACTS_AACommand_finish_01_0900 stdResult = ' + data.stdResult)
globalThis.stdResult19 = data.stdResult;
console.log('ACTS_AACommand_finish_01_0900 - executeShellCommand: end')
})
test(3000)
cmd = 'aa dump -a'
abilityDelegator.executeShellCommand(cmd,
(err, data) => {
console.info('ACTS_AACommand_finish_01_0900 : err : ' + JSON.stringify(err));
console.info('ACTS_AACommand_finish_01_0900 : data : ' + JSON.stringify(data));
globalThis.stdResult20 = data["stdResult"];
console.info('ACTS_AACommand_finish_01_0900 end');
})
test(3000)
cmd = 'aa test -m entry_test -b com.example.aacommandrelyhap' +
' -s class ACTS_AACommand_01_3#ACTS_AACommand_finish_01_1200 -s unittest OpenHarmonyTestRunner'
globalThis.abilityDelegator.executeShellCommand(cmd, (err, data) => {
console.log('ACTS_AACommand_finish_01_1200 - executeShellCommand: start ')
console.log('ACTS_AACommand_finish_01_1200 start err: ' + JSON.stringify(err))
console.log('ACTS_AACommand_finish_01_1200 stdResult = ' + data.stdResult)
globalThis.stdResult21 = data.stdResult;
console.log('ACTS_AACommand_finish_01_1200 - executeShellCommand: end')
})
test(3000)
cmd = 'aa dump -a'
abilityDelegator.executeShellCommand(cmd,
(err, data) => {
console.info('ACTS_AACommand_finish_01_1200 : err : ' + JSON.stringify(err));
console.info('ACTS_AACommand_finish_01_1200 : data : ' + JSON.stringify(data));
globalThis.stdResult22 = data["stdResult"];
console.info('ACTS_AACommand_finish_01_1200 end');
})
test(3000)
cmd = 'aa test -m entry_test -b com.example.aacommandrelyhap ' +
'-s class ACTS_AACommand_01_3#ACTS_AACommand_finish_01_1300 -s unittest OpenHarmonyTestRunner'
globalThis.abilityDelegator.executeShellCommand(cmd, (err, data) => {
console.log('ACTS_AACommand_finish_01_1300 - executeShellCommand: start ')
console.log('ACTS_AACommand_finish_01_1300 start err: ' + JSON.stringify(err))
console.log('ACTS_AACommand_finish_01_1300 stdResult = ' + data.stdResult)
globalThis.stdResult23 = data.stdResult;
console.log('ACTS_AACommand_finish_01_1300 - executeShellCommand: end')
})
test(3000)
cmd = 'aa dump -a'
abilityDelegator.executeShellCommand(cmd,
(err, data) => {
console.info('ACTS_AACommand_finish_01_1300 : err : ' + JSON.stringify(err));
console.info('ACTS_AACommand_finish_01_1300 : data : ' + JSON.stringify(data));
globalThis.stdResult24 = data["stdResult"];
console.info('ACTS_AACommand_finish_01_1300 end');
})
test(3000)
cmd = 'aa test -m entry_test -b com.example.aacommandrelyhap ' +
'-s class ACTS_AACommand_01_3#ACTS_AACommand_finish_01_1400 -s unittest OpenHarmonyTestRunner'
globalThis.abilityDelegator.executeShellCommand(cmd, (err, data) => {
console.log('ACTS_AACommand_finish_01_1400 - executeShellCommand: start ')
console.log('ACTS_AACommand_finish_01_1400 start err: ' + JSON.stringify(err))
console.log('ACTS_AACommand_finish_01_1400 stdResult = ' + data.stdResult)
globalThis.stdResult25 = data.stdResult;
console.log('ACTS_AACommand_finish_01_1400 - executeShellCommand: end')
})
test(3000)
cmd = 'aa dump -a'
abilityDelegator.executeShellCommand(cmd,
(err, data) => {
console.info('ACTS_AACommand_finish_01_1400 : err : ' + JSON.stringify(err));
console.info('ACTS_AACommand_finish_01_1400 : data : ' + JSON.stringify(data));
globalThis.stdResult26 = data["stdResult"];
console.info('ACTS_AACommand_finish_01_1400 end');
})
test(3000)
cmd = 'aa test -m entry_test -b com.example.aacommandrelyhap ' +
'-s class ACTS_AACommand_01_3#ACTS_AACommand_finish_01_1500 -s unittest OpenHarmonyTestRunner'
globalThis.abilityDelegator.executeShellCommand(cmd, (err, data) => {
console.log('ACTS_AACommand_finish_01_1500 - executeShellCommand: start ')
console.log('ACTS_AACommand_finish_01_1500 start err: ' + JSON.stringify(err))
console.log('ACTS_AACommand_finish_01_1500 stdResult = ' + data.stdResult)
globalThis.stdResult27 = data.stdResult;
console.log('ACTS_AACommand_finish_01_1500 - executeShellCommand: end')
})
test(3000)
cmd = 'aa dump -a'
abilityDelegator.executeShellCommand(cmd,
(err, data) => {
console.info('ACTS_AACommand_finish_01_1500 : err : ' + JSON.stringify(err));
console.info('ACTS_AACommand_finish_01_1500 : data : ' + JSON.stringify(data));
globalThis.stdResult28 = data["stdResult"];
console.info('ACTS_AACommand_finish_01_1500 end');
})
test(3000)
cmd = 'aa test -m entry_test -b com.example.aacommandrelyhap ' +
'-s class ACTS_AACommand_01_3#ACTS_AACommand_finish_01_0200 -s unittest OpenHarmonyTestRunner'
globalThis.abilityDelegator.executeShellCommand(cmd, (err, data) => {
console.log('ACTS_AACommand_finish_01_0200 - executeShellCommand: start ')
console.log('ACTS_AACommand_finish_01_0200 start err: ' + JSON.stringify(err))
console.log('ACTS_AACommand_finish_01_0200 stdResult = ' + data.stdResult)
console.log('ACTS_AACommand_finish_01_0200 - executeShellCommand: end')
})
test(3000)
cmd = 'aa dump -a'
abilityDelegator.executeShellCommand(cmd,
(err, data) => {
console.info('ACTS_AACommand_finish_01_0200 : err : ' + JSON.stringify(err));
console.info('ACTS_AACommand_finish_01_0200 : data : ' + JSON.stringify(data));
globalThis.stdResult29 = data["stdResult"];
console.info('ACTS_AACommand_finish_01_0200 end');
})
test(3000)
cmd = 'aa test -m entry_test -b com.example.aacommandrelyhap ' +
'-s class ACTS_AACommand_01_3#ACTS_AACommand_finish_01_0300 -s unittest OpenHarmonyTestRunner'
globalThis.abilityDelegator.executeShellCommand(cmd, (err, data) => {
console.log('ACTS_AACommand_finish_01_0300 - executeShellCommand: start ')
console.log('ACTS_AACommand_finish_01_0300 start err: ' + JSON.stringify(err))
console.log('ACTS_AACommand_finish_01_0300 stdResult = ' + data.stdResult)
console.log('ACTS_AACommand_finish_01_0300 - executeShellCommand: end')
})
test(3000)
cmd = 'aa dump -a'
abilityDelegator.executeShellCommand(cmd,
(err, data) => {
console.info('ACTS_AACommand_finish_01_0300 : err : ' + JSON.stringify(err));
console.info('ACTS_AACommand_finish_01_0300 : data : ' + JSON.stringify(data));
globalThis.stdResult30 = data["stdResult"];
console.info('ACTS_AACommand_finish_01_0300 end');
})
test(3000)
cmd = 'aa test -m entry_test -b com.example.aacommandrelyhap -s ' +
'class ACTS_AACommand_01_3#ACTS_AACommand_finish_01_0800 -s unittest OpenHarmonyTestRunner'
globalThis.abilityDelegator.executeShellCommand(cmd, (err, data) => {
console.log('ACTS_AACommand_finish_01_0800 - executeShellCommand: start ')
console.log('ACTS_AACommand_finish_01_0800 start err: ' + JSON.stringify(err))
console.log('ACTS_AACommand_finish_01_0800 stdResult = ' + data.stdResult)
console.log('ACTS_AACommand_finish_01_0800 - executeShellCommand: end')
})
test(3000)
cmd = 'aa dump -a'
abilityDelegator.executeShellCommand(cmd,
(err, data) => {
console.info('ACTS_AACommand_finish_01_0800 : err : ' + JSON.stringify(err));
console.info('ACTS_AACommand_finish_01_0800 : data : ' + JSON.stringify(data));
globalThis.stdResult31 = data["stdResult"];
console.info('ACTS_AACommand_finish_01_0800 end');
})
test(3000)
cmd = 'aa test -m entry_test -b com.example.aacommandrelyhap -s ' +
'class ACTS_AACommand_01_3#ACTS_AACommand_finish_01_1000 -s unittest OpenHarmonyTestRunner'
globalThis.abilityDelegator.executeShellCommand(cmd, (err, data) => {
console.log('ACTS_AACommand_finish_01_1000 - executeShellCommand: start ')
console.log('ACTS_AACommand_finish_01_1000 start err: ' + JSON.stringify(err))
console.log('ACTS_AACommand_finish_01_1000 stdResult = ' + data.stdResult)
console.log('ACTS_AACommand_finish_01_1000 - executeShellCommand: end')
})
test(3000)
cmd = 'aa dump -a'
abilityDelegator.executeShellCommand(cmd,
(err, data) => {
console.info('ACTS_AACommand_finish_01_1000 : err : ' + JSON.stringify(err));
console.info('ACTS_AACommand_finish_01_1000 : data : ' + JSON.stringify(data));
globalThis.stdResult32 = data["stdResult"];
console.info('ACTS_AACommand_finish_01_1000 end');
})
test(3000)
cmd = 'aa test -m entry_test -b com.example.aacommandrelyhap ' +
'-s class ACTS_AACommand_01_3#ACTS_AACommand_finish_01_1100 -s unittest OpenHarmonyTestRunner'
globalThis.abilityDelegator.executeShellCommand(cmd, (err, data) => {
console.log('ACTS_AACommand_finish_01_1100 - executeShellCommand: start ')
console.log('ACTS_AACommand_finish_01_1100 start err: ' + JSON.stringify(err))
console.log('ACTS_AACommand_finish_01_1100 stdResult = ' + data.stdResult)
console.log('ACTS_AACommand_finish_01_1100 - executeShellCommand: end')
})
test(3000)
cmd = 'aa dump -a'
abilityDelegator.executeShellCommand(cmd,
(err, data) => {
console.info('ACTS_AACommand_finish_01_1100 : err : ' + JSON.stringify(err));
console.info('ACTS_AACommand_finish_01_1100 : data : ' + JSON.stringify(data));
globalThis.stdResult33 = data["stdResult"];
console.info('ACTS_AACommand_finish_01_1100 end');
})
test(3000)
cmd = 'aa test -m entry_test -b com.example.aacommandrelyhap' +
' -s class ACTS_AACommand_01_3#ACTS_AACommand_finish_01_1600 -s unittest OpenHarmonyTestRunner'
globalThis.abilityDelegator.executeShellCommand(cmd, (err, data) => {
console.log('ACTS_AACommand_finish_01_1600 - executeShellCommand: start ')
console.log('ACTS_AACommand_finish_01_1600 start err: ' + JSON.stringify(err))
console.log('ACTS_AACommand_finish_01_1600 stdResult = ' + data.stdResult)
console.log('ACTS_AACommand_finish_01_1600 - executeShellCommand: end')
})
test(3000)
cmd = 'aa dump -a'
abilityDelegator.executeShellCommand(cmd,
(err, data) => {
console.info('ACTS_AACommand_finish_01_1600 : err : ' + JSON.stringify(err));
console.info('ACTS_AACommand_finish_01_1600 : data : ' + JSON.stringify(data));
globalThis.stdResult34 = data["stdResult"];
console.info('ACTS_AACommand_finish_01_1600 end');
})
test(3000)
setTimeout(() => {
Hypium.hypiumTest(abilityDelegator, abilityDelegatorArguments, testsuite)
}, 12000)
}
@State message: string = 'Hello World'
build() {
Row() {
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录