Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
OpenHarmony
Xts Acts
提交
88a5e326
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看板
未验证
提交
88a5e326
编写于
3月 01, 2022
作者:
O
openharmony_ci
提交者:
Gitee
3月 01, 2022
浏览文件
操作
浏览文件
下载
差异文件
!2136 修复ActsAnsDoNotDisturbTest用例失败问题
Merge pull request !2136 from JayLeeHW/bugfix
上级
9259d716
a906e13a
变更
1
隐藏空白更改
内联
并排
Showing
1 changed file
with
159 addition
and
181 deletion
+159
-181
notification/ans_standard/publish_test/donotdisturbmode/entry/src/main/js/test/doNotDisturbTest.js
...notdisturbmode/entry/src/main/js/test/doNotDisturbTest.js
+159
-181
未找到文件。
notification/ans_standard/publish_test/donotdisturbmode/entry/src/main/js/test/doNotDisturbTest.js
浏览文件 @
88a5e326
...
...
@@ -117,15 +117,15 @@ describe('ActsAnsDoNotDisturbTest', function () {
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
}).
then
(
await
notify
.
getDoNotDisturbDate
().
then
((
data
)
=>
{
}).
then
(
()
=>
{
notify
.
getDoNotDisturbDate
().
then
((
data
)
=>
{
console
.
log
(
"
===>test_0400 getDoNotDisturbDate===>
"
+
JSON
.
stringify
(
data
));
expect
(
data
.
type
).
assertEqual
(
0
);
expect
(
data
.
begin
.
toString
()).
assertEqual
(
"
Thu Jan 01 1970 00:00:00 GMT+0000
"
);
expect
(
data
.
end
.
toString
()).
assertEqual
(
"
Thu Jan 01 1970 00:00:00 GMT+0000
"
);
done
();
})
)
}
)
})
/*
...
...
@@ -157,14 +157,13 @@ describe('ActsAnsDoNotDisturbTest', function () {
console
.
log
(
"
===>getDoNotDisturbDate DoNotDateE===>
"
+
DoNotDateE
)
console
.
log
(
"
===>getDoNotDisturbDate beginDate===>
"
+
data
.
begin
)
console
.
log
(
"
===>getDoNotDisturbDate endDate===>
"
+
data
.
end
)
expect
(
data
.
begin
.
toString
()).
assertEqual
(
DoNotDateE
);
expect
(
data
.
end
.
toString
()).
assertEqual
(
endDate
);
await
notify
.
setDoNotDisturbDate
(
{
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
})
expect
(
data
.
begin
.
toString
()).
assertEqual
(
DoNotDateE
.
toString
());
expect
(
data
.
end
.
toString
()).
assertEqual
(
endDate
.
toString
());
await
notify
.
setDoNotDisturbDate
({
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
});
done
();
})
})
...
...
@@ -186,8 +185,8 @@ describe('ActsAnsDoNotDisturbTest', function () {
type
:
notify
.
DoNotDisturbType
.
TYPE_ONCE
,
begin
:
beginDate
,
end
:
endDate
}).
then
(
notify
.
getDoNotDisturbDate
().
then
(
async
(
data
)
=>
{
}).
then
(
()
=>
{
notify
.
getDoNotDisturbDate
().
then
(
async
(
data
)
=>
{
console
.
log
(
"
===>test_0600 success===>
"
+
JSON
.
stringify
(
data
))
expect
(
data
.
type
).
assertEqual
(
1
);
var
DoNotDateF
=
new
Date
(
beginDate
.
getFullYear
(),
...
...
@@ -198,17 +197,16 @@ describe('ActsAnsDoNotDisturbTest', function () {
console
.
log
(
"
===>test_0600 begin===>
"
+
DoNotDateF
)
console
.
log
(
"
===>test_0600 beginDate===>
"
+
data
.
begin
)
console
.
log
(
"
===>test_0600 endDate===>
"
+
data
.
end
)
expect
(
data
.
begin
.
toString
()).
assertEqual
(
DoNotDateF
);
expect
(
data
.
end
.
toString
()).
assertEqual
(
endDate
);
await
notify
.
setDoNotDisturbDate
(
{
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
})
expect
(
data
.
begin
.
toString
()).
assertEqual
(
DoNotDateF
.
toString
());
expect
(
data
.
end
.
toString
()).
assertEqual
(
endDate
.
toString
());
await
notify
.
setDoNotDisturbDate
({
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
});
done
();
})
)
}
)
})
/*
...
...
@@ -240,14 +238,13 @@ describe('ActsAnsDoNotDisturbTest', function () {
console
.
log
(
"
===>0700 begin===>
"
+
DoNotDateG
)
console
.
log
(
"
===>0700 beginDate===>
"
+
data
.
begin
)
console
.
log
(
"
===>0700 endDate===>
"
+
data
.
end
)
expect
(
data
.
begin
.
toString
()).
assertEqual
(
DoNotDateG
);
expect
(
data
.
end
.
toString
()).
assertEqual
(
endDate
);
await
notify
.
setDoNotDisturbDate
(
{
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
})
expect
(
data
.
begin
.
toString
()).
assertEqual
(
DoNotDateG
.
toString
());
expect
(
data
.
end
.
toString
()).
assertEqual
(
endDate
.
toString
());
await
notify
.
setDoNotDisturbDate
({
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
});
done
();
})
})
...
...
@@ -271,8 +268,8 @@ describe('ActsAnsDoNotDisturbTest', function () {
type
:
notify
.
DoNotDisturbType
.
TYPE_DAILY
,
begin
:
beginDate
,
end
:
endDate
}).
then
(
notify
.
getDoNotDisturbDate
().
then
(
async
(
data
)
=>
{
}).
then
(
()
=>
{
notify
.
getDoNotDisturbDate
().
then
(
async
(
data
)
=>
{
console
.
log
(
"
===>test_0800 success===>
"
+
JSON
.
stringify
(
data
))
expect
(
data
.
type
).
assertEqual
(
2
);
var
DoNotDateH
=
new
Date
(
beginDate
.
getFullYear
(),
...
...
@@ -283,17 +280,16 @@ describe('ActsAnsDoNotDisturbTest', function () {
console
.
log
(
"
===>0800 begin===>
"
+
DoNotDateH
)
console
.
log
(
"
===>0800 beginDate===>
"
+
data
.
begin
)
console
.
log
(
"
===>0800 endDate===>
"
+
data
.
end
)
expect
(
data
.
begin
.
toString
()).
assertEqual
(
DoNotDateH
);
expect
(
data
.
end
.
toString
()).
assertEqual
(
endDate
);
await
notify
.
setDoNotDisturbDate
(
{
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
})
expect
(
data
.
begin
.
toString
()).
assertEqual
(
DoNotDateH
.
toString
());
expect
(
data
.
end
.
toString
()).
assertEqual
(
endDate
.
toString
());
await
notify
.
setDoNotDisturbDate
({
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
});
done
();
})
)
}
)
})
/*
...
...
@@ -325,14 +321,13 @@ describe('ActsAnsDoNotDisturbTest', function () {
console
.
log
(
"
===>test_0900 begin===>
"
+
DoNotDateI
)
console
.
log
(
"
===>test_0900 beginDate===>
"
+
data
.
begin
)
console
.
log
(
"
===>test_0900 endDate===>
"
+
data
.
end
)
expect
(
data
.
begin
.
toString
()).
assertEqual
(
DoNotDateI
);
expect
(
data
.
end
.
toString
()).
assertEqual
(
endDate
);
await
notify
.
setDoNotDisturbDate
(
{
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
})
expect
(
data
.
begin
.
toString
()).
assertEqual
(
DoNotDateI
.
toString
());
expect
(
data
.
end
.
toString
()).
assertEqual
(
endDate
.
toString
());
await
notify
.
setDoNotDisturbDate
({
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
});
done
();
})
})
...
...
@@ -356,8 +351,8 @@ describe('ActsAnsDoNotDisturbTest', function () {
type
:
notify
.
DoNotDisturbType
.
TYPE_CLEARLY
,
begin
:
beginDate
,
end
:
endDate
}).
then
(
notify
.
getDoNotDisturbDate
().
then
(
async
(
data
)
=>
{
}).
then
(
()
=>
{
notify
.
getDoNotDisturbDate
().
then
(
async
(
data
)
=>
{
console
.
log
(
"
===>test_1000 getDoNotDisturbDate===>
"
+
JSON
.
stringify
(
data
))
expect
(
data
.
type
).
assertEqual
(
3
);
var
DoNotDateJ
=
new
Date
(
beginDate
.
getFullYear
(),
...
...
@@ -368,17 +363,16 @@ describe('ActsAnsDoNotDisturbTest', function () {
console
.
log
(
"
===>test_1000 begin===>
"
+
DoNotDateJ
)
console
.
log
(
"
===>test_1000 beginDate===>
"
+
data
.
begin
)
console
.
log
(
"
===>test_1000 endDate===>
"
+
data
.
end
)
expect
(
data
.
begin
.
toString
()).
assertEqual
(
DoNotDateJ
);
expect
(
data
.
end
.
toString
()).
assertEqual
(
endDate
);
await
notify
.
setDoNotDisturbDate
(
{
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
})
expect
(
data
.
begin
.
toString
()).
assertEqual
(
DoNotDateJ
.
toString
());
expect
(
data
.
end
.
toString
()).
assertEqual
(
endDate
.
toString
());
await
notify
.
setDoNotDisturbDate
({
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
});
done
();
})
)
}
)
})
/*
...
...
@@ -405,14 +399,13 @@ describe('ActsAnsDoNotDisturbTest', function () {
beginDate
.
getDate
(),
beginDate
.
getHours
(),
beginDate
.
getMinutes
())
expect
(
data
.
begin
.
toString
()).
assertEqual
(
DoNotDateK
);
expect
(
data
.
end
.
toString
()).
assertEqual
(
DoNotDateK
);
await
notify
.
setDoNotDisturbDate
(
{
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
})
expect
(
data
.
begin
.
toString
()).
assertEqual
(
DoNotDateK
.
toString
());
expect
(
data
.
end
.
toString
()).
assertEqual
(
DoNotDateK
.
toString
());
await
notify
.
setDoNotDisturbDate
({
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
});
done
();
})
})
...
...
@@ -432,8 +425,8 @@ describe('ActsAnsDoNotDisturbTest', function () {
type
:
notify
.
DoNotDisturbType
.
TYPE_DAILY
,
begin
:
beginDate
,
end
:
endDate
}).
then
(
await
notify
.
getDoNotDisturbDate
(
async
(
err
,
data
)
=>
{
}).
then
(
()
=>
{
notify
.
getDoNotDisturbDate
(
async
(
err
,
data
)
=>
{
console
.
log
(
"
===>test_1200 getDoNotDisturbDate===>
"
+
err
.
code
+
JSON
.
stringify
(
data
));
expect
(
data
.
type
).
assertEqual
(
2
);
var
DoNotDateL
=
new
Date
(
beginDate
.
getFullYear
(),
...
...
@@ -441,24 +434,22 @@ describe('ActsAnsDoNotDisturbTest', function () {
beginDate
.
getDate
(),
beginDate
.
getHours
(),
beginDate
.
getMinutes
())
expect
(
data
.
begin
.
toString
()).
assertEqual
(
DoNotDateL
);
expect
(
data
.
end
.
toString
()).
assertEqual
(
DoNotDateL
);
await
notify
.
setDoNotDisturbDate
(
{
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
})
done
();
})
).
catch
(
async
(
err
)
=>
{
console
.
log
(
"
===>test_1200 getDoNotDisturbDate fail===>
"
+
JSON
.
stringify
(
err
))
await
notify
.
setDoNotDisturbDate
(
{
expect
(
data
.
begin
.
toString
()).
assertEqual
(
DoNotDateL
.
toString
());
expect
(
data
.
end
.
toString
()).
assertEqual
(
DoNotDateL
.
toString
());
await
notify
.
setDoNotDisturbDate
({
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
})
});
done
();
})
}).
catch
(
async
(
err
)
=>
{
console
.
log
(
"
===>test_1200 getDoNotDisturbDate fail===>
"
+
JSON
.
stringify
(
err
))
await
notify
.
setDoNotDisturbDate
({
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
});
done
();
})
})
...
...
@@ -491,14 +482,13 @@ describe('ActsAnsDoNotDisturbTest', function () {
beginDate
.
getDate
(),
beginDate
.
getHours
(),
beginDate
.
getMinutes
())
expect
(
data
.
begin
.
toString
()).
assertEqual
(
DoNotDateM
);
expect
(
data
.
end
.
toString
()).
assertEqual
(
endDate
);
await
notify
.
setDoNotDisturbDate
(
{
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
})
expect
(
data
.
begin
.
toString
()).
assertEqual
(
DoNotDateM
.
toString
());
expect
(
data
.
end
.
toString
()).
assertEqual
(
endDate
.
toString
());
await
notify
.
setDoNotDisturbDate
({
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
});
done
();
})
})
...
...
@@ -522,8 +512,8 @@ describe('ActsAnsDoNotDisturbTest', function () {
type
:
notify
.
DoNotDisturbType
.
TYPE_DAILY
,
begin
:
beginDate
,
end
:
endDate
}).
then
(
await
notify
.
getDoNotDisturbDate
(
async
(
err
,
data
)
=>
{
}).
then
(
()
=>
{
notify
.
getDoNotDisturbDate
(
async
(
err
,
data
)
=>
{
console
.
log
(
"
===>test_1400 getDoNotDisturbDate===>
"
+
err
.
code
+
JSON
.
stringify
(
data
))
expect
(
data
.
type
).
assertEqual
(
2
);
var
DoNotDateN
=
new
Date
(
beginDate
.
getFullYear
(),
...
...
@@ -531,24 +521,22 @@ describe('ActsAnsDoNotDisturbTest', function () {
beginDate
.
getDate
(),
beginDate
.
getHours
(),
beginDate
.
getMinutes
())
expect
(
data
.
begin
.
toString
()).
assertEqual
(
DoNotDateN
);
expect
(
data
.
end
.
toString
()).
assertEqual
(
endDate
);
await
notify
.
setDoNotDisturbDate
(
{
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
})
done
();
})
).
catch
(
async
(
err
)
=>
{
console
.
log
(
"
===>test_1400 getDoNotDisturbDate fail===>
"
+
JSON
.
stringify
(
err
))
await
notify
.
setDoNotDisturbDate
(
{
expect
(
data
.
begin
.
toString
()).
assertEqual
(
DoNotDateN
.
toString
());
expect
(
data
.
end
.
toString
()).
assertEqual
(
endDate
.
toString
());
await
notify
.
setDoNotDisturbDate
({
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
})
});
done
();
})
}).
catch
(
async
(
err
)
=>
{
console
.
log
(
"
===>test_1400 getDoNotDisturbDate fail===>
"
+
JSON
.
stringify
(
err
))
await
notify
.
setDoNotDisturbDate
({
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
});
done
();
})
})
...
...
@@ -570,12 +558,11 @@ describe('ActsAnsDoNotDisturbTest', function () {
},
async
(
err
)
=>
{
console
.
log
(
"
===>ActsSetDoNotDisturbTest_test_1500 success===>
"
+
err
.
code
);
expect
(
err
.
code
).
assertEqual
(
ERR_ANS_INVALID_PARAM
);
await
notify
.
setDoNotDisturbDate
(
{
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
})
await
notify
.
setDoNotDisturbDate
({
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
});
done
();
})
})
...
...
@@ -597,12 +584,11 @@ describe('ActsAnsDoNotDisturbTest', function () {
}).
then
().
catch
(
async
(
err
)
=>
{
console
.
log
(
"
===>test_1600 fail===>
"
+
JSON
.
stringify
(
err
));
expect
(
err
.
code
).
assertEqual
(
ERR_ANS_INVALID_PARAM
);
await
notify
.
setDoNotDisturbDate
(
{
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
})
await
notify
.
setDoNotDisturbDate
({
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
});
done
();
})
})
...
...
@@ -624,12 +610,11 @@ describe('ActsAnsDoNotDisturbTest', function () {
},
async
(
err
)
=>
{
console
.
log
(
"
===>test_1700 setDoNotDisturbDate===>
"
+
JSON
.
stringify
(
err
));
expect
(
err
.
code
).
assertEqual
(
ERR_ANS_INVALID_PARAM
);
await
notify
.
setDoNotDisturbDate
(
{
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
})
await
notify
.
setDoNotDisturbDate
({
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
});
done
();
})
})
...
...
@@ -651,12 +636,11 @@ describe('ActsAnsDoNotDisturbTest', function () {
}).
then
().
catch
(
async
(
err
)
=>
{
console
.
log
(
"
===>test_1800 setDoNotDisturbDate fail===>
"
+
JSON
.
stringify
(
err
))
expect
(
err
.
code
).
assertEqual
(
ERR_ANS_INVALID_PARAM
);
await
notify
.
setDoNotDisturbDate
(
{
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
})
await
notify
.
setDoNotDisturbDate
({
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
});
done
();
})
})
...
...
@@ -718,8 +702,8 @@ describe('ActsAnsDoNotDisturbTest', function () {
beginDate
.
getDate
(),
beginDate
.
getHours
(),
beginDate
.
getMinutes
())
expect
(
data
.
begin
.
toString
()).
assertEqual
(
DoNotDateO
);
expect
(
data
.
end
.
toString
()).
assertEqual
(
endDate
);
expect
(
data
.
begin
.
toString
()).
assertEqual
(
DoNotDateO
.
toString
()
);
expect
(
data
.
end
.
toString
()).
assertEqual
(
endDate
.
toString
()
);
await
notify
.
getDoNotDisturbDate
(
async
(
err
,
data
)
=>
{
console
.
log
(
"
===>test_2100 getDoNotDisturbDate===>
"
+
err
.
code
+
JSON
.
stringify
(
data
))
notify
.
unsubscribe
(
subInfo
,
unSubscribeCallbacka
);
...
...
@@ -729,14 +713,13 @@ describe('ActsAnsDoNotDisturbTest', function () {
beginDate
.
getDate
(),
beginDate
.
getHours
(),
beginDate
.
getMinutes
())
expect
(
data
.
begin
.
toString
()).
assertEqual
(
DoNotDateP
);
expect
(
data
.
end
.
toString
()).
assertEqual
(
endDate
);
await
notify
.
setDoNotDisturbDate
(
{
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
})
expect
(
data
.
begin
.
toString
()).
assertEqual
(
DoNotDateP
.
toString
());
expect
(
data
.
end
.
toString
()).
assertEqual
(
endDate
.
toString
());
await
notify
.
setDoNotDisturbDate
({
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
});
done
();
})
},
...
...
@@ -773,8 +756,8 @@ describe('ActsAnsDoNotDisturbTest', function () {
beginDate
.
getDate
(),
beginDate
.
getHours
(),
beginDate
.
getMinutes
())
expect
(
data
.
begin
.
toString
()).
assertEqual
(
DoNotDateQ
);
expect
(
data
.
end
.
toString
()).
assertEqual
(
endDate
);
expect
(
data
.
begin
.
toString
()).
assertEqual
(
DoNotDateQ
.
toString
()
);
expect
(
data
.
end
.
toString
()).
assertEqual
(
endDate
.
toString
()
);
await
notify
.
getDoNotDisturbDate
().
then
(
async
(
data
)
=>
{
console
.
log
(
"
===>test_2200 getDoNotDisturbDate===>
"
+
JSON
.
stringify
(
data
));
notify
.
unsubscribe
(
subInfo
,
unSubscribeCallbackb
);
...
...
@@ -784,14 +767,13 @@ describe('ActsAnsDoNotDisturbTest', function () {
beginDate
.
getDate
(),
beginDate
.
getHours
(),
beginDate
.
getMinutes
())
expect
(
data
.
begin
.
toString
()).
assertEqual
(
DoNotDateR
);
expect
(
data
.
end
.
toString
()).
assertEqual
(
endDate
);
await
notify
.
setDoNotDisturbDate
(
{
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
})
expect
(
data
.
begin
.
toString
()).
assertEqual
(
DoNotDateR
.
toString
());
expect
(
data
.
end
.
toString
()).
assertEqual
(
endDate
.
toString
());
await
notify
.
setDoNotDisturbDate
({
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
});
done
();
})
},
...
...
@@ -801,9 +783,9 @@ describe('ActsAnsDoNotDisturbTest', function () {
type
:
notify
.
DoNotDisturbType
.
TYPE_CLEARLY
,
begin
:
beginDate
,
end
:
endDate
}).
then
(
}).
then
(
()
=>
{
console
.
log
(
"
===>test_2200 setDoNotDisturbDate===>
"
)
)
}
)
})
/*
...
...
@@ -928,12 +910,11 @@ describe('ActsAnsDoNotDisturbTest', function () {
console
.
info
(
"
===test_2500 setTimeout===>
"
);
await
notify
.
unsubscribe
(
subscriber
);
console
.
info
(
"
===test_2500 setTimeout unsubscribe===>
"
);
await
notify
.
setDoNotDisturbDate
(
{
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
});
await
notify
.
setDoNotDisturbDate
({
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
});
console
.
info
(
"
====test_2500 setDoNotDisturbDate removeSlot============>
"
);
await
notify
.
removeSlot
(
notify
.
SlotType
.
SOCIAL_COMMUNICATION
);
console
.
info
(
"
====test_2500 setTimeout removeSlot============>
"
);
...
...
@@ -1030,12 +1011,11 @@ describe('ActsAnsDoNotDisturbTest', function () {
console
.
info
(
"
====test_2600 setTimeout unsubscribe====>
"
);
await
notify
.
removeSlot
(
notify
.
SlotType
.
SOCIAL_COMMUNICATION
);
console
.
info
(
"
====test_2600 setTimeout removeSlot============>
"
);
await
notify
.
setDoNotDisturbDate
(
{
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
})
await
notify
.
setDoNotDisturbDate
({
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
});
console
.
info
(
"
====test_2600 setTimeout setDoNotDisturbDate============>
"
);
done
();
}),
500
);
...
...
@@ -1130,12 +1110,11 @@ describe('ActsAnsDoNotDisturbTest', function () {
console
.
info
(
"
====test_2700 setTimeout unsubscribe============>
"
);
await
notify
.
removeSlot
(
notify
.
SlotType
.
SOCIAL_COMMUNICATION
);
console
.
info
(
"
====test_2700 setTimeout removeSlot============>
"
);
await
notify
.
setDoNotDisturbDate
(
{
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
})
await
notify
.
setDoNotDisturbDate
({
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
});
done
();
}),
500
);
})
...
...
@@ -1228,15 +1207,14 @@ describe('ActsAnsDoNotDisturbTest', function () {
await
notify
.
unsubscribe
(
subscriber
);
console
.
info
(
"
======test_2800 setTimeout unsubscribe============>
"
);
await
notify
.
removeSlot
(
notify
.
SlotType
.
SOCIAL_COMMUNICATION
);
await
notify
.
setDoNotDisturbDate
(
{
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
})
await
notify
.
setDoNotDisturbDate
({
type
:
notify
.
DoNotDisturbType
.
TYPE_NONE
,
begin
:
beginDate
,
end
:
endDate
});
done
();
}),
500
);
})
})
})
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录