Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
OpenHarmony
Xts Acts
提交
e61d11c3
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看板
提交
e61d11c3
编写于
2月 22, 2022
作者:
S
shikai-123
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Signed-off-by: shikai-123 <lifansheng1@huawei.com>
Modify test suite cannot test
上级
62fe177b
变更
2
隐藏空白更改
内联
并排
Showing
2 changed file
with
47 addition
and
46 deletion
+47
-46
compileruntime/util_lib_standard/src/main/js/test/ExampleJsunit.test.js
.../util_lib_standard/src/main/js/test/ExampleJsunit.test.js
+1
-1
compileruntime/util_lib_standard/src/main/js/test/util.test.js
...leruntime/util_lib_standard/src/main/js/test/util.test.js
+46
-45
未找到文件。
compileruntime/util_lib_standard/src/main/js/test/ExampleJsunit.test.js
浏览文件 @
e61d11c3
...
...
@@ -14,7 +14,7 @@
*/
import
app
from
'
@system.app
'
import
{
describe
,
beforeAll
,
beforeEach
,
afterEach
,
afterAll
,
it
,
expect
}
from
'
deccjsunit/
lite
'
import
{
describe
,
beforeAll
,
beforeEach
,
afterEach
,
afterAll
,
it
,
expect
}
from
'
deccjsunit/
index
'
describe
(
'
appInfoTest
'
,
function
()
{
it
(
'
app_info_test_001
'
,
0
,
function
()
{
...
...
compileruntime/util_lib_standard/src/main/js/test/util.test.js
浏览文件 @
e61d11c3
...
...
@@ -968,7 +968,8 @@ describe('ScopeTest', function () {
*/
it
(
'
testGetLower001
'
,
0
,
function
()
{
var
result
=
range
.
getLower
()
expect
(
result
).
assertEqual
(
30
)
console
.
info
(
'
testGetLower001 type
'
+
typeof
(
result
))
expect
(
result
.
toString
()).
assertEqual
(
'
30
'
)
})
/**
...
...
@@ -979,7 +980,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testGetLower002
'
,
0
,
function
()
{
var
result
=
rangeFir
.
getLower
()
expect
(
result
).
assertEqual
(
35
)
expect
(
result
.
toString
()).
assertEqual
(
'
35
'
)
})
/**
...
...
@@ -990,7 +991,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testGetLower003
'
,
0
,
function
()
{
var
result
=
rangeSec
.
getLower
()
expect
(
result
).
assertEqual
(
20
)
expect
(
result
.
toString
()).
assertEqual
(
'
20
'
)
})
/**
...
...
@@ -1001,7 +1002,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testGetLower004
'
,
0
,
function
()
{
var
result
=
rangeThi
.
getLower
()
expect
(
result
).
assertEqual
(
20
)
expect
(
result
.
toString
()).
assertEqual
(
'
20
'
)
})
/**
...
...
@@ -1012,7 +1013,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testGetLower005
'
,
0
,
function
()
{
var
result
=
rangeFif
.
getLower
()
expect
(
result
).
assertEqual
(
35
)
expect
(
result
.
toString
()).
assertEqual
(
'
35
'
)
})
/**
...
...
@@ -1023,7 +1024,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testGetUpper001
'
,
0
,
function
()
{
var
result
=
range
.
getUpper
()
expect
(
result
).
assertEqual
(
40
)
expect
(
result
.
toString
()).
assertEqual
(
'
40
'
)
})
/**
...
...
@@ -1034,7 +1035,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testGetUpper002
'
,
0
,
function
()
{
var
result
=
rangeFir
.
getUpper
()
expect
(
result
).
assertEqual
(
39
)
expect
(
result
.
toString
()).
assertEqual
(
'
39
'
)
})
/**
...
...
@@ -1045,7 +1046,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testGetUpper003
'
,
0
,
function
()
{
var
result
=
rangeSec
.
getUpper
()
expect
(
result
).
assertEqual
(
45
)
expect
(
result
.
toString
()).
assertEqual
(
'
45
'
)
})
/**
...
...
@@ -1056,7 +1057,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testGetUpper004
'
,
0
,
function
()
{
var
result
=
rangeThi
.
getUpper
()
expect
(
result
).
assertEqual
(
35
)
expect
(
result
.
toString
()).
assertEqual
(
'
35
'
)
})
/**
...
...
@@ -1067,7 +1068,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testGetUpper005
'
,
0
,
function
()
{
var
result
=
rangeFif
.
getUpper
()
expect
(
result
).
assertEqual
(
45
)
expect
(
result
.
toString
()).
assertEqual
(
'
45
'
)
})
/**
...
...
@@ -1078,7 +1079,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testClamp001
'
,
0
,
function
()
{
var
result
=
range
.
clamp
(
tempLess
)
expect
(
result
).
assertEqual
(
30
)
expect
(
result
.
toString
()).
assertEqual
(
'
30
'
)
})
/**
...
...
@@ -1089,7 +1090,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testClamp002
'
,
0
,
function
()
{
var
result
=
range
.
clamp
(
tempMiDF
)
expect
(
result
).
assertEqual
(
35
)
expect
(
result
.
toString
()).
assertEqual
(
'
35
'
)
})
/**
...
...
@@ -1100,7 +1101,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testClamp003
'
,
0
,
function
()
{
var
result
=
range
.
clamp
(
tempMore
)
expect
(
result
).
assertEqual
(
40
)
expect
(
result
.
toString
()).
assertEqual
(
'
40
'
)
})
/**
...
...
@@ -1111,7 +1112,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testClamp004
'
,
0
,
function
()
{
var
result
=
range
.
clamp
(
tempLower
)
expect
(
result
).
assertEqual
(
30
)
expect
(
result
.
toString
()).
assertEqual
(
'
30
'
)
})
/**
...
...
@@ -1122,7 +1123,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testClamp005
'
,
0
,
function
()
{
var
result
=
range
.
clamp
(
tempUpper
)
expect
(
result
).
assertEqual
(
40
)
expect
(
result
.
toString
()).
assertEqual
(
'
40
'
)
})
/**
...
...
@@ -1243,7 +1244,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testExpand001
'
,
0
,
function
()
{
var
result
=
range
.
expand
(
tempMiDF
,
tempMidS
)
expect
(
result
).
assertEqual
(
'
[30, 40]
'
)
expect
(
result
.
toString
()
).
assertEqual
(
'
[30, 40]
'
)
})
/**
...
...
@@ -1254,7 +1255,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testExpand002
'
,
0
,
function
()
{
var
result
=
range
.
expand
(
tempLess
,
tempMore
)
expect
(
result
).
assertEqual
(
'
[20, 45]
'
)
expect
(
result
.
toString
()
).
assertEqual
(
'
[20, 45]
'
)
})
/**
...
...
@@ -1265,7 +1266,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testExpand003
'
,
0
,
function
()
{
var
result
=
range
.
expand
(
tempLess
,
tempMiDF
)
expect
(
result
).
assertEqual
(
'
[20, 40]
'
)
expect
(
result
.
toString
()
).
assertEqual
(
'
[20, 40]
'
)
})
/**
...
...
@@ -1276,7 +1277,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testExpand004
'
,
0
,
function
()
{
var
result
=
range
.
expand
(
tempMiDF
,
tempMore
)
expect
(
result
).
assertEqual
(
'
[30, 45]
'
)
expect
(
result
.
toString
()
).
assertEqual
(
'
[30, 45]
'
)
})
/**
...
...
@@ -1287,7 +1288,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testExpand005
'
,
0
,
function
()
{
var
result
=
range
.
expand
(
tempLower
,
tempUpper
)
expect
(
result
).
assertEqual
(
'
[30, 40]
'
)
expect
(
result
.
toString
()
).
assertEqual
(
'
[30, 40]
'
)
})
/**
...
...
@@ -1298,7 +1299,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testExpand001
'
,
0
,
function
()
{
var
result
=
range
.
expand
(
rangeFir
)
expect
(
result
).
assertEqual
(
'
[30, 40]
'
)
expect
(
result
.
toString
()
).
assertEqual
(
'
[30, 40]
'
)
})
/**
...
...
@@ -1309,7 +1310,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testExpand002
'
,
0
,
function
()
{
var
result
=
range
.
expand
(
rangeSec
)
expect
(
result
).
assertEqual
(
'
[20, 45]
'
)
expect
(
result
.
toString
()
).
assertEqual
(
'
[20, 45]
'
)
})
/**
...
...
@@ -1320,7 +1321,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testExpand003
'
,
0
,
function
()
{
var
result
=
range
.
expand
(
rangeThi
)
expect
(
result
).
assertEqual
(
'
[20, 40]
'
)
expect
(
result
.
toString
()
).
assertEqual
(
'
[20, 40]
'
)
})
/**
...
...
@@ -1331,7 +1332,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testExpand004
'
,
0
,
function
()
{
var
result
=
range
.
expand
(
rangeFif
)
expect
(
result
).
assertEqual
(
'
[30, 45]
'
)
expect
(
result
.
toString
()
).
assertEqual
(
'
[30, 45]
'
)
})
/**
...
...
@@ -1342,7 +1343,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testExpand005
'
,
0
,
function
()
{
var
result
=
range
.
expand
(
range
)
expect
(
result
).
assertEqual
(
'
[30, 40]
'
)
expect
(
result
.
toString
()
).
assertEqual
(
'
[30, 40]
'
)
})
/**
...
...
@@ -1353,7 +1354,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testExpand001
'
,
0
,
function
()
{
var
result
=
range
.
expand
(
tempMiDF
)
expect
(
result
).
assertEqual
(
'
[30, 40]
'
)
expect
(
result
.
toString
()
).
assertEqual
(
'
[30, 40]
'
)
})
/**
...
...
@@ -1364,7 +1365,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testExpand002
'
,
0
,
function
()
{
var
result
=
range
.
expand
(
tempLess
)
expect
(
result
).
assertEqual
(
'
[20, 40]
'
)
expect
(
result
.
toString
()
).
assertEqual
(
'
[20, 40]
'
)
})
/**
...
...
@@ -1375,7 +1376,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testExpand003
'
,
0
,
function
()
{
var
result
=
range
.
expand
(
tempMore
)
expect
(
result
).
assertEqual
(
'
[30, 45]
'
)
expect
(
result
.
toString
()
).
assertEqual
(
'
[30, 45]
'
)
})
/**
...
...
@@ -1386,7 +1387,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testExpand004
'
,
0
,
function
()
{
var
result
=
range
.
expand
(
tempLower
)
expect
(
result
).
assertEqual
(
'
[30, 40]
'
)
expect
(
result
.
toString
()
).
assertEqual
(
'
[30, 40]
'
)
})
/**
...
...
@@ -1397,7 +1398,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testExpand005
'
,
0
,
function
()
{
var
result
=
range
.
expand
(
tempUpper
)
expect
(
result
).
assertEqual
(
'
[30, 40]
'
)
expect
(
result
.
toString
()
).
assertEqual
(
'
[30, 40]
'
)
})
/**
...
...
@@ -1408,7 +1409,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testInstersect001
'
,
0
,
function
()
{
var
result
=
range
.
intersect
(
rangeFir
)
expect
(
result
).
assertEqual
(
'
[35, 39]
'
)
expect
(
result
.
toString
()
).
assertEqual
(
'
[35, 39]
'
)
})
/**
...
...
@@ -1419,7 +1420,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testInstersect002
'
,
0
,
function
()
{
var
result
=
range
.
intersect
(
rangeSec
)
expect
(
result
).
assertEqual
(
'
[30, 40]
'
)
expect
(
result
.
toString
()
).
assertEqual
(
'
[30, 40]
'
)
})
/**
...
...
@@ -1430,7 +1431,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testInstersect003
'
,
0
,
function
()
{
var
result
=
range
.
intersect
(
rangeThi
)
expect
(
result
).
assertEqual
(
'
[30, 35]
'
)
expect
(
result
.
toString
()
).
assertEqual
(
'
[30, 35]
'
)
})
/**
...
...
@@ -1441,7 +1442,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testInstersect004
'
,
0
,
function
()
{
var
result
=
range
.
intersect
(
rangeFif
)
expect
(
result
).
assertEqual
(
'
[35, 40]
'
)
expect
(
result
.
toString
()
).
assertEqual
(
'
[35, 40]
'
)
})
/**
...
...
@@ -1452,7 +1453,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testInstersect005
'
,
0
,
function
()
{
var
result
=
range
.
intersect
(
range
)
expect
(
result
).
assertEqual
(
'
[30, 40]
'
)
expect
(
result
.
toString
()
).
assertEqual
(
'
[30, 40]
'
)
})
/**
...
...
@@ -1464,7 +1465,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testInstersect001
'
,
0
,
function
()
{
var
result
=
range
.
intersect
(
tempMiDF
,
tempMidS
)
expect
(
result
).
assertEqual
(
'
[35, 39]
'
)
expect
(
result
.
toString
()
).
assertEqual
(
'
[35, 39]
'
)
})
/**
...
...
@@ -1476,7 +1477,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testInstersect002
'
,
0
,
function
()
{
var
result
=
range
.
intersect
(
tempLess
,
tempMore
)
expect
(
result
).
assertEqual
(
'
[30, 40]
'
)
expect
(
result
.
toString
()
).
assertEqual
(
'
[30, 40]
'
)
})
/**
...
...
@@ -1488,7 +1489,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testInstersect003
'
,
0
,
function
()
{
var
result
=
range
.
intersect
(
tempLess
,
tempMiDF
)
expect
(
result
).
assertEqual
(
'
[30, 35]
'
)
expect
(
result
.
toString
()
).
assertEqual
(
'
[30, 35]
'
)
})
/**
...
...
@@ -1500,7 +1501,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testInstersect004
'
,
0
,
function
()
{
var
result
=
range
.
intersect
(
tempMiDF
,
tempMore
)
expect
(
result
).
assertEqual
(
'
[35, 40]
'
)
expect
(
result
.
toString
()
).
assertEqual
(
'
[35, 40]
'
)
})
/**
...
...
@@ -1512,7 +1513,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testInstersect005
'
,
0
,
function
()
{
var
result
=
range
.
intersect
(
tempLower
,
tempUpper
)
expect
(
result
).
assertEqual
(
'
[30, 40]
'
)
expect
(
result
.
toString
()
).
assertEqual
(
'
[30, 40]
'
)
})
/**
...
...
@@ -1523,7 +1524,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testToString001
'
,
0
,
function
()
{
var
result
=
range
.
toString
()
expect
(
result
).
assertEqual
(
'
[30, 40]
'
)
expect
(
result
.
toString
()
).
assertEqual
(
'
[30, 40]
'
)
})
/**
...
...
@@ -1534,7 +1535,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testToString002
'
,
0
,
function
()
{
var
result
=
rangeFir
.
toString
()
expect
(
result
).
assertEqual
(
'
[35, 39]
'
)
expect
(
result
.
toString
()
).
assertEqual
(
'
[35, 39]
'
)
})
/**
...
...
@@ -1545,7 +1546,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testToString003
'
,
0
,
function
()
{
var
result
=
rangeSec
.
toString
()
expect
(
result
).
assertEqual
(
'
[20, 45]
'
)
expect
(
result
.
toString
()
).
assertEqual
(
'
[20, 45]
'
)
})
/**
...
...
@@ -1556,7 +1557,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testToString004
'
,
0
,
function
()
{
var
result
=
rangeThi
.
toString
()
expect
(
result
).
assertEqual
(
'
[20, 35]
'
)
expect
(
result
.
toString
()
).
assertEqual
(
'
[20, 35]
'
)
})
/**
...
...
@@ -1567,7 +1568,7 @@ describe('ScopeTest', function () {
*/
it
(
'
testToString005
'
,
0
,
function
()
{
var
result
=
rangeFif
.
toString
()
expect
(
result
).
assertEqual
(
'
[35, 45]
'
)
expect
(
result
.
toString
()
).
assertEqual
(
'
[35, 45]
'
)
})
})
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录