未验证 提交 28244f1b 编写于 作者: O openharmony_ci 提交者: Gitee

!2324 pick FD to 3.1 rls

Merge pull request !2324 from 杨清/cherry-pick-1646893082
......@@ -384,5 +384,35 @@ describe('resMgrTest', function () {
done();
})
/* *
* @tc.number SUB_GLOBAL_RESMGR_JS_2200
* @tc.name test closeRawFileDescriptor method in callback mode
* @tc.desc get the closeRawFileDescriptor in callback mode
*/
it('closeRawFileDescriptor_test_001', 0, async function (done) {
resmgr.getResourceManager((error, mgr) => {
mgr.closeRawFileDescriptor('rawfiletest.xml', (error, value) => {
expect(error == null).assertTrue();
console.log('closeRawFileDescriptor_test_001--' + error);
})
})
done();
})
/* *
* @tc.number SUB_GLOBAL_RESMGR_JS_2300
* @tc.name test closeRawFileDescriptor method in promise mode
* @tc.desc get the closeRawFileDescriptor in promise mode
*/
it('closeRawFileDescriptor_test_002', 0, async function (done) {
resmgr.getResourceManager((error, mgr) => {
mgr.closeRawFileDescriptor('rawfiletest.xml').then(value => {
expect(value !== null).assertTrue();
console.log('closeRawFileDescriptor_test_002--' + value);
})
})
done();
})
console.log('*************end ResmgrTest*************');
})
\ No newline at end of file
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册