• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1{
2    "description": "Configuration for mediaLibrary Tests",
3    "driver": {
4        "type": "OHJSUnitTest",
5        "test-timeout": "180000",
6        "bundle-name": "ohos.acts.multimedia.mediaLibrary",
7        "module-name": "phone",
8        "shell-timeout": "600000",
9        "testcase-timeout": 20000
10    },
11    "kits": [
12        {
13            "type": "ShellKit",
14            "pre-push": [],
15            "run-command": [
16                "rm -rf /storage/media/100/local/files/Pictures",
17                "rm -rf /storage/media/100/local/files/Videos",
18                "rm -rf /storage/media/100/local/files/Camera",
19                "rm -rf /storage/media/100/local/files/Audios",
20                "rm -rf /storage/media/100/local/files/Docs/Documents/*",
21                "rm -rf /storage/media/100/local/files/Docs/Documents/.*",
22                "rm -rf /storage/media/100/local/files/Photo/*",
23                "sleep 5",
24                "rm -rf /data/app/el2/100/database/com.ohos.medialibrary.medialibrarydata/*",
25                "kill -9 `pidof com.ohos.medialibrary.medialibrarydata`"
26            ]
27        },
28        {
29            "test-file-name": [
30                "ActsMediaLibraryFileAssetTest.hap"
31            ],
32            "type": "AppInstallKit",
33            "cleanup-apps": true
34        },
35        {
36            "type": "ShellKit",
37            "pre-push": [],
38            "run-command": [
39                "param set persist.ace.testmode.enabled 1",
40                "power-shell wakeup",
41                "uinput  -T -d 300 2700 -m 300 2700 300 100 -u 300 100",
42                "power-shell setmode 602",
43                "mkdir -p /storage/media/100/local/files/Pictures",
44                "mkdir -p /storage/media/100/local/files/Videos",
45                "mkdir -p /storage/media/100/local/files/Camera",
46                "mkdir -p /storage/media/100/local/files/Audios",
47                "mkdir -pv /storage/media/100/local/files/Pictures/{ModifyCb,ModifyPro,RW,R,W,RW_cb,R_cb,W_cb,openClose}",
48                "mkdir -pv /storage/media/100/local/files/Videos/{ModifyCb,ModifyPro,RW,R,W,RW_cb,R_cb,W_cb,openClose}",
49                "mkdir -pv /storage/media/100/local/files/Audios/{ModifyCb,ModifyPro,RW,R,W,RW_cb,R_cb,W_cb,openClose}",
50                "mkdir -pv /storage/media/100/local/files/Docs/Documents/{ModifyCb,ModifyPro,RW,R,W,RW_cb,R_cb,W_cb,openClose}",
51                "mkdir -p /data/app/el2/100/base/ohos.acts.multimedia.mediaLibrary/haps/phone/files",
52                "chmod 777 -R /data/app/el2/100/base/ohos.acts.multimedia.mediaLibrary/haps/phone",
53                "chmod -R 777 /storage/media/100/local/files/*",
54                "chmod -R 777 /data/service/el2/100/hmdfs/account/files/*"
55            ]
56        },
57        {
58            "type": "PushKit",
59            "pre-push": [],
60            "push": [
61                "./resource/medialibrary/01.jpg ->/data/app/el2/100/base/ohos.acts.multimedia.mediaLibrary/haps/phone/files/",
62                "./resource/medialibrary/01.mp3 ->/data/app/el2/100/base/ohos.acts.multimedia.mediaLibrary/haps/phone/files/",
63                "./resource/medialibrary/01.mp4 ->/data/app/el2/100/base/ohos.acts.multimedia.mediaLibrary/haps/phone/files/",
64                "./resource/medialibrary/01.dat ->/data/app/el2/100/base/ohos.acts.multimedia.mediaLibrary/haps/phone/files/"
65            ]
66        },
67        {
68            "type": "ShellKit",
69            "run-command": [
70                "hilog -Q pidoff",
71                "hilog -Q domainoff",
72                "hilog -b D -D 0xD002B70"
73            ],
74            "teardown-command": [
75                "power-shell setmode 600",
76                "hilog -Q pidon",
77                "hilog -Q domainon",
78                "rm -rf /storage/media/100/local/files/Pictures",
79                "rm -rf /storage/media/100/local/files/Videos",
80                "rm -rf /storage/media/100/local/files/Camera",
81                "rm -rf /storage/media/100/local/files/Audios",
82                "rm -rf /storage/media/100/local/files/Docs/Documents/*",
83                "rm -rf /storage/media/100/local/files/Docs/Documents/.*",
84                "rm -rf /storage/media/100/local/files/Photo/*",
85                "sleep 5",
86                "rm -rf /data/app/el2/100/database/com.ohos.medialibrary.medialibrarydata/*",
87                "kill -9 `pidof com.ohos.medialibrary.medialibrarydata`"
88            ]
89        }
90    ]
91}