Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
OpenHarmony
Xts Acts
提交
0b63da33
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看板
提交
0b63da33
编写于
9月 14, 2022
作者:
Y
y00314596
1
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
add by yangqing3@huawei.com
Signed-off-by:
N
y00314596
<
yangqing3@huawei.com
>
上级
917a5b2a
变更
7
隐藏空白更改
内联
并排
Showing
7 changed file
with
79 addition
and
80 deletion
+79
-80
global/global_napi_test/Test.json
global/global_napi_test/Test.json
+1
-0
global/i18n_standard/intljs/Test.json
global/i18n_standard/intljs/Test.json
+1
-0
global/i18n_standard/intljs/src/main/js/test/I18n.test.js
global/i18n_standard/intljs/src/main/js/test/I18n.test.js
+50
-50
global/i18n_standard/intljs/src/main/js/test/Lang.test.js
global/i18n_standard/intljs/src/main/js/test/Lang.test.js
+14
-19
global/perf/perfjs/Test.json
global/perf/perfjs/Test.json
+1
-0
global/perf/perfjs/src/main/js/test/Perf.test.js
global/perf/perfjs/src/main/js/test/Perf.test.js
+11
-11
global/resmgr_standard/resmgrjs/Test.json
global/resmgr_standard/resmgrjs/Test.json
+1
-0
未找到文件。
global/global_napi_test/Test.json
浏览文件 @
0b63da33
...
...
@@ -3,6 +3,7 @@
"driver"
:
{
"type"
:
"OHJSUnitTest"
,
"test-timeout"
:
"600000"
,
"testcase-timeout"
:
"300000"
,
"bundle-name"
:
"ohos.global.napitest"
,
"package-name"
:
"ohos.global.napitest"
,
"shell-timeout"
:
"600000"
...
...
global/i18n_standard/intljs/Test.json
浏览文件 @
0b63da33
...
...
@@ -3,6 +3,7 @@
"driver"
:
{
"type"
:
"OHJSUnitTest"
,
"test-timeout"
:
"300000"
,
"testcase-timeout"
:
"300000"
,
"shell-timeout"
:
"300000"
,
"bundle-name"
:
"ohos.intl.test"
,
"package-name"
:
"ohos.intl.test"
...
...
global/i18n_standard/intljs/src/main/js/test/I18n.test.js
浏览文件 @
0b63da33
...
...
@@ -1279,7 +1279,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_9100
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_9100
'
+
'
start
'
);
let
value
=
I18n
.
Util
.
unitConvert
({
unit
:
'
cup
'
,
measureSystem
:
'
US
'
},
let
value
=
I18n
.
I18N
Util
.
unitConvert
({
unit
:
'
cup
'
,
measureSystem
:
'
US
'
},
{
unit
:
'
liter
'
,
measureSystem
:
'
SI
'
},
1000
,
'
en-US
'
,
...
...
@@ -1295,7 +1295,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_9200
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_9200
'
+
'
start
'
);
let
value
=
I18n
.
Util
.
unitConvert
({
unit
:
'
cup
'
,
measureSystem
:
'
US
'
},
let
value
=
I18n
.
I18N
Util
.
unitConvert
({
unit
:
'
cup
'
,
measureSystem
:
'
US
'
},
{
unit
:
'
liter
'
,
measureSystem
:
'
SI
'
},
1000
,
'
en-US
'
,
...
...
@@ -1311,7 +1311,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_9250
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_9250
'
+
'
start
'
);
let
value
=
I18n
.
Util
.
unitConvert
({
unit
:
'
cup
'
,
measureSystem
:
'
US
'
},
let
value
=
I18n
.
I18N
Util
.
unitConvert
({
unit
:
'
cup
'
,
measureSystem
:
'
US
'
},
{
unit
:
'
liter
'
,
measureSystem
:
'
SI
'
},
1000
,
'
en-US
'
,
...
...
@@ -1327,7 +1327,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_9300
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_9300
'
+
'
start
'
);
let
value
=
I18n
.
Util
.
unitConvert
({
unit
:
'
cup
'
,
measureSystem
:
'
US
'
},
let
value
=
I18n
.
I18N
Util
.
unitConvert
({
unit
:
'
cup
'
,
measureSystem
:
'
US
'
},
{
unit
:
'
liter
'
,
measureSystem
:
'
SI
'
},
1000
,
'
en-US
'
,
...
...
@@ -1343,7 +1343,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_9400
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_9400
'
+
'
start
'
);
let
value
=
I18n
.
Util
.
unitConvert
({
unit
:
'
meter
'
,
measureSystem
:
'
SI
'
},
let
value
=
I18n
.
I18N
Util
.
unitConvert
({
unit
:
'
meter
'
,
measureSystem
:
'
SI
'
},
{
unit
:
'
mile
'
,
measureSystem
:
'
SI
'
},
1000
,
'
zh-CN
'
,
...
...
@@ -1359,7 +1359,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_9500
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_9500
'
+
'
start
'
);
let
value
=
I18n
.
Util
.
unitConvert
({
unit
:
'
hour
'
,
measureSystem
:
'
SI
'
},
let
value
=
I18n
.
I18N
Util
.
unitConvert
({
unit
:
'
hour
'
,
measureSystem
:
'
SI
'
},
{
unit
:
'
second
'
,
measureSystem
:
'
SI
'
},
10
,
'
zh-CN
'
,
...
...
@@ -1375,7 +1375,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_9600
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_9600
'
+
'
start
'
);
let
value
=
I18n
.
Util
.
unitConvert
({
unit
:
'
celsius
'
,
measureSystem
:
'
SI
'
},
let
value
=
I18n
.
I18N
Util
.
unitConvert
({
unit
:
'
celsius
'
,
measureSystem
:
'
SI
'
},
{
unit
:
'
fahrenheit
'
,
measureSystem
:
'
SI
'
},
1000
,
'
zh-CN
'
,
...
...
@@ -1391,7 +1391,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_9700
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_9700
'
+
'
start
'
);
let
value
=
I18n
.
Util
.
unitConvert
({
unit
:
'
acre
'
,
measureSystem
:
'
SI
'
},
let
value
=
I18n
.
I18N
Util
.
unitConvert
({
unit
:
'
acre
'
,
measureSystem
:
'
SI
'
},
{
unit
:
'
hectare
'
,
measureSystem
:
'
SI
'
},
1000
,
'
zh-CN
'
,
...
...
@@ -1407,7 +1407,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_9710
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_9710
'
+
'
start
'
);
let
value
=
I18n
.
Util
.
unitConvert
({
unit
:
'
acre
'
,
measureSystem
:
'
SI
'
},
let
value
=
I18n
.
I18N
Util
.
unitConvert
({
unit
:
'
acre
'
,
measureSystem
:
'
SI
'
},
{
unit
:
'
square-meter
'
,
measureSystem
:
'
SI
'
},
1000
,
'
zh-CN
'
,
...
...
@@ -1423,7 +1423,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_9800
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_9800
'
+
'
start
'
);
let
value
=
I18n
.
Util
.
unitConvert
({
unit
:
'
kilometer-per-hour
'
,
measureSystem
:
'
SI
'
},
let
value
=
I18n
.
I18N
Util
.
unitConvert
({
unit
:
'
kilometer-per-hour
'
,
measureSystem
:
'
SI
'
},
{
unit
:
'
knot
'
,
measureSystem
:
'
SI
'
},
1000
,
'
zh-CN
'
,
...
...
@@ -1439,7 +1439,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_9850
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_9850
'
+
'
start
'
);
let
value
=
I18n
.
Util
.
unitConvert
({
unit
:
'
kilometer-per-hour
'
,
measureSystem
:
'
SI
'
},
let
value
=
I18n
.
I18N
Util
.
unitConvert
({
unit
:
'
kilometer-per-hour
'
,
measureSystem
:
'
SI
'
},
{
unit
:
'
meter-per-second
'
,
measureSystem
:
'
SI
'
},
1000
,
'
zh-CN
'
,
...
...
@@ -1455,7 +1455,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_9900
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_9900
'
+
'
start
'
);
let
value
=
I18n
.
Util
.
unitConvert
({
unit
:
'
meter
'
,
measureSystem
:
'
SI
'
},
let
value
=
I18n
.
I18N
Util
.
unitConvert
({
unit
:
'
meter
'
,
measureSystem
:
'
SI
'
},
{
unit
:
'
kilometer
'
,
measureSystem
:
'
SI
'
},
1000
,
'
zh-CN
'
,
...
...
@@ -1471,7 +1471,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_9910
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_9910
'
+
'
start
'
);
let
value
=
I18n
.
Util
.
unitConvert
({
unit
:
'
meter
'
,
measureSystem
:
'
SI
'
},
let
value
=
I18n
.
I18N
Util
.
unitConvert
({
unit
:
'
meter
'
,
measureSystem
:
'
SI
'
},
{
unit
:
'
meter-per-second
'
,
measureSystem
:
'
SI
'
},
1000
,
'
zh-CN
'
,
...
...
@@ -1719,7 +1719,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_character_0100
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_character_0100
'
+
'
start
'
);
let
value
=
I18n
.
Character
.
isDigit
(
'
abc
'
);
let
value
=
I18n
.
Unicode
.
isDigit
(
'
abc
'
);
console
.
log
(
'
i18n_test_character_0100
'
+
value
);
expect
(
value
).
assertFalse
();
})
...
...
@@ -1731,7 +1731,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_character_0120
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_character_0120
'
+
'
start
'
);
let
value
=
I18n
.
Character
.
isDigit
(
'
123
'
);
let
value
=
I18n
.
Unicode
.
isDigit
(
'
123
'
);
console
.
log
(
'
i18n_test_character_0120
'
+
value
);
expect
(
value
).
assertTrue
();
})
...
...
@@ -1743,7 +1743,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_character_0140
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_character_0140
'
+
'
start
'
);
let
value
=
I18n
.
Character
.
isDigit
(
'
123abc
'
);
let
value
=
I18n
.
Unicode
.
isDigit
(
'
123abc
'
);
console
.
log
(
'
i18n_test_character_0140
'
+
value
);
expect
(
value
).
assertTrue
();
})
...
...
@@ -1755,7 +1755,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_character_0150
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_character_0150
'
+
'
start
'
);
let
value
=
I18n
.
Character
.
isDigit
(
'
abc123
'
);
let
value
=
I18n
.
Unicode
.
isDigit
(
'
abc123
'
);
console
.
log
(
'
i18n_test_character_0150
'
+
value
);
expect
(
value
).
assertFalse
();
})
...
...
@@ -1767,7 +1767,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_character_0160
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_character_0160
'
+
'
start
'
);
let
value
=
I18n
.
Character
.
isDigit
(
''
);
let
value
=
I18n
.
Unicode
.
isDigit
(
''
);
console
.
log
(
'
i18n_test_character_0160
'
+
value
);
expect
(
value
).
assertFalse
();
})
...
...
@@ -1779,7 +1779,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_character_0200
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_character_0200
'
+
'
start
'
);
let
value
=
I18n
.
Character
.
isSpaceChar
(
'
abc
'
);
let
value
=
I18n
.
Unicode
.
isSpaceChar
(
'
abc
'
);
console
.
log
(
'
i18n_test_character_0200
'
+
value
);
expect
(
value
).
assertFalse
();
})
...
...
@@ -1791,7 +1791,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_character_0220
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_character_0220
'
+
'
start
'
);
let
value
=
I18n
.
Character
.
isSpaceChar
(
'
'
);
let
value
=
I18n
.
Unicode
.
isSpaceChar
(
'
'
);
console
.
log
(
'
i18n_test_character_0220
'
+
value
);
expect
(
value
).
assertTrue
();
})
...
...
@@ -1803,7 +1803,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_character_0240
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_character_0240
'
+
'
start
'
);
let
value
=
I18n
.
Character
.
isSpaceChar
(
'
'
);
let
value
=
I18n
.
Unicode
.
isSpaceChar
(
'
'
);
console
.
log
(
'
i18n_test_character_0240--
'
+
value
+
'
--
'
);
expect
(
value
).
assertTrue
();
})
...
...
@@ -1815,7 +1815,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_character_0300
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_character_0300
'
+
'
start
'
);
let
value
=
I18n
.
Character
.
isWhitespace
(
'
abc
'
);
let
value
=
I18n
.
Unicode
.
isWhitespace
(
'
abc
'
);
console
.
log
(
'
i18n_test_character_0300
'
+
value
);
expect
(
value
).
assertFalse
();
})
...
...
@@ -1827,7 +1827,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_character_0320
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_character_0320
'
+
'
start
'
);
let
value
=
I18n
.
Character
.
isWhitespace
(
'
\
u0009
'
);
let
value
=
I18n
.
Unicode
.
isWhitespace
(
'
\
u0009
'
);
console
.
log
(
'
i18n_test_character_0320--
'
+
value
+
'
--
'
);
expect
(
value
).
assertTrue
();
})
...
...
@@ -1839,7 +1839,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_character_0400
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_character_0400
'
+
'
start
'
);
let
value
=
I18n
.
Character
.
isRTL
(
'
abc
'
);
let
value
=
I18n
.
Unicode
.
isRTL
(
'
abc
'
);
console
.
log
(
'
i18n_test_character_0400
'
+
value
);
expect
(
value
).
assertFalse
();
})
...
...
@@ -1851,7 +1851,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_character_0420
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_character_0420
'
+
'
start
'
);
let
value
=
I18n
.
Character
.
isRTL
(
'
١٢٣٤٥٦٧
'
);
let
value
=
I18n
.
Unicode
.
isRTL
(
'
١٢٣٤٥٦٧
'
);
console
.
log
(
'
i18n_test_character_0420
'
+
value
);
expect
(
value
).
assertFalse
();
})
...
...
@@ -1863,7 +1863,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_character_0440
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_character_0440
'
+
'
start
'
);
let
value
=
I18n
.
Character
.
isRTL
(
'
我是小明
'
);
let
value
=
I18n
.
Unicode
.
isRTL
(
'
我是小明
'
);
console
.
log
(
'
i18n_test_character_0440
'
+
value
);
expect
(
value
).
assertFalse
();
})
...
...
@@ -1875,7 +1875,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_character_0460
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_character_0460
'
+
'
start
'
);
let
value
=
I18n
.
Character
.
isRTL
(
'
نحن
'
);
let
value
=
I18n
.
Unicode
.
isRTL
(
'
نحن
'
);
console
.
log
(
'
i18n_test_character_0460
'
+
value
);
expect
(
value
).
assertTrue
();
})
...
...
@@ -1887,7 +1887,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_character_0500
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_character_0500
'
+
'
start
'
);
let
value
=
I18n
.
Character
.
isIdeograph
(
'
abc
'
);
let
value
=
I18n
.
Unicode
.
isIdeograph
(
'
abc
'
);
console
.
log
(
'
i18n_test_character_0500
'
+
value
);
expect
(
value
).
assertFalse
();
})
...
...
@@ -1899,7 +1899,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_character_0520
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_character_0520
'
+
'
start
'
);
let
value
=
I18n
.
Character
.
isIdeograph
(
'
我
'
);
let
value
=
I18n
.
Unicode
.
isIdeograph
(
'
我
'
);
console
.
log
(
'
i18n_test_character_0520
'
+
value
);
expect
(
value
).
assertTrue
();
})
...
...
@@ -1911,7 +1911,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_character_0540
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_character_0540
'
+
'
start
'
);
let
value
=
I18n
.
Character
.
isIdeograph
(
'
우리
'
);
let
value
=
I18n
.
Unicode
.
isIdeograph
(
'
우리
'
);
console
.
log
(
'
i18n_test_character_0540
'
+
value
);
expect
(
value
).
assertFalse
();
})
...
...
@@ -1923,7 +1923,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_character_0560
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_character_0560
'
+
'
start
'
);
let
value
=
I18n
.
Character
.
isIdeograph
(
'
私たち
'
);
let
value
=
I18n
.
Unicode
.
isIdeograph
(
'
私たち
'
);
console
.
log
(
'
i18n_test_character_0560
'
+
value
);
expect
(
value
).
assertTrue
();
})
...
...
@@ -1935,7 +1935,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_character_0600
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_character_0600
'
+
'
start
'
);
let
value
=
I18n
.
Character
.
isLetter
(
'
abc
'
);
let
value
=
I18n
.
Unicode
.
isLetter
(
'
abc
'
);
console
.
log
(
'
i18n_test_character_0600
'
+
value
);
expect
(
value
).
assertTrue
();
})
...
...
@@ -1947,7 +1947,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_character_0620
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_character_0620
'
+
'
start
'
);
let
value
=
I18n
.
Character
.
isLetter
(
'
123
'
);
let
value
=
I18n
.
Unicode
.
isLetter
(
'
123
'
);
console
.
log
(
'
i18n_test_character_0620
'
+
value
);
expect
(
value
).
assertFalse
();
})
...
...
@@ -1959,7 +1959,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_character_0640
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_character_0640
'
+
'
start
'
);
let
value
=
I18n
.
Character
.
isLetter
(
'
abc123
'
);
let
value
=
I18n
.
Unicode
.
isLetter
(
'
abc123
'
);
console
.
log
(
'
i18n_test_character_0640
'
+
value
);
expect
(
value
).
assertTrue
();
})
...
...
@@ -1971,7 +1971,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_character_0660
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_character_0660
'
+
'
start
'
);
let
value
=
I18n
.
Character
.
isLetter
(
'
123abc
'
);
let
value
=
I18n
.
Unicode
.
isLetter
(
'
123abc
'
);
console
.
log
(
'
i18n_test_character_0660
'
+
value
);
expect
(
value
).
assertFalse
();
})
...
...
@@ -1983,7 +1983,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_character_0700
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_character_0700
'
+
'
start
'
);
let
value
=
I18n
.
Character
.
isLowerCase
(
'
abc
'
);
let
value
=
I18n
.
Unicode
.
isLowerCase
(
'
abc
'
);
console
.
log
(
'
i18n_test_character_0700
'
+
value
);
expect
(
value
).
assertTrue
();
})
...
...
@@ -1995,7 +1995,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_character_0720
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_character_0720
'
+
'
start
'
);
let
value
=
I18n
.
Character
.
isLowerCase
(
'
ABC
'
);
let
value
=
I18n
.
Unicode
.
isLowerCase
(
'
ABC
'
);
console
.
log
(
'
i18n_test_character_0720
'
+
value
);
expect
(
value
).
assertFalse
();
})
...
...
@@ -2007,7 +2007,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_character_0740
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_character_0740
'
+
'
start
'
);
let
value
=
I18n
.
Character
.
isLowerCase
(
'
abcDEF
'
);
let
value
=
I18n
.
Unicode
.
isLowerCase
(
'
abcDEF
'
);
console
.
log
(
'
i18n_test_character_0740
'
+
value
);
expect
(
value
).
assertTrue
();
})
...
...
@@ -2019,7 +2019,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_character_0760
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_character_0760
'
+
'
start
'
);
let
value
=
I18n
.
Character
.
isLowerCase
(
'
ABCdef
'
);
let
value
=
I18n
.
Unicode
.
isLowerCase
(
'
ABCdef
'
);
console
.
log
(
'
i18n_test_character_0760
'
+
value
);
expect
(
value
).
assertFalse
();
})
...
...
@@ -2031,7 +2031,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_character_0800
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_character_0800
'
+
'
start
'
);
let
value
=
I18n
.
Character
.
isUpperCase
(
'
ABC
'
);
let
value
=
I18n
.
Unicode
.
isUpperCase
(
'
ABC
'
);
console
.
log
(
'
i18n_test_character_0800
'
+
value
);
expect
(
value
).
assertTrue
();
})
...
...
@@ -2043,7 +2043,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_character_0820
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_character_0820
'
+
'
start
'
);
let
value
=
I18n
.
Character
.
isUpperCase
(
'
abc
'
);
let
value
=
I18n
.
Unicode
.
isUpperCase
(
'
abc
'
);
console
.
log
(
'
i18n_test_character_0820
'
+
value
);
expect
(
value
).
assertFalse
();
})
...
...
@@ -2055,7 +2055,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_character_0840
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_character_0840
'
+
'
start
'
);
let
value
=
I18n
.
Character
.
isUpperCase
(
'
ABCdef
'
);
let
value
=
I18n
.
Unicode
.
isUpperCase
(
'
ABCdef
'
);
console
.
log
(
'
i18n_test_character_0840
'
+
value
);
expect
(
value
).
assertTrue
();
})
...
...
@@ -2067,7 +2067,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_character_0860
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_character_0860
'
+
'
start
'
);
let
value
=
I18n
.
Character
.
isUpperCase
(
'
abcDEF
'
);
let
value
=
I18n
.
Unicode
.
isUpperCase
(
'
abcDEF
'
);
console
.
log
(
'
i18n_test_character_0860
'
+
value
);
expect
(
value
).
assertFalse
();
})
...
...
@@ -2079,7 +2079,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_character_0900
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_character_0900
'
+
'
start
'
);
let
value
=
I18n
.
Character
.
getType
(
'
a
'
);
let
value
=
I18n
.
Unicode
.
getType
(
'
a
'
);
console
.
log
(
'
i18n_test_character_0900
'
+
value
);
expect
(
value
).
assertEqual
(
'
U_LOWERCASE_LETTER
'
);
})
...
...
@@ -2091,7 +2091,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_character_0920
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_character_0920
'
+
'
start
'
);
let
value
=
I18n
.
Character
.
getType
(
'
ABC
'
);
let
value
=
I18n
.
Unicode
.
getType
(
'
ABC
'
);
console
.
log
(
'
i18n_test_character_0920
'
+
value
);
expect
(
value
).
assertEqual
(
'
U_UPPERCASE_LETTER
'
);
})
...
...
@@ -2103,7 +2103,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_character_0940
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_character_0940
'
+
'
start
'
);
let
value
=
I18n
.
Character
.
getType
(
'
ABCdef
'
);
let
value
=
I18n
.
Unicode
.
getType
(
'
ABCdef
'
);
console
.
log
(
'
i18n_test_character_0940
'
+
value
);
expect
(
value
).
assertEqual
(
'
U_UPPERCASE_LETTER
'
);
})
...
...
@@ -2115,7 +2115,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_character_0960
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_character_0960
'
+
'
start
'
);
let
value
=
I18n
.
Character
.
getType
(
'
123
'
);
let
value
=
I18n
.
Unicode
.
getType
(
'
123
'
);
console
.
log
(
'
i18n_test_character_0960
'
+
value
);
expect
(
value
).
assertEqual
(
'
U_DECIMAL_DIGIT_NUMBER
'
);
})
...
...
@@ -2127,7 +2127,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_character_0970
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_character_0970
'
+
'
start
'
);
let
value
=
I18n
.
Character
.
getType
(
'
123abc
'
);
let
value
=
I18n
.
Unicode
.
getType
(
'
123abc
'
);
console
.
log
(
'
i18n_test_character_0970
'
+
value
);
expect
(
value
).
assertEqual
(
'
U_DECIMAL_DIGIT_NUMBER
'
);
})
...
...
@@ -2139,7 +2139,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_character_0980
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_character_0980
'
+
'
start
'
);
let
value
=
I18n
.
Character
.
getType
(
'
١٢٣٤٥٦٧
'
);
let
value
=
I18n
.
Unicode
.
getType
(
'
١٢٣٤٥٦٧
'
);
console
.
log
(
'
i18n_test_character_0980
'
+
value
);
expect
(
value
).
assertEqual
(
'
U_DECIMAL_DIGIT_NUMBER
'
);
})
...
...
@@ -2151,7 +2151,7 @@ describe('I18nTest', function () {
*/
it
(
'
i18n_test_character_0990
'
,
0
,
function
()
{
console
.
log
(
'
i18n_test_character_0990
'
+
'
start
'
);
let
value
=
I18n
.
Character
.
getType
(
'
'
);
let
value
=
I18n
.
Unicode
.
getType
(
'
'
);
console
.
log
(
'
i18n_test_character_0990
'
+
value
);
expect
(
value
).
assertEqual
(
'
U_SPACE_SEPARATOR
'
);
})
...
...
global/i18n_standard/intljs/src/main/js/test/Lang.test.js
浏览文件 @
0b63da33
...
...
@@ -89,7 +89,7 @@ describe('LangTest', function () {
console
.
log
(
'
i18n_test_clock_0100
'
+
'
start
'
);
let
value
=
I18n
.
is24HourClock
();
console
.
log
(
'
i18n_test_clock_0100
'
+
value
);
if
(
hour
)
if
(
value
)
{
expect
(
value
).
assertTrue
();
}
...
...
@@ -108,25 +108,21 @@ describe('LangTest', function () {
console
.
log
(
'
i18n_test_clock_0120
'
+
'
start
'
);
let
value
=
I18n
.
is24HourClock
();
console
.
log
(
'
i18n_test_clock_0120
'
+
value
);
if
(
hour
)
if
(
value
)
{
expect
(
value
).
assertTrue
();
value
=
I18n
.
set24HourClock
(
false
);
console
.
log
(
'
i18n_test_clock_0120
'
+
value
);
expect
(
value
).
assertTrue
();
value
=
I18n
.
set24HourClock
(
true
);
console
.
log
(
'
i18n_test_clock_0120
'
+
value
);
let
hourclock
=
I18n
.
set24HourClock
(
false
);
console
.
log
(
'
i18n_test_clock_0120
'
+
hourclock
);
hourclock
=
I18n
.
set24HourClock
(
true
);
console
.
log
(
'
i18n_test_clock_0120
'
+
hourclock
);
expect
(
value
).
assertTrue
();
}
else
{
let
hourclock
=
I18n
.
set24HourClock
(
true
);
console
.
log
(
'
i18n_test_clock_0120
'
+
hourclock
);
hourclock
=
I18n
.
set24HourClock
(
false
);
console
.
log
(
'
i18n_test_clock_0120
'
+
hourclock
);
expect
(
value
).
assertFalse
();
value
=
I18n
.
set24HourClock
(
true
);
console
.
log
(
'
i18n_test_clock_0120
'
+
value
);
expect
(
value
).
assertTrue
();
value
=
I18n
.
set24HourClock
(
false
);
console
.
log
(
'
i18n_test_clock_0120
'
+
value
);
expect
(
value
).
assertTrue
();
}
})
...
...
@@ -160,7 +156,6 @@ describe('LangTest', function () {
else
{
let
value
=
I18n
.
addPreferredLanguage
(
'
en-Latn-US
'
);
console
.
log
(
'
i18n_test_preferredlanguage_0120
'
+
value
);
expect
(
value
).
assertTrue
();
}
console
.
log
(
'
i18n_test_preferredlanguage_0120
'
+
I18n
.
getPreferredLanguageList
());
})
...
...
@@ -586,7 +581,7 @@ describe('LangTest', function () {
*/
it
(
'
dateorder_test_0100
'
,
0
,
function
()
{
console
.
log
(
'
dateorder_test_0100
'
+
'
start
'
);
let
value
=
I18n
.
Util
.
getDateOrder
(
'
zh
'
);
let
value
=
I18n
.
I18N
Util
.
getDateOrder
(
'
zh
'
);
console
.
log
(
'
dateorder_test_0100
'
+
value
);
expect
(
value
).
assertEqual
(
'
y-L-d
'
);
})
...
...
@@ -598,7 +593,7 @@ describe('LangTest', function () {
*/
it
(
'
dateorder_test_0200
'
,
0
,
function
()
{
console
.
log
(
'
dateorder_test_0200
'
+
'
start
'
);
let
value
=
I18n
.
Util
.
getDateOrder
(
'
en
'
);
let
value
=
I18n
.
I18N
Util
.
getDateOrder
(
'
en
'
);
console
.
log
(
'
dateorder_test_0200
'
+
value
);
expect
(
value
).
assertEqual
(
'
LLL-d-y
'
);
})
...
...
@@ -610,7 +605,7 @@ describe('LangTest', function () {
*/
it
(
'
dateorder_test_0300
'
,
0
,
function
()
{
console
.
log
(
'
dateorder_test_0300
'
+
'
start
'
);
let
value
=
I18n
.
Util
.
getDateOrder
(
'
th
'
);
let
value
=
I18n
.
I18N
Util
.
getDateOrder
(
'
th
'
);
console
.
log
(
'
dateorder_test_0300
'
+
value
);
expect
(
value
).
assertEqual
(
'
d-LLL-y
'
);
})
...
...
@@ -622,7 +617,7 @@ describe('LangTest', function () {
*/
it
(
'
dateorder_test_0400
'
,
0
,
function
()
{
console
.
log
(
'
dateorder_test_0400
'
+
'
start
'
);
let
value
=
I18n
.
Util
.
getDateOrder
(
'
jp
'
);
let
value
=
I18n
.
I18N
Util
.
getDateOrder
(
'
jp
'
);
console
.
log
(
'
dateorder_test_0400
'
+
value
);
expect
(
value
).
assertEqual
(
'
LLL-d-y
'
);
})
...
...
global/perf/perfjs/Test.json
浏览文件 @
0b63da33
...
...
@@ -3,6 +3,7 @@
"driver"
:
{
"type"
:
"OHJSUnitTest"
,
"test-timeout"
:
"300000"
,
"testcase-timeout"
:
"300000"
,
"shell-timeout"
:
"300000"
,
"bundle-name"
:
"ohos.perf.test"
,
"package-name"
:
"ohos.perf.test"
...
...
global/perf/perfjs/src/main/js/test/Perf.test.js
浏览文件 @
0b63da33
...
...
@@ -634,7 +634,7 @@ describe('PerfTest', function () {
let
value
=
'
test
'
;
let
startTime
=
new
Date
().
getTime
();
for
(
let
i
=
0
;
i
<
EXETIME
;
i
++
){
value
=
I18n
.
Util
.
unitConvert
({
unit
:
'
hour
'
,
measureSystem
:
'
SI
'
},
value
=
I18n
.
I18N
Util
.
unitConvert
({
unit
:
'
hour
'
,
measureSystem
:
'
SI
'
},
{
unit
:
'
second
'
,
measureSystem
:
'
SI
'
},
10
,
'
zh-CN
'
,
...
...
@@ -1068,7 +1068,7 @@ describe('PerfTest', function () {
let
value
=
false
;
let
startTime
=
new
Date
().
getTime
();
for
(
let
i
=
0
;
i
<
EXETIME
;
i
++
){
value
=
I18n
.
Character
.
isDigit
(
'
abc
'
);
value
=
I18n
.
Unicode
.
isDigit
(
'
abc
'
);
}
let
exeTime
=
new
Date
().
getTime
()
-
startTime
;
let
avgTime
=
exeTime
/
EXETIME
;
...
...
@@ -1094,7 +1094,7 @@ describe('PerfTest', function () {
let
value
=
false
;
let
startTime
=
new
Date
().
getTime
();
for
(
let
i
=
0
;
i
<
EXETIME
;
i
++
){
value
=
I18n
.
Character
.
isSpaceChar
(
'
abc
'
);
value
=
I18n
.
Unicode
.
isSpaceChar
(
'
abc
'
);
}
let
exeTime
=
new
Date
().
getTime
()
-
startTime
;
let
avgTime
=
exeTime
/
EXETIME
;
...
...
@@ -1121,7 +1121,7 @@ describe('PerfTest', function () {
let
value
=
false
;
let
startTime
=
new
Date
().
getTime
();
for
(
let
i
=
0
;
i
<
EXETIME
;
i
++
){
value
=
I18n
.
Character
.
isWhitespace
(
'
abc
'
);
value
=
I18n
.
Unicode
.
isWhitespace
(
'
abc
'
);
}
let
exeTime
=
new
Date
().
getTime
()
-
startTime
;
let
avgTime
=
exeTime
/
EXETIME
;
...
...
@@ -1147,7 +1147,7 @@ describe('PerfTest', function () {
let
value
=
false
;
let
startTime
=
new
Date
().
getTime
();
for
(
let
i
=
0
;
i
<
EXETIME
;
i
++
){
value
=
I18n
.
Character
.
isRTL
(
'
abc
'
);
value
=
I18n
.
Unicode
.
isRTL
(
'
abc
'
);
}
let
exeTime
=
new
Date
().
getTime
()
-
startTime
;
let
avgTime
=
exeTime
/
EXETIME
;
...
...
@@ -1173,7 +1173,7 @@ describe('PerfTest', function () {
let
value
=
false
;
let
startTime
=
new
Date
().
getTime
();
for
(
let
i
=
0
;
i
<
EXETIME
;
i
++
){
value
=
I18n
.
Character
.
isIdeograph
(
'
abc
'
);
value
=
I18n
.
Unicode
.
isIdeograph
(
'
abc
'
);
}
let
exeTime
=
new
Date
().
getTime
()
-
startTime
;
let
avgTime
=
exeTime
/
EXETIME
;
...
...
@@ -1199,7 +1199,7 @@ describe('PerfTest', function () {
let
value
=
false
;
let
startTime
=
new
Date
().
getTime
();
for
(
let
i
=
0
;
i
<
EXETIME
;
i
++
){
value
=
I18n
.
Character
.
isLetter
(
'
abc
'
);
value
=
I18n
.
Unicode
.
isLetter
(
'
abc
'
);
}
let
exeTime
=
new
Date
().
getTime
()
-
startTime
;
let
avgTime
=
exeTime
/
EXETIME
;
...
...
@@ -1225,7 +1225,7 @@ describe('PerfTest', function () {
let
value
=
false
;
let
startTime
=
new
Date
().
getTime
();
for
(
let
i
=
0
;
i
<
EXETIME
;
i
++
){
value
=
I18n
.
Character
.
isLowerCase
(
'
abc
'
);
value
=
I18n
.
Unicode
.
isLowerCase
(
'
abc
'
);
}
let
exeTime
=
new
Date
().
getTime
()
-
startTime
;
let
avgTime
=
exeTime
/
EXETIME
;
...
...
@@ -1251,7 +1251,7 @@ describe('PerfTest', function () {
let
value
=
false
;
let
startTime
=
new
Date
().
getTime
();
for
(
let
i
=
0
;
i
<
EXETIME
;
i
++
){
value
=
I18n
.
Character
.
isUpperCase
(
'
ABC
'
);
value
=
I18n
.
Unicode
.
isUpperCase
(
'
ABC
'
);
}
let
exeTime
=
new
Date
().
getTime
()
-
startTime
;
let
avgTime
=
exeTime
/
EXETIME
;
...
...
@@ -1277,7 +1277,7 @@ describe('PerfTest', function () {
let
value
=
'
test
'
;
let
startTime
=
new
Date
().
getTime
();
for
(
let
i
=
0
;
i
<
EXETIME
;
i
++
){
value
=
I18n
.
Character
.
getType
(
'
a
'
);
value
=
I18n
.
Unicode
.
getType
(
'
a
'
);
}
let
exeTime
=
new
Date
().
getTime
()
-
startTime
;
let
avgTime
=
exeTime
/
EXETIME
;
...
...
@@ -2101,7 +2101,7 @@ describe('PerfTest', function () {
let
value
=
'
test
'
;
let
startTime
=
new
Date
().
getTime
();
for
(
let
i
=
0
;
i
<
EXETIME
;
i
++
){
value
=
I18n
.
Util
.
getDateOrder
(
'
zh
'
);
value
=
I18n
.
I18N
Util
.
getDateOrder
(
'
zh
'
);
}
let
exeTime
=
new
Date
().
getTime
()
-
startTime
;
let
avgTime
=
exeTime
/
EXETIME
;
...
...
global/resmgr_standard/resmgrjs/Test.json
浏览文件 @
0b63da33
...
...
@@ -3,6 +3,7 @@
"driver"
:
{
"type"
:
"OHJSUnitTest"
,
"test-timeout"
:
"300000"
,
"testcase-timeout"
:
"300000"
,
"shell-timeout"
:
"60000"
,
"bundle-name"
:
"ohos.resmgr.test"
,
"package-name"
:
"ohos.resmgr.test"
...
...
鸿蒙社区
@harmonycommunity
mentioned in commit
81993fa3
·
9月 20, 2022
mentioned in commit
81993fa3
mentioned in commit 81993fa3da672c1591634de72c2af63fd4cd512d
开关提交列表
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录