Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
OpenHarmony
Xts Acts
提交
22308402
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看板
提交
22308402
编写于
9月 27, 2022
作者:
A
anning
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
applications
Signed-off-by:
N
anning
<
anning7@huawei.com
>
上级
ae45f8c7
变更
16
隐藏空白更改
内联
并排
Showing
16 changed file
with
1574 addition
and
1556 deletion
+1574
-1556
applications/BUILD.gn
applications/BUILD.gn
+17
-0
applications/settingsdata/BUILD.gn
applications/settingsdata/BUILD.gn
+0
-0
applications/settingsdata/settings_ets/BUILD.gn
applications/settingsdata/settings_ets/BUILD.gn
+1
-1
applications/settingsdata/settings_ets/Test.json
applications/settingsdata/settings_ets/Test.json
+19
-19
applications/settingsdata/settings_ets/entry/src/main/config.json
...ions/settingsdata/settings_ets/entry/src/main/config.json
+99
-99
applications/settingsdata/settings_ets/entry/src/main/ets/MainAbility/app.ets
...sdata/settings_ets/entry/src/main/ets/MainAbility/app.ets
+21
-21
applications/settingsdata/settings_ets/entry/src/main/ets/MainAbility/pages/index.ets
...ttings_ets/entry/src/main/ets/MainAbility/pages/index.ets
+37
-37
applications/settingsdata/settings_ets/entry/src/main/ets/TestAbility/app.ets
...sdata/settings_ets/entry/src/main/ets/TestAbility/app.ets
+31
-31
applications/settingsdata/settings_ets/entry/src/main/ets/TestAbility/pages/index.ets
...ttings_ets/entry/src/main/ets/TestAbility/pages/index.ets
+48
-48
applications/settingsdata/settings_ets/entry/src/main/ets/TestRunner/OpenHarmonyTestRunner.ts
...ts/entry/src/main/ets/TestRunner/OpenHarmonyTestRunner.ts
+76
-76
applications/settingsdata/settings_ets/entry/src/main/ets/test/List.test.ets
...gsdata/settings_ets/entry/src/main/ets/test/List.test.ets
+18
-18
applications/settingsdata/settings_ets/entry/src/main/ets/test/SettingUiJsunit.test.ets
...ings_ets/entry/src/main/ets/test/SettingUiJsunit.test.ets
+1187
-1187
applications/settingsdata/settings_ets/entry/src/main/resources/base/element/string.json
...ngs_ets/entry/src/main/resources/base/element/string.json
+19
-19
applications/settingsdata/settings_ets/entry/src/main/resources/base/media/icon.png
...settings_ets/entry/src/main/resources/base/media/icon.png
+0
-0
applications/settingsdata/settings_ets/signature/openharmony_sx.p7b
...ns/settingsdata/settings_ets/signature/openharmony_sx.p7b
+0
-0
test_packages.gni
test_packages.gni
+1
-0
未找到文件。
applications/BUILD.gn
0 → 100644
浏览文件 @
22308402
# Copyright (C) 2021 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.
group("applications") {
testonly = true
deps = [ "settingsdata:settingsdata" ]
}
settingsdata/BUILD.gn
→
applications/
settingsdata/BUILD.gn
100755 → 100644
浏览文件 @
22308402
文件已移动
settingsdata/settings_ets/BUILD.gn
→
applications/
settingsdata/settings_ets/BUILD.gn
浏览文件 @
22308402
...
@@ -9,7 +9,7 @@
...
@@ -9,7 +9,7 @@
# distributed under the License is distributed on an "AS IS" BASIS,
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# See the License for the specific language governing permissions and
# limitations under the License.
# limitations under the License.
import("//test/xts/tools/build/suite.gni")
import("//test/xts/tools/build/suite.gni")
...
...
settingsdata/settings_ets/Test.json
→
applications/
settingsdata/settings_ets/Test.json
浏览文件 @
22308402
{
{
"description"
:
"Configuration for settings Tests"
,
"description"
:
"Configuration for settings Tests"
,
"driver"
:
{
"driver"
:
{
"type"
:
"OHJSUnitTest"
,
"type"
:
"OHJSUnitTest"
,
"test-timeout"
:
"600000"
,
"test-timeout"
:
"600000"
,
"bundle-name"
:
"com.open.harmony.settings"
,
"bundle-name"
:
"com.open.harmony.settings"
,
"package-name"
:
"com.open.harmony.settings"
,
"package-name"
:
"com.open.harmony.settings"
,
"shell-timeout"
:
"600000"
"shell-timeout"
:
"600000"
},
},
"kits"
:
[
"kits"
:
[
{
{
"test-file-name"
:
[
"test-file-name"
:
[
"ActsSettingsEtsTest.hap"
"ActsSettingsEtsTest.hap"
],
],
"type"
:
"AppInstallKit"
,
"type"
:
"AppInstallKit"
,
"cleanup-apps"
:
true
"cleanup-apps"
:
true
}
}
]
]
}
}
settingsdata/settings_ets/entry/src/main/config.json
→
applications/
settingsdata/settings_ets/entry/src/main/config.json
浏览文件 @
22308402
{
{
"app"
:
{
"app"
:
{
"bundleName"
:
"com.open.harmony.settings"
,
"bundleName"
:
"com.open.harmony.settings"
,
"vendor"
:
"open"
,
"vendor"
:
"open"
,
"version"
:
{
"version"
:
{
"code"
:
1000000
,
"code"
:
1000000
,
"name"
:
"1.0.0"
"name"
:
"1.0.0"
},
},
"apiVersion"
:
{
"apiVersion"
:
{
"compatible"
:
7
,
"compatible"
:
7
,
"releaseType"
:
"Release"
,
"releaseType"
:
"Release"
,
"target"
:
7
"target"
:
7
}
}
},
},
"deviceConfig"
:
{},
"deviceConfig"
:
{},
"module"
:
{
"module"
:
{
"package"
:
"com.open.harmony.settings"
,
"package"
:
"com.open.harmony.settings"
,
"name"
:
".MyApplication"
,
"name"
:
".MyApplication"
,
"mainAbility"
:
"com.open.harmony.settings.MainAbility"
,
"mainAbility"
:
"com.open.harmony.settings.MainAbility"
,
"srcPath"
:
""
,
"srcPath"
:
""
,
"deviceType"
:
[
"deviceType"
:
[
"phone"
"phone"
],
],
"distro"
:
{
"distro"
:
{
"deliveryWithInstall"
:
true
,
"deliveryWithInstall"
:
true
,
"moduleName"
:
"entry"
,
"moduleName"
:
"entry"
,
"moduleType"
:
"entry"
,
"moduleType"
:
"entry"
,
"installationFree"
:
false
"installationFree"
:
false
},
},
"abilities"
:
[
"abilities"
:
[
{
{
"skills"
:
[
"skills"
:
[
{
{
"entities"
:
[
"entities"
:
[
"entity.system.home"
"entity.system.home"
],
],
"actions"
:
[
"actions"
:
[
"action.system.home"
"action.system.home"
]
]
}
}
],
],
"orientation"
:
"unspecified"
,
"orientation"
:
"unspecified"
,
"visible"
:
true
,
"visible"
:
true
,
"srcPath"
:
"MainAbility"
,
"srcPath"
:
"MainAbility"
,
"name"
:
".MainAbility"
,
"name"
:
".MainAbility"
,
"srcLanguage"
:
"ets"
,
"srcLanguage"
:
"ets"
,
"icon"
:
"$media:icon"
,
"icon"
:
"$media:icon"
,
"description"
:
"$string:description_mainability"
,
"description"
:
"$string:description_mainability"
,
"formsEnabled"
:
false
,
"formsEnabled"
:
false
,
"label"
:
"$string:entry_MainAbility"
,
"label"
:
"$string:entry_MainAbility"
,
"type"
:
"page"
,
"type"
:
"page"
,
"launchType"
:
"standard"
"launchType"
:
"standard"
},
},
{
{
"orientation"
:
"unspecified"
,
"orientation"
:
"unspecified"
,
"visible"
:
true
,
"visible"
:
true
,
"srcPath"
:
"TestAbility"
,
"srcPath"
:
"TestAbility"
,
"name"
:
".TestAbility"
,
"name"
:
".TestAbility"
,
"srcLanguage"
:
"ets"
,
"srcLanguage"
:
"ets"
,
"icon"
:
"$media:icon"
,
"icon"
:
"$media:icon"
,
"description"
:
"$string:TestAbility_desc"
,
"description"
:
"$string:TestAbility_desc"
,
"formsEnabled"
:
false
,
"formsEnabled"
:
false
,
"label"
:
"$string:TestAbility_label"
,
"label"
:
"$string:TestAbility_label"
,
"type"
:
"page"
,
"type"
:
"page"
,
"launchType"
:
"standard"
"launchType"
:
"standard"
}
}
],
],
"js"
:
[
"js"
:
[
{
{
"mode"
:
{
"mode"
:
{
"syntax"
:
"ets"
,
"syntax"
:
"ets"
,
"type"
:
"pageAbility"
"type"
:
"pageAbility"
},
},
"pages"
:
[
"pages"
:
[
"pages/index"
"pages/index"
],
],
"name"
:
".MainAbility"
,
"name"
:
".MainAbility"
,
"window"
:
{
"window"
:
{
"designWidth"
:
720
,
"designWidth"
:
720
,
"autoDesignWidth"
:
false
"autoDesignWidth"
:
false
}
}
},
},
{
{
"mode"
:
{
"mode"
:
{
"syntax"
:
"ets"
,
"syntax"
:
"ets"
,
"type"
:
"pageAbility"
"type"
:
"pageAbility"
},
},
"pages"
:
[
"pages"
:
[
"pages/index"
"pages/index"
],
],
"name"
:
".TestAbility"
,
"name"
:
".TestAbility"
,
"window"
:
{
"window"
:
{
"designWidth"
:
720
,
"designWidth"
:
720
,
"autoDesignWidth"
:
false
"autoDesignWidth"
:
false
}
}
}
}
]
]
}
}
}
}
settingsdata/settings_ets/entry/src/main/ets/MainAbility/app.ets
→
applications/
settingsdata/settings_ets/entry/src/main/ets/MainAbility/app.ets
浏览文件 @
22308402
/**
/**
* Copyright (c) 2021 Huawei Device Co., Ltd.
* Copyright (c) 2021 Huawei Device Co., Ltd.
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
* You may obtain a copy of the License at
*
*
* http://www.apache.org/licenses/LICENSE-2.0
* http://www.apache.org/licenses/LICENSE-2.0
*
*
* Unless required by applicable law or agreed to in writing, software
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* See the License for the specific language governing permissions and
* limitations under the License.
* limitations under the License.
*/
*/
export default {
export default {
onCreate() {
onCreate() {
console.info('Application onCreate')
console.info('Application onCreate')
},
},
onDestroy() {
onDestroy() {
console.info('Application onDestroy')
console.info('Application onDestroy')
},
},
}
}
\ No newline at end of file
settingsdata/settings_ets/entry/src/main/ets/MainAbility/pages/index.ets
→
applications/
settingsdata/settings_ets/entry/src/main/ets/MainAbility/pages/index.ets
浏览文件 @
22308402
// @ts-nocheck
// @ts-nocheck
/**
/**
* Copyright (c) 2021 Huawei Device Co., Ltd.
* Copyright (c) 2021 Huawei Device Co., Ltd.
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
* You may obtain a copy of the License at
*
*
* http://www.apache.org/licenses/LICENSE-2.0
* http://www.apache.org/licenses/LICENSE-2.0
*
*
* Unless required by applicable law or agreed to in writing, software
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* See the License for the specific language governing permissions and
* limitations under the License.
* limitations under the License.
*/
*/
@Entry
@Entry
@Component
@Component
struct MyComponent {
struct MyComponent {
aboutToAppear() {
aboutToAppear() {
}
}
build() {
build() {
Flex({
Flex({
direction: FlexDirection.Column,
direction: FlexDirection.Column,
alignItems: ItemAlign.Center,
alignItems: ItemAlign.Center,
justifyContent: FlexAlign.Center
justifyContent: FlexAlign.Center
}) {
}) {
Text('Settings ETS TEST')
Text('Settings ETS TEST')
.fontSize(50)
.fontSize(50)
.fontWeight(FontWeight.Bold)
.fontWeight(FontWeight.Bold)
}
}
.width('100%')
.width('100%')
.height('100%')
.height('100%')
}
}
}
}
settingsdata/settings_ets/entry/src/main/ets/TestAbility/app.ets
→
applications/
settingsdata/settings_ets/entry/src/main/ets/TestAbility/app.ets
浏览文件 @
22308402
/*
/*
* Copyright (C) 2022 Huawei Device Co., Ltd.
* Copyright (C) 2022 Huawei Device Co., Ltd.
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
* You may obtain a copy of the License at
*
*
* http://www.apache.org/licenses/LICENSE-2.0
* http://www.apache.org/licenses/LICENSE-2.0
*
*
* Unless required by applicable law or agreed to in writing, software
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* See the License for the specific language governing permissions and
* limitations under the License.
* limitations under the License.
*/
*/
import AbilityDelegatorRegistry from '@ohos.application.abilityDelegatorRegistry'
import AbilityDelegatorRegistry from '@ohos.application.abilityDelegatorRegistry'
import { Hypium } from 'hypium/index'
import { Hypium } from 'hypium/index'
import testsuite from '../test/List.test'
import testsuite from '../test/List.test'
export default {
export default {
onCreate() {
onCreate() {
console.info('Application onCreate')
console.info('Application onCreate')
var abilityDelegator: any
var abilityDelegator: any
abilityDelegator = AbilityDelegatorRegistry.getAbilityDelegator()
abilityDelegator = AbilityDelegatorRegistry.getAbilityDelegator()
var abilityDelegatorArguments: any
var abilityDelegatorArguments: any
abilityDelegatorArguments = AbilityDelegatorRegistry.getArguments()
abilityDelegatorArguments = AbilityDelegatorRegistry.getArguments()
console.info('start run testcase!!!')
console.info('start run testcase!!!')
Hypium.hypiumTest(abilityDelegator, abilityDelegatorArguments, testsuite)
Hypium.hypiumTest(abilityDelegator, abilityDelegatorArguments, testsuite)
},
},
onDestroy() {
onDestroy() {
console.info('Application onDestroy')
console.info('Application onDestroy')
},
},
}
}
\ No newline at end of file
settingsdata/settings_ets/entry/src/main/ets/TestAbility/pages/index.ets
→
applications/
settingsdata/settings_ets/entry/src/main/ets/TestAbility/pages/index.ets
浏览文件 @
22308402
/*
/*
* Copyright (C) 2022 Huawei Device Co., Ltd.
* Copyright (C) 2022 Huawei Device Co., Ltd.
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
* You may obtain a copy of the License at
*
*
* http://www.apache.org/licenses/LICENSE-2.0
* http://www.apache.org/licenses/LICENSE-2.0
*
*
* Unless required by applicable law or agreed to in writing, software
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* See the License for the specific language governing permissions and
* limitations under the License.
* limitations under the License.
*/
*/
import router from '@system.router';
import router from '@system.router';
@Entry
@Entry
@Component
@Component
struct Index {
struct Index {
aboutToAppear() {
aboutToAppear() {
console.info('TestAbility index aboutToAppear')
console.info('TestAbility index aboutToAppear')
}
}
@State message: string = 'Hello World'
@State message: string = 'Hello World'
build() {
build() {
Row() {
Row() {
Column() {
Column() {
Text(this.message)
Text(this.message)
.fontSize(50)
.fontSize(50)
.fontWeight(FontWeight.Bold)
.fontWeight(FontWeight.Bold)
Button() {
Button() {
Text('next page')
Text('next page')
.fontSize(20)
.fontSize(20)
.fontWeight(FontWeight.Bold)
.fontWeight(FontWeight.Bold)
}.type(ButtonType.Capsule)
}.type(ButtonType.Capsule)
.margin({
.margin({
top: 20
top: 20
})
})
.backgroundColor('#0D9FFB')
.backgroundColor('#0D9FFB')
.width('35%')
.width('35%')
.height('5%')
.height('5%')
.onClick(()=>{
.onClick(()=>{
})
})
}
}
.width('100%')
.width('100%')
}
}
.height('100%')
.height('100%')
}
}
}
}
\ No newline at end of file
settingsdata/settings_ets/entry/src/main/ets/TestRunner/OpenHarmonyTestRunner.ts
→
applications/
settingsdata/settings_ets/entry/src/main/ets/TestRunner/OpenHarmonyTestRunner.ts
浏览文件 @
22308402
/*
/*
* Copyright (C) 2022 Huawei Device Co., Ltd.
* Copyright (C) 2022 Huawei Device Co., Ltd.
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
* You may obtain a copy of the License at
*
*
* http://www.apache.org/licenses/LICENSE-2.0
* http://www.apache.org/licenses/LICENSE-2.0
*
*
* Unless required by applicable law or agreed to in writing, software
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* See the License for the specific language governing permissions and
* limitations under the License.
* limitations under the License.
*/
*/
import
TestRunner
from
'
@ohos.application.testRunner
'
import
TestRunner
from
'
@ohos.application.testRunner
'
import
AbilityDelegatorRegistry
from
'
@ohos.application.abilityDelegatorRegistry
'
import
AbilityDelegatorRegistry
from
'
@ohos.application.abilityDelegatorRegistry
'
var
abilityDelegator
=
undefined
var
abilityDelegator
=
undefined
var
abilityDelegatorArguments
=
undefined
var
abilityDelegatorArguments
=
undefined
function
translateParamsToString
(
parameters
)
{
function
translateParamsToString
(
parameters
)
{
const
keySet
=
new
Set
([
const
keySet
=
new
Set
([
'
-s class
'
,
'
-s notClass
'
,
'
-s suite
'
,
'
-s itName
'
,
'
-s class
'
,
'
-s notClass
'
,
'
-s suite
'
,
'
-s itName
'
,
'
-s level
'
,
'
-s testType
'
,
'
-s size
'
,
'
-s timeout
'
,
'
-s level
'
,
'
-s testType
'
,
'
-s size
'
,
'
-s timeout
'
,
'
-s package
'
'
-s package
'
])
])
let
targetParams
=
''
;
let
targetParams
=
''
;
for
(
const
key
in
parameters
)
{
for
(
const
key
in
parameters
)
{
if
(
keySet
.
has
(
key
))
{
if
(
keySet
.
has
(
key
))
{
targetParams
+=
'
'
+
key
+
'
'
+
parameters
[
key
]
targetParams
+=
'
'
+
key
+
'
'
+
parameters
[
key
]
}
}
}
}
return
targetParams
.
trim
()
return
targetParams
.
trim
()
}
}
async
function
onAbilityCreateCallback
()
{
async
function
onAbilityCreateCallback
()
{
console
.
log
(
'
onAbilityCreateCallback
'
);
console
.
log
(
'
onAbilityCreateCallback
'
);
}
}
async
function
addAbilityMonitorCallback
(
err
:
any
)
{
async
function
addAbilityMonitorCallback
(
err
:
any
)
{
console
.
info
(
'
addAbilityMonitorCallback :
'
+
JSON
.
stringify
(
err
))
console
.
info
(
'
addAbilityMonitorCallback :
'
+
JSON
.
stringify
(
err
))
}
}
export
default
class
OpenHarmonyTestRunner
implements
TestRunner
{
export
default
class
OpenHarmonyTestRunner
implements
TestRunner
{
constructor
()
{
constructor
()
{
}
}
onPrepare
()
{
onPrepare
()
{
console
.
info
(
'
OpenHarmonyTestRunner OnPrepare
'
)
console
.
info
(
'
OpenHarmonyTestRunner OnPrepare
'
)
}
}
onRun
()
{
onRun
()
{
console
.
log
(
'
OpenHarmonyTestRunner onRun run
'
)
console
.
log
(
'
OpenHarmonyTestRunner onRun run
'
)
abilityDelegatorArguments
=
AbilityDelegatorRegistry
.
getArguments
()
abilityDelegatorArguments
=
AbilityDelegatorRegistry
.
getArguments
()
abilityDelegator
=
AbilityDelegatorRegistry
.
getAbilityDelegator
()
abilityDelegator
=
AbilityDelegatorRegistry
.
getAbilityDelegator
()
let
lMonitor
=
{
let
lMonitor
=
{
abilityName
:
testAbilityName
,
abilityName
:
testAbilityName
,
onAbilityCreate
:
onAbilityCreateCallback
,
onAbilityCreate
:
onAbilityCreateCallback
,
};
};
var
testAbilityName
=
abilityDelegatorArguments
.
parameters
[
'
-p
'
]
+
'
.TestAbility
'
var
testAbilityName
=
abilityDelegatorArguments
.
parameters
[
'
-p
'
]
+
'
.TestAbility
'
abilityDelegator
.
addAbilityMonitor
(
lMonitor
,
addAbilityMonitorCallback
)
abilityDelegator
.
addAbilityMonitor
(
lMonitor
,
addAbilityMonitorCallback
)
var
cmd
=
'
aa start -d 0 -a
'
+
testAbilityName
+
'
-b
'
+
abilityDelegatorArguments
.
bundleName
var
cmd
=
'
aa start -d 0 -a
'
+
testAbilityName
+
'
-b
'
+
abilityDelegatorArguments
.
bundleName
cmd
+=
'
'
+
translateParamsToString
(
abilityDelegatorArguments
.
parameters
)
cmd
+=
'
'
+
translateParamsToString
(
abilityDelegatorArguments
.
parameters
)
console
.
info
(
'
cmd :
'
+
cmd
)
console
.
info
(
'
cmd :
'
+
cmd
)
abilityDelegator
.
executeShellCommand
(
cmd
,
abilityDelegator
.
executeShellCommand
(
cmd
,
(
err
:
any
,
d
:
any
)
=>
{
(
err
:
any
,
d
:
any
)
=>
{
console
.
info
(
'
executeShellCommand : err :
'
+
JSON
.
stringify
(
err
));
console
.
info
(
'
executeShellCommand : err :
'
+
JSON
.
stringify
(
err
));
console
.
info
(
'
executeShellCommand : data :
'
+
d
.
stdResult
);
console
.
info
(
'
executeShellCommand : data :
'
+
d
.
stdResult
);
console
.
info
(
'
executeShellCommand : data :
'
+
d
.
exitCode
);
console
.
info
(
'
executeShellCommand : data :
'
+
d
.
exitCode
);
})
})
console
.
info
(
'
OpenHarmonyTestRunner onRun call abilityDelegator.getAppContext
'
)
console
.
info
(
'
OpenHarmonyTestRunner onRun call abilityDelegator.getAppContext
'
)
var
context
=
abilityDelegator
.
getAppContext
()
var
context
=
abilityDelegator
.
getAppContext
()
console
.
info
(
'
getAppContext :
'
+
JSON
.
stringify
(
context
))
console
.
info
(
'
getAppContext :
'
+
JSON
.
stringify
(
context
))
console
.
info
(
'
OpenHarmonyTestRunner onRun end
'
)
console
.
info
(
'
OpenHarmonyTestRunner onRun end
'
)
}
}
};
};
\ No newline at end of file
settingsdata/settings_ets/entry/src/main/ets/test/List.test.ets
→
applications/
settingsdata/settings_ets/entry/src/main/ets/test/List.test.ets
浏览文件 @
22308402
/**
/**
* Copyright (c) 2021 Huawei Device Co., Ltd.
* Copyright (c) 2021 Huawei Device Co., Ltd.
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
* You may obtain a copy of the License at
*
*
* http://www.apache.org/licenses/LICENSE-2.0
* http://www.apache.org/licenses/LICENSE-2.0
*
*
* Unless required by applicable law or agreed to in writing, software
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* See the License for the specific language governing permissions and
* limitations under the License.
* limitations under the License.
*/
*/
import settingUiJsunit from './SettingUiJsunit.test.ets';
import settingUiJsunit from './SettingUiJsunit.test.ets';
export default function testsuite() {
export default function testsuite() {
settingUiJsunit();
settingUiJsunit();
}
}
\ No newline at end of file
settingsdata/settings_ets/entry/src/main/ets/test/SettingUiJsunit.test.ets
→
applications/
settingsdata/settings_ets/entry/src/main/ets/test/SettingUiJsunit.test.ets
浏览文件 @
22308402
// @ts-nocheck
// @ts-nocheck
/**
/**
* Copyright (c) 2021 Huawei Device Co., Ltd.
* Copyright (c) 2021 Huawei Device Co., Ltd.
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
* You may obtain a copy of the License at
*
*
* http://www.apache.org/licenses/LICENSE-2.0
* http://www.apache.org/licenses/LICENSE-2.0
*
*
* Unless required by applicable law or agreed to in writing, software
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* See the License for the specific language governing permissions and
* limitations under the License.
* limitations under the License.
*/
*/
import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "hypium/index";
import {describe, beforeAll, beforeEach, afterEach, afterAll, it, expect} from "hypium/index";
import settings from '@ohos.settings'
import settings from '@ohos.settings'
import featureAbility from '@ohos.ability.featureAbility';
import featureAbility from '@ohos.ability.featureAbility';
export default function settingUiJsunit() {
export default function settingUiJsunit() {
describe('appInfoTest', function () {
describe('appInfoTest', function () {
console.log("************* settings Test start*************");
console.log("************* settings Test start*************");
it('settings_uri_test_001', 0,async function (done) {
it('settings_uri_test_001', 0,async function (done) {
var name = 'settings.screen.test';
var name = 'settings.screen.test';
var uri = settings.getUriSync(name);
var uri = settings.getUriSync(name);
console.info("[settings_uri_test_001] uri is: " + uri);
console.info("[settings_uri_test_001] uri is: " + uri);
var uri2 = settings.getUriSync(name);
var uri2 = settings.getUriSync(name);
console.info("[settings_uri_test_001] uri2 is: " + uri2);
console.info("[settings_uri_test_001] uri2 is: " + uri2);
expect(uri).assertEqual(uri2);
expect(uri).assertEqual(uri2);
done();
done();
});
});
it('settings_uri_test_002', 0, async function (done) {
it('settings_uri_test_002', 0, async function (done) {
var name = '';
var name = '';
var uri = settings.getUriSync(name);
var uri = settings.getUriSync(name);
console.info("[settings_uri_test_002] uri is: " + uri);
console.info("[settings_uri_test_002] uri is: " + uri);
expect(uri).assertEqual('dataability:///com.ohos.settingsdata.DataAbility')
expect(uri).assertEqual('dataability:///com.ohos.settingsdata.DataAbility')
done();
done();
});
});
it('settings_uri_test_003', 0, async function (done) {
it('settings_uri_test_003', 0, async function (done) {
var name = 122.00;
var name = 122.00;
try {
try {
var uri = settings.getUriSync(name);
var uri = settings.getUriSync(name);
console.info("[settings_uri_test_003] uri is: " + uri);
console.info("[settings_uri_test_003] uri is: " + uri);
} catch (err) {
} catch (err) {
let errMsg = err;
let errMsg = err;
console.error("[settings_uri_test_003] error = " + errMsg);
console.error("[settings_uri_test_003] error = " + errMsg);
expect(errMsg == "Error: assertion (valueType == napi_string) failed: Wrong argument type. String expected.")
expect(errMsg == "Error: assertion (valueType == napi_string) failed: Wrong argument type. String expected.")
.assertTrue();
.assertTrue();
}
}
done();
done();
});
});
it('settings_uri_test_004', 0, async function (done) {
it('settings_uri_test_004', 0, async function (done) {
var name = 'settings.screen.brightness';
var name = 'settings.screen.brightness';
var uri = settings.getUriSync(name);
var uri = settings.getUriSync(name);
console.info("[settings_uri_test_004] uri is: " + uri);
console.info("[settings_uri_test_004] uri is: " + uri);
expect(uri).assertEqual('dataability:///com.ohos.settingsdata.DataAbility/settings.screen.brightness')
expect(uri).assertEqual('dataability:///com.ohos.settingsdata.DataAbility/settings.screen.brightness')
done();
done();
});
});
it('settings_get_value_005', 0, async function (done) {
it('settings_get_value_005', 0, async function (done) {
var name = 'settings.screen.brightness20';
var name = 'settings.screen.brightness20';
var uri = settings.getUriSync(name);
var uri = settings.getUriSync(name);
var helper = featureAbility.acquireDataAbilityHelper(uri);
var helper = featureAbility.acquireDataAbilityHelper(uri);
let value = settings.getValueSync(helper, name, "test getValueSync");
let value = settings.getValueSync(helper, name, "test getValueSync");
console.info("[settings_get_value_005] value is: " + value);
console.info("[settings_get_value_005] value is: " + value);
expect(value).assertEqual("test getValueSync");
expect(value).assertEqual("test getValueSync");
done();
done();
});
});
it('settings_get_value_006', 0, async function (done) {
it('settings_get_value_006', 0, async function (done) {
var name = 'settings.screen.brightness2';
var name = 'settings.screen.brightness2';
var uri = settings.getUriSync(name);
var uri = settings.getUriSync(name);
console.info("[settings_get_value_006] uri is: " + uri);
console.info("[settings_get_value_006] uri is: " + uri);
var helper = featureAbility.acquireDataAbilityHelper(uri);
var helper = featureAbility.acquireDataAbilityHelper(uri);
let obj = {
let obj = {
aa: "aa"
aa: "aa"
}
}
try {
try {
let value = settings.getValueSync(helper, name, obj);
let value = settings.getValueSync(helper, name, obj);
console.info("[settings_get_value_006] value is: " + value);
console.info("[settings_get_value_006] value is: " + value);
expect(value).assertEqual("test getValueSync");
expect(value).assertEqual("test getValueSync");
} catch (err) {
} catch (err) {
console.error("[settings_get_value_006] error = " + err);
console.error("[settings_get_value_006] error = " + err);
expect(err == "Error: assertion (valueType == napi_string) failed: Wrong argument[2] type. String expected.")
expect(err == "Error: assertion (valueType == napi_string) failed: Wrong argument[2] type. String expected.")
.assertTrue();
.assertTrue();
}
}
done();
done();
});
});
it('settings_get_value_007', 0, async function (done) {
it('settings_get_value_007', 0, async function (done) {
var name = 'settings.screen.brightness3';
var name = 'settings.screen.brightness3';
var uri = settings.getUriSync(name);
var uri = settings.getUriSync(name);
console.info("[settings_get_value_007] uri is: " + uri);
console.info("[settings_get_value_007] uri is: " + uri);
var helper = featureAbility.acquireDataAbilityHelper(uri);
var helper = featureAbility.acquireDataAbilityHelper(uri);
let obj = '';
let obj = '';
try {
try {
let value = settings.getValueSync(helper, name, obj);
let value = settings.getValueSync(helper, name, obj);
console.info("[settings_get_value_007] value is: " + value);
console.info("[settings_get_value_007] value is: " + value);
expect(value).assertEqual('');
expect(value).assertEqual('');
} catch (err) {
} catch (err) {
console.error("[settings_get_value_007] error = " + err);
console.error("[settings_get_value_007] error = " + err);
expect(err == "Error: assertion (valueType == napi_string) failed: Wrong argument type. String expected.")
expect(err == "Error: assertion (valueType == napi_string) failed: Wrong argument type. String expected.")
.assertTrue();
.assertTrue();
}
}
done();
done();
});
});
it('settings_get_value_008', 0, async function (done) {
it('settings_get_value_008', 0, async function (done) {
var name = 'settings.screen.brightness4';
var name = 'settings.screen.brightness4';
var uri = settings.getUriSync(name);
var uri = settings.getUriSync(name);
console.info("[settings_get_value_008] uri is: " + uri);
console.info("[settings_get_value_008] uri is: " + uri);
var helper = featureAbility.acquireDataAbilityHelper(uri);
var helper = featureAbility.acquireDataAbilityHelper(uri);
let obj = null;
let obj = null;
try {
try {
let value = settings.getValueSync(helper, name, obj);
let value = settings.getValueSync(helper, name, obj);
console.info("[settings_get_value_008] value is: " + value);
console.info("[settings_get_value_008] value is: " + value);
} catch (err) {
} catch (err) {
console.error("[settings_get_value_008] error = " + err);
console.error("[settings_get_value_008] error = " + err);
expect(err == "Error: assertion (valueType == napi_string) failed: Wrong argument[2] type. String expected.")
expect(err == "Error: assertion (valueType == napi_string) failed: Wrong argument[2] type. String expected.")
.assertTrue();
.assertTrue();
}
}
done();
done();
});
});
it('settings_get_value_009', 0, async function (done) {
it('settings_get_value_009', 0, async function (done) {
var name = 'settings.screen.brightness5';
var name = 'settings.screen.brightness5';
var uri = settings.getUriSync(name);
var uri = settings.getUriSync(name);
console.info("[settings_get_value_009] uri is: " + uri);
console.info("[settings_get_value_009] uri is: " + uri);
var helper = "helper";
var helper = "helper";
try {
try {
let value = settings.getValueSync(helper, name, "test getValueSync");
let value = settings.getValueSync(helper, name, "test getValueSync");
console.info("[settings_get_value_009] value is: " + value);
console.info("[settings_get_value_009] value is: " + value);
} catch (err) {
} catch (err) {
console.error("[settings_get_value_009] error = " + err);
console.error("[settings_get_value_009] error = " + err);
expect(err == "Error: assertion (valueType == napi_object) failed: Wrong argument[0] type. Object expected.")
expect(err == "Error: assertion (valueType == napi_object) failed: Wrong argument[0] type. Object expected.")
.assertTrue();
.assertTrue();
}
}
done();
done();
});
});
it('settings_get_value_010', 0, async function (done) {
it('settings_get_value_010', 0, async function (done) {
var name = 'settings.screen.brightness6';
var name = 'settings.screen.brightness6';
var uri = settings.getUriSync(name);
var uri = settings.getUriSync(name);
console.info("[settings_get_value_010] uri is: " + uri);
console.info("[settings_get_value_010] uri is: " + uri);
var helper = null;
var helper = null;
try {
try {
let value = settings.getValueSync(helper, name, "test getValueSync");
let value = settings.getValueSync(helper, name, "test getValueSync");
console.info("[settings_get_value_010] value is: " + value);
console.info("[settings_get_value_010] value is: " + value);
} catch (err) {
} catch (err) {
console.error("[settings_get_value_010] error = " + err);
console.error("[settings_get_value_010] error = " + err);
expect(err == "Error: assertion (valueType == napi_object) failed: Wrong argument[0] type. Object expected.")
expect(err == "Error: assertion (valueType == napi_object) failed: Wrong argument[0] type. Object expected.")
.assertTrue();
.assertTrue();
}
}
done();
done();
});
});
it('settings_get_value_0011', 0, async function (done) {
it('settings_get_value_0011', 0, async function (done) {
var name = 'settings.screen.brightness7';
var name = 'settings.screen.brightness7';
var uri = settings.getUriSync(name);
var uri = settings.getUriSync(name);
console.info("[settings_get_value_0011] uri is: " + uri);
console.info("[settings_get_value_0011] uri is: " + uri);
var helper = "helper";
var helper = "helper";
let obj = 121;
let obj = 121;
try {
try {
let value = settings.getValueSync(helper, name, obj);
let value = settings.getValueSync(helper, name, obj);
console.info("[settings_get_value_0011] value is: " + value);
console.info("[settings_get_value_0011] value is: " + value);
} catch (err) {
} catch (err) {
console.error("[settings_get_value_0011] error = " + err);
console.error("[settings_get_value_0011] error = " + err);
expect(err == "Error: assertion (valueType == napi_object) failed: Wrong argument[0] type. Object expected.")
expect(err == "Error: assertion (valueType == napi_object) failed: Wrong argument[0] type. Object expected.")
.assertTrue();
.assertTrue();
}
}
done();
done();
});
});
it('settings_get_value_0012', 0, async function (done) {
it('settings_get_value_0012', 0, async function (done) {
var name = 'settings.screen.brightness8';
var name = 'settings.screen.brightness8';
var uri = settings.getUriSync(name);
var uri = settings.getUriSync(name);
console.info("[settings_get_value_0012] uri is: " + uri);
console.info("[settings_get_value_0012] uri is: " + uri);
var helper = null;
var helper = null;
let obj = null;
let obj = null;
try {
try {
let value = settings.getValueSync(helper, name, obj);
let value = settings.getValueSync(helper, name, obj);
console.info("[settings_get_value_0012] value is: " + value);
console.info("[settings_get_value_0012] value is: " + value);
} catch (err) {
} catch (err) {
console.error("[settings_get_value_0012] error = " + err);
console.error("[settings_get_value_0012] error = " + err);
expect(err == "Error: assertion (valueType == napi_object) failed: Wrong argument[0] type. Object expected.")
expect(err == "Error: assertion (valueType == napi_object) failed: Wrong argument[0] type. Object expected.")
.assertTrue();
.assertTrue();
}
}
done();
done();
});
});
it('settings_get_value_013', 0, async function (done) {
it('settings_get_value_013', 0, async function (done) {
var name = 1322.00;
var name = 1322.00;
try {
try {
var uri = settings.getUriSync(name);
var uri = settings.getUriSync(name);
console.info("[settings_get_value_013] uri is: " + uri);
console.info("[settings_get_value_013] uri is: " + uri);
} catch (err) {
} catch (err) {
let errMsg = err;
let errMsg = err;
console.error("[settings_get_value_013] error = " + errMsg);
console.error("[settings_get_value_013] error = " + errMsg);
expect(errMsg == "Error: assertion (valueType == napi_string) failed: Wrong argument type. String expected.")
expect(errMsg == "Error: assertion (valueType == napi_string) failed: Wrong argument type. String expected.")
.assertTrue();
.assertTrue();
}
}
var helper = featureAbility.acquireDataAbilityHelper(uri);
var helper = featureAbility.acquireDataAbilityHelper(uri);
try {
try {
let value = settings.getValueSync(helper, name, "test getValueSync");
let value = settings.getValueSync(helper, name, "test getValueSync");
console.info("[settings_get_value_013] value is: " + value);
console.info("[settings_get_value_013] value is: " + value);
} catch (err) {
} catch (err) {
console.error("[settings_get_value_013] error = " + err);
console.error("[settings_get_value_013] error = " + err);
expect(err == "Error: assertion (valueType == napi_object) failed: Wrong argument[0] type. Object expected.")
expect(err == "Error: assertion (valueType == napi_object) failed: Wrong argument[0] type. Object expected.")
.assertTrue();
.assertTrue();
}
}
done();
done();
});
});
it('settings_get_value_014', 0, async function (done) {
it('settings_get_value_014', 0, async function (done) {
let name = null;
let name = null;
try {
try {
var uri = settings.getUriSync(name);
var uri = settings.getUriSync(name);
console.info("[settings_get_value_014] uri is: " + uri);
console.info("[settings_get_value_014] uri is: " + uri);
} catch (err) {
} catch (err) {
let errMsg = err;
let errMsg = err;
console.error("[settings_get_value_014] error = " + errMsg);
console.error("[settings_get_value_014] error = " + errMsg);
expect(errMsg == "Error: assertion (valueType == napi_string) failed: Wrong argument type. String expected.")
expect(errMsg == "Error: assertion (valueType == napi_string) failed: Wrong argument type. String expected.")
.assertTrue();
.assertTrue();
}
}
var helper = featureAbility.acquireDataAbilityHelper(uri);
var helper = featureAbility.acquireDataAbilityHelper(uri);
try {
try {
let value = settings.getValueSync(helper, name, "test getValueSync");
let value = settings.getValueSync(helper, name, "test getValueSync");
console.info("[settings_get_value_014] value is: " + value);
console.info("[settings_get_value_014] value is: " + value);
} catch (err) {
} catch (err) {
console.error("[settings_get_value_014] error = " + err);
console.error("[settings_get_value_014] error = " + err);
expect(err == "Error: assertion (valueType == napi_object) failed: Wrong argument[0] type. Object expected.")
expect(err == "Error: assertion (valueType == napi_object) failed: Wrong argument[0] type. Object expected.")
.assertTrue();
.assertTrue();
}
}
done();
done();
});
});
it('settings_get_value_0015', 0, async function (done) {
it('settings_get_value_0015', 0, async function (done) {
let name = 1332;
let name = 1332;
try {
try {
var uri = settings.getUriSync(name);
var uri = settings.getUriSync(name);
console.info("[settings_get_value_0015] uri is: " + uri);
console.info("[settings_get_value_0015] uri is: " + uri);
} catch (err) {
} catch (err) {
let errMsg = err;
let errMsg = err;
console.error("[settings_get_value_0015] error = " + errMsg);
console.error("[settings_get_value_0015] error = " + errMsg);
expect(errMsg == "Error: assertion (valueType == napi_string) failed: Wrong argument type. String expected.")
expect(errMsg == "Error: assertion (valueType == napi_string) failed: Wrong argument type. String expected.")
.assertTrue();
.assertTrue();
}
}
var helper = featureAbility.acquireDataAbilityHelper(uri);
var helper = featureAbility.acquireDataAbilityHelper(uri);
let obj = 22223;
let obj = 22223;
try {
try {
let value = settings.getValueSync(helper, name, obj);
let value = settings.getValueSync(helper, name, obj);
console.info("[settings_get_value_0015] value is: " + value);
console.info("[settings_get_value_0015] value is: " + value);
} catch (err) {
} catch (err) {
console.error("[settings_get_value_0015] error = " + err);
console.error("[settings_get_value_0015] error = " + err);
expect(err == "Error: assertion (valueType == napi_object) failed: Wrong argument[0] type. Object expected.")
expect(err == "Error: assertion (valueType == napi_object) failed: Wrong argument[0] type. Object expected.")
.assertTrue();
.assertTrue();
}
}
done();
done();
});
});
it('settings_get_value_0016', 0, async function (done) {
it('settings_get_value_0016', 0, async function (done) {
let name = 1332;
let name = 1332;
try {
try {
var uri = settings.getUriSync(name);
var uri = settings.getUriSync(name);
console.info("[settings_get_value_0016] uri is: " + uri);
console.info("[settings_get_value_0016] uri is: " + uri);
} catch (err) {
} catch (err) {
let errMsg = err;
let errMsg = err;
console.error("[settings_get_value_0016] error = " + errMsg);
console.error("[settings_get_value_0016] error = " + errMsg);
expect(errMsg == "Error: assertion (valueType == napi_string) failed: Wrong argument type. String expected.")
expect(errMsg == "Error: assertion (valueType == napi_string) failed: Wrong argument type. String expected.")
.assertTrue();
.assertTrue();
}
}
var helper = "helper";
var helper = "helper";
try {
try {
let value = settings.getValueSync(helper, name, "test getValueSync");
let value = settings.getValueSync(helper, name, "test getValueSync");
console.info("[settings_get_value_0016] value is: " + value);
console.info("[settings_get_value_0016] value is: " + value);
} catch (err) {
} catch (err) {
console.error("[settings_get_value_0016] error = " + err);
console.error("[settings_get_value_0016] error = " + err);
expect(err == "Error: assertion (valueType == napi_object) failed: Wrong argument[0] type. Object expected.")
expect(err == "Error: assertion (valueType == napi_object) failed: Wrong argument[0] type. Object expected.")
.assertTrue();
.assertTrue();
}
}
done();
done();
});
});
it('settings_get_value_0017', 0, async function (done) {
it('settings_get_value_0017', 0, async function (done) {
let name = 1332;
let name = 1332;
try {
try {
var uri = settings.getUriSync(name);
var uri = settings.getUriSync(name);
console.info("[settings_get_value_0017] uri is: " + uri);
console.info("[settings_get_value_0017] uri is: " + uri);
} catch (err) {
} catch (err) {
let errMsg = err;
let errMsg = err;
console.error("[settings_get_value_0017] error = " + errMsg);
console.error("[settings_get_value_0017] error = " + errMsg);
expect(errMsg == "Error: assertion (valueType == napi_string) failed: Wrong argument type. String expected.")
expect(errMsg == "Error: assertion (valueType == napi_string) failed: Wrong argument type. String expected.")
.assertTrue();
.assertTrue();
}
}
var helper = "helper";
var helper = "helper";
let obj = 221323;
let obj = 221323;
try {
try {
let value = settings.getValueSync(helper, name, obj);
let value = settings.getValueSync(helper, name, obj);
console.info("[settings_get_value_0017] value is: " + value);
console.info("[settings_get_value_0017] value is: " + value);
} catch (err) {
} catch (err) {
console.error("[settings_get_value_0017] error = " + err);
console.error("[settings_get_value_0017] error = " + err);
expect(err == "Error: assertion (valueType == napi_object) failed: Wrong argument[0] type. Object expected.")
expect(err == "Error: assertion (valueType == napi_object) failed: Wrong argument[0] type. Object expected.")
.assertTrue();
.assertTrue();
}
}
done();
done();
});
});
it('settings_set_value_018', 0, async function (done) {
it('settings_set_value_018', 0, async function (done) {
let name = 'settings.screen.brightness10';
let name = 'settings.screen.brightness10';
var uri = settings.getUriSync(name);
var uri = settings.getUriSync(name);
var helper = featureAbility.acquireDataAbilityHelper(uri);
var helper = featureAbility.acquireDataAbilityHelper(uri);
let value = settings.setValueSync(helper, name, "test getValueSync");
let value = settings.setValueSync(helper, name, "test getValueSync");
expect(value).assertEqual(true);
expect(value).assertEqual(true);
done();
done();
});
});
it('settings_set_value_019', 0, async function (done) {
it('settings_set_value_019', 0, async function (done) {
let name = 'settings.screen.brightness11';
let name = 'settings.screen.brightness11';
var uri = settings.getUriSync(name);
var uri = settings.getUriSync(name);
var helper = featureAbility.acquireDataAbilityHelper(uri);
var helper = featureAbility.acquireDataAbilityHelper(uri);
let obj = 32344.00;
let obj = 32344.00;
try {
try {
let value = settings.setValueSync(helper, name, obj);
let value = settings.setValueSync(helper, name, obj);
console.info("[settings_set_value_019] value is: " + value);
console.info("[settings_set_value_019] value is: " + value);
expect(value).assertEqual(true);
expect(value).assertEqual(true);
} catch (err) {
} catch (err) {
console.error("[settings_set_value_019] error = " + err);
console.error("[settings_set_value_019] error = " + err);
expect(err == "Error: assertion (valueType == napi_string) failed: Wrong argument[2] type. String expected.")
expect(err == "Error: assertion (valueType == napi_string) failed: Wrong argument[2] type. String expected.")
.assertTrue();
.assertTrue();
}
}
done();
done();
});
});
it('settings_set_value_020', 0, async function (done) {
it('settings_set_value_020', 0, async function (done) {
let name = 'settings.screen.brightness12';
let name = 'settings.screen.brightness12';
var uri = settings.getUriSync(name);
var uri = settings.getUriSync(name);
var helper = featureAbility.acquireDataAbilityHelper(uri);
var helper = featureAbility.acquireDataAbilityHelper(uri);
let obj = null;
let obj = null;
try {
try {
let value = settings.setValueSync(helper, name, obj);
let value = settings.setValueSync(helper, name, obj);
console.info("[settings_set_value_020] value is: " + value);
console.info("[settings_set_value_020] value is: " + value);
expect(value).assertEqual(true);
expect(value).assertEqual(true);
} catch (err) {
} catch (err) {
console.error("[settings_set_value_020] error = " + err);
console.error("[settings_set_value_020] error = " + err);
expect(err == "Error: assertion (valueType == napi_string) failed: Wrong argument[2] type. String expected.")
expect(err == "Error: assertion (valueType == napi_string) failed: Wrong argument[2] type. String expected.")
.assertTrue();
.assertTrue();
}
}
done();
done();
});
});
it('settings_set_value_021', 0, async function (done) {
it('settings_set_value_021', 0, async function (done) {
let name = 'settings.screen.brightness13';
let name = 'settings.screen.brightness13';
var helper = "helper";
var helper = "helper";
try {
try {
let value = settings.setValueSync(helper, name, "test getValueSync");
let value = settings.setValueSync(helper, name, "test getValueSync");
expect(value).assertEqual(true);
expect(value).assertEqual(true);
} catch (err) {
} catch (err) {
console.error("[settings_set_value_021] error = " + err);
console.error("[settings_set_value_021] error = " + err);
expect(err == "Error: assertion (valueType == napi_object) failed: Wrong argument[0] type. Object expected.")
expect(err == "Error: assertion (valueType == napi_object) failed: Wrong argument[0] type. Object expected.")
.assertTrue();
.assertTrue();
}
}
done();
done();
});
});
it('settings_set_value_022', 0, async function (done) {
it('settings_set_value_022', 0, async function (done) {
let name = 'settings.screen.brightness13';
let name = 'settings.screen.brightness13';
var helper = null;
var helper = null;
try {
try {
let value = settings.setValueSync(helper, name, "test getValueSync");
let value = settings.setValueSync(helper, name, "test getValueSync");
expect(value).assertEqual(true);
expect(value).assertEqual(true);
} catch (err) {
} catch (err) {
console.error("[settings_set_value_022] error = " + err);
console.error("[settings_set_value_022] error = " + err);
expect(err == "Error: assertion (valueType == napi_object) failed: Wrong argument[0] type. Object expected.")
expect(err == "Error: assertion (valueType == napi_object) failed: Wrong argument[0] type. Object expected.")
.assertTrue();
.assertTrue();
}
}
done();
done();
});
});
it('settings_set_value_023', 0, async function (done) {
it('settings_set_value_023', 0, async function (done) {
let name = 'settings.screen.brightness14';
let name = 'settings.screen.brightness14';
var helper = "helper";
var helper = "helper";
let obj = 343434.00;
let obj = 343434.00;
try {
try {
let value = settings.setValueSync(helper, name, obj);
let value = settings.setValueSync(helper, name, obj);
expect(value).assertEqual(true);
expect(value).assertEqual(true);
} catch (err) {
} catch (err) {
console.error("[settings_set_value_023] error = " + err);
console.error("[settings_set_value_023] error = " + err);
expect(err == "Error: assertion (valueType == napi_object) failed: Wrong argument[0] type. Object expected.")
expect(err == "Error: assertion (valueType == napi_object) failed: Wrong argument[0] type. Object expected.")
.assertTrue();
.assertTrue();
}
}
done();
done();
});
});
it('settings_set_value_024', 0, async function (done) {
it('settings_set_value_024', 0, async function (done) {
let name = 'settings.screen.brightness14';
let name = 'settings.screen.brightness14';
var helper = "helper";
var helper = "helper";
let obj = null;
let obj = null;
try {
try {
let value = settings.setValueSync(helper, name, obj);
let value = settings.setValueSync(helper, name, obj);
expect(value).assertEqual(true);
expect(value).assertEqual(true);
} catch (err) {
} catch (err) {
console.error("[settings_set_value_024] error = " + err);
console.error("[settings_set_value_024] error = " + err);
expect(err == "Error: assertion (valueType == napi_object) failed: Wrong argument[0] type. Object expected.")
expect(err == "Error: assertion (valueType == napi_object) failed: Wrong argument[0] type. Object expected.")
.assertTrue();
.assertTrue();
}
}
done();
done();
});
});
it('settings_set_value_025', 0, async function (done) {
it('settings_set_value_025', 0, async function (done) {
let name = 'settings.screen.brightness14';
let name = 'settings.screen.brightness14';
var helper = null;
var helper = null;
let obj = 2323.00;
let obj = 2323.00;
try {
try {
let value = settings.setValueSync(helper, name, obj);
let value = settings.setValueSync(helper, name, obj);
expect(value).assertEqual(true);
expect(value).assertEqual(true);
} catch (err) {
} catch (err) {
console.error("[settings_set_value_025] error = " + err);
console.error("[settings_set_value_025] error = " + err);
expect(err == "Error: assertion (valueType == napi_object) failed: Wrong argument[0] type. Object expected.")
expect(err == "Error: assertion (valueType == napi_object) failed: Wrong argument[0] type. Object expected.")
.assertTrue();
.assertTrue();
}
}
done();
done();
});
});
it('settings_set_value_026', 0, async function (done) {
it('settings_set_value_026', 0, async function (done) {
let name = 1332;
let name = 1332;
try {
try {
var uri = settings.getUriSync(name);
var uri = settings.getUriSync(name);
console.info("[settings_set_value_026] uri is: " + uri);
console.info("[settings_set_value_026] uri is: " + uri);
} catch (err) {
} catch (err) {
let errMsg = err;
let errMsg = err;
console.error("[settings_set_value_026] error = " + errMsg);
console.error("[settings_set_value_026] error = " + errMsg);
expect(errMsg == "Error: assertion (valueType == napi_string) failed: Wrong argument type. String expected.")
expect(errMsg == "Error: assertion (valueType == napi_string) failed: Wrong argument type. String expected.")
.assertTrue();
.assertTrue();
}
}
var helper = featureAbility.acquireDataAbilityHelper(uri);
var helper = featureAbility.acquireDataAbilityHelper(uri);
try {
try {
let value = settings.setValueSync(helper, name, "test getValueSync");
let value = settings.setValueSync(helper, name, "test getValueSync");
expect(value).assertEqual(true);
expect(value).assertEqual(true);
} catch (err) {
} catch (err) {
console.error("[settings_set_value_026] error = " + err);
console.error("[settings_set_value_026] error = " + err);
expect(err == "Error: assertion (valueType == napi_object) failed: Wrong argument[0] type. Object expected.")
expect(err == "Error: assertion (valueType == napi_object) failed: Wrong argument[0] type. Object expected.")
.assertTrue();
.assertTrue();
}
}
done();
done();
});
});
it('settings_set_value_027', 0, async function (done) {
it('settings_set_value_027', 0, async function (done) {
let name = null;
let name = null;
try {
try {
var uri = settings.getUriSync(name);
var uri = settings.getUriSync(name);
console.info("[settings_set_value_027] uri is: " + uri);
console.info("[settings_set_value_027] uri is: " + uri);
} catch (err) {
} catch (err) {
let errMsg = err;
let errMsg = err;
console.error("[settings_set_value_027] error = " + errMsg);
console.error("[settings_set_value_027] error = " + errMsg);
expect(errMsg == "Error: assertion (valueType == napi_string) failed: Wrong argument type. String expected.")
expect(errMsg == "Error: assertion (valueType == napi_string) failed: Wrong argument type. String expected.")
.assertTrue();
.assertTrue();
}
}
var helper = featureAbility.acquireDataAbilityHelper(uri);
var helper = featureAbility.acquireDataAbilityHelper(uri);
try {
try {
let value = settings.setValueSync(helper, name, "test getValueSync");
let value = settings.setValueSync(helper, name, "test getValueSync");
expect(value).assertEqual(true);
expect(value).assertEqual(true);
} catch (err) {
} catch (err) {
console.error("[settings_set_value_027] error = " + err);
console.error("[settings_set_value_027] error = " + err);
expect(err == "Error: assertion (valueType == napi_object) failed: Wrong argument[0] type. Object expected.")
expect(err == "Error: assertion (valueType == napi_object) failed: Wrong argument[0] type. Object expected.")
.assertTrue();
.assertTrue();
}
}
done();
done();
});
});
it('settings_set_value_028', 0, async function (done) {
it('settings_set_value_028', 0, async function (done) {
let name = 2323;
let name = 2323;
try {
try {
var uri = settings.getUriSync(name);
var uri = settings.getUriSync(name);
console.info("[settings_set_value_028] uri is: " + uri);
console.info("[settings_set_value_028] uri is: " + uri);
} catch (err) {
} catch (err) {
let errMsg = err;
let errMsg = err;
console.error("[settings_set_value_028] error = " + errMsg);
console.error("[settings_set_value_028] error = " + errMsg);
expect(errMsg == "Error: assertion (valueType == napi_string) failed: Wrong argument type. String expected.")
expect(errMsg == "Error: assertion (valueType == napi_string) failed: Wrong argument type. String expected.")
.assertTrue();
.assertTrue();
}
}
var helper = featureAbility.acquireDataAbilityHelper(uri);
var helper = featureAbility.acquireDataAbilityHelper(uri);
let obj = 232.00;
let obj = 232.00;
try {
try {
let value = settings.setValueSync(helper, name, obj);
let value = settings.setValueSync(helper, name, obj);
expect(value).assertEqual(true);
expect(value).assertEqual(true);
} catch (err) {
} catch (err) {
console.error("[settings_set_value_028] error = " + err);
console.error("[settings_set_value_028] error = " + err);
expect(err == "Error: assertion (valueType == napi_object) failed: Wrong argument[0] type. Object expected.")
expect(err == "Error: assertion (valueType == napi_object) failed: Wrong argument[0] type. Object expected.")
.assertTrue();
.assertTrue();
}
}
done();
done();
});
});
it('settings_set_value_029', 0, async function (done) {
it('settings_set_value_029', 0, async function (done) {
let name = 2323;
let name = 2323;
try {
try {
var uri = settings.getUriSync(name);
var uri = settings.getUriSync(name);
console.info("[settings_set_value_029] uri is: " + uri);
console.info("[settings_set_value_029] uri is: " + uri);
} catch (err) {
} catch (err) {
let errMsg = err;
let errMsg = err;
console.error("[settings_set_value_029] error = " + errMsg);
console.error("[settings_set_value_029] error = " + errMsg);
expect(errMsg == "Error: assertion (valueType == napi_string) failed: Wrong argument type. String expected.")
expect(errMsg == "Error: assertion (valueType == napi_string) failed: Wrong argument type. String expected.")
.assertTrue();
.assertTrue();
}
}
var helper = featureAbility.acquireDataAbilityHelper(uri);
var helper = featureAbility.acquireDataAbilityHelper(uri);
let obj = null;
let obj = null;
try {
try {
let value = settings.setValueSync(helper, name, obj);
let value = settings.setValueSync(helper, name, obj);
expect(value).assertEqual(true);
expect(value).assertEqual(true);
} catch (err) {
} catch (err) {
console.error("[settings_set_value_029] error = " + err);
console.error("[settings_set_value_029] error = " + err);
expect(err == "Error: assertion (valueType == napi_object) failed: Wrong argument[0] type. Object expected.")
expect(err == "Error: assertion (valueType == napi_object) failed: Wrong argument[0] type. Object expected.")
.assertTrue();
.assertTrue();
}
}
done();
done();
});
});
it('settings_set_value_030', 0, async function (done) {
it('settings_set_value_030', 0, async function (done) {
let name = 2323;
let name = 2323;
try {
try {
var uri = settings.getUriSync(name);
var uri = settings.getUriSync(name);
console.info("[settings_set_value_030] uri is: " + uri);
console.info("[settings_set_value_030] uri is: " + uri);
} catch (err) {
} catch (err) {
let errMsg = err;
let errMsg = err;
console.error("[settings_set_value_030] error = " + errMsg);
console.error("[settings_set_value_030] error = " + errMsg);
expect(errMsg == "Error: assertion (valueType == napi_string) failed: Wrong argument type. String expected.")
expect(errMsg == "Error: assertion (valueType == napi_string) failed: Wrong argument type. String expected.")
.assertTrue();
.assertTrue();
}
}
var helper = "helper";
var helper = "helper";
try {
try {
let value = settings.setValueSync(helper, name, "text value");
let value = settings.setValueSync(helper, name, "text value");
expect(value).assertEqual(true);
expect(value).assertEqual(true);
} catch (err) {
} catch (err) {
console.error("[settings_set_value_030] error = " + err);
console.error("[settings_set_value_030] error = " + err);
expect(err == "Error: assertion (valueType == napi_object) failed: Wrong argument[0] type. Object expected.")
expect(err == "Error: assertion (valueType == napi_object) failed: Wrong argument[0] type. Object expected.")
.assertTrue();
.assertTrue();
}
}
done();
done();
});
});
it('settings_set_value_031', 0, async function (done) {
it('settings_set_value_031', 0, async function (done) {
let name = 2323;
let name = 2323;
try {
try {
var uri = settings.getUriSync(name);
var uri = settings.getUriSync(name);
console.info("[settings_set_value_031] uri is: " + uri);
console.info("[settings_set_value_031] uri is: " + uri);
} catch (err) {
} catch (err) {
let errMsg = err;
let errMsg = err;
console.error("[settings_set_value_031] error = " + errMsg);
console.error("[settings_set_value_031] error = " + errMsg);
expect(errMsg == "Error: assertion (valueType == napi_string) failed: Wrong argument type. String expected.")
expect(errMsg == "Error: assertion (valueType == napi_string) failed: Wrong argument type. String expected.")
.assertTrue();
.assertTrue();
}
}
var helper = null;
var helper = null;
try {
try {
let value = settings.setValueSync(helper, name, "text value");
let value = settings.setValueSync(helper, name, "text value");
expect(value).assertEqual(true);
expect(value).assertEqual(true);
} catch (err) {
} catch (err) {
console.error("[settings_set_value_031] error = " + err);
console.error("[settings_set_value_031] error = " + err);
expect(err == "Error: assertion (valueType == napi_object) failed: Wrong argument[0] type. Object expected.")
expect(err == "Error: assertion (valueType == napi_object) failed: Wrong argument[0] type. Object expected.")
.assertTrue();
.assertTrue();
}
}
done();
done();
});
});
it('settings_set_value_032', 0, async function (done) {
it('settings_set_value_032', 0, async function (done) {
let name = 2323;
let name = 2323;
try {
try {
var uri = settings.getUriSync(name);
var uri = settings.getUriSync(name);
console.info("[settings_set_value_032] uri is: " + uri);
console.info("[settings_set_value_032] uri is: " + uri);
} catch (err) {
} catch (err) {
let errMsg = err;
let errMsg = err;
console.error("[settings_set_value_032] error = " + errMsg);
console.error("[settings_set_value_032] error = " + errMsg);
expect(errMsg == "Error: assertion (valueType == napi_string) failed: Wrong argument type. String expected.")
expect(errMsg == "Error: assertion (valueType == napi_string) failed: Wrong argument type. String expected.")
.assertTrue();
.assertTrue();
}
}
var helper = "helper";
var helper = "helper";
let obj = 2323;
let obj = 2323;
try {
try {
let value = settings.setValueSync(helper, name, obj);
let value = settings.setValueSync(helper, name, obj);
expect(value).assertEqual(true);
expect(value).assertEqual(true);
} catch (err) {
} catch (err) {
console.error("[settings_set_value_032] error = " + err);
console.error("[settings_set_value_032] error = " + err);
expect(err == "Error: assertion (valueType == napi_object) failed: Wrong argument[0] type. Object expected.")
expect(err == "Error: assertion (valueType == napi_object) failed: Wrong argument[0] type. Object expected.")
.assertTrue();
.assertTrue();
}
}
done();
done();
});
});
it('settings_get_value_033', 0, async function (done){
it('settings_get_value_033', 0, async function (done){
let uri = 'dataability:///com.ohos.settingsdata.DataAbility';
let uri = 'dataability:///com.ohos.settingsdata.DataAbility';
let helper = featureAbility.acquireDataAbilityHelper(uri);
let helper = featureAbility.acquireDataAbilityHelper(uri);
let name = 'settings.screen.brightness33';
let name = 'settings.screen.brightness33';
let value = 'brightness33'
let value = 'brightness33'
try{
try{
settings.setValueSync(helper, name, value);
settings.setValueSync(helper, name, value);
settings.getValue(helper, name, ret =>{
settings.getValue(helper, name, ret =>{
console.info("[settings_get_value_033] value is: " + ret);
console.info("[settings_get_value_033] value is: " + ret);
expect(ret).assertEqual(value);
expect(ret).assertEqual(value);
done();
done();
})
})
} catch(err){
} catch(err){
console.info("[settings_get_value_033] error is: " + toString(error));
console.info("[settings_get_value_033] error is: " + toString(error));
expect(true).assertTrue();
expect(true).assertTrue();
done();
done();
return;
return;
}
}
});
});
it('settings_get_value_034', 0, async function (done){
it('settings_get_value_034', 0, async function (done){
let uri = 'dataability:///com.ohos.settingsdata.DataAbility';
let uri = 'dataability:///com.ohos.settingsdata.DataAbility';
let helper = featureAbility.acquireDataAbilityHelper(uri);
let helper = featureAbility.acquireDataAbilityHelper(uri);
let name = 'settings.screen.brightness34';
let name = 'settings.screen.brightness34';
let value = 'brightness34'
let value = 'brightness34'
try{
try{
settings.setValueSync(helper, name, value);
settings.setValueSync(helper, name, value);
settings.getValue(helper, name).then(ret =>{
settings.getValue(helper, name).then(ret =>{
console.info("[settings_get_value_034] value is: " + ret);
console.info("[settings_get_value_034] value is: " + ret);
expect(ret).assertEqual(value);
expect(ret).assertEqual(value);
done();
done();
})
})
} catch(err){
} catch(err){
console.info("[settings_get_value_034] error is: " + toString(error));
console.info("[settings_get_value_034] error is: " + toString(error));
expect(true).assertTrue();
expect(true).assertTrue();
done();
done();
return;
return;
}
}
});
});
it('settings_get_value_035', 0, async function (done){
it('settings_get_value_035', 0, async function (done){
var name = 'settings.screen.brightness35';
var name = 'settings.screen.brightness35';
let uriPrefix = 'dataability:///com.ohos.settingsdata.DataAbility'
let uriPrefix = 'dataability:///com.ohos.settingsdata.DataAbility'
let expectValue = uriPrefix + '/' + name;
let expectValue = uriPrefix + '/' + name;
try{
try{
settings.getURI(name).then(data => {
settings.getURI(name).then(data => {
console.info("[settings_get_uri_035] uri is: " + data);
console.info("[settings_get_uri_035] uri is: " + data);
expect(data).assertEqual(expectValue);
expect(data).assertEqual(expectValue);
done();
done();
})
})
} catch(err){
} catch(err){
console.info("[settings_get_uri_035] error is: " + toString(error));
console.info("[settings_get_uri_035] error is: " + toString(error));
expect(true).assertTrue();
expect(true).assertTrue();
done();
done();
return;
return;
}
}
});
});
it('settings_get_value_036', 0, async function (done){
it('settings_get_value_036', 0, async function (done){
var name = 'settings.screen.brightness36';
var name = 'settings.screen.brightness36';
let uriPrefix = 'dataability:///com.ohos.settingsdata.DataAbility'
let uriPrefix = 'dataability:///com.ohos.settingsdata.DataAbility'
let expectValue = uriPrefix + '/' + name;
let expectValue = uriPrefix + '/' + name;
try{
try{
settings.getURI(name, (data) =>{
settings.getURI(name, (data) =>{
console.info("[settings_get_uri_036] uri is: " + data);
console.info("[settings_get_uri_036] uri is: " + data);
expect(data).assertEqual(expectValue);
expect(data).assertEqual(expectValue);
done();
done();
})
})
}catch(err){
}catch(err){
console.info("[settings_get_uri_036] error is: " + toString(error));
console.info("[settings_get_uri_036] error is: " + toString(error));
expect(true).assertTrue();
expect(true).assertTrue();
done();
done();
return;
return;
}
}
});
});
it('settings_get_value_037',0,async function (done) {
it('settings_get_value_037',0,async function (done) {
var str ="settings.date.date_format"
var str ="settings.date.date_format"
expect(str).assertEqual(settings.date.DATE_FORMAT);
expect(str).assertEqual(settings.date.DATE_FORMAT);
done();
done();
});
});
it('settings_get_value_038',0,async function (done) {
it('settings_get_value_038',0,async function (done) {
var str ="settings.date.time_format"
var str ="settings.date.time_format"
expect(str).assertEqual(settings.date.TIME_FORMAT);
expect(str).assertEqual(settings.date.TIME_FORMAT);
done();
done();
});
});
it('settings_get_value_039',0,async function (done) {
it('settings_get_value_039',0,async function (done) {
var str ="settings.date.auto_gain_time"
var str ="settings.date.auto_gain_time"
expect(str).assertEqual(settings.date.AUTO_GAIN_TIME);
expect(str).assertEqual(settings.date.AUTO_GAIN_TIME);
done();
done();
});
});
it('settings_get_value_040',0,async function (done) {
it('settings_get_value_040',0,async function (done) {
var str ="settings.date.auto_gain_time_zone"
var str ="settings.date.auto_gain_time_zone"
expect(str).assertEqual(settings.date.AUTO_GAIN_TIME_ZONE);
expect(str).assertEqual(settings.date.AUTO_GAIN_TIME_ZONE);
done();
done();
});
});
it('settings_get_value_041',0,async function (done) {
it('settings_get_value_041',0,async function (done) {
var str ="settings.display.font_scale"
var str ="settings.display.font_scale"
expect(str).assertEqual(settings.display.FONT_SCALE);
expect(str).assertEqual(settings.display.FONT_SCALE);
done();
done();
});
});
it('settings_get_value_042',0,async function (done) {
it('settings_get_value_042',0,async function (done) {
var str ="settings.display.screen_brightness_status"
var str ="settings.display.screen_brightness_status"
expect(str).assertEqual(settings.display.SCREEN_BRIGHTNESS_STATUS);
expect(str).assertEqual(settings.display.SCREEN_BRIGHTNESS_STATUS);
done();
done();
});
});
it('settings_get_value_043',0,async function (done) {
it('settings_get_value_043',0,async function (done) {
var str ="settings.display.auto_screen_brightness"
var str ="settings.display.auto_screen_brightness"
expect(str).assertEqual(settings.display.AUTO_SCREEN_BRIGHTNESS);
expect(str).assertEqual(settings.display.AUTO_SCREEN_BRIGHTNESS);
done();
done();
});
});
it('settings_get_value_044',0,async function (done) {
it('settings_get_value_044',0,async function (done) {
var int = 1
var int = 1
expect(int).assertEqual(settings.display.AUTO_SCREEN_BRIGHTNESS_MODE);
expect(int).assertEqual(settings.display.AUTO_SCREEN_BRIGHTNESS_MODE);
done();
done();
});
});
it('settings_get_value_045',0,async function (done) {
it('settings_get_value_045',0,async function (done) {
var int = 0
var int = 0
expect(int).assertEqual(settings.display.MANUAL_SCREEN_BRIGHTNESS_MODE);
expect(int).assertEqual(settings.display.MANUAL_SCREEN_BRIGHTNESS_MODE);
done();
done();
});
});
it('settings_get_value_046',0,async function (done) {
it('settings_get_value_046',0,async function (done) {
var str ="settings.display.screen_off_timeout"
var str ="settings.display.screen_off_timeout"
expect(str).assertEqual(settings.display.SCREEN_OFF_TIMEOUT);
expect(str).assertEqual(settings.display.SCREEN_OFF_TIMEOUT);
done();
done();
});
});
it('settings_get_value_047',0,async function (done) {
it('settings_get_value_047',0,async function (done) {
var str ="settings.display.default_screen_rotation"
var str ="settings.display.default_screen_rotation"
expect(str).assertEqual(settings.display.DEFAULT_SCREEN_ROTATION);
expect(str).assertEqual(settings.display.DEFAULT_SCREEN_ROTATION);
done();
done();
});
});
it('settings_get_value_048',0,async function (done) {
it('settings_get_value_048',0,async function (done) {
var str ="settings.display.animator_duration_scale"
var str ="settings.display.animator_duration_scale"
expect(str).assertEqual(settings.display.ANIMATOR_DURATION_SCALE);
expect(str).assertEqual(settings.display.ANIMATOR_DURATION_SCALE);
done();
done();
});
});
it('settings_get_value_049',0,async function (done) {
it('settings_get_value_049',0,async function (done) {
var str ="settings.display.transition_animation_scale"
var str ="settings.display.transition_animation_scale"
expect(str).assertEqual(settings.display.TRANSITION_ANIMATION_SCALE);
expect(str).assertEqual(settings.display.TRANSITION_ANIMATION_SCALE);
done();
done();
});
});
it('settings_get_value_050',0,async function (done) {
it('settings_get_value_050',0,async function (done) {
var str ="settings.display.window_animation_scale"
var str ="settings.display.window_animation_scale"
expect(str).assertEqual(settings.display.WINDOW_ANIMATION_SCALE);
expect(str).assertEqual(settings.display.WINDOW_ANIMATION_SCALE);
done();
done();
});
});
it('settings_get_value_051',0,async function (done) {
it('settings_get_value_051',0,async function (done) {
var str = "settings.display.display_inversion_status"
var str = "settings.display.display_inversion_status"
expect(str).assertEqual(settings.display.DISPLAY_INVERSION_STATUS);
expect(str).assertEqual(settings.display.DISPLAY_INVERSION_STATUS);
done();
done();
});
});
it('settings_get_value_052',0,async function (done) {
it('settings_get_value_052',0,async function (done) {
var str = "settings.general.setup_wizard_finished"
var str = "settings.general.setup_wizard_finished"
expect(str).assertEqual(settings.general.SETUP_WIZARD_FINISHED);
expect(str).assertEqual(settings.general.SETUP_WIZARD_FINISHED);
done();
done();
});
});
it('settings_get_value_053',0,async function (done) {
it('settings_get_value_053',0,async function (done) {
var str = "settings.general.end_button_action"
var str = "settings.general.end_button_action"
expect(str).assertEqual(settings.general.END_BUTTON_ACTION);
expect(str).assertEqual(settings.general.END_BUTTON_ACTION);
done();
done();
});
});
it('settings_get_value_054',0,async function (done) {
it('settings_get_value_054',0,async function (done) {
var str = "settings.general.airplane_mode_status"
var str = "settings.general.airplane_mode_status"
expect(str).assertEqual(settings.general.AIRPLANE_MODE_STATUS);
expect(str).assertEqual(settings.general.AIRPLANE_MODE_STATUS);
done();
done();
});
});
it('settings_get_value_055',0,async function (done) {
it('settings_get_value_055',0,async function (done) {
var str = "settings.general.accelerometer_rotation_status"
var str = "settings.general.accelerometer_rotation_status"
expect(str).assertEqual(settings.general.ACCELEROMETER_ROTATION_STATUS);
expect(str).assertEqual(settings.general.ACCELEROMETER_ROTATION_STATUS);
done();
done();
});
});
it('settings_get_value_056',0,async function (done) {
it('settings_get_value_056',0,async function (done) {
var str = "settings.general.device_provision_status"
var str = "settings.general.device_provision_status"
expect(str).assertEqual(settings.general.DEVICE_PROVISION_STATUS);
expect(str).assertEqual(settings.general.DEVICE_PROVISION_STATUS);
done();
done();
});
});
it('settings_get_value_057',0,async function (done) {
it('settings_get_value_057',0,async function (done) {
var str = "settings.general.hdc_status"
var str = "settings.general.hdc_status"
expect(str).assertEqual(settings.general.HDC_STATUS);
expect(str).assertEqual(settings.general.HDC_STATUS);
done();
done();
});
});
it('settings_get_value_058',0,async function (done) {
it('settings_get_value_058',0,async function (done) {
var str = "settings.general.boot_counting"
var str = "settings.general.boot_counting"
expect(str).assertEqual(settings.general.BOOT_COUNTING);
expect(str).assertEqual(settings.general.BOOT_COUNTING);
done();
done();
});
});
it('settings_get_value_059',0,async function (done) {
it('settings_get_value_059',0,async function (done) {
var str = "settings.general.contact_metadata_sync_status"
var str = "settings.general.contact_metadata_sync_status"
expect(str).assertEqual(settings.general.CONTACT_METADATA_SYNC_STATUS);
expect(str).assertEqual(settings.general.CONTACT_METADATA_SYNC_STATUS);
done();
done();
});
});
it('settings_get_value_060',0,async function (done) {
it('settings_get_value_060',0,async function (done) {
var str = "settings.general.development_settings_status"
var str = "settings.general.development_settings_status"
expect(str).assertEqual(settings.general.DEVELOPMENT_SETTINGS_STATUS);
expect(str).assertEqual(settings.general.DEVELOPMENT_SETTINGS_STATUS);
done();
done();
});
});
it('settings_get_value_061',0,async function (done) {
it('settings_get_value_061',0,async function (done) {
var str = "settings.general.device_name"
var str = "settings.general.device_name"
expect(str).assertEqual(settings.general.DEVICE_NAME);
expect(str).assertEqual(settings.general.DEVICE_NAME);
done();
done();
});
});
it('settings_get_value_062',0,async function (done) {
it('settings_get_value_062',0,async function (done) {
var str = "settings.general.usb_storage_status"
var str = "settings.general.usb_storage_status"
expect(str).assertEqual(settings.general.USB_STORAGE_STATUS);
expect(str).assertEqual(settings.general.USB_STORAGE_STATUS);
done();
done();
});
});
it('settings_get_value_063',0,async function (done) {
it('settings_get_value_063',0,async function (done) {
var str = "settings.general.debugger_waiting"
var str = "settings.general.debugger_waiting"
expect(str).assertEqual(settings.general.DEBUGGER_WAITING);
expect(str).assertEqual(settings.general.DEBUGGER_WAITING);
done();
done();
});
});
it('settings_get_value_064',0,async function (done) {
it('settings_get_value_064',0,async function (done) {
var str = "settings.general.debug_app_package"
var str = "settings.general.debug_app_package"
expect(str).assertEqual(settings.general.DEBUG_APP_PACKAGE);
expect(str).assertEqual(settings.general.DEBUG_APP_PACKAGE);
done();
done();
});
});
it('settings_get_value_065',0,async function (done) {
it('settings_get_value_065',0,async function (done) {
var str = "settings.general.accessibility_status"
var str = "settings.general.accessibility_status"
expect(str).assertEqual(settings.general.ACCESSIBILITY_STATUS);
expect(str).assertEqual(settings.general.ACCESSIBILITY_STATUS);
done();
done();
});
});
it('settings_get_value_066',0,async function (done) {
it('settings_get_value_066',0,async function (done) {
var str = "settings.general.activated_accessibility_services"
var str = "settings.general.activated_accessibility_services"
expect(str).assertEqual(settings.general.ACTIVATED_ACCESSIBILITY_SERVICES);
expect(str).assertEqual(settings.general.ACTIVATED_ACCESSIBILITY_SERVICES);
done();
done();
});
});
it('settings_get_value_067',0,async function (done) {
it('settings_get_value_067',0,async function (done) {
var str = "settings.general.geolocation_origins_allowed"
var str = "settings.general.geolocation_origins_allowed"
expect(str).assertEqual(settings.general.GEOLOCATION_ORIGINS_ALLOWED);
expect(str).assertEqual(settings.general.GEOLOCATION_ORIGINS_ALLOWED);
done();
done();
});
});
it('settings_get_value_068',0,async function (done) {
it('settings_get_value_068',0,async function (done) {
var str = "settings.general.skip_use_hints"
var str = "settings.general.skip_use_hints"
expect(str).assertEqual(settings.general.SKIP_USE_HINTS);
expect(str).assertEqual(settings.general.SKIP_USE_HINTS);
done();
done();
});
});
it('settings_get_value_069',0,async function (done) {
it('settings_get_value_069',0,async function (done) {
var str = "settings.general.touch_exploration_status"
var str = "settings.general.touch_exploration_status"
expect(str).assertEqual(settings.general.TOUCH_EXPLORATION_STATUS);
expect(str).assertEqual(settings.general.TOUCH_EXPLORATION_STATUS);
done();
done();
});
});
it('settings_get_value_070',0,async function (done) {
it('settings_get_value_070',0,async function (done) {
var str = "settings.input.default_input_method"
var str = "settings.input.default_input_method"
expect(str).assertEqual(settings.input.DEFAULT_INPUT_METHOD);
expect(str).assertEqual(settings.input.DEFAULT_INPUT_METHOD);
done();
done();
});
});
it('settings_get_value_071',0,async function (done){
it('settings_get_value_071',0,async function (done){
var str = "settings.input.activated_input_method_submode"
var str = "settings.input.activated_input_method_submode"
let expectValue:string=settings.input.ACTIVATED_INPUT_METHOD_SUB_MODE;
let expectValue:string=settings.input.ACTIVATED_INPUT_METHOD_SUB_MODE;
expect(str).assertEqual(expectValue);
expect(str).assertEqual(expectValue);
done();
done();
});
});
it('settings_get_value_072',0,async function (done){
it('settings_get_value_072',0,async function (done){
var str = "settings.input.activated_input_methods"
var str = "settings.input.activated_input_methods"
expect(str).assertEqual(settings.input.ACTIVATED_INPUT_METHODS);
expect(str).assertEqual(settings.input.ACTIVATED_INPUT_METHODS);
done();
done();
});
});
it('settings_get_value_073',0,async function (done){
it('settings_get_value_073',0,async function (done){
var str = "settings.input.selector_visibility_for_input_method"
var str = "settings.input.selector_visibility_for_input_method"
expect(str).assertEqual(settings.input.SELECTOR_VISIBILITY_FOR_INPUT_METHOD);
expect(str).assertEqual(settings.input.SELECTOR_VISIBILITY_FOR_INPUT_METHOD);
done();
done();
});
});
it('settings_get_value_074',0,async function (done){
it('settings_get_value_074',0,async function (done){
var str = "settings.input.auto_caps_text_input"
var str = "settings.input.auto_caps_text_input"
expect(str).assertEqual(settings.input.AUTO_CAPS_TEXT_INPUT);
expect(str).assertEqual(settings.input.AUTO_CAPS_TEXT_INPUT);
done();
done();
});
});
it('settings_get_value_075',0,async function (done){
it('settings_get_value_075',0,async function (done){
var str = "settings.input.auto_punctuate_text_input"
var str = "settings.input.auto_punctuate_text_input"
expect(str).assertEqual(settings.input.AUTO_PUNCTUATE_TEXT_INPUT);
expect(str).assertEqual(settings.input.AUTO_PUNCTUATE_TEXT_INPUT);
done();
done();
});
});
it('settings_get_value_076',0,async function (done){
it('settings_get_value_076',0,async function (done){
var str = "settings.input.auto_replace_text_input"
var str = "settings.input.auto_replace_text_input"
expect(str).assertEqual(settings.input.AUTO_REPLACE_TEXT_INPUT);
expect(str).assertEqual(settings.input.AUTO_REPLACE_TEXT_INPUT);
done();
done();
});
});
it('settings_get_value_077',0,async function (done){
it('settings_get_value_077',0,async function (done){
var str = "settings.input.show_password_text_input"
var str = "settings.input.show_password_text_input"
expect(str).assertEqual(settings.input.SHOW_PASSWORD_TEXT_INPUT);
expect(str).assertEqual(settings.input.SHOW_PASSWORD_TEXT_INPUT);
done();
done();
});
});
it('settings_get_value_078',0,async function (done){
it('settings_get_value_078',0,async function (done){
var str = "settings.network.data_roaming_status"
var str = "settings.network.data_roaming_status"
expect(str).assertEqual(settings.network.DATA_ROAMING_STATUS);
expect(str).assertEqual(settings.network.DATA_ROAMING_STATUS);
done();
done();
});
});
it('settings_get_value_079',0,async function (done){
it('settings_get_value_079',0,async function (done){
var str = "settings.network.http_proxy_cfg"
var str = "settings.network.http_proxy_cfg"
expect(str).assertEqual(settings.network.HTTP_PROXY_CFG);
expect(str).assertEqual(settings.network.HTTP_PROXY_CFG);
done();
done();
});
});
it('settings_get_value_080',0,async function (done){
it('settings_get_value_080',0,async function (done){
var str = "settings.network.network_preference_usage"
var str = "settings.network.network_preference_usage"
expect(str).assertEqual(settings.network.NETWORK_PREFERENCE_USAGE);
expect(str).assertEqual(settings.network.NETWORK_PREFERENCE_USAGE);
done();
done();
});
});
it('settings_get_value_081',0,async function (done){
it('settings_get_value_081',0,async function (done){
var str = "settings.phone.rtt_calling_status"
var str = "settings.phone.rtt_calling_status"
expect(str).assertEqual(settings.phone.RTT_CALLING_STATUS);
expect(str).assertEqual(settings.phone.RTT_CALLING_STATUS);
done();
done();
});
});
it('settings_get_value_082',0,async function (done){
it('settings_get_value_082',0,async function (done){
var str = "settings.sound.vibrate_while_ringing"
var str = "settings.sound.vibrate_while_ringing"
expect(str).assertEqual(settings.sound.VIBRATE_WHILE_RINGING);
expect(str).assertEqual(settings.sound.VIBRATE_WHILE_RINGING);
done();
done();
});
});
it('settings_get_value_083',0,async function (done){
it('settings_get_value_083',0,async function (done){
var str = "settings.sound.default_alarm_alert"
var str = "settings.sound.default_alarm_alert"
expect(str).assertEqual(settings.sound.DEFAULT_ALARM_ALERT);
expect(str).assertEqual(settings.sound.DEFAULT_ALARM_ALERT);
done();
done();
});
});
it('settings_get_value_084',0,async function (done){
it('settings_get_value_084',0,async function (done){
var str = "settings.sound.dtmf_tone_type_while_dialing"
var str = "settings.sound.dtmf_tone_type_while_dialing"
expect(str).assertEqual(settings.sound.DTMF_TONE_TYPE_WHILE_DIALING);
expect(str).assertEqual(settings.sound.DTMF_TONE_TYPE_WHILE_DIALING);
done();
done();
});
});
it('settings_get_value_085',0,async function (done){
it('settings_get_value_085',0,async function (done){
var str = "settings.sound.dtmf_tone_while_dialing"
var str = "settings.sound.dtmf_tone_while_dialing"
expect(str).assertEqual(settings.sound.DTMF_TONE_WHILE_DIALING);
expect(str).assertEqual(settings.sound.DTMF_TONE_WHILE_DIALING);
done();
done();
});
});
it('settings_get_value_086',0,async function (done){
it('settings_get_value_086',0,async function (done){
var str = "settings.sound.haptic_feedback_status"
var str = "settings.sound.haptic_feedback_status"
expect(str).assertEqual(settings.sound.HAPTIC_FEEDBACK_STATUS);
expect(str).assertEqual(settings.sound.HAPTIC_FEEDBACK_STATUS);
done();
done();
});
});
it('settings_get_value_087',0,async function (done){
it('settings_get_value_087',0,async function (done){
var str = "settings.sound.affected_mode_ringer_streams"
var str = "settings.sound.affected_mode_ringer_streams"
expect(str).assertEqual(settings.sound.AFFECTED_MODE_RINGER_STREAMS);
expect(str).assertEqual(settings.sound.AFFECTED_MODE_RINGER_STREAMS);
done();
done();
});
});
it('settings_get_value_088',0,async function (done){
it('settings_get_value_088',0,async function (done){
var str = "settings.sound.affected_mute_streams"
var str = "settings.sound.affected_mute_streams"
expect(str).assertEqual(settings.sound.AFFECTED_MUTE_STREAMS);
expect(str).assertEqual(settings.sound.AFFECTED_MUTE_STREAMS);
done();
done();
});
});
it('settings_get_value_089',0,async function (done){
it('settings_get_value_089',0,async function (done){
var str = "settings.sound.default_notification_sound"
var str = "settings.sound.default_notification_sound"
expect(str).assertEqual(settings.sound.DEFAULT_NOTIFICATION_SOUND);
expect(str).assertEqual(settings.sound.DEFAULT_NOTIFICATION_SOUND);
done();
done();
});
});
it('settings_get_value_090',0,async function (done){
it('settings_get_value_090',0,async function (done){
var str = "settings.sound.default_ringtone"
var str = "settings.sound.default_ringtone"
expect(str).assertEqual(settings.sound.DEFAULT_RINGTONE);
expect(str).assertEqual(settings.sound.DEFAULT_RINGTONE);
done();
done();
});
});
it('settings_get_value_091',0,async function (done) {
it('settings_get_value_091',0,async function (done) {
var str ="settings.sound.sound_effects_status"
var str ="settings.sound.sound_effects_status"
expect(str).assertEqual(settings.sound.SOUND_EFFECTS_STATUS);
expect(str).assertEqual(settings.sound.SOUND_EFFECTS_STATUS);
done();
done();
});
});
it('settings_get_value_092',0,async function (done) {
it('settings_get_value_092',0,async function (done) {
var str ="settings.sound.vibrate_status"
var str ="settings.sound.vibrate_status"
expect(str).assertEqual(settings.sound.VIBRATE_STATUS);
expect(str).assertEqual(settings.sound.VIBRATE_STATUS);
done();
done();
});
});
it('settings_get_value_093',0,async function (done) {
it('settings_get_value_093',0,async function (done) {
var str ="settings.tts.default_tts_pitch"
var str ="settings.tts.default_tts_pitch"
expect(str).assertEqual(settings.tts.DEFAULT_TTS_PITCH);
expect(str).assertEqual(settings.tts.DEFAULT_TTS_PITCH);
done();
done();
});
});
it('settings_get_value_094',0,async function (done) {
it('settings_get_value_094',0,async function (done) {
var str ="settings.tts.default_tts_rate"
var str ="settings.tts.default_tts_rate"
expect(str).assertEqual(settings.tts.DEFAULT_TTS_RATE);
expect(str).assertEqual(settings.tts.DEFAULT_TTS_RATE);
done();
done();
});
});
it('settings_get_value_095',0,async function (done) {
it('settings_get_value_095',0,async function (done) {
var str ="settings.tts.default_tts_synth"
var str ="settings.tts.default_tts_synth"
expect(str).assertEqual(settings.tts.DEFAULT_TTS_SYNTH);
expect(str).assertEqual(settings.tts.DEFAULT_TTS_SYNTH);
done();
done();
});
});
it('settings_get_value_096',0,async function (done) {
it('settings_get_value_096',0,async function (done) {
var str ="settings.tts.enabled_tts_plugins"
var str ="settings.tts.enabled_tts_plugins"
expect(str).assertEqual(settings.tts.ENABLED_TTS_PLUGINS);
expect(str).assertEqual(settings.tts.ENABLED_TTS_PLUGINS);
done();
done();
});
});
it('settings_get_value_097',0,async function (done) {
it('settings_get_value_097',0,async function (done) {
var str ="settings.wireless.bluetooth_radio"
var str ="settings.wireless.bluetooth_radio"
expect(str).assertEqual(settings.wireless.BLUETOOTH_RADIO);
expect(str).assertEqual(settings.wireless.BLUETOOTH_RADIO);
done();
done();
});
});
it('settings_get_value_098',0,async function (done) {
it('settings_get_value_098',0,async function (done) {
var str ="settings.wireless.cell_radio"
var str ="settings.wireless.cell_radio"
expect(str).assertEqual(settings.wireless.CELL_RADIO);
expect(str).assertEqual(settings.wireless.CELL_RADIO);
done();
done();
});
});
it('settings_get_value_099',0,async function (done) {
it('settings_get_value_099',0,async function (done) {
var str ="settings.wireless.nfc_radio"
var str ="settings.wireless.nfc_radio"
expect(str).assertEqual(settings.wireless.NFC_RADIO);
expect(str).assertEqual(settings.wireless.NFC_RADIO);
done();
done();
});
});
it('settings_get_value_100',0,async function (done) {
it('settings_get_value_100',0,async function (done) {
var str ="settings.wireless.airplane_mode_radios"
var str ="settings.wireless.airplane_mode_radios"
expect(str).assertEqual(settings.wireless.AIRPLANE_MODE_RADIOS);
expect(str).assertEqual(settings.wireless.AIRPLANE_MODE_RADIOS);
done();
done();
});
});
it('settings_get_value_101',0,async function (done) {
it('settings_get_value_101',0,async function (done) {
var str ="settings.wireless.bluetooth_status"
var str ="settings.wireless.bluetooth_status"
expect(str).assertEqual(settings.wireless.BLUETOOTH_STATUS);
expect(str).assertEqual(settings.wireless.BLUETOOTH_STATUS);
done();
done();
});
});
it('settings_get_value_102',0,async function (done) {
it('settings_get_value_102',0,async function (done) {
var str ="settings.wireless.bluetooth_discoverability_status"
var str ="settings.wireless.bluetooth_discoverability_status"
expect(str).assertEqual(settings.wireless.BLUETOOTH_DISCOVER_ABILITY_STATUS);
expect(str).assertEqual(settings.wireless.BLUETOOTH_DISCOVER_ABILITY_STATUS);
done();
done();
});
});
it('settings_get_value_103',0,async function (done) {
it('settings_get_value_103',0,async function (done) {
var str ="settings.wireless.bluetooth_discover_timeout"
var str ="settings.wireless.bluetooth_discover_timeout"
expect(str).assertEqual(settings.wireless.BLUETOOTH_DISCOVER_TIMEOUT);
expect(str).assertEqual(settings.wireless.BLUETOOTH_DISCOVER_TIMEOUT);
done();
done();
});
});
it('settings_get_value_104',0,async function (done) {
it('settings_get_value_104',0,async function (done) {
var str ="settings.wireless.wifi_dhcp_max_retry_count"
var str ="settings.wireless.wifi_dhcp_max_retry_count"
expect(str).assertEqual(settings.wireless.WIFI_DHCP_MAX_RETRY_COUNT);
expect(str).assertEqual(settings.wireless.WIFI_DHCP_MAX_RETRY_COUNT);
done();
done();
});
});
it('settings_get_value_105',0,async function (done) {
it('settings_get_value_105',0,async function (done) {
var str ="settings.wireless.wifi_to_mobile_data_awake_timeout"
var str ="settings.wireless.wifi_to_mobile_data_awake_timeout"
expect(str).assertEqual(settings.wireless.WIFI_TO_MOBILE_DATA_AWAKE_TIMEOUT);
expect(str).assertEqual(settings.wireless.WIFI_TO_MOBILE_DATA_AWAKE_TIMEOUT);
done();
done();
});
});
it('settings_get_value_106',0,async function (done) {
it('settings_get_value_106',0,async function (done) {
var str ="settings.wireless.wifi_status"
var str ="settings.wireless.wifi_status"
expect(str).assertEqual(settings.wireless.WIFI_STATUS);
expect(str).assertEqual(settings.wireless.WIFI_STATUS);
done();
done();
});
});
it('settings_get_value_107',0,async function (done) {
it('settings_get_value_107',0,async function (done) {
var str ="settings.wireless.wifi_watchdog_status"
var str ="settings.wireless.wifi_watchdog_status"
expect(str).assertEqual(settings.wireless.WIFI_WATCHDOG_STATUS);
expect(str).assertEqual(settings.wireless.WIFI_WATCHDOG_STATUS);
done();
done();
});
});
it('settings_get_value_108',0,async function (done) {
it('settings_get_value_108',0,async function (done) {
var str ="settings.wireless.wifi_radio"
var str ="settings.wireless.wifi_radio"
expect(str).assertEqual(settings.wireless.WIFI_RADIO);
expect(str).assertEqual(settings.wireless.WIFI_RADIO);
done();
done();
});
});
it('settings_get_value_109',0,async function (done) {
it('settings_get_value_109',0,async function (done) {
var str ="settings.wireless.owner_lockdown_wifi_cfg"
var str ="settings.wireless.owner_lockdown_wifi_cfg"
expect(str).assertEqual(settings.wireless.OWNER_LOCKDOWN_WIFI_CFG);
expect(str).assertEqual(settings.wireless.OWNER_LOCKDOWN_WIFI_CFG);
done();
done();
});
});
it('settings_get_value_110',0,async function (done) {
it('settings_get_value_110',0,async function (done) {
var str ="settings.wireless.owner_lockdown_wifi_cfg"
var str ="settings.wireless.owner_lockdown_wifi_cfg"
expect(str).assertEqual(settings.wireless.OWNER_LOCKDOWN_WIFI_CFG);
expect(str).assertEqual(settings.wireless.OWNER_LOCKDOWN_WIFI_CFG);
done();
done();
});
});
it('settings_get_value_111',0,async function (done) {
it('settings_get_value_111',0,async function (done) {
let uri = 'dataability:///com.ohos.settingsdata.DataAbility';
let uri = 'dataability:///com.ohos.settingsdata.DataAbility';
let helper = featureAbility.acquireDataAbilityHelper(uri);
let helper = featureAbility.acquireDataAbilityHelper(uri);
let name = 'settings.screen.brightness111';//关键字
let name = 'settings.screen.brightness111';//关键字
let value = 'brightness111'//值
let value = 'brightness111'//值
try{
try{
settings.setValue(helper, name, value,(data)=>{
settings.setValue(helper, name, value,(data)=>{
console.info("[settings_get_value_111] value is:" + data);
console.info("[settings_get_value_111] value is:" + data);
settings.getValue(helper, name).then(ret => {
settings.getValue(helper, name).then(ret => {
console.info("[settings_get_value_111] value is:" + ret);
console.info("[settings_get_value_111] value is:" + ret);
expect(ret).assertEqual(value);
expect(ret).assertEqual(value);
done();
done();
})
})
});
});
}catch(err){
}catch(err){
console.info("[settings_get_value_111] error is:" + toString(error));
console.info("[settings_get_value_111] error is:" + toString(error));
expect(true).assertTrue();
expect(true).assertTrue();
done();
done();
return;
return;
}
}
});
});
it('settings_get_value_112',0,async function (done) {
it('settings_get_value_112',0,async function (done) {
let uri = 'dataability:///com.ohos.settingsdata.DataAbility';
let uri = 'dataability:///com.ohos.settingsdata.DataAbility';
let helper = featureAbility.acquireDataAbilityHelper(uri);
let helper = featureAbility.acquireDataAbilityHelper(uri);
let name = 'settings.screen.brightness112';//关键字
let name = 'settings.screen.brightness112';//关键字
let value = 'brightness112'//值
let value = 'brightness112'//值
try{
try{
settings.setValue(helper, name, value)
settings.setValue(helper, name, value)
.then((data)=>{
.then((data)=>{
console.info("[settings_get_value_112] value is:" + data);
console.info("[settings_get_value_112] value is:" + data);
settings.getValue(helper, name).then(ret => {
settings.getValue(helper, name).then(ret => {
console.info("[settings_get_value_112] value is:" + ret);
console.info("[settings_get_value_112] value is:" + ret);
expect(ret).assertEqual(value);
expect(ret).assertEqual(value);
done();
done();
})
})
})
})
.catch((err)=>{
.catch((err)=>{
console.info("[settings_get_value_112] error is:" + toString(error));
console.info("[settings_get_value_112] error is:" + toString(error));
expect(true).assertTrue();
expect(true).assertTrue();
done();
done();
return;
return;
})
})
}catch(err){
}catch(err){
console.info("[settings_get_value_112] error is:" + toString(error));
console.info("[settings_get_value_112] error is:" + toString(error));
expect(true).assertTrue();
expect(true).assertTrue();
done();
done();
return;
return;
}
}
});
});
})
})
}
}
settingsdata/settings_ets/entry/src/main/resources/base/element/string.json
→
applications/
settingsdata/settings_ets/entry/src/main/resources/base/element/string.json
浏览文件 @
22308402
{
{
"string"
:
[
"string"
:
[
{
{
"name"
:
"entry_MainAbility"
,
"name"
:
"entry_MainAbility"
,
"value"
:
"entry_MainAbility"
"value"
:
"entry_MainAbility"
},
},
{
{
"name"
:
"description_mainability"
,
"name"
:
"description_mainability"
,
"value"
:
"ETS_Empty Ability"
"value"
:
"ETS_Empty Ability"
},
},
{
{
"name"
:
"TestAbility_desc"
,
"name"
:
"TestAbility_desc"
,
"value"
:
"description"
"value"
:
"description"
},
},
{
{
"name"
:
"TestAbility_label"
,
"name"
:
"TestAbility_label"
,
"value"
:
"label"
"value"
:
"label"
}
}
]
]
}
}
\ No newline at end of file
settingsdata/settings_ets/entry/src/main/resources/base/media/icon.png
→
applications/
settingsdata/settings_ets/entry/src/main/resources/base/media/icon.png
浏览文件 @
22308402
文件已移动
settingsdata/settings_ets/signature/openharmony_sx.p7b
→
applications/
settingsdata/settings_ets/signature/openharmony_sx.p7b
浏览文件 @
22308402
无法预览此类型文件
test_packages.gni
浏览文件 @
22308402
...
@@ -47,6 +47,7 @@ _all_test_packages = [
...
@@ -47,6 +47,7 @@ _all_test_packages = [
"${ACTS_ROOT}/barrierfree:barrierfree",
"${ACTS_ROOT}/barrierfree:barrierfree",
"${ACTS_ROOT}/customization:customization",
"${ACTS_ROOT}/customization:customization",
"${ACTS_ROOT}/distributedschedule:systemabilitymgr",
"${ACTS_ROOT}/distributedschedule:systemabilitymgr",
"${ACTS_ROOT}/applications:applications",
]
]
_all_test_packages_ivi = [
_all_test_packages_ivi = [
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录