Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
OpenHarmony
Xts Acts
提交
3f93c7ca
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看板
提交
3f93c7ca
编写于
3月 10, 2022
作者:
Z
zhangxingxia
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
update filemanager xts
Signed-off-by:
N
zhangxingxia
<
zhangxingxia1@huawei.com
>
上级
67ec76e5
变更
2
隐藏空白更改
内联
并排
Showing
2 changed file
with
22 addition
and
14 deletion
+22
-14
storage/storagefilemanagerjstest/Test.json
storage/storagefilemanagerjstest/Test.json
+10
-10
storage/storagefilemanagerjstest/src/main/js/default/test/filemanager.test.js
...anagerjstest/src/main/js/default/test/filemanager.test.js
+12
-4
未找到文件。
storage/storagefilemanagerjstest/Test.json
浏览文件 @
3f93c7ca
...
...
@@ -10,26 +10,26 @@
{
"type"
:
"ShellKit"
,
"run-command"
:
[
"mkdir /storage/media/100/local/files/photo"
,
"mkdir /storage/media/100/local/files/document"
,
"mkdir /storage/media/100/local/files/video"
,
"mkdir /storage/media/100/local/files/audio"
,
"mkdir /storage/media/100/local/files/photo/weixin"
,
"mkdir
-p
/storage/media/100/local/files/photo"
,
"mkdir
-p
/storage/media/100/local/files/document"
,
"mkdir
-p
/storage/media/100/local/files/video"
,
"mkdir
-p
/storage/media/100/local/files/audio"
,
"mkdir
-p
/storage/media/100/local/files/photo/weixin"
,
"touch /storage/media/100/local/files/photo/weixin/1.jpg"
,
"touch /storage/media/100/local/files/photo/weixin/2.jpg"
,
"touch /storage/media/100/local/files/photo/weixin/3.jpg"
,
"touch /storage/media/100/local/files/photo/weixin/1.mp3"
,
"touch /storage/media/100/local/files/photo/weixin/1.mp4"
,
"mkdir /storage/media/100/local/files/photo/taobao"
,
"mkdir
-p
/storage/media/100/local/files/photo/taobao"
,
"touch /storage/media/100/local/files/photo/taobao/1.mp4"
,
"mkdir /storage/media/100/local/files/taobao"
,
"mkdir
-p
/storage/media/100/local/files/taobao"
,
"touch /storage/media/100/local/files/taobao/1.jpg"
,
"mkdir /storage/media/100/local/files/image"
,
"mkdir
-p
/storage/media/100/local/files/image"
,
"touch /storage/media/100/local/files/image/1.jpg"
,
"touch /storage/media/100/local/files/image/2.jpg"
,
"mkdir /storage/media/100/local/files/alarms"
,
"mkdir
-p
/storage/media/100/local/files/alarms"
,
"touch /storage/media/100/local/files/alarms/tree.mp3"
,
"mkdir /storage/media/100/local/files/wps"
,
"mkdir
-p
/storage/media/100/local/files/wps"
,
"touch /storage/media/100/local/files/wps/news.pdf"
,
"touch /storage/media/100/local/files/wps/introduce.doc"
,
"killall com.ohos.medialibrary.MediaScannerAbilityA"
,
...
...
storage/storagefilemanagerjstest/src/main/js/default/test/filemanager.test.js
浏览文件 @
3f93c7ca
...
...
@@ -35,6 +35,7 @@ let FILE_ROOT = "";
let
AUDIO_ROOT
=
""
;
let
IMAGE_ALBUM
=
""
;
let
LOG_
=
"
FMS_XTS_TEXT:
"
;
let
LENGTH
=
0
;
describe
(
"
filemanager_test
"
,
function
()
{
/**
...
...
@@ -242,10 +243,16 @@ describe("filemanager_test", function () {
it
(
"
filemanager_test_list_file_async_002
"
,
0
,
async
function
(
done
)
{
try
{
let
path
=
FILE_ROOT
;
filemanager
.
listFile
(
path
,
"
file
"
,
function
(
error
,
fileInfos
){
expect
(
Array
.
isArray
(
fileInfos
)).
assertTrue
();
done
();
});
let
options
=
{
dev
:{
"
name
"
:
"
local
"
},
offset
:
0
};
let
fileInfos
=
await
filemanager
.
listFile
(
path
,
"
file
"
,
options
);
LENGTH
=
fileInfos
.
length
;
expect
(
Array
.
isArray
(
fileInfos
)).
assertTrue
();
done
();
}
catch
(
error
)
{
console
.
log
(
"
filemanager_test_list_file_async_002 has failed for
"
+
error
);
expect
(
null
).
assertFail
();
...
...
@@ -302,6 +309,7 @@ describe("filemanager_test", function () {
};
filemanager
.
listFile
(
path
,
"
file
"
,
options
,
function
(
error
,
fileInfos
){
expect
(
Array
.
isArray
(
fileInfos
)).
assertTrue
();
expect
(
fileInfos
.
length
==
LENGTH
-
2
).
assertTrue
();
done
();
});
}
catch
(
error
)
{
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录