未验证 提交 7e872810 编写于 作者: O openharmony_ci 提交者: Gitee

!2620 【communication】update 3516 testcase

Merge pull request !2620 from 权力/myfeature1
# Copyright (C) 2021 Huawei Device Co., Ltd.
# Copyright (C) 2022 Huawei Device Co., Ltd.
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
......@@ -15,8 +15,17 @@ import("//build/ohos_var.gni")
group("communication") {
testonly = true
if (is_standard_system) {
deps = [ "wifi_standard:wifi_standard_test" ]
deps = [
# "bluetooth_ble:ActsBluetoothBleJsTest",
# "bluetooth_on:ActsBluetoothOnJsTest",
# "bluetooth_standard:ActsBluetoothJsTest",
# "dsoftbus/rpc:ActsRpcJsTest",
"wifi_hotspot:ActsHotSpotJSTest",
"wifi_p2p:ActsP2PJSTest",
"wifi_standard:ActsWifiJSTest",
]
} else {
deps = [ "wifi_standard:wifi_standard_test" ]
deps = [ "wifi_standard:ActsWifiJSTest" ]
}
}
# Copyright (C) 2022 Huawei Device Co., Ltd.
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
import("//test/xts/tools/build/suite.gni")
ohos_js_hap_suite("ActsHotSpotJSTest") {
hap_profile = "./src/main/config.json"
deps = [
":wifi_js_assets",
":wifi_resources",
]
certificate_profile = "./signature/openharmony_sx.p7b"
hap_name = "ActsHotSpotJSApiTest"
}
ohos_js_assets("wifi_js_assets") {
source_dir = "./src/main/js/default"
}
ohos_resources("wifi_resources") {
sources = [ "./src/main/resources" ]
hap_profile = "./src/main/config.json"
}
{
"description": "Configuration for wifi js api Tests",
"driver": {
"type": "JSUnitTest",
"test-timeout": "600000",
"package": "ohos.acts.communication.wifi.wifidevice",
"shell-timeout": "600000"
},
"kits": [
{
"test-file-name": [
"ActsHotSpotJSApiTest.hap"
],
"type": "AppInstallKit",
"cleanup-apps": true
}
]
}
{
"app": {
"bundleName": "ohos.acts.communication.wifi.wifidevice",
"vendor": "acts",
"version": {
"code": 1000000,
"name": "1.0.0"
},
"apiVersion": {
"compatible": 4,
"target": 5
}
},
"deviceConfig": {},
"module": {
"package": "ohos.acts.communication.wifi.wifidevice",
"name": ".MyApplication",
"mainAbility": "ohos.acts.communication.wifi.wifidevice.MainAbility",
"deviceType": [
"phone"
],
"distro": {
"deliveryWithInstall": true,
"moduleName": "wifi_standard",
"moduleType": "entry"
},
"abilities": [
{
"visible": true,
"skills": [
{
"entities": [
"entity.system.home"
],
"actions": [
"action.system.home"
]
}
],
"name": "ohos.acts.communication.wifi.wifidevice.MainAbility",
"icon": "$media:icon",
"description": "$string:mainability_description",
"label": "$string:app_name",
"type": "page",
"launchType": "standard"
}
],
"js": [
{
"pages": [
"pages/index/index"
],
"name": "default",
"window": {
"designWidth": 720,
"autoDesignWidth": false
}
}
],
"reqPermissions": [
{
"name" : "ohos.permission.GET_WIFI_INFO",
"reason" : "use ohos.permission.GET_WIFI_INFO"
},
{
"name" : "ohos.permission.SET_WIFI_INFO",
"reason" : "use ohos.permission.SET_WIFI_INFO"
},
{
"name" : "ohos.permission.MANAGE_WIFI_CONNECTION",
"reason" : "use ohos.permission.MANAGE_WIFI_CONNECTION"
},
{
"name" : "ohos.permission.SET_WIFI_CONFIG",
"reason" : "use ohos.permission.SET_WIFI_CONFIG"
},
{
"name" : "ohos.permission.GET_WIFI_CONFIG",
"reason" : "use ohos.permission.GET_WIFI_CONFIG"
},
{
"name" : "ohos.permission.GET_BUNDLE_INFO_PRIVILEGED",
"reason" : "use ohos.permission.GET_BUNDLE_INFO_PRIVILEGED"
},
{
"name" : "ohos.permission.GET_WIFI_LOCAL_MAC",
"reason" : "use ohos.permission.GET_WIFI_LOCAL_MAC"
},
{
"name" : "ohos.permission.MANAGE_WIFI_HOTSPOT",
"reason" : "use ohos.permission.MANAGE_WIFI_HOTSPOT"
},
{
"name" : "ohos.permission.GET_WIFI_INFO_INTERNAL",
"reason" : "use ohos.permission.GET_WIFI_INFO_INTERNAL"
}
]
}
}
/*
* Copyright (C) 2022 Huawei Device Co., Ltd.
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
export default {
onCreate() {
console.info('AceApplication onCreate');
},
onDestroy() {
console.info('AceApplication onDestroy');
}
};
{
"strings": {
"hello": "Hello",
"world": "World"
}
}
\ No newline at end of file
{
"strings": {
"hello": "您好",
"world": "世界"
}
}
\ No newline at end of file
/*
* Copyright (C) 2022 Huawei Device Co., Ltd.
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
.container {
flex-direction: column;
justify-content: center;
align-items: center;
}
.title {
font-size: 100px;
}
/*
* Copyright (C) 2022 Huawei Device Co., Ltd.
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
<div class="container">
<text class="title">
{{ $t('strings.hello') }} {{ title }}
</text>
</div>
/*
* Copyright (C) 2022 Huawei Device Co., Ltd.
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
import {Core, ExpectExtend} from 'deccjsunit/index'
export default {
data: {
title: '',
myTimeout: 15000
},
onInit() {
this.title = this.$t('strings.world');
},
onShow() {
console.info('onShow finish')
},
onReady() {
console.info('onReady finish')
const core = Core.getInstance()
const expectExtend = new ExpectExtend({
'id': 'extend'
})
core.addService('expect', expectExtend)
core.init()
const configService = core.getDefaultService('config')
this.timeout = this.myTimeout
configService.setConfig(this)
require('../../test/List.test')
core.execute()
},
}
/*
* Copyright (C) 2022 Huawei Device Co., Ltd.
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
require('./WifiSoftAP.test.js')
{
"string": [
{
"name": "app_name",
"value": "OsAccountTest"
},
{
"name": "mainability_description",
"value": "JS_Phone_Empty Feature Ability"
}
]
}
\ No newline at end of file
# Copyright (C) 2022 Huawei Device Co., Ltd.
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
import("//test/xts/tools/build/suite.gni")
ohos_js_hap_suite("ActsP2PJSTest") {
hap_profile = "./src/main/config.json"
deps = [
":wifi_js_assets",
":wifi_resources",
]
certificate_profile = "./signature/openharmony_sx.p7b"
hap_name = "ActsP2PJSApiTest"
}
ohos_js_assets("wifi_js_assets") {
source_dir = "./src/main/js/default"
}
ohos_resources("wifi_resources") {
sources = [ "./src/main/resources" ]
hap_profile = "./src/main/config.json"
}
{
"description": "Configuration for wifi js api Tests",
"driver": {
"type": "JSUnitTest",
"test-timeout": "600000",
"package": "ohos.acts.communication.wifi.wifidevice",
"shell-timeout": "600000"
},
"kits": [
{
"test-file-name": [
"ActsP2PJSApiTest.hap"
],
"type": "AppInstallKit",
"cleanup-apps": true
}
]
}
{
"app": {
"bundleName": "ohos.acts.communication.wifi.wifidevice",
"vendor": "acts",
"version": {
"code": 1000000,
"name": "1.0.0"
},
"apiVersion": {
"compatible": 4,
"target": 5
}
},
"deviceConfig": {},
"module": {
"package": "ohos.acts.communication.wifi.wifidevice",
"name": ".MyApplication",
"mainAbility": "ohos.acts.communication.wifi.wifidevice.MainAbility",
"deviceType": [
"phone"
],
"distro": {
"deliveryWithInstall": true,
"moduleName": "wifi_standard",
"moduleType": "entry"
},
"abilities": [
{
"visible": true,
"skills": [
{
"entities": [
"entity.system.home"
],
"actions": [
"action.system.home"
]
}
],
"name": "ohos.acts.communication.wifi.wifidevice.MainAbility",
"icon": "$media:icon",
"description": "$string:mainability_description",
"label": "$string:app_name",
"type": "page",
"launchType": "standard"
}
],
"js": [
{
"pages": [
"pages/index/index"
],
"name": "default",
"window": {
"designWidth": 720,
"autoDesignWidth": false
}
}
],
"reqPermissions": [
{
"name" : "ohos.permission.GET_WIFI_INFO",
"reason" : "use ohos.permission.GET_WIFI_INFO"
},
{
"name" : "ohos.permission.SET_WIFI_INFO",
"reason" : "use ohos.permission.SET_WIFI_INFO"
},
{
"name" : "ohos.permission.MANAGE_WIFI_CONNECTION",
"reason" : "use ohos.permission.MANAGE_WIFI_CONNECTION"
},
{
"name" : "ohos.permission.SET_WIFI_CONFIG",
"reason" : "use ohos.permission.SET_WIFI_CONFIG"
},
{
"name" : "ohos.permission.GET_WIFI_CONFIG",
"reason" : "use ohos.permission.GET_WIFI_CONFIG"
},
{
"name" : "ohos.permission.GET_BUNDLE_INFO_PRIVILEGED",
"reason" : "use ohos.permission.GET_BUNDLE_INFO_PRIVILEGED"
},
{
"name" : "ohos.permission.GET_WIFI_LOCAL_MAC",
"reason" : "use ohos.permission.GET_WIFI_LOCAL_MAC"
},
{
"name" : "ohos.permission.MANAGE_WIFI_HOTSPOT",
"reason" : "use ohos.permission.MANAGE_WIFI_HOTSPOT"
},
{
"name" : "ohos.permission.GET_WIFI_INFO_INTERNAL",
"reason" : "use ohos.permission.GET_WIFI_INFO_INTERNAL"
}
]
}
}
/*
* Copyright (C) 2022 Huawei Device Co., Ltd.
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
export default {
onCreate() {
console.info('AceApplication onCreate');
},
onDestroy() {
console.info('AceApplication onDestroy');
}
};
{
"strings": {
"hello": "Hello",
"world": "World"
}
}
\ No newline at end of file
{
"strings": {
"hello": "您好",
"world": "世界"
}
}
\ No newline at end of file
/*
* Copyright (C) 2022 Huawei Device Co., Ltd.
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
.container {
flex-direction: column;
justify-content: center;
align-items: center;
}
.title {
font-size: 100px;
}
/*
* Copyright (C) 2022 Huawei Device Co., Ltd.
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
<div class="container">
<text class="title">
{{ $t('strings.hello') }} {{ title }}
</text>
</div>
/*
* Copyright (C) 2022 Huawei Device Co., Ltd.
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
import {Core, ExpectExtend} from 'deccjsunit/index'
export default {
data: {
title: '',
myTimeout: 15000
},
onInit() {
this.title = this.$t('strings.world');
},
onShow() {
console.info('onShow finish')
},
onReady() {
console.info('onReady finish')
const core = Core.getInstance()
const expectExtend = new ExpectExtend({
'id': 'extend'
})
core.addService('expect', expectExtend)
core.init()
const configService = core.getDefaultService('config')
this.timeout = this.myTimeout
configService.setConfig(this)
require('../../test/List.test')
core.execute()
},
}
/*
* Copyright (C) 2022 Huawei Device Co., Ltd.
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
//require('./WifiSta.test.js')
//require('./WifiSoftAP.test.js')
require('./WifiP2P.test.js')
{
"string": [
{
"name": "app_name",
"value": "OsAccountTest"
},
{
"name": "mainability_description",
"value": "JS_Phone_Empty Feature Ability"
}
]
}
\ No newline at end of file
# Copyright (C) 2021 Huawei Device Co., Ltd.
# Copyright (C) 2022 Huawei Device Co., Ltd.
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
......@@ -13,7 +13,7 @@
import("//test/xts/tools/build/suite.gni")
ohos_js_hap_suite("wifi_standard_test") {
ohos_js_hap_suite("ActsWifiJSTest") {
hap_profile = "./src/main/config.json"
deps = [
":wifi_js_assets",
......
......@@ -15,12 +15,13 @@
"module": {
"package": "ohos.acts.communication.wifi.wifidevice",
"name": ".MyApplication",
"mainAbility": "ohos.acts.communication.wifi.wifidevice.MainAbility",
"deviceType": [
"phone"
],
"distro": {
"deliveryWithInstall": true,
"moduleName": "entry",
"moduleName": "wifi_standard",
"moduleType": "entry"
},
"abilities": [
......@@ -55,6 +56,44 @@
"autoDesignWidth": false
}
}
],
"reqPermissions": [
{
"name" : "ohos.permission.GET_WIFI_INFO",
"reason" : "use ohos.permission.GET_WIFI_INFO"
},
{
"name" : "ohos.permission.SET_WIFI_INFO",
"reason" : "use ohos.permission.SET_WIFI_INFO"
},
{
"name" : "ohos.permission.MANAGE_WIFI_CONNECTION",
"reason" : "use ohos.permission.MANAGE_WIFI_CONNECTION"
},
{
"name" : "ohos.permission.SET_WIFI_CONFIG",
"reason" : "use ohos.permission.SET_WIFI_CONFIG"
},
{
"name" : "ohos.permission.GET_WIFI_CONFIG",
"reason" : "use ohos.permission.GET_WIFI_CONFIG"
},
{
"name" : "ohos.permission.GET_BUNDLE_INFO_PRIVILEGED",
"reason" : "use ohos.permission.GET_BUNDLE_INFO_PRIVILEGED"
},
{
"name" : "ohos.permission.GET_WIFI_LOCAL_MAC",
"reason" : "use ohos.permission.GET_WIFI_LOCAL_MAC"
},
{
"name" : "ohos.permission.MANAGE_WIFI_HOTSPOT",
"reason" : "use ohos.permission.MANAGE_WIFI_HOTSPOT"
},
{
"name" : "ohos.permission.GET_WIFI_INFO_INTERNAL",
"reason" : "use ohos.permission.GET_WIFI_INFO_INTERNAL"
}
]
}
}
/*
* Copyright (C) 2021 Huawei Device Co., Ltd.
* Copyright (C) 2022 Huawei Device Co., Ltd.
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
......
/*
* Copyright (C) 2022 Huawei Device Co., Ltd.
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
.container {
flex-direction: column;
justify-content: center;
......
/*
* Copyright (C) 2022 Huawei Device Co., Ltd.
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
<div class="container">
<text class="title">
{{ $t('strings.hello') }} {{ title }}
......
/*
* Copyright (C) 2021 Huawei Device Co., Ltd.
* Copyright (C) 2022 Huawei Device Co., Ltd.
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
......@@ -13,36 +13,35 @@
* limitations under the License.
*/
import app from '@system.app'
import {Core, ExpectExtend} from 'deccjsunit/index'
export default {
data: {
title: ""
title: '',
myTimeout: 15000
},
onInit() {
this.title = this.$t('strings.world');
},
onShow() {
console.info('onShow finish')
},
onReady() {
console.info('onReady finish')
const core = Core.getInstance()
const expectExtend = new ExpectExtend({
'id': 'extend'
})
core.addService('expect', expectExtend)
// core.addService('report', instrumentLog)
core.init()
const configService = core.getDefaultService('config')
this.timeout = 600000
this.timeout = this.myTimeout
configService.setConfig(this)
require('../../test/List.test')
core.execute()
},
onReady() {
},
}
/*
* Copyright (C) 2021 Huawei Device Co., Ltd.
* Copyright (C) 2022 Huawei Device Co., Ltd.
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
......@@ -12,5 +12,8 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
require('./WifiSta.test.js')
//require('./WifiSoftAP.test.js')
//require('./WifiP2P.test.js')
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册