Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
OpenHarmony
Xts Acts
提交
de2841b6
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看板
未验证
提交
de2841b6
编写于
12月 01, 2022
作者:
O
openharmony_ci
提交者:
Gitee
12月 01, 2022
浏览文件
操作
浏览文件
下载
差异文件
!6755 Web添加Visibility XTS测试用例
Merge pull request !6755 from pilipala195/web_visibility_1130
上级
798fb521
b0a0de86
变更
2
隐藏空白更改
内联
并排
Showing
2 changed file
with
214 addition
and
190 deletion
+214
-190
arkui/ace_ets_web_dev/entry/src/main/ets/MainAbility/pages/web.ets
..._ets_web_dev/entry/src/main/ets/MainAbility/pages/web.ets
+17
-4
arkui/ace_ets_web_dev/entry/src/main/ets/test/WebJsunit.test.ets
...ce_ets_web_dev/entry/src/main/ets/test/WebJsunit.test.ets
+197
-186
未找到文件。
arkui/ace_ets_web_dev/entry/src/main/ets/MainAbility/pages/web.ets
浏览文件 @
de2841b6
...
...
@@ -55,6 +55,7 @@ struct Index {
@State mixedSwitch:boolean=false
@State mixedAllSwitch:boolean=false
@State overViewFalseHeight:number=0
@State webVisibility: Visibility = Visibility.Visible
onPageShow(){
let valueChangeEvent={
eventId:10,
...
...
@@ -89,7 +90,7 @@ struct Index {
let abilityDelegatorArguments: any
abilityDelegatorArguments = AbilityDelegatorRegistry.getArguments()
console.info('start run testcase!!!')
Hypium.hypiumTest(abilityDelegator, abilityDelegatorArguments, testsuite)
Hypium.hypiumTest(abilityDelegator, abilityDelegatorArguments, testsuite)
}
build(){
Column(){
...
...
@@ -623,6 +624,17 @@ struct Index {
},3000)
break;
}
case "emitWebVisibility":{
this.webVisibility = Visibility.Hidden;
setTimeout(()=>{
this.webVisibility = Visibility.None;
setTimeout(()=>{
this.webVisibility = Visibility.Visible;
Utils.emitEvent(0,90)
}, 3000)
},3000)
break;
}
default:
console.info("can not match case")
}
...
...
@@ -647,6 +659,7 @@ struct Index {
console.info("TextInput click")
})
Web({src:$rawfile('index.html'),controller:this.controller})
.visibility(this.webVisibility)
.javaScriptAccess(this.javaScriptAccess)
.fileAccess(this.fileAccess)
.imageAccess(this.imageAccess)
...
...
@@ -728,10 +741,10 @@ struct Index {
if(this.cacheError){
Utils.emitEvent("cacheError",182)
this.cacheError=false
}
}
})
.onHttpErrorReceive((event) => {
this.httpErrorReceive = event.response.getResponseCode()
this.httpErrorReceive = event.response.getResponseCode()
})
.onTitleReceive((event) => {
this.titleReceive = event.title
...
...
@@ -760,7 +773,7 @@ struct Index {
}
})
.onBlur(()=>{
console.info("onBlur==>")
console.info("onBlur==>")
this.controller.requestFocus()
})
}
...
...
arkui/ace_ets_web_dev/entry/src/main/ets/test/WebJsunit.test.ets
浏览文件 @
de2841b6
...
...
@@ -44,9 +44,9 @@ export default function webJsunit() {
await Utils.sleep(2000);
done();
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_001
*tc.name userAgent
/*
*tc.number SUB_ACE_BASIC_ETS_API_001
*tc.name userAgent
*tc.desic Sets the Web's user agent
*/
it('userAgent',0,async function(done){
...
...
@@ -55,8 +55,8 @@ export default function webJsunit() {
Utils.registerEvent("",userAgent,100,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_002
/*
*tc.number SUB_ACE_BASIC_ETS_API_002
*tc.name javaScriptProxy *tc.desic Injects the JavaScript object into window and invoke the function in window
*/
it('javaScriptProxy',0,async function(done){
...
...
@@ -64,8 +64,8 @@ export default function webJsunit() {
Utils.registerEvent("javaScriptProxy","backToEts",102,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_003
/*
*tc.number SUB_ACE_BASIC_ETS_API_003
*tc.name onUrlLoadIntercept *tc.desic Triggered when the URL loading is intercepted
*/
it('onUrlLoadIntercept',0,async function(done){
...
...
@@ -73,9 +73,9 @@ export default function webJsunit() {
Utils.registerEvent("onUrlLoadIntercept","https://gitee.com/",104,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_004
*tc.name onRenderExited
/*
*tc.number SUB_ACE_BASIC_ETS_API_004
*tc.name onRenderExited
*tc.desic Triggered when the render process exits
*/
it('onRenderExited',0,async function(done){
...
...
@@ -84,9 +84,9 @@ export default function webJsunit() {
Utils.registerEvent("onRenderExited",2,106,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_005
*tc.name onResourceLoad
/*
*tc.number SUB_ACE_BASIC_ETS_API_005
*tc.name onResourceLoad
*tc.desic Triggered when the url loading
*/
it('onResourceLoad',0,async function(done){
...
...
@@ -94,9 +94,9 @@ export default function webJsunit() {
Utils.registerEvent("onResourceLoad","file:///data/storage/el1/bundle/phone/resources/rawfile/second.html",108,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_006
*tc.name loadUrl
/*
*tc.number SUB_ACE_BASIC_ETS_API_006
*tc.name loadUrl
*tc.desic Loads the given URL
*/
it('loadUrl',0,async function(done){
...
...
@@ -104,9 +104,9 @@ export default function webJsunit() {
Utils.registerContainEvent("loadUrl","代码托管和研发协作平台",110,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_007
*tc.name runJavaScript
/*
*tc.number SUB_ACE_BASIC_ETS_API_007
*tc.name runJavaScript
*tc.desic Loads a piece of code and execute JS code in the context of the currently displayed page
*/
it('runJavaScript',0,async function(done){
...
...
@@ -114,8 +114,8 @@ export default function webJsunit() {
Utils.registerEvent("runJavaScript","\"testRunJavaScript\"",112,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_008
/*
*tc.number SUB_ACE_BASIC_ETS_API_008
*tc.name onProgressChange *tc.desic Triggered when the page loading progress changes
*/
it('onProgressChange',0,async function(done){
...
...
@@ -123,8 +123,8 @@ export default function webJsunit() {
Utils.registerEvent("onProgressChange","100",114,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_009
/*
*tc.number SUB_ACE_BASIC_ETS_API_009
*tc.name onRefreshAccessedHistory *tc.desic Triggered when the Web page refreshes accessed history
*/
it('onRefreshAccessedHistory',0,async function(done){
...
...
@@ -132,9 +132,9 @@ export default function webJsunit() {
Utils.registerEvent("onRefreshAccessedHistory","file:///data/storage/el1/bundle/phone/resources/rawfile/second.html",116,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_010
*tc.name getHitTest
/*
*tc.number SUB_ACE_BASIC_ETS_API_010
*tc.name getHitTest
*tc.desic Gets the type of HitTest
*/
it('getHitTest',0,async function(done){
...
...
@@ -142,9 +142,9 @@ export default function webJsunit() {
Utils.registerEvent("getHitTest","7",118,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_011
*tc.name getWebId
/*
*tc.number SUB_ACE_BASIC_ETS_API_011
*tc.name getWebId
*tc.desic Gets the id for the current Web
*/
it('getWebId',0,async function(done){
...
...
@@ -152,9 +152,9 @@ export default function webJsunit() {
Utils.registerEvent("getWebId","webId",120,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_012
*tc.name getTitle
/*
*tc.number SUB_ACE_BASIC_ETS_API_012
*tc.name getTitle
*tc.desic Gets the title of current Web page
*/
it('getTitle',0,async function(done){
...
...
@@ -162,9 +162,9 @@ export default function webJsunit() {
Utils.registerEvent("getTitle","index",122,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_013
*tc.name getPageHeight
/*
*tc.number SUB_ACE_BASIC_ETS_API_013
*tc.name getPageHeight
*tc.desic Gets the content height of current Web page
*/
it('getPageHeight',0,async function(done){
...
...
@@ -172,9 +172,9 @@ export default function webJsunit() {
Utils.registerEventTwo("getPageHeight",124,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_014
*tc.name requestFocus
/*
*tc.number SUB_ACE_BASIC_ETS_API_014
*tc.name requestFocus
*tc.desic Gets the request focus
*/
it('requestFocus',0,async function(done){
...
...
@@ -182,9 +182,9 @@ export default function webJsunit() {
Utils.registerEvent("requestFocus","requestFocus",126,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_015
*tc.name accessBackward
/*
*tc.number SUB_ACE_BASIC_ETS_API_015
*tc.name accessBackward
*tc.desic Checks whether the web page can go back
*/
it('accessBackward',0,async function(done){
...
...
@@ -192,9 +192,9 @@ export default function webJsunit() {
Utils.registerEvent("accessBackward","true",128,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_016
*tc.name accessForward
/*
*tc.number SUB_ACE_BASIC_ETS_API_016
*tc.name accessForward
*tc.desic Checks whether the web page can go forward
*/
it('accessForward',0,async function(done){
...
...
@@ -202,9 +202,9 @@ export default function webJsunit() {
Utils.registerEvent("accessForward","false",130,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_017
*tc.name accessStep
/*
*tc.number SUB_ACE_BASIC_ETS_API_017
*tc.name accessStep
*tc.desic Checks whether the web page can go back or forward the given number of steps
*/
it('accessStep',0,async function(done){
...
...
@@ -212,9 +212,9 @@ export default function webJsunit() {
Utils.registerEvent("accessStep","true",132,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_018
*tc.name backward
/*
*tc.number SUB_ACE_BASIC_ETS_API_018
*tc.name backward
*tc.desic Goes back in the history of the web page
*/
it('backward',0,async function(done){
...
...
@@ -222,9 +222,9 @@ export default function webJsunit() {
Utils.registerEvent("backward","index",134,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_019
*tc.name forward
/*
*tc.number SUB_ACE_BASIC_ETS_API_019
*tc.name forward
*tc.desic Goes forward in the history of the web page
*/
it('forward',0,async function(done){
...
...
@@ -232,9 +232,9 @@ export default function webJsunit() {
Utils.registerEvent("forward","second",136,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_020
*tc.name backOrForward
/*
*tc.number SUB_ACE_BASIC_ETS_API_020
*tc.name backOrForward
*tc.desic Goes forward or back backOrForward in the history of the web page
*/
it('backOrForward',0,async function(done){
...
...
@@ -242,9 +242,9 @@ export default function webJsunit() {
Utils.registerEvent("backOrForward","index",138,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_021
*tc.name geolocationAccessFalse
/*
*tc.number SUB_ACE_BASIC_ETS_API_021
*tc.name geolocationAccessFalse
*tc.desic Sets false not allow access to geographical locations
*/
it('geolocationAccessFalse',0,async function(done){
...
...
@@ -252,9 +252,9 @@ export default function webJsunit() {
Utils.registerContainEvent("geolocationAccessFalse","位置服务被拒绝",96,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_022
*tc.name initialScale
/*
*tc.number SUB_ACE_BASIC_ETS_API_022
*tc.name initialScale
*tc.desic Sets the initial scale for the Web
*/
it('initialScale',0,async function(done){
...
...
@@ -262,9 +262,9 @@ export default function webJsunit() {
Utils.registerEvent("initialScale",120,97,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_023
*tc.name onScaleChange
/*
*tc.number SUB_ACE_BASIC_ETS_API_023
*tc.name onScaleChange
*tc.desic Triggered when the scale of WebView changed
*/
it('onScaleChange',0,async function(done){
...
...
@@ -272,9 +272,9 @@ export default function webJsunit() {
Utils.registerContainEvent("onScaleChange","onScaleChange",98,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_024
*tc.name onGeolocationShow
/*
*tc.number SUB_ACE_BASIC_ETS_API_024
*tc.name onGeolocationShow
*tc.desic Triggered when requesting to show the geolocation permission
*/
it('onGeolocationShow',0,async function(done){
...
...
@@ -282,9 +282,9 @@ export default function webJsunit() {
Utils.registerContainEvent("onGeolocationShow","onGeolocationShow",99,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_025
*tc.name domStorageAccessFalse
/*
*tc.number SUB_ACE_BASIC_ETS_API_025
*tc.name domStorageAccessFalse
*tc.desic Sets not to enable the DOM Storage API permission
*/
it('domStorageAccessFalse',0,async function(done){
...
...
@@ -292,9 +292,9 @@ export default function webJsunit() {
Utils.registerContainEvent("domStorageAccessFalse","sorry",144,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_026
*tc.name domStorageAccessTrue
/*
*tc.number SUB_ACE_BASIC_ETS_API_026
*tc.name domStorageAccessTrue
*tc.desic Sets enable the DOM Storage API permission
*/
it('domStorageAccessTrue',0,async function(done){
...
...
@@ -302,9 +302,9 @@ export default function webJsunit() {
Utils.registerContainEvent("domStorageAccessTrue","domapi",146,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_027
*tc.name imageAccessFalse
/*
*tc.number SUB_ACE_BASIC_ETS_API_027
*tc.name imageAccessFalse
*tc.desic Sets Web can not automatically load image resources
*/
it('imageAccessFalse',0,async function(done){
...
...
@@ -312,9 +312,9 @@ export default function webJsunit() {
Utils.registerEvent("imageAccessFalse","null",148,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_028
*tc.name imageAccessTrue
/*
*tc.number SUB_ACE_BASIC_ETS_API_028
*tc.name imageAccessTrue
*tc.desic Sets Web can automatically load image resources
*/
it('imageAccessTrue',0,async function(done){
...
...
@@ -322,9 +322,9 @@ export default function webJsunit() {
Utils.registerContainEvent("imageAccessTrue","load complete",150,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_029
*tc.name onlineImageAccessFalse
/*
*tc.number SUB_ACE_BASIC_ETS_API_029
*tc.name onlineImageAccessFalse
*tc.desic Sets not to allow image resources to be loaded from the network
*/
it('onlineImageAccessFalse',0,async function(done){
...
...
@@ -332,9 +332,9 @@ export default function webJsunit() {
Utils.registerEvent("onlineImageAccessFalse","null",156,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_030
*tc.name onlineImageAccessTrue
/*
*tc.number SUB_ACE_BASIC_ETS_API_030
*tc.name onlineImageAccessTrue
*tc.desic Sets allow image resources to be loaded from the network
*/
it('onlineImageAccessTrue',0,async function(done){
...
...
@@ -342,9 +342,9 @@ export default function webJsunit() {
Utils.registerContainEvent("onlineImageAccessTrue","load image complete",158,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_031
*tc.name databaseAccessTrue
/*
*tc.number SUB_ACE_BASIC_ETS_API_031
*tc.name databaseAccessTrue
*tc.desic Sets allow the Web access the database
*/
it('databaseAccessTrue',0,async function(done){
...
...
@@ -352,9 +352,9 @@ export default function webJsunit() {
Utils.registerContainEvent("databaseAccessTrue","openDatabase",164,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_032
*tc.name overviewModeAccessFalse
/*
*tc.number SUB_ACE_BASIC_ETS_API_032
*tc.name overviewModeAccessFalse
*tc.desic Sets not allow the Web access overview mode
*/
it('overviewModeAccessFalse',0,async function(done){
...
...
@@ -362,9 +362,9 @@ export default function webJsunit() {
Utils.registerEventTwo("overviewModeAccessFalse",168,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_033
*tc.name overviewModeAccessTrue
/*
*tc.number SUB_ACE_BASIC_ETS_API_033
*tc.name overviewModeAccessTrue
*tc.desic Sets allow the Web access overview mode
*/
it('overviewModeAccessTrue',0,async function(done){
...
...
@@ -372,9 +372,9 @@ export default function webJsunit() {
Utils.registerLargerEvent("overviewModeAccessTrue",170,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_034
*tc.name onPrompt
/*
*tc.number SUB_ACE_BASIC_ETS_API_034
*tc.name onPrompt
*tc.desic Triggered when the web page wants to display a JavaScript prompt() dialog
*/
it('onPrompt',0,async function(done){
...
...
@@ -382,9 +382,9 @@ export default function webJsunit() {
Utils.registerEvent("onPrompt","age",178,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_035
*tc.name cacheModeOnly
/*
*tc.number SUB_ACE_BASIC_ETS_API_035
*tc.name cacheModeOnly
*tc.desic load cache and not online
*/
it('cacheModeOnly',0,async function(done){
...
...
@@ -392,9 +392,9 @@ export default function webJsunit() {
Utils.registerEvent("cacheModeOnly","cacheError",182,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_036
*tc.name cacheModeDefault
/*
*tc.number SUB_ACE_BASIC_ETS_API_036
*tc.name cacheModeDefault
*tc.desic load cache when they are available and not expired, otherwise load online
*/
it('cacheModeDefault',0,async function(done){
...
...
@@ -402,9 +402,9 @@ export default function webJsunit() {
Utils.registerContainEvent("cacheModeDefault","OpenHarmony",184,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_037
*tc.name mixedModeNone
/*
*tc.number SUB_ACE_BASIC_ETS_API_037
*tc.name mixedModeNone
*tc.desic Sets Don't allow unsecure sources from a secure origin
*/
it('mixedModeNone',0,async function(done){
...
...
@@ -412,9 +412,9 @@ export default function webJsunit() {
Utils.registerContainEvent("mixedModeNone","insecure",186,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_038
*tc.name mixedModeAll
/*
*tc.number SUB_ACE_BASIC_ETS_API_038
*tc.name mixedModeAll
*tc.desic Sets Allows all HTTP and HTTPS content can be loaded
*/
it('mixedModeAll',0,async function(done){
...
...
@@ -422,9 +422,9 @@ export default function webJsunit() {
Utils.registerEvent("mixedModeAll",3,188,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_039
*tc.name fileAccessTrue
/*
*tc.number SUB_ACE_BASIC_ETS_API_039
*tc.name fileAccessTrue
*tc.desic Sets enable local file system access in Web
*/
it('fileAccessTrue',0,async function(done){
...
...
@@ -432,9 +432,9 @@ export default function webJsunit() {
Utils.registerContainEvent("fileAccessTrue","index",190,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_040
*tc.name onPageBegin
/*
*tc.number SUB_ACE_BASIC_ETS_API_040
*tc.name onPageBegin
*tc.desic Triggered when the page loading progress changes
*/
it('onPageBegin',0,async function(done){
...
...
@@ -442,9 +442,9 @@ export default function webJsunit() {
Utils.registerEvent("onPageBegin","file:///data/storage/el1/bundle/phone/resources/rawfile/index.html",59,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_041
*tc.name onPageEnd
/*
*tc.number SUB_ACE_BASIC_ETS_API_041
*tc.name onPageEnd
*tc.desic Triggered at the begin of web page loading
*/
it('onPageEnd',0,async function(done){
...
...
@@ -452,9 +452,9 @@ export default function webJsunit() {
Utils.registerEvent("onPageEnd","file:///data/storage/el1/bundle/phone/resources/rawfile/index.html",60,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_042
*tc.name onConsole
/*
*tc.number SUB_ACE_BASIC_ETS_API_042
*tc.name onConsole
*tc.desic Triggered when the web page receives a JavaScript console message
*/
it('onConsole',0,async function(done){
...
...
@@ -462,9 +462,9 @@ export default function webJsunit() {
Utils.registerEvent("onConsole","console test",62,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_043
*tc.name onAlert
/*
*tc.number SUB_ACE_BASIC_ETS_API_043
*tc.name onAlert
*tc.desic Triggered when the Web wants to display a JavaScript alert() dialog
*/
it('onAlert',0,async function(done){
...
...
@@ -472,9 +472,9 @@ export default function webJsunit() {
Utils.registerEvent("onAlert","alert test",63,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_044
*tc.name onConfirm
/*
*tc.number SUB_ACE_BASIC_ETS_API_044
*tc.name onConfirm
*tc.desic Triggered when the web page wants to display a JavaScript confirm() dialog
*/
it('onConfirm',0,async function(done){
...
...
@@ -482,9 +482,9 @@ export default function webJsunit() {
Utils.registerEvent("onConfirm","confirm test",64,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_045
*tc.name onErrorReceive
/*
*tc.number SUB_ACE_BASIC_ETS_API_045
*tc.name onErrorReceive
*tc.desic Triggered when the web page receives a web resource loading error
*/
it('onErrorReceive',0,async function(done){
...
...
@@ -492,9 +492,9 @@ export default function webJsunit() {
Utils.registerEvent("onErrorReceive","http://192.168.5.40:9006/sso_web/html/H5/doctor/aboutUs.html",65,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_046
*tc.name onHttpErrorReceive
/*
*tc.number SUB_ACE_BASIC_ETS_API_046
*tc.name onHttpErrorReceive
*tc.desic Triggered when the web page receives a web resource loading HTTP error
*/
it('onHttpErrorReceive',0,async function(done){
...
...
@@ -502,9 +502,9 @@ export default function webJsunit() {
Utils.registerEvent("onHttpErrorReceive",404,66,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_047
*tc.name onTitleReceive
/*
*tc.number SUB_ACE_BASIC_ETS_API_047
*tc.name onTitleReceive
*tc.desic Triggered when the title of the main application document changes
*/
it('onTitleReceive',0,async function(done){
...
...
@@ -512,9 +512,9 @@ export default function webJsunit() {
Utils.registerEvent("onTitleReceive","index",67,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_048
*tc.name onDownloadStart
/*
*tc.number SUB_ACE_BASIC_ETS_API_048
*tc.name onDownloadStart
*tc.desic Triggered when starting to download
*/
it('onDownloadStart',0,async function(done){
...
...
@@ -522,9 +522,9 @@ export default function webJsunit() {
Utils.registerEvent("onDownloadStart","https://consumer.huawei.com/content/dam/huawei-cbg-site/cn/mkt/mobileservices/2022/download/PC107f1b3947c942ffaa14334a879065d8.2107261020.exe",68,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_049
*tc.name setCookie
/*
*tc.number SUB_ACE_BASIC_ETS_API_049
*tc.name setCookie
*tc.desic Sets the cookie
*/
it('setCookie',0,async function(done){
...
...
@@ -532,9 +532,9 @@ export default function webJsunit() {
Utils.registerEvent("setCookie","e=f",76,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_050
*tc.name getCookie
/*
*tc.number SUB_ACE_BASIC_ETS_API_050
*tc.name getCookie
*tc.desic Gets all cookies for the given URL
*/
it('getCookie',0,async function(done){
...
...
@@ -542,9 +542,9 @@ export default function webJsunit() {
Utils.registerEvent("getCookie","e=f",69,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_051
*tc.name zoom
/*
*tc.number SUB_ACE_BASIC_ETS_API_051
*tc.name zoom
*tc.desic Let the Web zoom by
*/
it('zoom',0,async function(done){
...
...
@@ -552,9 +552,9 @@ export default function webJsunit() {
Utils.registerEvent("zoom",true,77,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_052
*tc.name zoomOut
/*
*tc.number SUB_ACE_BASIC_ETS_API_052
*tc.name zoomOut
*tc.desic Let the Web zoom out
*/
it('zoomOut',0,async function(done){
...
...
@@ -562,9 +562,9 @@ export default function webJsunit() {
Utils.registerEvent("zoomOut",true,78,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_053
*tc.name zoomIn
/*
*tc.number SUB_ACE_BASIC_ETS_API_053
*tc.name zoomIn
*tc.desic Let the Web zoom in
*/
it('zoomIn',0,async function(done){
...
...
@@ -572,9 +572,9 @@ export default function webJsunit() {
Utils.registerEvent("zoomIn",false,79,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_054
*tc.name deleteEntireCookie
/*
*tc.number SUB_ACE_BASIC_ETS_API_054
*tc.name deleteEntireCookie
*tc.desic Delete all cookies
*/
it('deleteEntireCookie',0,async function(done){
...
...
@@ -582,9 +582,9 @@ export default function webJsunit() {
Utils.registerEvent("deleteEntireCookie","",80,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_055
*tc.name saveCookieSync
/*
*tc.number SUB_ACE_BASIC_ETS_API_055
*tc.name saveCookieSync
*tc.desic Saves the cookies
*/
it('saveCookieSync',0,async function(done){
...
...
@@ -592,9 +592,9 @@ export default function webJsunit() {
Utils.registerEvent("saveCookieSync",true,81,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_056
*tc.name clearHistory
/*
*tc.number SUB_ACE_BASIC_ETS_API_056
*tc.name clearHistory
*tc.desic Clears the history in the Web
*/
it('clearHistory',0,async function(done){
...
...
@@ -602,9 +602,9 @@ export default function webJsunit() {
Utils.registerEvent("clearHistory",false,82,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_057
*tc.name stop
/*
*tc.number SUB_ACE_BASIC_ETS_API_057
*tc.name stop
*tc.desic Stops the current load
*/
it('stop',0,async function(done){
...
...
@@ -612,9 +612,9 @@ export default function webJsunit() {
Utils.registerEvent("stop",true,83,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_058
*tc.name onInactive
/*
*tc.number SUB_ACE_BASIC_ETS_API_058
*tc.name onInactive
*tc.desic Let the Web inactive.
*/
it('onInactive',0,async function(done){
...
...
@@ -622,9 +622,9 @@ export default function webJsunit() {
Utils.registerEvent("onInactive",true,84,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_059
*tc.name onActive
/*
*tc.number SUB_ACE_BASIC_ETS_API_059
*tc.name onActive
*tc.desic Let the Web active
*/
it('onActive',0,async function(done){
...
...
@@ -632,9 +632,9 @@ export default function webJsunit() {
Utils.registerEvent("onActive","file:///data/storage/el1/bundle/phone/resources/rawfile/index.html",85,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_060
*tc.name registerJavaScriptProxy
/*
*tc.number SUB_ACE_BASIC_ETS_API_060
*tc.name registerJavaScriptProxy
*tc.desic Registers the JavaScript object and method list
*/
it('registerJavaScriptProxy',0,async function(done){
...
...
@@ -642,9 +642,9 @@ export default function webJsunit() {
Utils.registerEvent("registerJavaScriptProxy","backToEts",86,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_061
*tc.name deleteJavaScriptRegister
/*
*tc.number SUB_ACE_BASIC_ETS_API_061
*tc.name deleteJavaScriptRegister
*tc.desic Deletes a registered JavaScript object with given name
*/
it('deleteJavaScriptRegister',0,async function(done){
...
...
@@ -652,9 +652,9 @@ export default function webJsunit() {
Utils.registerEvent("deleteJavaScriptRegister",true,87,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_062
*tc.name javaScriptAccess
/*
*tc.number SUB_ACE_BASIC_ETS_API_062
*tc.name javaScriptAccess
*tc.desic Sets whether the Web allows JavaScript scripts to execute
*/
it('javaScriptAccess',0,async function(done){
...
...
@@ -662,15 +662,26 @@ export default function webJsunit() {
Utils.registerEvent("javaScriptAccess",true,88,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_063
*tc.name getCookieManager
/*
*tc.number SUB_ACE_BASIC_ETS_API_063
*tc.name getCookieManager
*tc.desic Gets network cookie manager
*/
it('getCookieManager',0,async function(done){
emitKey="emit
GetCookieManager
";
emitKey="emit
WebVisibility
";
Utils.registerEvent("getCookieManager","a=b",89,done);
sendEventByKey('webcomponent',10,'');
})
/*
*tc.number SUB_ACE_BASIC_ETS_API_064
*tc.name webVisibility
*tc.desic Web Visibility test
*/
it('webVisibility',0,async function(done){
emitKey="emitWebVisibility";
Utils.registerEvent("webVisibility", 0, 90, done);
sendEventByKey('webcomponent',10,'');
})
})
}
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录