Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
OpenHarmony
Xts Acts
提交
9c1c3fbb
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看板
未验证
提交
9c1c3fbb
编写于
4月 25, 2023
作者:
O
openharmony_ci
提交者:
Gitee
4月 25, 2023
浏览文件
操作
浏览文件
下载
差异文件
!8533 修复某些横屏状态下validator的experience模块界面显示不全的问题
Merge pull request !8533 from 田文哲/OpenHarmony-3.2-Release
上级
9c3f20bf
f735124c
变更
18
隐藏空白更改
内联
并排
Showing
18 changed file
with
1118 addition
and
1082 deletion
+1118
-1082
validator/acts_validator/src/main/ets/pages/Experience/CameraColdStartTest.ets
...tor/src/main/ets/pages/Experience/CameraColdStartTest.ets
+63
-61
validator/acts_validator/src/main/ets/pages/Experience/ContactsColdStartTest.ets
...r/src/main/ets/pages/Experience/ContactsColdStartTest.ets
+63
-61
validator/acts_validator/src/main/ets/pages/Experience/ContactsHotStartTest.ets
...or/src/main/ets/pages/Experience/ContactsHotStartTest.ets
+63
-61
validator/acts_validator/src/main/ets/pages/Experience/DeskFps.ets
.../acts_validator/src/main/ets/pages/Experience/DeskFps.ets
+72
-70
validator/acts_validator/src/main/ets/pages/Experience/KeyboardDisplayTest.ets
...tor/src/main/ets/pages/Experience/KeyboardDisplayTest.ets
+59
-57
validator/acts_validator/src/main/ets/pages/Experience/KeyboardInputTest.ets
...dator/src/main/ets/pages/Experience/KeyboardInputTest.ets
+59
-57
validator/acts_validator/src/main/ets/pages/Experience/MmsColdStartTest.ets
...idator/src/main/ets/pages/Experience/MmsColdStartTest.ets
+63
-61
validator/acts_validator/src/main/ets/pages/Experience/MmsHotStartTest.ets
...lidator/src/main/ets/pages/Experience/MmsHotStartTest.ets
+63
-61
validator/acts_validator/src/main/ets/pages/Experience/PhotoFps.ets
...acts_validator/src/main/ets/pages/Experience/PhotoFps.ets
+75
-73
validator/acts_validator/src/main/ets/pages/Experience/PhotosColdStartTest.ets
...tor/src/main/ets/pages/Experience/PhotosColdStartTest.ets
+63
-61
validator/acts_validator/src/main/ets/pages/Experience/PhotosHotStartTest.ets
...ator/src/main/ets/pages/Experience/PhotosHotStartTest.ets
+63
-61
validator/acts_validator/src/main/ets/pages/Experience/ScrollPhotosList.ets
...idator/src/main/ets/pages/Experience/ScrollPhotosList.ets
+59
-57
validator/acts_validator/src/main/ets/pages/Experience/SettingsColdStartTest.ets
...r/src/main/ets/pages/Experience/SettingsColdStartTest.ets
+63
-61
validator/acts_validator/src/main/ets/pages/Experience/SettingsHotStartTest.ets
...or/src/main/ets/pages/Experience/SettingsHotStartTest.ets
+63
-61
validator/acts_validator/src/main/ets/pages/Experience/StartBackgroundTask.ets
...tor/src/main/ets/pages/Experience/StartBackgroundTask.ets
+56
-54
validator/acts_validator/src/main/ets/pages/Experience/StartNotification.ets
...dator/src/main/ets/pages/Experience/StartNotification.ets
+56
-54
validator/acts_validator/src/main/ets/pages/Experience/StartTaskManager.ets
...idator/src/main/ets/pages/Experience/StartTaskManager.ets
+56
-54
validator/acts_validator/src/main/ets/pages/Experience/ViewPhotoTest.ets
...validator/src/main/ets/pages/Experience/ViewPhotoTest.ets
+59
-57
未找到文件。
validator/acts_validator/src/main/ets/pages/Experience/CameraColdStartTest.ets
浏览文件 @
9c1c3fbb
...
...
@@ -35,6 +35,7 @@ struct CustomContainerUser {
@State mmsNum: number = 0;
@State cameraNum: number = 0;
@State contactsNum: number = 0;
scroller: Scroller = new Scroller();
async aboutToAppear(){
await FirstDialog.ChooseDialog(this.StepTips,this.name);
this.Vue = false;
...
...
@@ -43,74 +44,75 @@ struct CustomContainerUser {
@Builder specificNoParam() {
Column() {
Flex({direction:FlexDirection.Column,alignItems: ItemAlign.Center, justifyContent: FlexAlign.SpaceBetween }) {
Column(){
Row(){
Text(`根据以下操作步骤完成测试`+ '\n' + '\n' )
.fontColor(Color.White).fontSize('24fp')
}
Row(){
Text(`测试步骤:`+ '\n' + '\n' + '1.测试设备通过USB连接工作台' + '\n' + '\n' + `2.点击开始键进入系统桌面` + '\n' + '\n'
+ `3.清空后台应用,将底层任务栏中应用拖至桌面` + '\n' + '\n' + `4.工作台运行‘点击启动测试.bat’选择冷启动>相机测试,回车执行`
+ '\n' + '\n' +`5.测试应用自动执行冷启动后手动返回validator界面` + '\n' + '\n' + '6.点击结束键观察测试结果'
+ '\n' + '\n' + `7.若冷启动测试在规定时延内完成则通过测试` + '\n' + '\n' )
.fontColor(Color.White).fontSize('20fp')
}
Row(){
Column(){
Button(`开始`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(this.StartEnable)
.opacity(this.StartEnable? 1 : 0.4)
.onClick(async () => {
this.num = 0;
this.StartEnable = !this.StartEnable;
let str = {
bundleName:"com.ohos.launcher",
abilityName: "com.ohos.launcher.MainAbility",
}
abilityContext.startAbility(str).then((data) => {
Scroll(this.scroller) {
Column(){
Row(){
Text(`根据以下操作步骤完成测试`+ '\n' + '\n' )
.fontColor(Color.White).fontSize('24fp')
}
Row(){
Text(`测试步骤:`+ '\n' + '\n' + '1.测试设备通过USB连接工作台' + '\n' + '\n' + `2.点击开始键进入系统桌面` + '\n' + '\n'
+ `3.清空后台应用,将底层任务栏中应用拖至桌面` + '\n' + '\n' + `4.工作台运行‘点击启动测试.bat’选择冷启动>相机测试,回车执行`
+ '\n' + '\n' +`5.测试应用自动执行冷启动后手动返回validator界面` + '\n' + '\n' + '6.点击结束键观察测试结果'
+ '\n' + '\n' + `7.若冷启动测试在规定时延内完成则通过测试` + '\n' + '\n' )
.fontColor(Color.White).fontSize('20fp')
}
Row(){
Column(){
Button(`开始`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(this.StartEnable)
.opacity(this.StartEnable? 1 : 0.4)
.onClick(async () => {
this.num = 0;
this.StartEnable = !this.StartEnable;
let str = {
bundleName:"com.ohos.launcher",
abilityName: "com.ohos.launcher.MainAbility",
}
abilityContext.startAbility(str).then((data) => {
}).catch((error) => {
}).catch((error) => {
})
})
})
}
Column(){
Button(`结束`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(!this.StartEnable)
.opacity(!this.StartEnable? 1 : 0.4)
.onClick(() => {
this.StartEnable = !this.StartEnable
/*
camera
*/
let CameraFd = fileio.openSync(CameraColdPath, 0o100 | 0o2002, 0o664);
let CameraBuf = new ArrayBuffer(4096);
fileio.readSync(CameraFd,CameraBuf);
let CameraReport = String.fromCharCode.apply(null,new Uint8Array(CameraBuf));
let CameraHead = CameraReport.indexOf('time:');
let CameraTime = CameraReport.substring(CameraHead+5);
this.cameraNum = parseFloat(CameraTime);
if( 0 < this.cameraNum && this.cameraNum < 2300 ) {
this.num++
}
if( this.num === 1 ) {
this.Vue = true;
}
})
}
}
Column(){
Button(`结束`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(!this.StartEnable)
.opacity(!this.StartEnable? 1 : 0.4)
.onClick(() => {
this.StartEnable = !this.StartEnable
/*
camera
*/
let CameraFd = fileio.openSync(CameraColdPath, 0o100 | 0o2002, 0o664);
let CameraBuf = new ArrayBuffer(4096);
fileio.readSync(CameraFd,CameraBuf);
let CameraReport = String.fromCharCode.apply(null,new Uint8Array(CameraBuf));
let CameraHead = CameraReport.indexOf('time:');
let CameraTime = CameraReport.substring(CameraHead+5);
this.cameraNum = parseFloat(CameraTime);
if( 0 < this.cameraNum && this.cameraNum < 2300 ) {
this.num++
}
if( this.num === 1 ) {
this.Vue = true;
}
})
Row(){
Text('\n' + '\n' + `测试结果:` + '\n' + '\n' + '相机冷启动时延' + this.cameraNum + 'ms' )
.fontColor(Color.White).fontSize('24fp')
}
}
Row(){
Text('\n' + '\n' + `测试结果:` + '\n' + '\n' + '相机冷启动时延' + this.cameraNum + 'ms' )
.fontColor(Color.White).fontSize('24fp')
}
}
}
}.width('100%').height('80%').backgroundColor(Color.Black)
.justifyContent(FlexAlign.SpaceEvenly)
...
...
validator/acts_validator/src/main/ets/pages/Experience/ContactsColdStartTest.ets
浏览文件 @
9c1c3fbb
...
...
@@ -35,6 +35,7 @@ struct CustomContainerUser {
@State mmsNum: number = 0;
@State cameraNum: number = 0;
@State contactsNum: number = 0;
scroller: Scroller = new Scroller();
async aboutToAppear(){
await FirstDialog.ChooseDialog(this.StepTips,this.name);
this.Vue = false;
...
...
@@ -43,74 +44,75 @@ struct CustomContainerUser {
@Builder specificNoParam() {
Column() {
Flex({direction:FlexDirection.Column,alignItems: ItemAlign.Center, justifyContent: FlexAlign.SpaceBetween }) {
Column(){
Row(){
Text(`根据以下操作步骤完成测试`+ '\n' + '\n' )
.fontColor(Color.White).fontSize('24fp')
}
Row(){
Text(`测试步骤:`+ '\n' + '\n' + '1.测试设备通过USB连接工作台' + '\n' + '\n' + `2.点击开始键进入系统桌面` + '\n' + '\n'
+ `3.清空后台应用,将底层任务栏中应用拖至桌面` + '\n' + '\n' + `4.工作台运行‘点击启动测试.bat’选择冷启动>联系人测试,回车执行`
+ '\n' + '\n' +`5.测试应用自动执行冷启动后手动返回validator界面` + '\n' + '\n' + '6.点击结束键观察测试结果'
+ '\n' + '\n' + `7.若冷启动测试在规定时延内完成则通过测试` + '\n' + '\n' )
.fontColor(Color.White).fontSize('20fp')
}
Row(){
Column(){
Button(`开始`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(this.StartEnable)
.opacity(this.StartEnable? 1 : 0.4)
.onClick(async () => {
this.num = 0;
this.StartEnable = !this.StartEnable;
let str = {
bundleName:"com.ohos.launcher",
abilityName: "com.ohos.launcher.MainAbility",
}
abilityContext.startAbility(str).then((data) => {
Scroll(this.scroller) {
Column(){
Row(){
Text(`根据以下操作步骤完成测试`+ '\n' + '\n' )
.fontColor(Color.White).fontSize('24fp')
}
Row(){
Text(`测试步骤:`+ '\n' + '\n' + '1.测试设备通过USB连接工作台' + '\n' + '\n' + `2.点击开始键进入系统桌面` + '\n' + '\n'
+ `3.清空后台应用,将底层任务栏中应用拖至桌面` + '\n' + '\n' + `4.工作台运行‘点击启动测试.bat’选择冷启动>联系人测试,回车执行`
+ '\n' + '\n' +`5.测试应用自动执行冷启动后手动返回validator界面` + '\n' + '\n' + '6.点击结束键观察测试结果'
+ '\n' + '\n' + `7.若冷启动测试在规定时延内完成则通过测试` + '\n' + '\n' )
.fontColor(Color.White).fontSize('20fp')
}
Row(){
Column(){
Button(`开始`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(this.StartEnable)
.opacity(this.StartEnable? 1 : 0.4)
.onClick(async () => {
this.num = 0;
this.StartEnable = !this.StartEnable;
let str = {
bundleName:"com.ohos.launcher",
abilityName: "com.ohos.launcher.MainAbility",
}
abilityContext.startAbility(str).then((data) => {
}).catch((error) => {
}).catch((error) => {
})
})
})
}
Column(){
Button(`结束`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(!this.StartEnable)
.opacity(!this.StartEnable? 1 : 0.4)
.onClick(() => {
this.StartEnable = !this.StartEnable
/*
Contacts
*/
let ContactsFd = fileio.openSync(ContactsColdPath, 0o100 | 0o2002, 0o664);
let ContactsBuf = new ArrayBuffer(4096);
fileio.readSync(ContactsFd,ContactsBuf);
let ContactsReport = String.fromCharCode.apply(null,new Uint8Array(ContactsBuf));
let ContactsHead = ContactsReport.indexOf('time:');
let ContactsTime = ContactsReport.substring(ContactsHead+5);
this.contactsNum = parseFloat(ContactsTime);
if( 0 < this.contactsNum && this.contactsNum < 2300 ) {
this.num++
}
if( this.num === 1 ) {
this.Vue = true;
}
})
}
}
Column(){
Button(`结束`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(!this.StartEnable)
.opacity(!this.StartEnable? 1 : 0.4)
.onClick(() => {
this.StartEnable = !this.StartEnable
/*
Contacts
*/
let ContactsFd = fileio.openSync(ContactsColdPath, 0o100 | 0o2002, 0o664);
let ContactsBuf = new ArrayBuffer(4096);
fileio.readSync(ContactsFd,ContactsBuf);
let ContactsReport = String.fromCharCode.apply(null,new Uint8Array(ContactsBuf));
let ContactsHead = ContactsReport.indexOf('time:');
let ContactsTime = ContactsReport.substring(ContactsHead+5);
this.contactsNum = parseFloat(ContactsTime);
if( 0 < this.contactsNum && this.contactsNum < 2300 ) {
this.num++
}
if( this.num === 1 ) {
this.Vue = true;
}
})
Row(){
Text('\n' + '\n' + `测试结果:` + '\n' + '\n' + '联系人冷启动时延' + this.contactsNum + 'ms' )
.fontColor(Color.White).fontSize('24fp')
}
}
Row(){
Text('\n' + '\n' + `测试结果:` + '\n' + '\n' + '联系人冷启动时延' + this.contactsNum + 'ms' )
.fontColor(Color.White).fontSize('24fp')
}
}
}
}.width('100%').height('80%').backgroundColor(Color.Black)
.justifyContent(FlexAlign.SpaceEvenly)
...
...
validator/acts_validator/src/main/ets/pages/Experience/ContactsHotStartTest.ets
浏览文件 @
9c1c3fbb
...
...
@@ -35,6 +35,7 @@ struct CustomContainerUser {
@State mmsNum: number = 0;
@State cameraNum: number = 0;
@State contactsNum: number = 0;
scroller: Scroller = new Scroller();
async aboutToAppear(){
await FirstDialog.ChooseDialog(this.StepTips,this.name);
this.Vue = false;
...
...
@@ -43,74 +44,75 @@ struct CustomContainerUser {
@Builder specificNoParam() {
Column() {
Flex({direction:FlexDirection.Column,alignItems: ItemAlign.Center, justifyContent: FlexAlign.SpaceBetween }) {
Column(){
Row(){
Text(`根据以下操作步骤完成测试`+ '\n' + '\n' )
.fontColor(Color.White).fontSize('24fp')
}
Row(){
Text(`测试步骤:`+ '\n' + '\n' + '1.测试设备通过USB连接工作台' + '\n' + '\n' + `2.点击开始键进入系统桌面`+ '\n' + '\n'
+ `3.开启联系人应用回退到桌面,保证此时后台应用存在` + '\n' + '\n' + `4.工作台运行’点击启动测试.bat‘选择热启动>联系人测试`+ '\n' + '\n' +
`5.测试应用手动执行热启动返回validator界面` + '\n' + '\n' + '6.点击结束键观察测试结果' + '\n' + '\n'
+ `7.若所有热启动测试均在规定时延内完成则通过测试` + '\n' + '\n' + '\n' + '\n' )
.fontColor(Color.White).fontSize('20fp')
}
Row(){
Column(){
Button(`开始`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(this.StartEnable)
.opacity(this.StartEnable? 1 : 0.4)
.onClick(async () => {
this.num = 0;
this.StartEnable = !this.StartEnable;
let str = {
bundleName:"com.ohos.launcher",
abilityName: "com.ohos.launcher.MainAbility",
}
abilityContext.startAbility(str).then((data) => {
Scroll(this.scroller) {
Column(){
Row(){
Text(`根据以下操作步骤完成测试`+ '\n' + '\n' )
.fontColor(Color.White).fontSize('24fp')
}
Row(){
Text(`测试步骤:`+ '\n' + '\n' + '1.测试设备通过USB连接工作台' + '\n' + '\n' + `2.点击开始键进入系统桌面`+ '\n' + '\n'
+ `3.开启联系人应用回退到桌面,保证此时后台应用存在` + '\n' + '\n' + `4.工作台运行’点击启动测试.bat‘选择热启动>联系人测试`+ '\n' + '\n' +
`5.测试应用手动执行热启动返回validator界面` + '\n' + '\n' + '6.点击结束键观察测试结果' + '\n' + '\n'
+ `7.若所有热启动测试均在规定时延内完成则通过测试` + '\n' + '\n' + '\n' + '\n' )
.fontColor(Color.White).fontSize('20fp')
}
Row(){
Column(){
Button(`开始`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(this.StartEnable)
.opacity(this.StartEnable? 1 : 0.4)
.onClick(async () => {
this.num = 0;
this.StartEnable = !this.StartEnable;
let str = {
bundleName:"com.ohos.launcher",
abilityName: "com.ohos.launcher.MainAbility",
}
abilityContext.startAbility(str).then((data) => {
}).catch((error) => {
}).catch((error) => {
})
})
})
}
Column(){
Button(`结束`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(!this.StartEnable)
.opacity(!this.StartEnable? 1 : 0.4)
.onClick(() => {
this.StartEnable = !this.StartEnable
/*
Contacts
*/
let ContactsFd = fileio.openSync(ContactsColdPath, 0o100 | 0o2002, 0o664);
let ContactsBuf = new ArrayBuffer(4096);
fileio.readSync(ContactsFd,ContactsBuf);
let ContactsReport = String.fromCharCode.apply(null,new Uint8Array(ContactsBuf));
let ContactsHead = ContactsReport.indexOf(':');
let ContactsTime = ContactsReport.substring(ContactsHead+1);
this.contactsNum = parseFloat(ContactsTime);
if( 0 < this.contactsNum && this.contactsNum < 600 ) {
this.num++
}
if( this.num === 1 ) {
this.Vue = true;
}
})
}
}
Column(){
Button(`结束`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(!this.StartEnable)
.opacity(!this.StartEnable? 1 : 0.4)
.onClick(() => {
this.StartEnable = !this.StartEnable
/*
Contacts
*/
let ContactsFd = fileio.openSync(ContactsColdPath, 0o100 | 0o2002, 0o664);
let ContactsBuf = new ArrayBuffer(4096);
fileio.readSync(ContactsFd,ContactsBuf);
let ContactsReport = String.fromCharCode.apply(null,new Uint8Array(ContactsBuf));
let ContactsHead = ContactsReport.indexOf(':');
let ContactsTime = ContactsReport.substring(ContactsHead+1);
this.contactsNum = parseFloat(ContactsTime);
if( 0 < this.contactsNum && this.contactsNum < 600 ) {
this.num++
}
if( this.num === 1 ) {
this.Vue = true;
}
})
Row(){
Text('\n' + '\n' + '\n' + '\n' + `测试结果:` + '\n' + '\n' + '联系人热启动时延' + this.contactsNum + 'ms')
.fontColor(Color.White).fontSize('24fp')
}
}
Row(){
Text('\n' + '\n' + '\n' + '\n' + `测试结果:` + '\n' + '\n' + '联系人热启动时延' + this.contactsNum + 'ms')
.fontColor(Color.White).fontSize('24fp')
}
}
}
}.width('100%').height('80%').backgroundColor(Color.Black)
.justifyContent(FlexAlign.SpaceEvenly)
...
...
validator/acts_validator/src/main/ets/pages/Experience/DeskFps.ets
浏览文件 @
9c1c3fbb
...
...
@@ -31,6 +31,7 @@ struct CustomContainerUser {
@State Vue: boolean = false;
@State StartEnable: boolean = true;
@State Fps: string = '0';
scroller: Scroller = new Scroller();
async aboutToAppear(){
await FirstDialog.ChooseDialog(this.StepTips,this.name);
this.Vue = false;
...
...
@@ -39,83 +40,84 @@ struct CustomContainerUser {
@Builder specificNoParam() {
Column() {
Flex({direction:FlexDirection.Column,alignItems: ItemAlign.Center, justifyContent: FlexAlign.SpaceBetween }) {
Column(){
Row(){
Text(`根据以下操作步骤完成测试`+ '\n' + '\n' + '\n' + '\n'+ '\n' + '\n' + '\n' + '\n')
.fontColor(Color.White).fontSize('24fp')
}
Row(){
Text(`测试步骤:`+ '\n' + '\n' + '1.测试设备通过USB连接工作台' + '\n' + '\n' + `2.点击开始键进入系统桌面`+ '\n' + '\n'
+ `3.工作台运行’点击启动测试.bat‘选择帧率>桌面`+ '\n' + '\n' +`4.左右滑动系统桌面连续10s以上` + '\n' + '\n'
+ '5.回到DeskFps测试项点击结束键' + '\n' + '\n' + `6.若测试最高帧率大于55帧则通过测试`
+ '\n' + '\n' + '\n' + '\n' + '\n' + '\n' + '\n' + '\n' )
.fontColor(Color.White).fontSize('20fp')
}
Row(){
Column(){
Button(`开始`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(this.StartEnable)
.opacity(this.StartEnable? 1 : 0.4)
.onClick(async () => {
this.StartEnable = !this.StartEnable;
let str = {
bundleName:"com.ohos.launcher",
abilityName: "com.ohos.launcher.MainAbility",
}
abilityContext.startAbility(str).then((data) => {
Scroll(this.scroller) {
Column(){
Row(){
Text(`根据以下操作步骤完成测试`+ '\n' + '\n' + '\n' + '\n'+ '\n' + '\n' + '\n' + '\n')
.fontColor(Color.White).fontSize('24fp')
}
Row(){
Text(`测试步骤:`+ '\n' + '\n' + '1.测试设备通过USB连接工作台' + '\n' + '\n' + `2.点击开始键进入系统桌面`+ '\n' + '\n'
+ `3.工作台运行’点击启动测试.bat‘选择帧率>桌面`+ '\n' + '\n' +`4.左右滑动系统桌面连续10s以上` + '\n' + '\n'
+ '5.回到DeskFps测试项点击结束键' + '\n' + '\n' + `6.若测试最高帧率大于55帧则通过测试`
+ '\n' + '\n' + '\n' + '\n' + '\n' + '\n' + '\n' + '\n' )
.fontColor(Color.White).fontSize('20fp')
}
Row(){
Column(){
Button(`开始`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(this.StartEnable)
.opacity(this.StartEnable? 1 : 0.4)
.onClick(async () => {
this.StartEnable = !this.StartEnable;
let str = {
bundleName:"com.ohos.launcher",
abilityName: "com.ohos.launcher.MainAbility",
}
abilityContext.startAbility(str).then((data) => {
}).catch((error) => {
}).catch((error) => {
})
})
})
}
Column(){
Button(`结束`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(!this.StartEnable)
.opacity(!this.StartEnable? 1 : 0.4)
.onClick(() => {
this.StartEnable = !this.StartEnable
let fd = fileio.openSync(Xpath, 0o100 | 0o2002, 0o664);
let buf = new ArrayBuffer(4096);
fileio.readSync(fd,buf);
let report = String.fromCharCode.apply(null,new Uint8Array(buf));
let headList = new Array();
let endList = new Array();
let head = report.indexOf(":");
let end = report.indexOf('|');
let Fps = new Array();
}
Column(){
Button(`结束`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(!this.StartEnable)
.opacity(!this.StartEnable? 1 : 0.4)
.onClick(() => {
this.StartEnable = !this.StartEnable
let fd = fileio.openSync(Xpath, 0o100 | 0o2002, 0o664);
let buf = new ArrayBuffer(4096);
fileio.readSync(fd,buf);
let report = String.fromCharCode.apply(null,new Uint8Array(buf));
let headList = new Array();
let endList = new Array();
let head = report.indexOf(":");
let end = report.indexOf('|');
let Fps = new Array();
while(head > -1){
headList.push(head);
head = report.indexOf(":",head + 1);
}
while(end > -1){
endList.push(end);
end = report.indexOf("|",end + 1);
}
for(let i = 0; i < headList.length; i++) {
Fps[i] = Number(report.substring(headList[i]+1,endList[i]));
}
let maxFps = Math.max(...Fps);
this.Fps = maxFps.toString();
if(maxFps >= 55) {
this.Vue = true;
}
})
while(head > -1){
headList.push(head);
head = report.indexOf(":",head + 1);
}
while(end > -1){
endList.push(end);
end = report.indexOf("|",end + 1);
}
for(let i = 0; i < headList.length; i++) {
Fps[i] = Number(report.substring(headList[i]+1,endList[i]));
}
let maxFps = Math.max(...Fps);
this.Fps = maxFps.toString();
if(maxFps >= 55) {
this.Vue = true;
}
})
}
}
Row(){
Text('\n' + '\n' + '\n' + '\n'+ '\n' + '\n' + '\n' + '\n' + `测试结果:` + this.Fps + '帧' )
.fontColor(Color.White).fontSize('24fp')
}
}
Row(){
Text('\n' + '\n' + '\n' + '\n'+ '\n' + '\n' + '\n' + '\n' + `测试结果:` + this.Fps + '帧' )
.fontColor(Color.White).fontSize('24fp')
}
}
}
}.width('100%').height('80%').backgroundColor(Color.Black)
.justifyContent(FlexAlign.SpaceEvenly)
...
...
validator/acts_validator/src/main/ets/pages/Experience/KeyboardDisplayTest.ets
浏览文件 @
9c1c3fbb
...
...
@@ -29,6 +29,7 @@ struct CustomContainerUser {
@State Vue: boolean = false;
@State StartEnable: boolean = true;
@State time: string = '0';
scroller: Scroller = new Scroller();
async aboutToAppear(){
await FirstDialog.ChooseDialog(this.StepTips,this.name);
this.Vue = false;
...
...
@@ -37,70 +38,71 @@ struct CustomContainerUser {
@Builder specificNoParam() {
Column() {
Flex({direction:FlexDirection.Column,alignItems: ItemAlign.Center, justifyContent: FlexAlign.SpaceBetween }) {
Column(){
Row(){
Text(`根据以下操作步骤完成测试`+ '\n' + '\n' + '\n' + '\n'+ '\n' + '\n' + '\n' + '\n')
.fontColor(Color.White).fontSize('24fp')
}
Row(){
Text(`测试步骤:`+ '\n' + '\n' + '1.测试设备通过USB连接工作台' + '\n' + '\n' + `2.点击开始键进入信息` + '\n' + '\n' +
'3.新建一条信息显示输入框'+ '\n' + '\n' + `4.工作台运行’点击启动测试.bat‘选择完成时延>键盘按键弹出`+ '\n' + '\n' +
`5.点击输入框等待键盘弹出` + '\n' + '\n' + '6.待脚本执行结束回到Validator点击结束键' + '\n' + '\n'
+ `7.若弹出键盘时延小于或等于1000ms则通过测试` + '\n' + '\n' + '\n' + '\n' )
.fontColor(Color.White).fontSize('20fp')
}
Row(){
Column(){
Button(`开始`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(this.StartEnable)
.opacity(this.StartEnable? 1 : 0.4)
.onClick(async () => {
this.StartEnable = !this.StartEnable;
let bundleName=new String("com.ohos.mms").toString();
let abilityName=new String("com.ohos.mms.MainAbility").toString();
let str = {
"bundleName": bundleName,
"abilityName": abilityName,
}
Scroll(this.scroller) {
Column(){
Row(){
Text(`根据以下操作步骤完成测试`+ '\n' + '\n' + '\n' + '\n'+ '\n' + '\n' + '\n' + '\n')
.fontColor(Color.White).fontSize('24fp')
}
Row(){
Text(`测试步骤:`+ '\n' + '\n' + '1.测试设备通过USB连接工作台' + '\n' + '\n' + `2.点击开始键进入信息` + '\n' + '\n' +
'3.新建一条信息显示输入框'+ '\n' + '\n' + `4.工作台运行’点击启动测试.bat‘选择完成时延>键盘按键弹出`+ '\n' + '\n' +
`5.点击输入框等待键盘弹出` + '\n' + '\n' + '6.待脚本执行结束回到Validator点击结束键' + '\n' + '\n'
+ `7.若弹出键盘时延小于或等于1000ms则通过测试` + '\n' + '\n' + '\n' + '\n' )
.fontColor(Color.White).fontSize('20fp')
}
Row(){
Column(){
Button(`开始`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(this.StartEnable)
.opacity(this.StartEnable? 1 : 0.4)
.onClick(async () => {
this.StartEnable = !this.StartEnable;
let bundleName=new String("com.ohos.mms").toString();
let abilityName=new String("com.ohos.mms.MainAbility").toString();
let str = {
"bundleName": bundleName,
"abilityName": abilityName,
}
globalThis.abilityContext.startAbility(str, (err, data) => {
if(err) {
return;
globalThis.abilityContext.startAbility(str, (err, data) => {
if(err) {
return;
}
})
})
}
Column(){
Button(`结束`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(!this.StartEnable)
.opacity(!this.StartEnable? 1 : 0.4)
.onClick(() => {
this.StartEnable = !this.StartEnable
let fd = fileio.openSync(Xpath, 0o100 | 0o2002, 0o664);
let buf = new ArrayBuffer(4096);
fileio.readSync(fd,buf);
let report = String.fromCharCode.apply(null,new Uint8Array(buf));
let head = report.indexOf(":");
this.time = report.substring(head+1);
let time = parseFloat(this.time)
if( 0 < time && time < 1000 ) {
this.Vue = true;
}
})
})
}
}
Column(){
Button(`结束`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(!this.StartEnable)
.opacity(!this.StartEnable? 1 : 0.4)
.onClick(() => {
this.StartEnable = !this.StartEnable
let fd = fileio.openSync(Xpath, 0o100 | 0o2002, 0o664);
let buf = new ArrayBuffer(4096);
fileio.readSync(fd,buf);
let report = String.fromCharCode.apply(null,new Uint8Array(buf));
let head = report.indexOf(":");
this.time = report.substring(head+1);
let time = parseFloat(this.time)
if( 0 < time && time < 1000 ) {
this.Vue = true;
}
})
Row(){
Text('\n' + '\n' + '\n' + '\n'+ '\n' + '\n' + '\n' + '\n' + `输入键盘弹出时延:` + this.time + 'ms' )
.fontColor(Color.White).fontSize('24fp')
}
}
Row(){
Text('\n' + '\n' + '\n' + '\n'+ '\n' + '\n' + '\n' + '\n' + `输入键盘弹出时延:` + this.time + 'ms' )
.fontColor(Color.White).fontSize('24fp')
}
}
}
}.width('100%').height('80%').backgroundColor(Color.Black)
.justifyContent(FlexAlign.SpaceEvenly)
...
...
validator/acts_validator/src/main/ets/pages/Experience/KeyboardInputTest.ets
浏览文件 @
9c1c3fbb
...
...
@@ -29,6 +29,7 @@ struct CustomContainerUser {
@State Vue: boolean = false;
@State StartEnable: boolean = true;
@State time: string = '0';
scroller: Scroller = new Scroller();
async aboutToAppear(){
await FirstDialog.ChooseDialog(this.StepTips,this.name);
this.Vue = false;
...
...
@@ -37,70 +38,71 @@ struct CustomContainerUser {
@Builder specificNoParam() {
Column() {
Flex({direction:FlexDirection.Column,alignItems: ItemAlign.Center, justifyContent: FlexAlign.SpaceBetween }) {
Column(){
Row(){
Text(`根据以下操作步骤完成测试`+ '\n' + '\n' + '\n' + '\n'+ '\n' + '\n' + '\n' + '\n')
.fontColor(Color.White).fontSize('24fp')
}
Row(){
Text(`测试步骤:`+ '\n' + '\n' + '1.测试设备通过USB连接工作台' + '\n' + '\n' + `2.点击开始键进入信息` + '\n' + '\n' +
'3.新建一条信息点击输入框打开键盘'+ '\n' + '\n' + `4.工作台运行’点击启动测试.bat‘选择响应时延>键盘按键输入`+ '\n' + '\n'
+`5.随意点击按键等待响应` + '\n' + '\n' + '6.待脚本执行结束回到Validator点击结束键' + '\n' + '\n' +
`7.若按键响应时延小于或等于150ms则通过测试` + '\n' + '\n' + '\n' + '\n' )
.fontColor(Color.White).fontSize('20fp')
}
Row(){
Column(){
Button(`开始`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(this.StartEnable)
.opacity(this.StartEnable? 1 : 0.4)
.onClick(async () => {
this.StartEnable = !this.StartEnable;
let bundleName=new String("com.ohos.mms").toString();
let abilityName=new String("com.ohos.mms.MainAbility").toString();
let str = {
"bundleName": bundleName,
"abilityName": abilityName,
}
Scroll(this.scroller) {
Column(){
Row(){
Text(`根据以下操作步骤完成测试`+ '\n' + '\n' + '\n' + '\n'+ '\n' + '\n' + '\n' + '\n')
.fontColor(Color.White).fontSize('24fp')
}
Row(){
Text(`测试步骤:`+ '\n' + '\n' + '1.测试设备通过USB连接工作台' + '\n' + '\n' + `2.点击开始键进入信息` + '\n' + '\n' +
'3.新建一条信息点击输入框打开键盘'+ '\n' + '\n' + `4.工作台运行’点击启动测试.bat‘选择响应时延>键盘按键输入`+ '\n' + '\n'
+`5.随意点击按键等待响应` + '\n' + '\n' + '6.待脚本执行结束回到Validator点击结束键' + '\n' + '\n' +
`7.若按键响应时延小于或等于150ms则通过测试` + '\n' + '\n' + '\n' + '\n' )
.fontColor(Color.White).fontSize('20fp')
}
Row(){
Column(){
Button(`开始`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(this.StartEnable)
.opacity(this.StartEnable? 1 : 0.4)
.onClick(async () => {
this.StartEnable = !this.StartEnable;
let bundleName=new String("com.ohos.mms").toString();
let abilityName=new String("com.ohos.mms.MainAbility").toString();
let str = {
"bundleName": bundleName,
"abilityName": abilityName,
}
globalThis.abilityContext.startAbility(str, (err, data) => {
if(err) {
return;
globalThis.abilityContext.startAbility(str, (err, data) => {
if(err) {
return;
}
})
})
}
Column(){
Button(`结束`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(!this.StartEnable)
.opacity(!this.StartEnable? 1 : 0.4)
.onClick(() => {
this.StartEnable = !this.StartEnable
let fd = fileio.openSync(Xpath, 0o100 | 0o2002, 0o664);
let buf = new ArrayBuffer(4096);
fileio.readSync(fd,buf);
let report = String.fromCharCode.apply(null,new Uint8Array(buf));
let head = report.indexOf(":");
this.time = report.substring(head+1);
let time = parseFloat(this.time)
if( 0 < time && time < 150 ) {
this.Vue = true;
}
})
})
}
}
Column(){
Button(`结束`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(!this.StartEnable)
.opacity(!this.StartEnable? 1 : 0.4)
.onClick(() => {
this.StartEnable = !this.StartEnable
let fd = fileio.openSync(Xpath, 0o100 | 0o2002, 0o664);
let buf = new ArrayBuffer(4096);
fileio.readSync(fd,buf);
let report = String.fromCharCode.apply(null,new Uint8Array(buf));
let head = report.indexOf(":");
this.time = report.substring(head+1);
let time = parseFloat(this.time)
if( 0 < time && time < 150 ) {
this.Vue = true;
}
})
Row(){
Text('\n' + '\n' + '\n' + '\n'+ '\n' + '\n' + '\n' + '\n' + `按键响应时延:` + this.time + 'ms' )
.fontColor(Color.White).fontSize('24fp')
}
}
Row(){
Text('\n' + '\n' + '\n' + '\n'+ '\n' + '\n' + '\n' + '\n' + `按键响应时延:` + this.time + 'ms' )
.fontColor(Color.White).fontSize('24fp')
}
}
}
}.width('100%').height('80%').backgroundColor(Color.Black)
.justifyContent(FlexAlign.SpaceEvenly)
...
...
validator/acts_validator/src/main/ets/pages/Experience/MmsColdStartTest.ets
浏览文件 @
9c1c3fbb
...
...
@@ -35,6 +35,7 @@ struct CustomContainerUser {
@State mmsNum: number = 0;
@State cameraNum: number = 0;
@State contactsNum: number = 0;
scroller: Scroller = new Scroller();
async aboutToAppear(){
await FirstDialog.ChooseDialog(this.StepTips,this.name);
this.Vue = false;
...
...
@@ -43,74 +44,75 @@ struct CustomContainerUser {
@Builder specificNoParam() {
Column() {
Flex({direction:FlexDirection.Column,alignItems: ItemAlign.Center, justifyContent: FlexAlign.SpaceBetween }) {
Column(){
Row(){
Text(`根据以下操作步骤完成测试`+ '\n' + '\n' )
.fontColor(Color.White).fontSize('24fp')
}
Row(){
Text(`测试步骤:`+ '\n' + '\n' + '1.测试设备通过USB连接工作台' + '\n' + '\n' + `2.点击开始键进入系统桌面` + '\n' + '\n'
+ `3.清空后台应用,将底层任务栏中应用拖至桌面` + '\n' + '\n' + `4.工作台运行‘点击启动测试.bat’选择冷启动>信息测试,回车执行`
+ '\n' + '\n' +`5.测试应用自动执行冷启动后手动返回validator界面` + '\n' + '\n' + '6.点击结束键观察测试结果'
+ '\n' + '\n' + `7.若冷启动测试在规定时延内完成则通过测试` + '\n' + '\n' )
.fontColor(Color.White).fontSize('20fp')
}
Row(){
Column(){
Button(`开始`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(this.StartEnable)
.opacity(this.StartEnable? 1 : 0.4)
.onClick(async () => {
this.num = 0;
this.StartEnable = !this.StartEnable;
let str = {
bundleName:"com.ohos.launcher",
abilityName: "com.ohos.launcher.MainAbility",
}
abilityContext.startAbility(str).then((data) => {
Scroll(this.scroller) {
Column(){
Row(){
Text(`根据以下操作步骤完成测试`+ '\n' + '\n' )
.fontColor(Color.White).fontSize('24fp')
}
Row(){
Text(`测试步骤:`+ '\n' + '\n' + '1.测试设备通过USB连接工作台' + '\n' + '\n' + `2.点击开始键进入系统桌面` + '\n' + '\n'
+ `3.清空后台应用,将底层任务栏中应用拖至桌面` + '\n' + '\n' + `4.工作台运行‘点击启动测试.bat’选择冷启动>信息测试,回车执行`
+ '\n' + '\n' +`5.测试应用自动执行冷启动后手动返回validator界面` + '\n' + '\n' + '6.点击结束键观察测试结果'
+ '\n' + '\n' + `7.若冷启动测试在规定时延内完成则通过测试` + '\n' + '\n' )
.fontColor(Color.White).fontSize('20fp')
}
Row(){
Column(){
Button(`开始`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(this.StartEnable)
.opacity(this.StartEnable? 1 : 0.4)
.onClick(async () => {
this.num = 0;
this.StartEnable = !this.StartEnable;
let str = {
bundleName:"com.ohos.launcher",
abilityName: "com.ohos.launcher.MainAbility",
}
abilityContext.startAbility(str).then((data) => {
}).catch((error) => {
}).catch((error) => {
})
})
})
}
Column(){
Button(`结束`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(!this.StartEnable)
.opacity(!this.StartEnable? 1 : 0.4)
.onClick(() => {
this.StartEnable = !this.StartEnable
/*
mms
*/
let MmsFd = fileio.openSync(MmsColdPath, 0o100 | 0o2002, 0o664);
let MmsBuf = new ArrayBuffer(4096);
fileio.readSync(MmsFd,MmsBuf);
let MmsReport = String.fromCharCode.apply(null,new Uint8Array(MmsBuf));
let MmsHead = MmsReport.indexOf('time:');
let MmsTime = MmsReport.substring(MmsHead+5);
this.mmsNum = parseFloat(MmsTime);
if( 0 < this.mmsNum && this.mmsNum < 2300 ) {
this.num++
}
if( this.num === 1 ) {
this.Vue = true;
}
})
}
}
Column(){
Button(`结束`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(!this.StartEnable)
.opacity(!this.StartEnable? 1 : 0.4)
.onClick(() => {
this.StartEnable = !this.StartEnable
/*
mms
*/
let MmsFd = fileio.openSync(MmsColdPath, 0o100 | 0o2002, 0o664);
let MmsBuf = new ArrayBuffer(4096);
fileio.readSync(MmsFd,MmsBuf);
let MmsReport = String.fromCharCode.apply(null,new Uint8Array(MmsBuf));
let MmsHead = MmsReport.indexOf('time:');
let MmsTime = MmsReport.substring(MmsHead+5);
this.mmsNum = parseFloat(MmsTime);
if( 0 < this.mmsNum && this.mmsNum < 2300 ) {
this.num++
}
if( this.num === 1 ) {
this.Vue = true;
}
})
Row(){
Text('\n' + '\n' + `测试结果:` + '\n' + '\n' + '信息冷启动时延' + this.mmsNum + 'ms')
.fontColor(Color.White).fontSize('24fp')
}
}
Row(){
Text('\n' + '\n' + `测试结果:` + '\n' + '\n' + '信息冷启动时延' + this.mmsNum + 'ms')
.fontColor(Color.White).fontSize('24fp')
}
}
}
}.width('100%').height('80%').backgroundColor(Color.Black)
.justifyContent(FlexAlign.SpaceEvenly)
...
...
validator/acts_validator/src/main/ets/pages/Experience/MmsHotStartTest.ets
浏览文件 @
9c1c3fbb
...
...
@@ -35,6 +35,7 @@ struct CustomContainerUser {
@State mmsNum: number = 0;
@State cameraNum: number = 0;
@State contactsNum: number = 0;
scroller: Scroller = new Scroller();
async aboutToAppear(){
await FirstDialog.ChooseDialog(this.StepTips,this.name);
this.Vue = false;
...
...
@@ -43,74 +44,75 @@ struct CustomContainerUser {
@Builder specificNoParam() {
Column() {
Flex({direction:FlexDirection.Column,alignItems: ItemAlign.Center, justifyContent: FlexAlign.SpaceBetween }) {
Column(){
Row(){
Text(`根据以下操作步骤完成测试`+ '\n' + '\n' )
.fontColor(Color.White).fontSize('24fp')
}
Row(){
Text(`测试步骤:`+ '\n' + '\n' + '1.测试设备通过USB连接工作台' + '\n' + '\n' + `2.点击开始键进入系统桌面`+ '\n' + '\n'
+ `3.开启信息应用回退到桌面,保证此时后台应用存在` + '\n' + '\n' + `4.工作台运行’点击启动测试.bat‘选择热启动>信息测试`+ '\n' + '\n' +
`5.测试应用手动执行热启动返回validator界面` + '\n' + '\n' + '6.点击结束键观察测试结果' + '\n' + '\n'
+ `7.若所有热启动测试均在规定时延内完成则通过测试` + '\n' + '\n' + '\n' + '\n' )
.fontColor(Color.White).fontSize('20fp')
}
Row(){
Column(){
Button(`开始`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(this.StartEnable)
.opacity(this.StartEnable? 1 : 0.4)
.onClick(async () => {
this.num = 0;
this.StartEnable = !this.StartEnable;
let str = {
bundleName:"com.ohos.launcher",
abilityName: "com.ohos.launcher.MainAbility",
}
abilityContext.startAbility(str).then((data) => {
Scroll(this.scroller) {
Column(){
Row(){
Text(`根据以下操作步骤完成测试`+ '\n' + '\n' )
.fontColor(Color.White).fontSize('24fp')
}
Row(){
Text(`测试步骤:`+ '\n' + '\n' + '1.测试设备通过USB连接工作台' + '\n' + '\n' + `2.点击开始键进入系统桌面`+ '\n' + '\n'
+ `3.开启信息应用回退到桌面,保证此时后台应用存在` + '\n' + '\n' + `4.工作台运行’点击启动测试.bat‘选择热启动>信息测试`+ '\n' + '\n' +
`5.测试应用手动执行热启动返回validator界面` + '\n' + '\n' + '6.点击结束键观察测试结果' + '\n' + '\n'
+ `7.若所有热启动测试均在规定时延内完成则通过测试` + '\n' + '\n' + '\n' + '\n' )
.fontColor(Color.White).fontSize('20fp')
}
Row(){
Column(){
Button(`开始`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(this.StartEnable)
.opacity(this.StartEnable? 1 : 0.4)
.onClick(async () => {
this.num = 0;
this.StartEnable = !this.StartEnable;
let str = {
bundleName:"com.ohos.launcher",
abilityName: "com.ohos.launcher.MainAbility",
}
abilityContext.startAbility(str).then((data) => {
}).catch((error) => {
}).catch((error) => {
})
})
})
}
Column(){
Button(`结束`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(!this.StartEnable)
.opacity(!this.StartEnable? 1 : 0.4)
.onClick(() => {
this.StartEnable = !this.StartEnable
/*
mms
*/
let MmsFd = fileio.openSync(MmsColdPath, 0o100 | 0o2002, 0o664);
let MmsBuf = new ArrayBuffer(4096);
fileio.readSync(MmsFd,MmsBuf);
let MmsReport = String.fromCharCode.apply(null,new Uint8Array(MmsBuf));
let MmsHead = MmsReport.indexOf(':');
let MmsTime = MmsReport.substring(MmsHead+1);
this.mmsNum = parseFloat(MmsTime);
if( 0 < this.mmsNum && this.mmsNum < 600 ) {
this.num++
}
if( this.num === 1 ) {
this.Vue = true;
}
})
}
}
Column(){
Button(`结束`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(!this.StartEnable)
.opacity(!this.StartEnable? 1 : 0.4)
.onClick(() => {
this.StartEnable = !this.StartEnable
/*
mms
*/
let MmsFd = fileio.openSync(MmsColdPath, 0o100 | 0o2002, 0o664);
let MmsBuf = new ArrayBuffer(4096);
fileio.readSync(MmsFd,MmsBuf);
let MmsReport = String.fromCharCode.apply(null,new Uint8Array(MmsBuf));
let MmsHead = MmsReport.indexOf(':');
let MmsTime = MmsReport.substring(MmsHead+1);
this.mmsNum = parseFloat(MmsTime);
if( 0 < this.mmsNum && this.mmsNum < 600 ) {
this.num++
}
if( this.num === 1 ) {
this.Vue = true;
}
})
Row(){
Text('\n' + '\n' + '\n' + '\n' + `测试结果:` + '\n' + '\n'+ '信息热启动时延' + this.mmsNum + 'ms')
.fontColor(Color.White).fontSize('24fp')
}
}
Row(){
Text('\n' + '\n' + '\n' + '\n' + `测试结果:` + '\n' + '\n'+ '信息热启动时延' + this.mmsNum + 'ms')
.fontColor(Color.White).fontSize('24fp')
}
}
}
}.width('100%').height('80%').backgroundColor(Color.Black)
.justifyContent(FlexAlign.SpaceEvenly)
...
...
validator/acts_validator/src/main/ets/pages/Experience/PhotoFps.ets
浏览文件 @
9c1c3fbb
...
...
@@ -29,6 +29,7 @@ struct CustomContainerUser {
@State Vue: boolean = false;
@State StartEnable: boolean = true;
@State Fps: string = '0';
scroller: Scroller = new Scroller();
async aboutToAppear(){
await FirstDialog.ChooseDialog(this.StepTips,this.name);
this.Vue = false;
...
...
@@ -37,86 +38,87 @@ struct CustomContainerUser {
@Builder specificNoParam() {
Column() {
Flex({direction:FlexDirection.Column,alignItems: ItemAlign.Center, justifyContent: FlexAlign.SpaceBetween }) {
Column(){
Row(){
Text(`根据以下操作步骤完成测试`+ '\n' + '\n' + '\n' + '\n'+ '\n' + '\n' + '\n' + '\n')
.fontColor(Color.White).fontSize('24fp')
}
Row(){
Text(`测试步骤:`+ '\n' + '\n' + '1.测试设备通过USB连接工作台' + '\n' + '\n' + `2.在图库中预置500张图片`+ '\n' + '\n'
+ `3.点击开始键进入图库`+ '\n' + '\n' + `4.工作台运行’点击启动测试.bat‘选择帧率>图库`+ '\n' + '\n' +
`5.滑动图库缩略图界面连续10s以上` + '\n' + '\n' + '6.回到PhotoFps测试项点击结束键' + '\n' + '\n' +
`7.若测试最高帧率大于或等于55帧则通过测试` + '\n' + '\n' + '\n' + '\n' + '\n' + '\n' + '\n' + '\n' )
.fontColor(Color.White).fontSize('20fp')
}
Row(){
Column(){
Button(`开始`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(this.StartEnable)
.opacity(this.StartEnable? 1 : 0.4)
.onClick(async () => {
this.StartEnable = !this.StartEnable;
let bundleName=new String("com.ohos.photos").toString();
let abilityName=new String("com.ohos.photos.MainAbility").toString();
let str = {
"bundleName": bundleName,
"abilityName": abilityName,
}
Scroll(this.scroller) {
Column(){
Row(){
Text(`根据以下操作步骤完成测试`+ '\n' + '\n' + '\n' + '\n'+ '\n' + '\n' + '\n' + '\n')
.fontColor(Color.White).fontSize('24fp')
}
Row(){
Text(`测试步骤:`+ '\n' + '\n' + '1.测试设备通过USB连接工作台' + '\n' + '\n' + `2.在图库中预置500张图片`+ '\n' + '\n'
+ `3.点击开始键进入图库`+ '\n' + '\n' + `4.工作台运行’点击启动测试.bat‘选择帧率>图库`+ '\n' + '\n' +
`5.滑动图库缩略图界面连续10s以上` + '\n' + '\n' + '6.回到PhotoFps测试项点击结束键' + '\n' + '\n' +
`7.若测试最高帧率大于或等于55帧则通过测试` + '\n' + '\n' + '\n' + '\n' + '\n' + '\n' + '\n' + '\n' )
.fontColor(Color.White).fontSize('20fp')
}
Row(){
Column(){
Button(`开始`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(this.StartEnable)
.opacity(this.StartEnable? 1 : 0.4)
.onClick(async () => {
this.StartEnable = !this.StartEnable;
let bundleName=new String("com.ohos.photos").toString();
let abilityName=new String("com.ohos.photos.MainAbility").toString();
let str = {
"bundleName": bundleName,
"abilityName": abilityName,
}
globalThis.abilityContext.startAbility(str, (err, data) => {
if(err) {
return;
}
})
})
}
Column(){
Button(`结束`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(!this.StartEnable)
.opacity(!this.StartEnable? 1 : 0.4)
.onClick(() => {
this.StartEnable = !this.StartEnable
let fd = fileio.openSync(Xpath, 0o100 | 0o2002, 0o664);
let buf = new ArrayBuffer(4096);
fileio.readSync(fd,buf);
let report = String.fromCharCode.apply(null,new Uint8Array(buf));
let headList = new Array();
let endList = new Array();
let head = report.indexOf(":");
let end = report.indexOf('|');
let Fps = new Array();
globalThis.abilityContext.startAbility(str, (err, data) => {
if(err) {
return;
while(head > -1){
headList.push(head);
head = report.indexOf(":",head + 1);
}
while(end > -1){
endList.push(end);
end = report.indexOf("|",end + 1);
}
for(let i = 0; i < headList.length; i++) {
Fps[i] = Number(report.substring(headList[i]+1,endList[i]));
}
let maxFps = Math.max(...Fps);
this.Fps = maxFps.toString();
if(maxFps >= 55) {
this.Vue = true;
}
})
})
}
}
Column(){
Button(`结束`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(!this.StartEnable)
.opacity(!this.StartEnable? 1 : 0.4)
.onClick(() => {
this.StartEnable = !this.StartEnable
let fd = fileio.openSync(Xpath, 0o100 | 0o2002, 0o664);
let buf = new ArrayBuffer(4096);
fileio.readSync(fd,buf);
let report = String.fromCharCode.apply(null,new Uint8Array(buf));
let headList = new Array();
let endList = new Array();
let head = report.indexOf(":");
let end = report.indexOf('|');
let Fps = new Array();
while(head > -1){
headList.push(head);
head = report.indexOf(":",head + 1);
}
while(end > -1){
endList.push(end);
end = report.indexOf("|",end + 1);
}
for(let i = 0; i < headList.length; i++) {
Fps[i] = Number(report.substring(headList[i]+1,endList[i]));
}
let maxFps = Math.max(...Fps);
this.Fps = maxFps.toString();
if(maxFps >= 55) {
this.Vue = true;
}
})
Row(){
Text('\n' + '\n' + '\n' + '\n'+ '\n' + '\n' + '\n' + '\n' + `测试结果:` + this.Fps + '帧' )
.fontColor(Color.White).fontSize('24fp')
}
}
Row(){
Text('\n' + '\n' + '\n' + '\n'+ '\n' + '\n' + '\n' + '\n' + `测试结果:` + this.Fps + '帧' )
.fontColor(Color.White).fontSize('24fp')
}
}
}
}.width('100%').height('80%').backgroundColor(Color.Black)
.justifyContent(FlexAlign.SpaceEvenly)
...
...
validator/acts_validator/src/main/ets/pages/Experience/PhotosColdStartTest.ets
浏览文件 @
9c1c3fbb
...
...
@@ -35,6 +35,7 @@ struct CustomContainerUser {
@State mmsNum: number = 0;
@State cameraNum: number = 0;
@State contactsNum: number = 0;
scroller: Scroller = new Scroller();
async aboutToAppear(){
await FirstDialog.ChooseDialog(this.StepTips,this.name);
this.Vue = false;
...
...
@@ -43,74 +44,75 @@ struct CustomContainerUser {
@Builder specificNoParam() {
Column() {
Flex({direction:FlexDirection.Column,alignItems: ItemAlign.Center, justifyContent: FlexAlign.SpaceBetween }) {
Column(){
Row(){
Text(`根据以下操作步骤完成测试`+ '\n' + '\n' )
.fontColor(Color.White).fontSize('24fp')
}
Row(){
Text(`测试步骤:`+ '\n' + '\n' + '1.测试设备通过USB连接工作台' + '\n' + '\n' + `2.点击开始键进入系统桌面` + '\n' + '\n'
+ `3.清空后台应用,将底层任务栏中应用拖至桌面` + '\n' + '\n' + `4.工作台运行‘点击启动测试.bat’选择冷启动>图库测试,回车执行`
+ '\n' + '\n' +`5.测试应用自动执行冷启动后手动返回validator界面` + '\n' + '\n' + '6.点击结束键观察测试结果'
+ '\n' + '\n' + `7.若冷启动测试在规定时延内完成则通过测试` + '\n' + '\n' )
.fontColor(Color.White).fontSize('20fp')
}
Row(){
Column(){
Button(`开始`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(this.StartEnable)
.opacity(this.StartEnable? 1 : 0.4)
.onClick(async () => {
this.num = 0;
this.StartEnable = !this.StartEnable;
let str = {
bundleName:"com.ohos.launcher",
abilityName: "com.ohos.launcher.MainAbility",
}
abilityContext.startAbility(str).then((data) => {
Scroll(this.scroller) {
Column(){
Row(){
Text(`根据以下操作步骤完成测试`+ '\n' + '\n' )
.fontColor(Color.White).fontSize('24fp')
}
Row(){
Text(`测试步骤:`+ '\n' + '\n' + '1.测试设备通过USB连接工作台' + '\n' + '\n' + `2.点击开始键进入系统桌面` + '\n' + '\n'
+ `3.清空后台应用,将底层任务栏中应用拖至桌面` + '\n' + '\n' + `4.工作台运行‘点击启动测试.bat’选择冷启动>图库测试,回车执行`
+ '\n' + '\n' +`5.测试应用自动执行冷启动后手动返回validator界面` + '\n' + '\n' + '6.点击结束键观察测试结果'
+ '\n' + '\n' + `7.若冷启动测试在规定时延内完成则通过测试` + '\n' + '\n' )
.fontColor(Color.White).fontSize('20fp')
}
Row(){
Column(){
Button(`开始`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(this.StartEnable)
.opacity(this.StartEnable? 1 : 0.4)
.onClick(async () => {
this.num = 0;
this.StartEnable = !this.StartEnable;
let str = {
bundleName:"com.ohos.launcher",
abilityName: "com.ohos.launcher.MainAbility",
}
abilityContext.startAbility(str).then((data) => {
}).catch((error) => {
}).catch((error) => {
})
})
})
}
Column(){
Button(`结束`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(!this.StartEnable)
.opacity(!this.StartEnable? 1 : 0.4)
.onClick(() => {
this.StartEnable = !this.StartEnable
/*
photos
*/
let photosFd = fileio.openSync(PhotosColdPath, 0o100 | 0o2002, 0o664);
let photosBuf = new ArrayBuffer(4096);
fileio.readSync(photosFd,photosBuf);
let photosReport = String.fromCharCode.apply(null,new Uint8Array(photosBuf));
let photosHead = photosReport.indexOf('time:');
let photosTime = photosReport.substring(photosHead+5);
this.photosNum = parseFloat(photosTime);
if( 0 < this.photosNum && this.photosNum < 2300 ) {
this.num++
}
if( this.num === 1 ) {
this.Vue = true;
}
})
}
}
Column(){
Button(`结束`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(!this.StartEnable)
.opacity(!this.StartEnable? 1 : 0.4)
.onClick(() => {
this.StartEnable = !this.StartEnable
/*
photos
*/
let photosFd = fileio.openSync(PhotosColdPath, 0o100 | 0o2002, 0o664);
let photosBuf = new ArrayBuffer(4096);
fileio.readSync(photosFd,photosBuf);
let photosReport = String.fromCharCode.apply(null,new Uint8Array(photosBuf));
let photosHead = photosReport.indexOf('time:');
let photosTime = photosReport.substring(photosHead+5);
this.photosNum = parseFloat(photosTime);
if( 0 < this.photosNum && this.photosNum < 2300 ) {
this.num++
}
if( this.num === 1 ) {
this.Vue = true;
}
})
Row(){
Text('\n' + '\n' + `测试结果:` + '\n' + '\n' + '图库冷启动时延' + this.photosNum + 'ms')
.fontColor(Color.White).fontSize('24fp')
}
}
Row(){
Text('\n' + '\n' + `测试结果:` + '\n' + '\n' + '图库冷启动时延' + this.photosNum + 'ms')
.fontColor(Color.White).fontSize('24fp')
}
}
}
}.width('100%').height('80%').backgroundColor(Color.Black)
.justifyContent(FlexAlign.SpaceEvenly)
...
...
validator/acts_validator/src/main/ets/pages/Experience/PhotosHotStartTest.ets
浏览文件 @
9c1c3fbb
...
...
@@ -35,6 +35,7 @@ struct CustomContainerUser {
@State mmsNum: number = 0;
@State cameraNum: number = 0;
@State contactsNum: number = 0;
scroller: Scroller = new Scroller();
async aboutToAppear(){
await FirstDialog.ChooseDialog(this.StepTips,this.name);
this.Vue = false;
...
...
@@ -43,74 +44,75 @@ struct CustomContainerUser {
@Builder specificNoParam() {
Column() {
Flex({direction:FlexDirection.Column,alignItems: ItemAlign.Center, justifyContent: FlexAlign.SpaceBetween }) {
Column(){
Row(){
Text(`根据以下操作步骤完成测试`+ '\n' + '\n' )
.fontColor(Color.White).fontSize('24fp')
}
Row(){
Text(`测试步骤:`+ '\n' + '\n' + '1.测试设备通过USB连接工作台' + '\n' + '\n' + `2.点击开始键进入系统桌面`+ '\n' + '\n'
+ `3.开启图库应用回退到桌面,保证此时后台应用存在` + '\n' + '\n' + `4.工作台运行’点击启动测试.bat‘选择热启动>图库测试`+ '\n' + '\n' +
`5.测试应用手动执行热启动返回validator界面` + '\n' + '\n' + '6.点击结束键观察测试结果' + '\n' + '\n'
+ `7.若所有热启动测试均在规定时延内完成则通过测试` + '\n' + '\n' + '\n' + '\n' )
.fontColor(Color.White).fontSize('20fp')
}
Row(){
Column(){
Button(`开始`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(this.StartEnable)
.opacity(this.StartEnable? 1 : 0.4)
.onClick(async () => {
this.num = 0;
this.StartEnable = !this.StartEnable;
let str = {
bundleName:"com.ohos.launcher",
abilityName: "com.ohos.launcher.MainAbility",
}
abilityContext.startAbility(str).then((data) => {
Scroll(this.scroller) {
Column(){
Row(){
Text(`根据以下操作步骤完成测试`+ '\n' + '\n' )
.fontColor(Color.White).fontSize('24fp')
}
Row(){
Text(`测试步骤:`+ '\n' + '\n' + '1.测试设备通过USB连接工作台' + '\n' + '\n' + `2.点击开始键进入系统桌面`+ '\n' + '\n'
+ `3.开启图库应用回退到桌面,保证此时后台应用存在` + '\n' + '\n' + `4.工作台运行’点击启动测试.bat‘选择热启动>图库测试`+ '\n' + '\n' +
`5.测试应用手动执行热启动返回validator界面` + '\n' + '\n' + '6.点击结束键观察测试结果' + '\n' + '\n'
+ `7.若所有热启动测试均在规定时延内完成则通过测试` + '\n' + '\n' + '\n' + '\n' )
.fontColor(Color.White).fontSize('20fp')
}
Row(){
Column(){
Button(`开始`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(this.StartEnable)
.opacity(this.StartEnable? 1 : 0.4)
.onClick(async () => {
this.num = 0;
this.StartEnable = !this.StartEnable;
let str = {
bundleName:"com.ohos.launcher",
abilityName: "com.ohos.launcher.MainAbility",
}
abilityContext.startAbility(str).then((data) => {
}).catch((error) => {
}).catch((error) => {
})
})
})
}
Column(){
Button(`结束`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(!this.StartEnable)
.opacity(!this.StartEnable? 1 : 0.4)
.onClick(() => {
this.StartEnable = !this.StartEnable
/*
photos
*/
let photosFd = fileio.openSync(PhotosColdPath, 0o100 | 0o2002, 0o664);
let photosBuf = new ArrayBuffer(4096);
fileio.readSync(photosFd,photosBuf);
let photosReport = String.fromCharCode.apply(null,new Uint8Array(photosBuf));
let photosHead = photosReport.indexOf(':');
let photosTime = photosReport.substring(photosHead+1);
this.photosNum = parseFloat(photosTime);
if( 0 < this.photosNum && this.photosNum < 600 ) {
this.num++
}
if( this.num === 1 ) {
this.Vue = true;
}
})
}
}
Column(){
Button(`结束`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(!this.StartEnable)
.opacity(!this.StartEnable? 1 : 0.4)
.onClick(() => {
this.StartEnable = !this.StartEnable
/*
photos
*/
let photosFd = fileio.openSync(PhotosColdPath, 0o100 | 0o2002, 0o664);
let photosBuf = new ArrayBuffer(4096);
fileio.readSync(photosFd,photosBuf);
let photosReport = String.fromCharCode.apply(null,new Uint8Array(photosBuf));
let photosHead = photosReport.indexOf(':');
let photosTime = photosReport.substring(photosHead+1);
this.photosNum = parseFloat(photosTime);
if( 0 < this.photosNum && this.photosNum < 600 ) {
this.num++
}
if( this.num === 1 ) {
this.Vue = true;
}
})
Row(){
Text('\n' + '\n' + '\n' + '\n' + `测试结果:` + '\n' + '\n' + '图库热启动时延' + this.photosNum + 'ms')
.fontColor(Color.White).fontSize('24fp')
}
}
Row(){
Text('\n' + '\n' + '\n' + '\n' + `测试结果:` + '\n' + '\n' + '图库热启动时延' + this.photosNum + 'ms')
.fontColor(Color.White).fontSize('24fp')
}
}
}
}.width('100%').height('80%').backgroundColor(Color.Black)
.justifyContent(FlexAlign.SpaceEvenly)
...
...
validator/acts_validator/src/main/ets/pages/Experience/ScrollPhotosList.ets
浏览文件 @
9c1c3fbb
...
...
@@ -29,6 +29,7 @@ struct CustomContainerUser {
@State Vue: boolean = false;
@State StartEnable: boolean = true;
@State time: string = '0';
scroller: Scroller = new Scroller();
async aboutToAppear(){
await FirstDialog.ChooseDialog(this.StepTips,this.name);
this.Vue = false;
...
...
@@ -37,70 +38,71 @@ struct CustomContainerUser {
@Builder specificNoParam() {
Column() {
Flex({direction:FlexDirection.Column,alignItems: ItemAlign.Center, justifyContent: FlexAlign.SpaceBetween }) {
Column(){
Row(){
Text(`根据以下操作步骤完成测试`+ '\n' + '\n' + '\n' + '\n'+ '\n' + '\n' + '\n' + '\n')
.fontColor(Color.White).fontSize('24fp')
}
Row(){
Text(`测试步骤:`+ '\n' + '\n' + '1.测试设备通过USB连接工作台' + '\n' + '\n' + `2.在图库中预置500张图片`+ '\n' + '\n'
+`3.点击开始键进入图库`+ '\n' + '\n' + `4.工作台运行’点击启动测试.bat‘选择响应时延>图库缩略列表滑动`+ '\n' + '\n' +
`5.滑动图库缩略列表等待响应` + '\n' + '\n' + '6.待脚本执行结束回到Validator点击结束键' + '\n' + '\n' +
`7.若滑动响应时延小于或等于150ms则通过测试` + '\n' + '\n' + '\n' + '\n' )
.fontColor(Color.White).fontSize('20fp')
}
Row(){
Column(){
Button(`开始`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(this.StartEnable)
.opacity(this.StartEnable? 1 : 0.4)
.onClick(async () => {
this.StartEnable = !this.StartEnable;
let bundleName=new String("com.ohos.photos").toString();
let abilityName=new String("com.ohos.photos.MainAbility").toString();
let str = {
"bundleName": bundleName,
"abilityName": abilityName,
}
Scroll(this.scroller) {
Column(){
Row(){
Text(`根据以下操作步骤完成测试`+ '\n' + '\n' + '\n' + '\n'+ '\n' + '\n' + '\n' + '\n')
.fontColor(Color.White).fontSize('24fp')
}
Row(){
Text(`测试步骤:`+ '\n' + '\n' + '1.测试设备通过USB连接工作台' + '\n' + '\n' + `2.在图库中预置500张图片`+ '\n' + '\n'
+`3.点击开始键进入图库`+ '\n' + '\n' + `4.工作台运行’点击启动测试.bat‘选择响应时延>图库缩略列表滑动`+ '\n' + '\n' +
`5.滑动图库缩略列表等待响应` + '\n' + '\n' + '6.待脚本执行结束回到Validator点击结束键' + '\n' + '\n' +
`7.若滑动响应时延小于或等于150ms则通过测试` + '\n' + '\n' + '\n' + '\n' )
.fontColor(Color.White).fontSize('20fp')
}
Row(){
Column(){
Button(`开始`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(this.StartEnable)
.opacity(this.StartEnable? 1 : 0.4)
.onClick(async () => {
this.StartEnable = !this.StartEnable;
let bundleName=new String("com.ohos.photos").toString();
let abilityName=new String("com.ohos.photos.MainAbility").toString();
let str = {
"bundleName": bundleName,
"abilityName": abilityName,
}
globalThis.abilityContext.startAbility(str, (err, data) => {
if(err) {
return;
globalThis.abilityContext.startAbility(str, (err, data) => {
if(err) {
return;
}
})
})
}
Column(){
Button(`结束`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(!this.StartEnable)
.opacity(!this.StartEnable? 1 : 0.4)
.onClick(() => {
this.StartEnable = !this.StartEnable
let fd = fileio.openSync(Xpath, 0o100 | 0o2002, 0o664);
let buf = new ArrayBuffer(4096);
fileio.readSync(fd,buf);
let report = String.fromCharCode.apply(null,new Uint8Array(buf));
let head = report.indexOf(":");
this.time = report.substring(head+1);
let time = parseFloat(this.time)
if( 0 < time && time < 150 ) {
this.Vue = true;
}
})
})
}
}
Column(){
Button(`结束`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(!this.StartEnable)
.opacity(!this.StartEnable? 1 : 0.4)
.onClick(() => {
this.StartEnable = !this.StartEnable
let fd = fileio.openSync(Xpath, 0o100 | 0o2002, 0o664);
let buf = new ArrayBuffer(4096);
fileio.readSync(fd,buf);
let report = String.fromCharCode.apply(null,new Uint8Array(buf));
let head = report.indexOf(":");
this.time = report.substring(head+1);
let time = parseFloat(this.time)
if( 0 < time && time < 150 ) {
this.Vue = true;
}
})
Row(){
Text('\n' + '\n' + '\n' + '\n'+ '\n' + '\n' + '\n' + '\n' + `滑动响应时延:` + this.time + 'ms' )
.fontColor(Color.White).fontSize('24fp')
}
}
Row(){
Text('\n' + '\n' + '\n' + '\n'+ '\n' + '\n' + '\n' + '\n' + `滑动响应时延:` + this.time + 'ms' )
.fontColor(Color.White).fontSize('24fp')
}
}
}
}.width('100%').height('80%').backgroundColor(Color.Black)
.justifyContent(FlexAlign.SpaceEvenly)
...
...
validator/acts_validator/src/main/ets/pages/Experience/SettingsColdStartTest.ets
浏览文件 @
9c1c3fbb
...
...
@@ -35,6 +35,7 @@ struct CustomContainerUser {
@State mmsNum: number = 0;
@State cameraNum: number = 0;
@State contactsNum: number = 0;
scroller: Scroller = new Scroller();
async aboutToAppear(){
await FirstDialog.ChooseDialog(this.StepTips,this.name);
this.Vue = false;
...
...
@@ -43,74 +44,75 @@ struct CustomContainerUser {
@Builder specificNoParam() {
Column() {
Flex({direction:FlexDirection.Column,alignItems: ItemAlign.Center, justifyContent: FlexAlign.SpaceBetween }) {
Column(){
Row(){
Text(`根据以下操作步骤完成测试`+ '\n' + '\n' )
.fontColor(Color.White).fontSize('24fp')
}
Row(){
Text(`测试步骤:`+ '\n' + '\n' + '1.测试设备通过USB连接工作台' + '\n' + '\n' + `2.点击开始键进入系统桌面` + '\n' + '\n'
+ `3.清空后台应用,将底层任务栏中应用拖至桌面` + '\n' + '\n' + `4.工作台运行‘点击启动测试.bat’选择冷启动>设置测试,回车执行`
+ '\n' + '\n' +`5.测试应用自动执行冷启动后手动返回validator界面` + '\n' + '\n' + '6.点击结束键观察测试结果'
+ '\n' + '\n' + `7.若冷启动测试在规定时延内完成则通过测试` + '\n' + '\n' )
.fontColor(Color.White).fontSize('20fp')
}
Row(){
Column(){
Button(`开始`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(this.StartEnable)
.opacity(this.StartEnable? 1 : 0.4)
.onClick(async () => {
this.num = 0;
this.StartEnable = !this.StartEnable;
let str = {
bundleName:"com.ohos.launcher",
abilityName: "com.ohos.launcher.MainAbility",
}
abilityContext.startAbility(str).then((data) => {
Scroll(this.scroller) {
Column(){
Row(){
Text(`根据以下操作步骤完成测试`+ '\n' + '\n' )
.fontColor(Color.White).fontSize('24fp')
}
Row(){
Text(`测试步骤:`+ '\n' + '\n' + '1.测试设备通过USB连接工作台' + '\n' + '\n' + `2.点击开始键进入系统桌面` + '\n' + '\n'
+ `3.清空后台应用,将底层任务栏中应用拖至桌面` + '\n' + '\n' + `4.工作台运行‘点击启动测试.bat’选择冷启动>设置测试,回车执行`
+ '\n' + '\n' +`5.测试应用自动执行冷启动后手动返回validator界面` + '\n' + '\n' + '6.点击结束键观察测试结果'
+ '\n' + '\n' + `7.若冷启动测试在规定时延内完成则通过测试` + '\n' + '\n' )
.fontColor(Color.White).fontSize('20fp')
}
Row(){
Column(){
Button(`开始`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(this.StartEnable)
.opacity(this.StartEnable? 1 : 0.4)
.onClick(async () => {
this.num = 0;
this.StartEnable = !this.StartEnable;
let str = {
bundleName:"com.ohos.launcher",
abilityName: "com.ohos.launcher.MainAbility",
}
abilityContext.startAbility(str).then((data) => {
}).catch((error) => {
}).catch((error) => {
})
})
})
}
Column(){
Button(`结束`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(!this.StartEnable)
.opacity(!this.StartEnable? 1 : 0.4)
.onClick(() => {
this.StartEnable = !this.StartEnable
/*
settings
*/
let setFd = fileio.openSync(SettingsColdPath, 0o100 | 0o2002, 0o664);
let setBuf = new ArrayBuffer(4096);
fileio.readSync(setFd,setBuf);
let setReport = String.fromCharCode.apply(null,new Uint8Array(setBuf));
let setHead = setReport.indexOf('time:');
let setTime = setReport.substring(setHead+5);
this.setNum = parseFloat(setTime);
if( 0 < this.setNum && this.setNum < 2300 ) {
this.num++
}
if( this.num === 1 ) {
this.Vue = true;
}
})
}
}
Column(){
Button(`结束`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(!this.StartEnable)
.opacity(!this.StartEnable? 1 : 0.4)
.onClick(() => {
this.StartEnable = !this.StartEnable
/*
settings
*/
let setFd = fileio.openSync(SettingsColdPath, 0o100 | 0o2002, 0o664);
let setBuf = new ArrayBuffer(4096);
fileio.readSync(setFd,setBuf);
let setReport = String.fromCharCode.apply(null,new Uint8Array(setBuf));
let setHead = setReport.indexOf('time:');
let setTime = setReport.substring(setHead+5);
this.setNum = parseFloat(setTime);
if( 0 < this.setNum && this.setNum < 2300 ) {
this.num++
}
if( this.num === 1 ) {
this.Vue = true;
}
})
Row(){
Text('\n' + '\n' + `测试结果:` + '\n' + '\n' + '设置冷启动时延' + this.setNum + 'ms')
.fontColor(Color.White).fontSize('24fp')
}
}
Row(){
Text('\n' + '\n' + `测试结果:` + '\n' + '\n' + '设置冷启动时延' + this.setNum + 'ms')
.fontColor(Color.White).fontSize('24fp')
}
}
}
}.width('100%').height('80%').backgroundColor(Color.Black)
.justifyContent(FlexAlign.SpaceEvenly)
...
...
validator/acts_validator/src/main/ets/pages/Experience/SettingsHotStartTest.ets
浏览文件 @
9c1c3fbb
...
...
@@ -35,6 +35,7 @@ struct CustomContainerUser {
@State mmsNum: number = 0;
@State cameraNum: number = 0;
@State contactsNum: number = 0;
scroller: Scroller = new Scroller();
async aboutToAppear(){
await FirstDialog.ChooseDialog(this.StepTips,this.name);
this.Vue = false;
...
...
@@ -43,74 +44,75 @@ struct CustomContainerUser {
@Builder specificNoParam() {
Column() {
Flex({direction:FlexDirection.Column,alignItems: ItemAlign.Center, justifyContent: FlexAlign.SpaceBetween }) {
Column(){
Row(){
Text(`根据以下操作步骤完成测试`+ '\n' + '\n' )
.fontColor(Color.White).fontSize('24fp')
}
Row(){
Text(`测试步骤:`+ '\n' + '\n' + '1.测试设备通过USB连接工作台' + '\n' + '\n' + `2.点击开始键进入系统桌面`+ '\n' + '\n'
+ `3.开启设置应用回退到桌面,保证此时后台应用存在` + '\n' + '\n' + `4.工作台运行’点击启动测试.bat‘选择热启动>设置测试`+ '\n' + '\n' +
`5.测试应用手动执行热启动返回validator界面` + '\n' + '\n' + '6.点击结束键观察测试结果' + '\n' + '\n'
+ `7.若所有热启动测试均在规定时延内完成则通过测试` + '\n' + '\n' + '\n' + '\n' )
.fontColor(Color.White).fontSize('20fp')
}
Row(){
Column(){
Button(`开始`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(this.StartEnable)
.opacity(this.StartEnable? 1 : 0.4)
.onClick(async () => {
this.num = 0;
this.StartEnable = !this.StartEnable;
let str = {
bundleName:"com.ohos.launcher",
abilityName: "com.ohos.launcher.MainAbility",
}
abilityContext.startAbility(str).then((data) => {
Scroll(this.scroller) {
Column(){
Row(){
Text(`根据以下操作步骤完成测试`+ '\n' + '\n' )
.fontColor(Color.White).fontSize('24fp')
}
Row(){
Text(`测试步骤:`+ '\n' + '\n' + '1.测试设备通过USB连接工作台' + '\n' + '\n' + `2.点击开始键进入系统桌面`+ '\n' + '\n'
+ `3.开启设置应用回退到桌面,保证此时后台应用存在` + '\n' + '\n' + `4.工作台运行’点击启动测试.bat‘选择热启动>设置测试`+ '\n' + '\n' +
`5.测试应用手动执行热启动返回validator界面` + '\n' + '\n' + '6.点击结束键观察测试结果' + '\n' + '\n'
+ `7.若所有热启动测试均在规定时延内完成则通过测试` + '\n' + '\n' + '\n' + '\n' )
.fontColor(Color.White).fontSize('20fp')
}
Row(){
Column(){
Button(`开始`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(this.StartEnable)
.opacity(this.StartEnable? 1 : 0.4)
.onClick(async () => {
this.num = 0;
this.StartEnable = !this.StartEnable;
let str = {
bundleName:"com.ohos.launcher",
abilityName: "com.ohos.launcher.MainAbility",
}
abilityContext.startAbility(str).then((data) => {
}).catch((error) => {
}).catch((error) => {
})
})
})
}
Column(){
Button(`结束`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(!this.StartEnable)
.opacity(!this.StartEnable? 1 : 0.4)
.onClick(() => {
this.StartEnable = !this.StartEnable
/*
settings
*/
let setFd = fileio.openSync(SettingsColdPath, 0o100 | 0o2002, 0o664);
let setBuf = new ArrayBuffer(4096);
fileio.readSync(setFd,setBuf);
let setReport = String.fromCharCode.apply(null,new Uint8Array(setBuf));
let setHead = setReport.indexOf(':');
let setTime = setReport.substring(setHead+1);
this.setNum = parseFloat(setTime);
if( 0 < this.setNum && this.setNum < 600 ) {
this.num++
}
if( this.num === 1 ) {
this.Vue = true;
}
})
}
}
Column(){
Button(`结束`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(!this.StartEnable)
.opacity(!this.StartEnable? 1 : 0.4)
.onClick(() => {
this.StartEnable = !this.StartEnable
/*
settings
*/
let setFd = fileio.openSync(SettingsColdPath, 0o100 | 0o2002, 0o664);
let setBuf = new ArrayBuffer(4096);
fileio.readSync(setFd,setBuf);
let setReport = String.fromCharCode.apply(null,new Uint8Array(setBuf));
let setHead = setReport.indexOf(':');
let setTime = setReport.substring(setHead+1);
this.setNum = parseFloat(setTime);
if( 0 < this.setNum && this.setNum < 600 ) {
this.num++
}
if( this.num === 1 ) {
this.Vue = true;
}
})
Row(){
Text('\n' + '\n' + '\n' + '\n' + `测试结果:` + '\n' + '\n' + '设置热启动时延' + this.setNum + 'ms')
.fontColor(Color.White).fontSize('24fp')
}
}
Row(){
Text('\n' + '\n' + '\n' + '\n' + `测试结果:` + '\n' + '\n' + '设置热启动时延' + this.setNum + 'ms')
.fontColor(Color.White).fontSize('24fp')
}
}
}
}.width('100%').height('80%').backgroundColor(Color.Black)
.justifyContent(FlexAlign.SpaceEvenly)
...
...
validator/acts_validator/src/main/ets/pages/Experience/StartBackgroundTask.ets
浏览文件 @
9c1c3fbb
...
...
@@ -31,6 +31,7 @@ struct CustomContainerUser {
@State Vue: boolean = false;
@State StartEnable: boolean = true;
@State time: string = '0';
scroller: Scroller = new Scroller();
async aboutToAppear(){
await FirstDialog.ChooseDialog(this.StepTips,this.name);
this.Vue = false;
...
...
@@ -39,67 +40,68 @@ struct CustomContainerUser {
@Builder specificNoParam() {
Column() {
Flex({direction:FlexDirection.Column,alignItems: ItemAlign.Center, justifyContent: FlexAlign.SpaceBetween }) {
Column(){
Row(){
Text(`根据以下操作步骤完成测试`+ '\n' + '\n' + '\n' + '\n'+ '\n' + '\n' + '\n' + '\n')
.fontColor(Color.White).fontSize('24fp')
}
Row(){
Text(`测试步骤:`+ '\n' + '\n' + '1.测试设备通过USB连接工作台' + '\n' + '\n' + `2.点击开始键进入桌面开启任务管理器`
+ '\n' + '\n' + `3.工作台运行’点击启动测试.bat‘选择完成时延>后台任务切换`+ '\n' + '\n' +`4.随意点开一个后台任务`
+ '\n' + '\n' + '5.待脚本执行结束回到Validator点击结束键' + '\n' + '\n' +
`6.若打开后台任务时延小于或等于600ms则通过测试` + '\n' + '\n' + '\n' + '\n' )
.fontColor(Color.White).fontSize('20fp')
}
Row(){
Column(){
Button(`开始`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(this.StartEnable)
.opacity(this.StartEnable? 1 : 0.4)
.onClick(async () => {
this.StartEnable = !this.StartEnable;
let str = {
bundleName:"com.ohos.launcher",
abilityName: "com.ohos.launcher.MainAbility",
}
abilityContext.startAbility(str).then((data) => {
Scroll(this.scroller) {
Column(){
Row(){
Text(`根据以下操作步骤完成测试`+ '\n' + '\n' + '\n' + '\n'+ '\n' + '\n' + '\n' + '\n')
.fontColor(Color.White).fontSize('24fp')
}
Row(){
Text(`测试步骤:`+ '\n' + '\n' + '1.测试设备通过USB连接工作台' + '\n' + '\n' + `2.点击开始键进入桌面开启任务管理器`
+ '\n' + '\n' + `3.工作台运行’点击启动测试.bat‘选择完成时延>后台任务切换`+ '\n' + '\n' +`4.随意点开一个后台任务`
+ '\n' + '\n' + '5.待脚本执行结束回到Validator点击结束键' + '\n' + '\n' +
`6.若打开后台任务时延小于或等于600ms则通过测试` + '\n' + '\n' + '\n' + '\n' )
.fontColor(Color.White).fontSize('20fp')
}
Row(){
Column(){
Button(`开始`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(this.StartEnable)
.opacity(this.StartEnable? 1 : 0.4)
.onClick(async () => {
this.StartEnable = !this.StartEnable;
let str = {
bundleName:"com.ohos.launcher",
abilityName: "com.ohos.launcher.MainAbility",
}
abilityContext.startAbility(str).then((data) => {
}).catch((error) => {
}).catch((error) => {
})
})
})
}
Column(){
Button(`结束`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(!this.StartEnable)
.opacity(!this.StartEnable? 1 : 0.4)
.onClick(() => {
this.StartEnable = !this.StartEnable
let fd = fileio.openSync(Xpath, 0o100 | 0o2002, 0o664);
let buf = new ArrayBuffer(4096);
fileio.readSync(fd,buf);
let report = String.fromCharCode.apply(null,new Uint8Array(buf));
let head = report.indexOf(":");
this.time = report.substring(head+1);
let time = parseFloat(this.time)
if( 0 < time && time < 600 ) {
this.Vue = true;
}
})
}
}
Column(){
Button(`结束`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(!this.StartEnable)
.opacity(!this.StartEnable? 1 : 0.4)
.onClick(() => {
this.StartEnable = !this.StartEnable
let fd = fileio.openSync(Xpath, 0o100 | 0o2002, 0o664);
let buf = new ArrayBuffer(4096);
fileio.readSync(fd,buf);
let report = String.fromCharCode.apply(null,new Uint8Array(buf));
let head = report.indexOf(":");
this.time = report.substring(head+1);
let time = parseFloat(this.time)
if( 0 < time && time < 600 ) {
this.Vue = true;
}
})
Row(){
Text('\n' + '\n' + '\n' + '\n'+ '\n' + '\n' + '\n' + '\n' + `打开后台任务时延:` + this.time + 'ms' )
.fontColor(Color.White).fontSize('24fp')
}
}
Row(){
Text('\n' + '\n' + '\n' + '\n'+ '\n' + '\n' + '\n' + '\n' + `打开后台任务时延:` + this.time + 'ms' )
.fontColor(Color.White).fontSize('24fp')
}
}
}
}.width('100%').height('80%').backgroundColor(Color.Black)
.justifyContent(FlexAlign.SpaceEvenly)
...
...
validator/acts_validator/src/main/ets/pages/Experience/StartNotification.ets
浏览文件 @
9c1c3fbb
...
...
@@ -31,6 +31,7 @@ struct CustomContainerUser {
@State Vue: boolean = false;
@State StartEnable: boolean = true;
@State time: string = '0';
scroller: Scroller = new Scroller();
async aboutToAppear(){
await FirstDialog.ChooseDialog(this.StepTips,this.name);
this.Vue = false;
...
...
@@ -39,67 +40,68 @@ struct CustomContainerUser {
@Builder specificNoParam() {
Column() {
Flex({direction:FlexDirection.Column,alignItems: ItemAlign.Center, justifyContent: FlexAlign.SpaceBetween }) {
Column(){
Row(){
Text(`根据以下操作步骤完成测试`+ '\n' + '\n' + '\n' + '\n'+ '\n' + '\n' + '\n' + '\n')
.fontColor(Color.White).fontSize('24fp')
}
Row(){
Text(`测试步骤:`+ '\n' + '\n' + '1.测试设备通过USB连接工作台' + '\n' + '\n' + `2.点击开始键进入桌面` + '\n' + '\n'
+ `3.工作台运行’点击启动测试.bat‘选择响应时延>下拉状态栏`+ '\n' + '\n' +`4.从屏幕顶部滑动下拉通知栏` + '\n' + '\n'
+ '5.待脚本执行结束回到Validator点击结束键' + '\n' + '\n' + `6.若下拉通知栏时延小于或等于150ms则通过测试` +
'\n' + '\n' + '\n' + '\n' )
.fontColor(Color.White).fontSize('20fp')
}
Row(){
Column(){
Button(`开始`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(this.StartEnable)
.opacity(this.StartEnable? 1 : 0.4)
.onClick(async () => {
this.StartEnable = !this.StartEnable;
let str = {
bundleName:"com.ohos.launcher",
abilityName: "com.ohos.launcher.MainAbility",
}
abilityContext.startAbility(str).then((data) => {
Scroll(this.scroller) {
Column(){
Row(){
Text(`根据以下操作步骤完成测试`+ '\n' + '\n' + '\n' + '\n'+ '\n' + '\n' + '\n' + '\n')
.fontColor(Color.White).fontSize('24fp')
}
Row(){
Text(`测试步骤:`+ '\n' + '\n' + '1.测试设备通过USB连接工作台' + '\n' + '\n' + `2.点击开始键进入桌面` + '\n' + '\n'
+ `3.工作台运行’点击启动测试.bat‘选择响应时延>下拉状态栏`+ '\n' + '\n' +`4.从屏幕顶部滑动下拉通知栏` + '\n' + '\n'
+ '5.待脚本执行结束回到Validator点击结束键' + '\n' + '\n' + `6.若下拉通知栏时延小于或等于150ms则通过测试` +
'\n' + '\n' + '\n' + '\n' )
.fontColor(Color.White).fontSize('20fp')
}
Row(){
Column(){
Button(`开始`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(this.StartEnable)
.opacity(this.StartEnable? 1 : 0.4)
.onClick(async () => {
this.StartEnable = !this.StartEnable;
let str = {
bundleName:"com.ohos.launcher",
abilityName: "com.ohos.launcher.MainAbility",
}
abilityContext.startAbility(str).then((data) => {
}).catch((error) => {
}).catch((error) => {
})
})
})
}
Column(){
Button(`结束`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(!this.StartEnable)
.opacity(!this.StartEnable? 1 : 0.4)
.onClick(() => {
this.StartEnable = !this.StartEnable
let fd = fileio.openSync(Xpath, 0o100 | 0o2002, 0o664);
let buf = new ArrayBuffer(4096);
fileio.readSync(fd,buf);
let report = String.fromCharCode.apply(null,new Uint8Array(buf));
let head = report.indexOf(":");
this.time = report.substring(head+1);
let time = parseFloat(this.time)
if( 0 < time && time < 150 ) {
this.Vue = true;
}
})
}
}
Column(){
Button(`结束`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(!this.StartEnable)
.opacity(!this.StartEnable? 1 : 0.4)
.onClick(() => {
this.StartEnable = !this.StartEnable
let fd = fileio.openSync(Xpath, 0o100 | 0o2002, 0o664);
let buf = new ArrayBuffer(4096);
fileio.readSync(fd,buf);
let report = String.fromCharCode.apply(null,new Uint8Array(buf));
let head = report.indexOf(":");
this.time = report.substring(head+1);
let time = parseFloat(this.time)
if( 0 < time && time < 150 ) {
this.Vue = true;
}
})
Row(){
Text('\n' + '\n' + '\n' + '\n'+ '\n' + '\n' + '\n' + '\n' + `下拉通知栏时延:` + this.time + 'ms' )
.fontColor(Color.White).fontSize('24fp')
}
}
Row(){
Text('\n' + '\n' + '\n' + '\n'+ '\n' + '\n' + '\n' + '\n' + `下拉通知栏时延:` + this.time + 'ms' )
.fontColor(Color.White).fontSize('24fp')
}
}
}
}.width('100%').height('80%').backgroundColor(Color.Black)
.justifyContent(FlexAlign.SpaceEvenly)
...
...
validator/acts_validator/src/main/ets/pages/Experience/StartTaskManager.ets
浏览文件 @
9c1c3fbb
...
...
@@ -31,6 +31,7 @@ struct CustomContainerUser {
@State Vue: boolean = false;
@State StartEnable: boolean = true;
@State time: string = '0';
scroller: Scroller = new Scroller();
async aboutToAppear(){
await FirstDialog.ChooseDialog(this.StepTips,this.name);
this.Vue = false;
...
...
@@ -39,67 +40,68 @@ struct CustomContainerUser {
@Builder specificNoParam() {
Column() {
Flex({direction:FlexDirection.Column,alignItems: ItemAlign.Center, justifyContent: FlexAlign.SpaceBetween }) {
Column(){
Row(){
Text(`根据以下操作步骤完成测试`+ '\n' + '\n' + '\n' + '\n'+ '\n' + '\n' + '\n' + '\n')
.fontColor(Color.White).fontSize('24fp')
}
Row(){
Text(`测试步骤:`+ '\n' + '\n' + '1.测试设备通过USB连接工作台' + '\n' + '\n' + `2.点击开始键进入桌面` + '\n' + '\n'
+ `3.工作台运行’点击启动测试.bat‘选择完成时延>启动任务管理器`+ '\n' + '\n' +`4.点击右下角方框开启任务管理器` + '\n' + '\n'
+ '5.待脚本执行结束回到Validator点击结束键' + '\n' + '\n' + `6.若启动任务管理器时延小于或等于1000ms则通过测试`
+ '\n' + '\n' + '\n' + '\n' )
.fontColor(Color.White).fontSize('20fp')
}
Row(){
Column(){
Button(`开始`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(this.StartEnable)
.opacity(this.StartEnable? 1 : 0.4)
.onClick(async () => {
this.StartEnable = !this.StartEnable;
let str = {
bundleName:"com.ohos.launcher",
abilityName: "com.ohos.launcher.MainAbility",
}
abilityContext.startAbility(str).then((data) => {
Scroll(this.scroller) {
Column(){
Row(){
Text(`根据以下操作步骤完成测试`+ '\n' + '\n' + '\n' + '\n'+ '\n' + '\n' + '\n' + '\n')
.fontColor(Color.White).fontSize('24fp')
}
Row(){
Text(`测试步骤:`+ '\n' + '\n' + '1.测试设备通过USB连接工作台' + '\n' + '\n' + `2.点击开始键进入桌面` + '\n' + '\n'
+ `3.工作台运行’点击启动测试.bat‘选择完成时延>启动任务管理器`+ '\n' + '\n' +`4.点击右下角方框开启任务管理器` + '\n' + '\n'
+ '5.待脚本执行结束回到Validator点击结束键' + '\n' + '\n' + `6.若启动任务管理器时延小于或等于1000ms则通过测试`
+ '\n' + '\n' + '\n' + '\n' )
.fontColor(Color.White).fontSize('20fp')
}
Row(){
Column(){
Button(`开始`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(this.StartEnable)
.opacity(this.StartEnable? 1 : 0.4)
.onClick(async () => {
this.StartEnable = !this.StartEnable;
let str = {
bundleName:"com.ohos.launcher",
abilityName: "com.ohos.launcher.MainAbility",
}
abilityContext.startAbility(str).then((data) => {
}).catch((error) => {
}).catch((error) => {
})
})
})
}
Column(){
Button(`结束`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(!this.StartEnable)
.opacity(!this.StartEnable? 1 : 0.4)
.onClick(() => {
this.StartEnable = !this.StartEnable
let fd = fileio.openSync(Xpath, 0o100 | 0o2002, 0o664);
let buf = new ArrayBuffer(4096);
fileio.readSync(fd,buf);
let report = String.fromCharCode.apply(null,new Uint8Array(buf));
let head = report.indexOf(":");
this.time = report.substring(head+1);
let time = parseFloat(this.time)
if( 0 < time && time < 1000 ) {
this.Vue = true;
}
})
}
}
Column(){
Button(`结束`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(!this.StartEnable)
.opacity(!this.StartEnable? 1 : 0.4)
.onClick(() => {
this.StartEnable = !this.StartEnable
let fd = fileio.openSync(Xpath, 0o100 | 0o2002, 0o664);
let buf = new ArrayBuffer(4096);
fileio.readSync(fd,buf);
let report = String.fromCharCode.apply(null,new Uint8Array(buf));
let head = report.indexOf(":");
this.time = report.substring(head+1);
let time = parseFloat(this.time)
if( 0 < time && time < 1000 ) {
this.Vue = true;
}
})
Row(){
Text('\n' + '\n' + '\n' + '\n'+ '\n' + '\n' + '\n' + '\n' + `启动任务管理器时延:` + this.time + 'ms' )
.fontColor(Color.White).fontSize('24fp')
}
}
Row(){
Text('\n' + '\n' + '\n' + '\n'+ '\n' + '\n' + '\n' + '\n' + `启动任务管理器时延:` + this.time + 'ms' )
.fontColor(Color.White).fontSize('24fp')
}
}
}
}.width('100%').height('80%').backgroundColor(Color.Black)
.justifyContent(FlexAlign.SpaceEvenly)
...
...
validator/acts_validator/src/main/ets/pages/Experience/ViewPhotoTest.ets
浏览文件 @
9c1c3fbb
...
...
@@ -29,6 +29,7 @@ struct CustomContainerUser {
@State Vue: boolean = false;
@State StartEnable: boolean = true;
@State time: string = '0';
scroller: Scroller = new Scroller();
async aboutToAppear(){
await FirstDialog.ChooseDialog(this.StepTips,this.name);
this.Vue = false;
...
...
@@ -37,70 +38,71 @@ struct CustomContainerUser {
@Builder specificNoParam() {
Column() {
Flex({direction:FlexDirection.Column,alignItems: ItemAlign.Center, justifyContent: FlexAlign.SpaceBetween }) {
Column(){
Row(){
Text(`根据以下操作步骤完成测试`+ '\n' + '\n' + '\n' + '\n'+ '\n' + '\n' + '\n' + '\n')
.fontColor(Color.White).fontSize('24fp')
}
Row(){
Text(`测试步骤:`+ '\n' + '\n' + '1.测试设备通过USB连接工作台' + '\n' + '\n' + `2.在图库中预置500张图片`+ '\n' + '\n'
+ `3.点击开始键进入图库`+ '\n' + '\n' + `4.工作台运行’点击启动测试.bat‘选择响应时延>查看图片` + '\n' + '\n' +
`5.点击一张图库缩略图等待响应` + '\n' + '\n' + '6.待脚本执行结束回到Validator点击结束键' + '\n' + '\n' +
`7.若图片响应时延小于或等于150ms则通过测试` + '\n' + '\n' + '\n' + '\n' )
.fontColor(Color.White).fontSize('20fp')
}
Row(){
Column(){
Button(`开始`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(this.StartEnable)
.opacity(this.StartEnable? 1 : 0.4)
.onClick(async () => {
this.StartEnable = !this.StartEnable;
let bundleName=new String("com.ohos.photos").toString();
let abilityName=new String("com.ohos.photos.MainAbility").toString();
let str = {
"bundleName": bundleName,
"abilityName": abilityName,
}
Scroll(this.scroller) {
Column(){
Row(){
Text(`根据以下操作步骤完成测试`+ '\n' + '\n' + '\n' + '\n'+ '\n' + '\n' + '\n' + '\n')
.fontColor(Color.White).fontSize('24fp')
}
Row(){
Text(`测试步骤:`+ '\n' + '\n' + '1.测试设备通过USB连接工作台' + '\n' + '\n' + `2.在图库中预置500张图片`+ '\n' + '\n'
+ `3.点击开始键进入图库`+ '\n' + '\n' + `4.工作台运行’点击启动测试.bat‘选择响应时延>查看图片` + '\n' + '\n' +
`5.点击一张图库缩略图等待响应` + '\n' + '\n' + '6.待脚本执行结束回到Validator点击结束键' + '\n' + '\n' +
`7.若图片响应时延小于或等于150ms则通过测试` + '\n' + '\n' + '\n' + '\n' )
.fontColor(Color.White).fontSize('20fp')
}
Row(){
Column(){
Button(`开始`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(this.StartEnable)
.opacity(this.StartEnable? 1 : 0.4)
.onClick(async () => {
this.StartEnable = !this.StartEnable;
let bundleName=new String("com.ohos.photos").toString();
let abilityName=new String("com.ohos.photos.MainAbility").toString();
let str = {
"bundleName": bundleName,
"abilityName": abilityName,
}
globalThis.abilityContext.startAbility(str, (err, data) => {
if(err) {
return;
globalThis.abilityContext.startAbility(str, (err, data) => {
if(err) {
return;
}
})
})
}
Column(){
Button(`结束`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(!this.StartEnable)
.opacity(!this.StartEnable? 1 : 0.4)
.onClick(() => {
this.StartEnable = !this.StartEnable
let fd = fileio.openSync(Xpath, 0o100 | 0o2002, 0o664);
let buf = new ArrayBuffer(4096);
fileio.readSync(fd,buf);
let report = String.fromCharCode.apply(null,new Uint8Array(buf));
let head = report.indexOf(":");
this.time = report.substring(head+1);
let time = parseFloat(this.time)
if( 0 < time && time < 150 ) {
this.Vue = true;
}
})
})
}
}
Column(){
Button(`结束`)
.borderRadius(8)
.backgroundColor(0x317aff)
.width('30%')
.enabled(!this.StartEnable)
.opacity(!this.StartEnable? 1 : 0.4)
.onClick(() => {
this.StartEnable = !this.StartEnable
let fd = fileio.openSync(Xpath, 0o100 | 0o2002, 0o664);
let buf = new ArrayBuffer(4096);
fileio.readSync(fd,buf);
let report = String.fromCharCode.apply(null,new Uint8Array(buf));
let head = report.indexOf(":");
this.time = report.substring(head+1);
let time = parseFloat(this.time)
if( 0 < time && time < 150 ) {
this.Vue = true;
}
})
Row(){
Text('\n' + '\n' + '\n' + '\n'+ '\n' + '\n' + '\n' + '\n' + `图片响应时延:` + this.time + 'ms' )
.fontColor(Color.White).fontSize('24fp')
}
}
Row(){
Text('\n' + '\n' + '\n' + '\n'+ '\n' + '\n' + '\n' + '\n' + `图片响应时延:` + this.time + 'ms' )
.fontColor(Color.White).fontSize('24fp')
}
}
}
}.width('100%').height('80%').backgroundColor(Color.Black)
.justifyContent(FlexAlign.SpaceEvenly)
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录