Test.json 4.5 KB
Newer Older
G
gudehe 已提交
1 2 3 4
{
    "description": "Configuration for mediaLibrary Tests",
    "driver": {
        "type": "JSUnitTest",
P
panqiangbiao 已提交
5
        "test-timeout": "600000",
G
gudehe 已提交
6
        "package": "ohos.acts.multimedia.mediaLibrary",
P
panqiangbiao 已提交
7
        "shell-timeout": "600000"
G
gudehe 已提交
8 9
    },
    "kits": [
J
JH C 已提交
10 11 12 13 14 15
        {
            "type": "ShellKit",
            "pre-push": [
            ],
            "run-command": [
                "rm -rf /storage/media/100/local/files/*",
P
panqiangbiao 已提交
16
                "rm -rf /data/accounts/account_0/appdata/com.ohos.medialibrary.medialibrarydata/*",
J
JH C 已提交
17
                "mkdir -pv /storage/media/100/local/files/{Pictures,Videos,Audios,Documents}",
P
panqiangbiao 已提交
18
                "mkdir -p /data/accounts/account_0/appdata/com.ohos.medialibrary.medialibrarydata"
J
JH C 已提交
19 20
            ]
        },
G
gudehe 已提交
21 22 23 24 25
        {
            "type": "PushKit",
            "pre-push": [
            ],
            "push": [
P
panqiangbiao 已提交
26 27 28 29
                "./resource/medialibrary/01.jpg ->/data/accounts/account_0/appdata/com.ohos.medialibrary.medialibrarydata",
                "./resource/medialibrary/01.mp3 ->/data/accounts/account_0/appdata/com.ohos.medialibrary.medialibrarydata",
                "./resource/medialibrary/01.mp4 ->/data/accounts/account_0/appdata/com.ohos.medialibrary.medialibrarydata",
                "./resource/medialibrary/01.dat ->/data/accounts/account_0/appdata/com.ohos.medialibrary.medialibrarydata"
G
gudehe 已提交
30 31 32 33 34
            ]
        },
        {
            "type": "ShellKit",
            "run-command": [
P
panqiangbiao 已提交
35 36 37 38
                "mkdir -pv /storage/media/100/local/files/Pictures/{Static,Static01,Album/Static,Dynamic,Dynamic01,Dynamic022,DeleteCb01,AblumInfo,DeletePro01,Dynamic03,Temp}",
                "mkdir -pv /storage/media/100/local/files/Videos/{Static,Static01,Album/Static,Dynamic,Dynamic01,Dynamic02,DeleteCb01,AblumInfo,DeletePro01,Dynamic03}",
                "mkdir -pv /storage/media/100/local/files/Audios/{Static,Static01,Album/Static,Dynamic,Dynamic01,Dynamic02,DeleteCb01,AblumInfo,DeletePro01,Dynamic03}",
                "mkdir -pv /storage/media/100/local/files/Documents/{Static,Static01,Album/Static,Dynamic,Dynamic01,Dynamic02,DeleteCb01,AblumInfo,DeletePro01}",
P
panqiangbiao 已提交
39 40 41 42
                "for d in Static Album/Static Dynamic Dynamic01 Dynamic022 AblumInfo; do for i in $$(seq 3); do cp /data/accounts/account_0/appdata/com.ohos.medialibrary.medialibrarydata/01.jpg /storage/media/100/local/files/Pictures/$$d/0$$i.jpg; done;done;",
                "for d in Static Album/Static Dynamic Dynamic01 Dynamic02 AblumInfo; do for i in $$(seq 3); do cp /data/accounts/account_0/appdata/com.ohos.medialibrary.medialibrarydata/01.mp3 /storage/media/100/local/files/Audios/$$d/0$$i.mp3; done;done;",
                "for d in Static Album/Static Dynamic Dynamic01 Dynamic02 AblumInfo; do for i in $$(seq 3); do cp /data/accounts/account_0/appdata/com.ohos.medialibrary.medialibrarydata/01.mp4 /storage/media/100/local/files/Videos/$$d/0$$i.mp4; done;done;",
                "for d in Static Album/Static Dynamic Dynamic01 Dynamic02 AblumInfo; do for i in $$(seq 3); do cp /data/accounts/account_0/appdata/com.ohos.medialibrary.medialibrarydata/01.dat /storage/media/100/local/files/Documents/$$d/0$$i.dat; done;done;",
J
JH C 已提交
43
               
P
panqiangbiao 已提交
44 45 46 47
                "for d in DeleteCb01 DeletePro01 Static01;  do cp /data/accounts/account_0/appdata/com.ohos.medialibrary.medialibrarydata/01.jpg /storage/media/100/local/files/Pictures/$$d ;done;",
                "for d in DeleteCb01 DeletePro01 Static01;  do cp /data/accounts/account_0/appdata/com.ohos.medialibrary.medialibrarydata/01.mp3 /storage/media/100/local/files/Audios/$$d ;done;",
                "for d in DeleteCb01 DeletePro01 Static01;  do cp /data/accounts/account_0/appdata/com.ohos.medialibrary.medialibrarydata/01.mp4 /storage/media/100/local/files/Videos/$$d ;done;",
                "for d in DeleteCb01 DeletePro01 Static01;  do cp /data/accounts/account_0/appdata/com.ohos.medialibrary.medialibrarydata/01.dat /storage/media/100/local/files/Documents/$$d ;done;",
J
JH C 已提交
48

G
gudehe 已提交
49
                "chmod -R 777 /storage/media/100/local/files/*",
P
panqiangbiao 已提交
50
                "chmod -R 777 /data/service/el2/100/hmdfs/account/files/*",
51 52
                "hilog -Q pidoff",
                "hilog -p off",
P
panqiangbiao 已提交
53
                "hilog -b D",
P
panqiangbiao 已提交
54
                "aa start -a com.ohos.photos.MainAbility -b com.ohos.photos",
55 56 57
                "sleep 10",
                "cem publish -e usual.event.SCREEN_OFF",
                "sleep 10"
G
gudehe 已提交
58 59 60 61
            ]
        },
        {
            "test-file-name": [
T
tongtongdad 已提交
62
                "ActsMediaLibraryJsTest.hap"
G
gudehe 已提交
63 64 65 66 67
            ],
            "type": "AppInstallKit",
            "cleanup-apps": true
        }
    ]
P
panqiangbiao 已提交
68
}