提交 8270766c 编写于 作者: W wangtiantian

IssueNo:#I726M5

Description:fix zlib bug
Sig:SIG_ApplicaitonFramework
Feature or Bugfix:Bugfix
Binary Source:No
Signed-off-by: Nwangtiantian <wangtiantian19@huawei.com>
上级 5cbd7cdc
......@@ -1462,24 +1462,22 @@ export default function ActsZlibTest() {
strategy: null
}).then((data) => {
console.log("compressFileStrategyNull invalid src file success!");
expect().assertFail();
}).catch((err) => {
console.log("compressFileStrategyNull zipFile fail: " + JSON.stringify(err));
expect().assertFail();
})
} catch (err) {
expect(err.code).assertEqual(PARAM_ERROR);
expect().assertFail();
}
try {
zlib.compressFile(path1, zipDest1, {
strategy: null
}, (err, data) => {
console.log("compressFile result");
expect().assertFail();
done();
})
} catch (err) {
expect(err.code).assertEqual(PARAM_ERROR);
expect().assertFail();
done();
}
console.log("==================compressFileOutFileNull end==================");
......@@ -1926,25 +1924,24 @@ export default function ActsZlibTest() {
strategy: null
}).then(data => {
console.log("decompressFile data: " + data);
expect().assertFail();
}).catch(err => {
console.log("decompress fail: " + JSON.stringify(err));
expect().assertFail();
})
} catch (err) {
console.log("decompress fail: " + JSON.stringify(err));
expect(err.code).assertEqual(PARAM_ERROR);
expect().assertFail();
}
try {
zlib.decompressFile(zipDest1, unzipdir, {
strategy: null
}, (err, data) => {
expect().assertFail();
console.log("decompressFile data: " + data);
done();
})
} catch (err) {
console.log("decompress fail: " + JSON.stringify(err));
expect(err.code).assertEqual(PARAM_ERROR);
expect().assertFail();
done();
}
console.log("==================decompressFileStrategyNull end==================");
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册