diff --git a/OAT.xml b/OAT.xml
index 75658c32ecac16a62b367d59e9007ec3b6705fd8..8671286f8b270db98a67064ba5b76e8255270916 100644
--- a/OAT.xml
+++ b/OAT.xml
@@ -27,19 +27,19 @@
-
+
-
+
-
+
-
+
diff --git a/mini_system_test/L1_mini_system_test.py b/mini_system_test/L1_mini_system_test.py
index bfb7460570a9696f5e250ddc1deed03978ce519c..ea5ae7288d88ed0cf0d5dd9877b8924fbdd47138 100644
--- a/mini_system_test/L1_mini_system_test.py
+++ b/mini_system_test/L1_mini_system_test.py
@@ -140,13 +140,15 @@ if __name__ == "__main__":
target_dir = os.path.normpath(os.path.join(args.archive_path, "rootfs"))
ret_size = GetDirSize(target_dir)/1024/1024
+ PrintToLog('Size of rootfs is ({:.2f}M)'.format(ret_size))
if ret_size > 15:
PrintToLog('ERROR: Size of rootfs({:.2f}M) is over the upper limit(15M)'.format(ret_size))
PrintToLog("End of check, test failed!")
sys.exit(99)
- target_dir = os.path.normpath(os.path.join(args.archive_path, "rootfs"))
+ target_dir = os.path.normpath(os.path.join(args.archive_path, "userfs"))
ret_size = GetDirSize(target_dir)/1024/1024
+ PrintToLog('Size of userfs is ({:.2f}M)'.format(ret_size))
if ret_size > 15:
PrintToLog('ERROR: Size of userfs({:.2f}M) is over the upper limit(15M)'.format(ret_size))
PrintToLog("End of check, test failed!")
diff --git a/mini_system_test/L2_mini_system_test.py b/mini_system_test/L2_mini_system_test.py
index 453676811f5a2bd4b4b9f12141dd69118fdd6b07..eae1daa5f4a3721205571aa1f90606fd7b3ac5b2 100644
--- a/mini_system_test/L2_mini_system_test.py
+++ b/mini_system_test/L2_mini_system_test.py
@@ -173,6 +173,7 @@ if __name__ == "__main__":
target_dir = os.path.normpath(os.path.join(args.archive_path, "system"))
PrintToLog(target_dir)
ret_size = GetDirSize(target_dir)/1024/1024
+ PrintToLog('Size of system is :{:.2f}M'.format(ret_size))
if ret_size > 50:
PrintToLog('ERROR: Size of system({:.2f}M) is over the upper limit(50M)'.format(ret_size))
PrintToLog("End of check, test failed!")
@@ -180,6 +181,7 @@ if __name__ == "__main__":
target_dir = os.path.normpath(os.path.join(args.archive_path, "data"))
ret_size = GetDirSize(target_dir)/1024/1024
+ PrintToLog('Size of data is :{:.2f}M'.format(ret_size))
if ret_size > 50:
PrintToLog('ERROR: Size of data({:.2f}M) is over the upper limit(50M)'.format(ret_size))
PrintToLog("End of check, test failed!")
@@ -187,6 +189,7 @@ if __name__ == "__main__":
target_dir = os.path.normpath(os.path.join(args.archive_path, "updater"))
ret_size = GetDirSize(target_dir)/1024/1024
+ PrintToLog('Size of updater is :{:.2f}M'.format(ret_size))
if ret_size > 50:
PrintToLog('ERROR: Size of updater({:.2f}M) is over the upper limit(50M)'.format(ret_size))
PrintToLog("End of check, test failed!")
@@ -194,6 +197,7 @@ if __name__ == "__main__":
target_dir = os.path.normpath(os.path.join(args.archive_path, "vendor"))
ret_size = GetDirSize(target_dir)/1024/1024
+ PrintToLog('Size of vendor is :{:.2f}M'.format(ret_size))
if ret_size > 50:
PrintToLog('ERROR: Size of vendor({:.2f}M) is over the upper limit(50M)'.format(ret_size))
PrintToLog("End of check, test failed!")
diff --git a/screenshot/photographtest/NativeRdbTest b/screenshot/photographtest/NativeRdbTest
new file mode 100644
index 0000000000000000000000000000000000000000..6c9d0acdd7ade997288664edb6b633c8c5d3459c
Binary files /dev/null and b/screenshot/photographtest/NativeRdbTest differ
diff --git a/screenshot/resource/app_capture_screen_test_config.json b/screenshot/resource/app_capture_screen_test_config.json
index 85196c3cb166b06f96850228707cfafc7f2d90a8..b4a8e6be27a8bf194df13b5ca62f6c0710213ae8 100644
--- a/screenshot/resource/app_capture_screen_test_config.json
+++ b/screenshot/resource/app_capture_screen_test_config.json
@@ -1,13 +1,18 @@
[
{
- "DEVICE_1":[1, 2, 3, 4, 8],
- "DEVICE_2":[5, 6, 7, 9],
+ "DEVICE_1":[2, 3, 4, 10, 11],
+ "DEVICE_2":[1, 5, 6, 7, 8, 9],
"return-x-y":[210, 1240],
"recent-x-y":[515, 1240],
"home-x-y":[360, 1240],
"recent_del-x-y":[360, 1170],
"permisson_ok-x-y":[575, 700],
"permisson_no-x-y":[140, 700],
+ "take_photos-x-y":[360, 1095],
+ "convert_to_video-x-y":[430, 980],
+ "convert_to_photos-x-y":[200, 1095],
+ "photos-x-y":[590, 40],
+ "stop_video-x-y":[320, 1095],
"shot_cmd":[""],
"remount":["mount -o rw,remount"],
"stop_hilog":["hilog -w stop"],
@@ -48,16 +53,15 @@
"entry": "",
"mk_test_dir":["mkdir -p /data/app/el1/bundle/public/ohos.acts.multimedia.video.videoplayer/ohos.acts.multimedia.video.videoplayer/assets/entry/resources/rawfile"],
"close_auto_log":["hilog -w stop;rm /data/log/hilog/*"],
- "start_video_log":["hilog -r;hilog -w start -l 400000000 -m none;hilog -G 512M"],
+ "start_video_log":["hilog -r;hilog -Q pidoff;hilog -G 512M;hilog -w start -l 400000000 -m none"],
"start_test":["aa start -a ohos.acts.multimedia.video.videoplayer.MainAbility -b ohos.acts.multimedia.video.videoplayer"],
- "recover_log":["cd data/log/hilog/;hilog -x > video_log.txt"],
"check_result":["cd /data/log/hilog && grep -nr 'total cases'", "failure 0,error 0,pass 1"],
"compress_log":["cd /data/log/hilog && tar -cf video_log.tar *"],
"clear_log":["rm /data/log/hilog/*"],
"all_actions": [
[1,"close_auto_log"], [1,"start_video_log"], [2, "install_hap", "vediotest/ActsVideoPlayerJsTest.hap"], [1, "mk_test_dir"], [1, "remount"],
[1, "send_file_to_dev", "vediotest/H264_AAC.mp4", "/data/app/el1/bundle/public/ohos.acts.multimedia.video.videoplayer/ohos.acts.multimedia.video.videoplayer/assets/entry/resources/rawfile/"],
- [15, "start_test"], [1, "recover_log"], [1, "stop_hilog"], [1, "check_result"], [1, "compress_log"],
+ [15, "start_test"], [1, "stop_hilog"], [1, "check_result"], [1, "compress_log"],
[1, "get_file_from_dev", "/data/log/hilog/video_log.tar"], [2, "recent-x-y"], [2, "recent_del-x-y"], [2, "home-x-y"], [2, "recent-x-y"], [2, "recent_del-x-y"]
]
},
@@ -73,6 +77,15 @@
[5, "audio_render_test"], [1, "stop_hilog"], [1, "compress_log"], [1, "get_file_from_dev", "/data/log/hilog/audio_render_log.tar"]
]
},
+ {
+ "app_name": "photos",
+ "entry": "aa start -a com.ohos.photos.MainAbility -b com.ohos.photos",
+ "compress_log":["cd /data/log/hilog && tar -cf photos_log.tar *"],
+ "all_actions": [
+ [2, "permisson_ok-x-y"], [2, "permisson_ok-x-y"], [2, "permisson_ok-x-y"], [2, "shot_cmd"], [2, "recent-x-y"], [2, "recent_del-x-y"], [1, "cmp_cmd-level"],
+ [2, "recent-x-y"], [2, "recent_del-x-y"], [1, "stop_hilog"], [1, "compress_log"], [1, "get_file_from_dev", "/data/log/hilog/photos_log.tar"]
+ ]
+ },
{
"app_name": "camera",
"entry": "",
@@ -83,8 +96,28 @@
"start_camera":["aa start -a com.ohos.camera.MainAbility -b com.ohos.camera"],
"recover_log":["cd data/log/hilog/;hilog -x > camera_log.txt;hilog -b D"],
"all_actions": [
- [1, "close_auto_log"], [1, "open_camera_log"], [5, "start_camera"], [2, "permisson_ok-x-y"], [2, "permisson_ok-x-y"], [2, "permisson_ok-x-y"], [2, "permisson_ok-x-y"], [2, "permisson_ok-x-y"], [2, "permisson_ok-x-y"], [1, "recover_log"], [1, "check_result"],
- [1, "shot_cmd"], [2, "recent-x-y"], [2, "recent_del-x-y"], [1, "compress_log"], [1, "get_file_from_dev", "/data/log/hilog/camera_log.tar"]
+ [1, "close_auto_log"], [1, "open_camera_log"], [5, "start_camera"], [2, "permisson_ok-x-y"], [2, "permisson_ok-x-y"], [2, "permisson_ok-x-y"], [2, "permisson_ok-x-y"], [2, "permisson_ok-x-y"], [2, "permisson_ok-x-y"],
+ [1, "recover_log"], [1, "check_result"], [1, "shot_cmd"], [2, "recent-x-y"], [2, "recent_del-x-y"], [1, "compress_log"], [1, "get_file_from_dev", "/data/log/hilog/camera_log.tar"]
+ ]
+ },
+ {
+ "app_name": "photograph",
+ "entry": "aa start -a com.ohos.camera.MainAbility -b com.ohos.camera",
+ "compress_log":["cd /data/log/hilog && tar -cf photograph_log.tar *"],
+ "chmodfile":["chmod 777 /data/NativeRdbTest"],
+ "start_photographtest":["cd /data && ./NativeRdbTest --gtest_filter=RdbStoreInsertTest.RdbStore_Insert_001 && rm *.xml", "[ PASSED ] 1 test"],
+ "all_actions": [
+ [2, "permisson_ok-x-y"], [2, "take_photos-x-y"], [2, "take_photos-x-y"], [1, "remount"], [1, "send_file_to_dev", "photographtest/NativeRdbTest", "/data/"], [2, "chmodfile"], [2, "start_photographtest"], [2, "recent-x-y"], [2, "recent_del-x-y"],
+ [1, "stop_hilog"], [1, "compress_log"],[1, "get_file_from_dev", "/data/log/hilog/photograph_log.tar"]
+ ]
+ },
+ {
+ "app_name": "jump_to_photos",
+ "entry": "aa start -a com.ohos.camera.MainAbility -b com.ohos.camera",
+ "compress_log":["cd /data/log/hilog && tar -cf jump_to_photos_log.tar *"],
+ "all_actions": [
+ [3, "convert_to_photos-x-y"], [3, "convert_to_photos-x-y"], [3, "convert_to_photos-x-y"], [2, "photos-x-y"], [2, "photos-x-y"], [2, "photos-x-y"], [2, "shot_cmd"], [1, "cmp_cmd-level", 737280], [2, "recent-x-y"], [2, "recent_del-x-y"],
+ [1, "stop_hilog"], [1, "compress_log"],[1, "get_file_from_dev", "/data/log/hilog/jump_to_photos_log.tar"]
]
},
{
@@ -96,15 +129,6 @@
[1, "compress_log"], [1, "get_file_from_dev", "/data/log/hilog/settings_log.tar"]
]
},
- {
- "app_name": "photos",
- "entry": "aa start -a com.ohos.photos.MainAbility -b com.ohos.photos",
- "compress_log":["cd /data/log/hilog && tar -cf photos_log.tar *"],
- "all_actions": [
- [2, "permisson_ok-x-y"], [2, "permisson_ok-x-y"], [2, "permisson_ok-x-y"], [2, "shot_cmd"], [2, "recent-x-y"], [2, "recent_del-x-y"], [1, "cmp_cmd-level"],
- [2, "recent-x-y"], [2, "recent_del-x-y"], [1, "stop_hilog"], [1, "compress_log"], [1, "get_file_from_dev", "/data/log/hilog/photos_log.tar"]
- ]
- },
{
"app_name": "note",
"entry": "aa start -a MainAbility -b com.ohos.note",
diff --git a/screenshot/resource/capturescreentest.py b/screenshot/resource/capturescreentest.py
index 330b1bc36bced1fb74a18c112cfe9faaf0434103..1ffaf01012e5ce578f70e89169e18534c70fbb34 100644
--- a/screenshot/resource/capturescreentest.py
+++ b/screenshot/resource/capturescreentest.py
@@ -89,6 +89,17 @@ def GetFileFromDev(src, dst):
cmd = "hdc_std -t {} file recv \"{}\" \"{}\"".format(args.device_num, src, dst)
return EnterCmd(cmd, 1, 1)
+def connection_judgment():
+ connection_status = EnterCmd("hdc_std list targets", 2)
+ connection_cnt = 0
+ while "7001005458323933328a" not in connection_status and connection_cnt < 15:
+ connection_status = EnterCmd("hdc_std list targets", 2)
+ connection_cnt += 1
+ if connection_cnt == 15:
+ PrintToLog("Device disconnection!!")
+ PrintToLog("End of check, test failed!")
+ sys.exit(101)
+
def ConnectToWifi(tools_path):
EnterShellCmd("mkdir /data/l2tool", 1)
SendFileToDev(os.path.normpath(os.path.join(tools_path, "l2tool/busybox")), "/data/l2tool/")
@@ -147,7 +158,7 @@ if __name__ == "__main__":
cmp_status = 0
global_pos = all_app[0]
-
+
#rmlock
rebootcnt = 2
while rebootcnt:
@@ -169,6 +180,7 @@ if __name__ == "__main__":
EnterShellCmd("/data/screen_test/printscreen -f /data/screen_test/launcher_{}.png".format(args.device_num), 1)
GetFileFromDev("/data/screen_test/launcher_{}.pngraw".format(args.device_num), args.save_path)
GetFileFromDev("/data/screen_test/launcher_{}.png".format(args.device_num), args.save_path)
+ connection_judgment()
cmp_launcher = "cmp -l /data/screen_test/launcher_{}.pngraw /data/screen_test/train_set/launcher.pngraw | wc -l".format(args.device_num)
p = EnterShellCmd(cmp_launcher, 1)
num = re.findall(r'[-+]?\d+', p)
@@ -321,12 +333,6 @@ if __name__ == "__main__":
elif type(single_action[1]) == str and single_action[1] == 'connect_wifi':
next_cmd = ""
ConnectToWifi(args.tools_path)
- elif type(single_action[1]) == str and single_action[1] == 'log_packaging':
- next_cmd = ""
- EnterShellCmd("cd /data/log/hilog && tar -cf photos_log_{}.tar *".format(4 - testcnt))
- elif type(single_action[1]) == str and single_action[1] == 'get_photos_log_from_dev':
- next_cmd = ""
- EnterCmd("hdc_std -t {} file recv \"/data/log/hilog/photos_log_{}.tar\" \"{}\"".format(args.device_num, 4 - testcnt, os.path.normpath(args.save_path)))
#process_crash_check
elif type(single_action[1]) == str and single_action[1] == 'process_crash_check':
next_cmd = ""
@@ -391,6 +397,7 @@ if __name__ == "__main__":
else:
testcnt = 0
EnterShellCmd("hilog -w stop", 1)
+ connection_judgment()
if smoke_first_failed == 'launcher':
break
@@ -460,8 +467,10 @@ if __name__ == "__main__":
sys.exit(0)
elif py_cmd == 98:
sys.exit(98)
- else:
+ elif py_cmd == 99:
sys.exit(99)
+ else:
+ sys.exit(101)
else:
PrintToLog("ERROR: name {}, index {}, these testcase is failed".format(fail_name_list, fail_idx_list))
PrintToLog("SmokeTest find some key problems!")
@@ -470,5 +479,4 @@ if __name__ == "__main__":
else:
PrintToLog("All testcase is ok")
PrintToLog("End of check, test succeeded!")
- sys.exit(0)
-
+ sys.exit(0)
\ No newline at end of file
diff --git a/screenshot/resource/jump_to_photos.png b/screenshot/resource/jump_to_photos.png
new file mode 100644
index 0000000000000000000000000000000000000000..6ff50bda8e861c5e09e88b784063bbc242a02c5f
Binary files /dev/null and b/screenshot/resource/jump_to_photos.png differ
diff --git a/screenshot/resource/jump_to_photos.pngraw b/screenshot/resource/jump_to_photos.pngraw
new file mode 100644
index 0000000000000000000000000000000000000000..e0dc8817ca92e03e52b6b123fdd6c49bd077225d
--- /dev/null
+++ b/screenshot/resource/jump_to_photos.pngraw
@@ -0,0 +1,5499 @@
+HQ\HQ\HQ\Zcm|gpxgpxgpxgpxgpxgpxgpxgpxgpxgpx9DO$1$1$1$1$1$1$1$1$1$1$1$1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