From 2719dff87a1eef7f9df08c013475e7fbd4872952 Mon Sep 17 00:00:00 2001 From: Ravi Mistry Date: Mon, 25 Mar 2019 13:21:51 +0000 Subject: [PATCH] [Recipe Modules] remove_file_on_device was in all flavors except DefaultFlavor Bug: skia:8901 Change-Id: Idde99d943c31ae62fcd0bc3f3b8cfc0ebc07e896 Reviewed-on: https://skia-review.googlesource.com/c/skia/+/203340 Reviewed-by: Eric Boren Commit-Queue: Ravi Mistry --- infra/bots/recipe_modules/flavor/default.py | 4 ++++ ...rm-Release-All-Android_SkottieTracing.json | 21 +++++++++++++++-- ...-GPU-MaliT880-arm64-Debug-All-Android.json | 21 +++++++++++++++-- ...GPU-Adreno418-arm64-Debug-All-Android.json | 21 +++++++++++++++-- ...bookPlus-GPU-MaliT860-arm-Release-All.json | 23 +++++++++++++++++-- ...Chorizo-CPU-Cortex_A7-arm-Release-All.json | 20 ++++++++++++++-- ...ng-GCE-CPU-AVX2-x86_64-Debug-All-MSAN.json | 17 ++++++++++++-- ...-GCE-CPU-AVX2-x86_64-Release-All-ASAN.json | 17 ++++++++++++-- ...PU-Mali400MP2-arm-Release-All-Android.json | 21 +++++++++++++++-- ...-GPU-MaliT880-arm64-Debug-All-Android.json | 21 +++++++++++++++-- ...GPU-Adreno418-arm64-Debug-All-Android.json | 21 +++++++++++++++-- ...eno418-arm64-Release-All-Android_ASAN.json | 21 +++++++++++++++-- ...bookPlus-GPU-MaliT860-arm-Release-All.json | 23 +++++++++++++++++-- ...CE-CPU-AVX2-x86_64-Debug-All-Coverage.json | 17 ++++++++++++-- ...CE-CPU-AVX2-x86_64-Release-All-Lottie.json | 17 ++++++++++++-- ...-GCE-CPU-AVX2-x86_64-Release-All-TSAN.json | 17 ++++++++++++-- ...ftShader-x86_64-Debug-All-SwiftShader.json | 17 ++++++++++++-- ...-IntelIris640-x86_64-Debug-All-OpenCL.json | 17 ++++++++++++-- ...-IntelIris640-x86_64-Debug-All-Vulkan.json | 17 ++++++++++++-- ...ro11.5-CPU-AVX2-x86_64-Debug-All-ASAN.json | 17 ++++++++++++-- ..._AbandonGpuContext_SK_CPU_LIMIT_SSE41.json | 17 ++++++++++++-- ...00-x86_64-Release-All-Vulkan_ProcDump.json | 17 ++++++++++++-- .../full.expected/cpu_scale_failed.json | 21 +++++++++++++++-- .../full.expected/cpu_scale_failed_golo.json | 21 +++++++++++++++-- .../full.expected/cpu_scale_failed_once.json | 21 +++++++++++++++-- .../full.expected/failed_infra_step.json | 21 +++++++++++++++-- .../full.expected/failed_read_version.json | 21 +++++++++++++++-- .../full.expected/retry_adb_command.json | 21 +++++++++++++++-- .../retry_adb_command_retries_exhausted.json | 21 +++++++++++++++-- .../full.expected/retry_ios_install.json | 16 +++++++++++-- .../retry_ios_install_retries_exhausted.json | 16 +++++++++++-- .../recipe_modules/flavor/examples/full.py | 3 ++- 32 files changed, 525 insertions(+), 61 deletions(-) diff --git a/infra/bots/recipe_modules/flavor/default.py b/infra/bots/recipe_modules/flavor/default.py index ba47d8106d..2950c96040 100644 --- a/infra/bots/recipe_modules/flavor/default.py +++ b/infra/bots/recipe_modules/flavor/default.py @@ -143,6 +143,10 @@ class DefaultFlavor(object): """Reads the specified file.""" return self.m.file.read_text('read %s' % path, path) + def remove_file_on_device(self, path): + """Removes the specified file.""" + return self.m.file.remove('remove %s' % path, path) + def install(self): """Run device-specific installation steps.""" pass diff --git a/infra/bots/recipe_modules/flavor/examples/full.expected/Perf-Android-Clang-AndroidOne-GPU-Mali400MP2-arm-Release-All-Android_SkottieTracing.json b/infra/bots/recipe_modules/flavor/examples/full.expected/Perf-Android-Clang-AndroidOne-GPU-Mali400MP2-arm-Release-All-Android_SkottieTracing.json index 19392be29c..dd5c792e15 100644 --- a/infra/bots/recipe_modules/flavor/examples/full.expected/Perf-Android-Clang-AndroidOne-GPU-Mali400MP2-arm-Release-All-Android_SkottieTracing.json +++ b/infra/bots/recipe_modules/flavor/examples/full.expected/Perf-Android-Clang-AndroidOne-GPU-Mali400MP2-arm-Release-All-Android_SkottieTracing.json @@ -34,7 +34,7 @@ "/opt/infra-android/tools/adb", "shell", "cat", - "file.text" + "file.txt" ], "cwd": "[START_DIR]/skia", "env": { @@ -43,9 +43,26 @@ "PATH": ":RECIPE_REPO[depot_tools]" }, "infra_step": true, - "name": "read file.text", + "name": "read file.txt", "stdout": "/path/to/tmp/" }, + { + "cmd": [ + "/opt/infra-android/tools/adb", + "shell", + "rm", + "-f", + "file.txt" + ], + "cwd": "[START_DIR]/skia", + "env": { + "ADB_VENDOR_KEYS": "/home/chrome-bot/.android/chrome_infrastructure_adbkey", + "CHROME_HEADLESS": "1", + "PATH": ":RECIPE_REPO[depot_tools]" + }, + "infra_step": true, + "name": "rm file.txt" + }, { "cmd": [ "python", diff --git a/infra/bots/recipe_modules/flavor/examples/full.expected/Perf-Android-Clang-GalaxyS7_G930FD-GPU-MaliT880-arm64-Debug-All-Android.json b/infra/bots/recipe_modules/flavor/examples/full.expected/Perf-Android-Clang-GalaxyS7_G930FD-GPU-MaliT880-arm64-Debug-All-Android.json index f6de2edd7c..ecd977a636 100644 --- a/infra/bots/recipe_modules/flavor/examples/full.expected/Perf-Android-Clang-GalaxyS7_G930FD-GPU-MaliT880-arm64-Debug-All-Android.json +++ b/infra/bots/recipe_modules/flavor/examples/full.expected/Perf-Android-Clang-GalaxyS7_G930FD-GPU-MaliT880-arm64-Debug-All-Android.json @@ -34,7 +34,7 @@ "/opt/infra-android/tools/adb", "shell", "cat", - "file.text" + "file.txt" ], "cwd": "[START_DIR]/skia", "env": { @@ -43,9 +43,26 @@ "PATH": ":RECIPE_REPO[depot_tools]" }, "infra_step": true, - "name": "read file.text", + "name": "read file.txt", "stdout": "/path/to/tmp/" }, + { + "cmd": [ + "/opt/infra-android/tools/adb", + "shell", + "rm", + "-f", + "file.txt" + ], + "cwd": "[START_DIR]/skia", + "env": { + "ADB_VENDOR_KEYS": "/home/chrome-bot/.android/chrome_infrastructure_adbkey", + "CHROME_HEADLESS": "1", + "PATH": ":RECIPE_REPO[depot_tools]" + }, + "infra_step": true, + "name": "rm file.txt" + }, { "cmd": [ "python", diff --git a/infra/bots/recipe_modules/flavor/examples/full.expected/Perf-Android-Clang-Nexus5x-GPU-Adreno418-arm64-Debug-All-Android.json b/infra/bots/recipe_modules/flavor/examples/full.expected/Perf-Android-Clang-Nexus5x-GPU-Adreno418-arm64-Debug-All-Android.json index 7711b9617c..88b7c41b8f 100644 --- a/infra/bots/recipe_modules/flavor/examples/full.expected/Perf-Android-Clang-Nexus5x-GPU-Adreno418-arm64-Debug-All-Android.json +++ b/infra/bots/recipe_modules/flavor/examples/full.expected/Perf-Android-Clang-Nexus5x-GPU-Adreno418-arm64-Debug-All-Android.json @@ -34,7 +34,7 @@ "/opt/infra-android/tools/adb", "shell", "cat", - "file.text" + "file.txt" ], "cwd": "[START_DIR]/skia", "env": { @@ -43,9 +43,26 @@ "PATH": ":RECIPE_REPO[depot_tools]" }, "infra_step": true, - "name": "read file.text", + "name": "read file.txt", "stdout": "/path/to/tmp/" }, + { + "cmd": [ + "/opt/infra-android/tools/adb", + "shell", + "rm", + "-f", + "file.txt" + ], + "cwd": "[START_DIR]/skia", + "env": { + "ADB_VENDOR_KEYS": "/home/chrome-bot/.android/chrome_infrastructure_adbkey", + "CHROME_HEADLESS": "1", + "PATH": ":RECIPE_REPO[depot_tools]" + }, + "infra_step": true, + "name": "rm file.txt" + }, { "cmd": [ "python", diff --git a/infra/bots/recipe_modules/flavor/examples/full.expected/Perf-ChromeOS-Clang-SamsungChromebookPlus-GPU-MaliT860-arm-Release-All.json b/infra/bots/recipe_modules/flavor/examples/full.expected/Perf-ChromeOS-Clang-SamsungChromebookPlus-GPU-MaliT860-arm-Release-All.json index f65025a31c..2e52e5e7b0 100644 --- a/infra/bots/recipe_modules/flavor/examples/full.expected/Perf-ChromeOS-Clang-SamsungChromebookPlus-GPU-MaliT860-arm-Release-All.json +++ b/infra/bots/recipe_modules/flavor/examples/full.expected/Perf-ChromeOS-Clang-SamsungChromebookPlus-GPU-MaliT860-arm-Release-All.json @@ -50,16 +50,35 @@ "-t", "foo@127.0.0.1", "cat", - "file.text" + "file.txt" ], "env": { "CHROME_HEADLESS": "1", "PATH": ":RECIPE_REPO[depot_tools]" }, "infra_step": true, - "name": "read file.text", + "name": "read file.txt", "stdout": "/path/to/tmp/" }, + { + "cmd": [ + "ssh", + "-oConnectTimeout=15", + "-oBatchMode=yes", + "-t", + "-t", + "foo@127.0.0.1", + "rm", + "-f", + "file.txt" + ], + "env": { + "CHROME_HEADLESS": "1", + "PATH": ":RECIPE_REPO[depot_tools]" + }, + "infra_step": true, + "name": "rm file.txt" + }, { "cmd": [ "python", diff --git a/infra/bots/recipe_modules/flavor/examples/full.expected/Perf-Chromecast-Clang-Chorizo-CPU-Cortex_A7-arm-Release-All.json b/infra/bots/recipe_modules/flavor/examples/full.expected/Perf-Chromecast-Clang-Chorizo-CPU-Cortex_A7-arm-Release-All.json index e2dd57244c..7815c2fc0d 100644 --- a/infra/bots/recipe_modules/flavor/examples/full.expected/Perf-Chromecast-Clang-Chorizo-CPU-Cortex_A7-arm-Release-All.json +++ b/infra/bots/recipe_modules/flavor/examples/full.expected/Perf-Chromecast-Clang-Chorizo-CPU-Cortex_A7-arm-Release-All.json @@ -68,7 +68,7 @@ "adb", "shell", "cat", - "file.text" + "file.txt" ], "cwd": "[START_DIR]/skia", "env": { @@ -76,9 +76,25 @@ "PATH": ":RECIPE_REPO[depot_tools]" }, "infra_step": true, - "name": "read file.text", + "name": "read file.txt", "stdout": "/path/to/tmp/" }, + { + "cmd": [ + "adb", + "shell", + "rm", + "-f", + "file.txt" + ], + "cwd": "[START_DIR]/skia", + "env": { + "CHROME_HEADLESS": "1", + "PATH": ":RECIPE_REPO[depot_tools]" + }, + "infra_step": true, + "name": "rm file.txt" + }, { "cmd": [ "python", diff --git a/infra/bots/recipe_modules/flavor/examples/full.expected/Perf-Debian9-Clang-GCE-CPU-AVX2-x86_64-Debug-All-MSAN.json b/infra/bots/recipe_modules/flavor/examples/full.expected/Perf-Debian9-Clang-GCE-CPU-AVX2-x86_64-Debug-All-MSAN.json index 94e3ff2919..17af3c2b75 100644 --- a/infra/bots/recipe_modules/flavor/examples/full.expected/Perf-Debian9-Clang-GCE-CPU-AVX2-x86_64-Debug-All-MSAN.json +++ b/infra/bots/recipe_modules/flavor/examples/full.expected/Perf-Debian9-Clang-GCE-CPU-AVX2-x86_64-Debug-All-MSAN.json @@ -7,11 +7,24 @@ "--json-output", "/path/to/tmp/json", "copy", - "file.text", + "file.txt", "/path/to/tmp/" ], "infra_step": true, - "name": "read file.text" + "name": "read file.txt" + }, + { + "cmd": [ + "python", + "-u", + "RECIPE_MODULE[recipe_engine::file]/resources/fileutil.py", + "--json-output", + "/path/to/tmp/json", + "remove", + "file.txt" + ], + "infra_step": true, + "name": "remove file.txt" }, { "cmd": [ diff --git a/infra/bots/recipe_modules/flavor/examples/full.expected/Perf-Debian9-Clang-GCE-CPU-AVX2-x86_64-Release-All-ASAN.json b/infra/bots/recipe_modules/flavor/examples/full.expected/Perf-Debian9-Clang-GCE-CPU-AVX2-x86_64-Release-All-ASAN.json index c769a8a0af..d6baf1fa47 100644 --- a/infra/bots/recipe_modules/flavor/examples/full.expected/Perf-Debian9-Clang-GCE-CPU-AVX2-x86_64-Release-All-ASAN.json +++ b/infra/bots/recipe_modules/flavor/examples/full.expected/Perf-Debian9-Clang-GCE-CPU-AVX2-x86_64-Release-All-ASAN.json @@ -7,11 +7,24 @@ "--json-output", "/path/to/tmp/json", "copy", - "file.text", + "file.txt", "/path/to/tmp/" ], "infra_step": true, - "name": "read file.text" + "name": "read file.txt" + }, + { + "cmd": [ + "python", + "-u", + "RECIPE_MODULE[recipe_engine::file]/resources/fileutil.py", + "--json-output", + "/path/to/tmp/json", + "remove", + "file.txt" + ], + "infra_step": true, + "name": "remove file.txt" }, { "cmd": [ diff --git a/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Android-Clang-AndroidOne-GPU-Mali400MP2-arm-Release-All-Android.json b/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Android-Clang-AndroidOne-GPU-Mali400MP2-arm-Release-All-Android.json index e7a0e69021..b06de4b82d 100644 --- a/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Android-Clang-AndroidOne-GPU-Mali400MP2-arm-Release-All-Android.json +++ b/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Android-Clang-AndroidOne-GPU-Mali400MP2-arm-Release-All-Android.json @@ -34,7 +34,7 @@ "/opt/infra-android/tools/adb", "shell", "cat", - "file.text" + "file.txt" ], "cwd": "[START_DIR]/skia", "env": { @@ -43,9 +43,26 @@ "PATH": ":RECIPE_REPO[depot_tools]" }, "infra_step": true, - "name": "read file.text", + "name": "read file.txt", "stdout": "/path/to/tmp/" }, + { + "cmd": [ + "/opt/infra-android/tools/adb", + "shell", + "rm", + "-f", + "file.txt" + ], + "cwd": "[START_DIR]/skia", + "env": { + "ADB_VENDOR_KEYS": "/home/chrome-bot/.android/chrome_infrastructure_adbkey", + "CHROME_HEADLESS": "1", + "PATH": ":RECIPE_REPO[depot_tools]" + }, + "infra_step": true, + "name": "rm file.txt" + }, { "cmd": [ "python", diff --git a/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Android-Clang-GalaxyS7_G930FD-GPU-MaliT880-arm64-Debug-All-Android.json b/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Android-Clang-GalaxyS7_G930FD-GPU-MaliT880-arm64-Debug-All-Android.json index 5ba8e63ccd..bb73f01da9 100644 --- a/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Android-Clang-GalaxyS7_G930FD-GPU-MaliT880-arm64-Debug-All-Android.json +++ b/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Android-Clang-GalaxyS7_G930FD-GPU-MaliT880-arm64-Debug-All-Android.json @@ -34,7 +34,7 @@ "/opt/infra-android/tools/adb", "shell", "cat", - "file.text" + "file.txt" ], "cwd": "[START_DIR]/skia", "env": { @@ -43,9 +43,26 @@ "PATH": ":RECIPE_REPO[depot_tools]" }, "infra_step": true, - "name": "read file.text", + "name": "read file.txt", "stdout": "/path/to/tmp/" }, + { + "cmd": [ + "/opt/infra-android/tools/adb", + "shell", + "rm", + "-f", + "file.txt" + ], + "cwd": "[START_DIR]/skia", + "env": { + "ADB_VENDOR_KEYS": "/home/chrome-bot/.android/chrome_infrastructure_adbkey", + "CHROME_HEADLESS": "1", + "PATH": ":RECIPE_REPO[depot_tools]" + }, + "infra_step": true, + "name": "rm file.txt" + }, { "cmd": [ "python", diff --git a/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Android-Clang-Nexus5x-GPU-Adreno418-arm64-Debug-All-Android.json b/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Android-Clang-Nexus5x-GPU-Adreno418-arm64-Debug-All-Android.json index 5ae5937c5b..b08b0394ed 100644 --- a/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Android-Clang-Nexus5x-GPU-Adreno418-arm64-Debug-All-Android.json +++ b/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Android-Clang-Nexus5x-GPU-Adreno418-arm64-Debug-All-Android.json @@ -34,7 +34,7 @@ "/opt/infra-android/tools/adb", "shell", "cat", - "file.text" + "file.txt" ], "cwd": "[START_DIR]/skia", "env": { @@ -43,9 +43,26 @@ "PATH": ":RECIPE_REPO[depot_tools]" }, "infra_step": true, - "name": "read file.text", + "name": "read file.txt", "stdout": "/path/to/tmp/" }, + { + "cmd": [ + "/opt/infra-android/tools/adb", + "shell", + "rm", + "-f", + "file.txt" + ], + "cwd": "[START_DIR]/skia", + "env": { + "ADB_VENDOR_KEYS": "/home/chrome-bot/.android/chrome_infrastructure_adbkey", + "CHROME_HEADLESS": "1", + "PATH": ":RECIPE_REPO[depot_tools]" + }, + "infra_step": true, + "name": "rm file.txt" + }, { "cmd": [ "python", diff --git a/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Android-Clang-Nexus5x-GPU-Adreno418-arm64-Release-All-Android_ASAN.json b/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Android-Clang-Nexus5x-GPU-Adreno418-arm64-Release-All-Android_ASAN.json index fee2a4447d..361123055b 100644 --- a/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Android-Clang-Nexus5x-GPU-Adreno418-arm64-Release-All-Android_ASAN.json +++ b/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Android-Clang-Nexus5x-GPU-Adreno418-arm64-Release-All-Android_ASAN.json @@ -34,7 +34,7 @@ "/opt/infra-android/tools/adb", "shell", "cat", - "file.text" + "file.txt" ], "cwd": "[START_DIR]/skia", "env": { @@ -43,9 +43,26 @@ "PATH": ":RECIPE_REPO[depot_tools]" }, "infra_step": true, - "name": "read file.text", + "name": "read file.txt", "stdout": "/path/to/tmp/" }, + { + "cmd": [ + "/opt/infra-android/tools/adb", + "shell", + "rm", + "-f", + "file.txt" + ], + "cwd": "[START_DIR]/skia", + "env": { + "ADB_VENDOR_KEYS": "/home/chrome-bot/.android/chrome_infrastructure_adbkey", + "CHROME_HEADLESS": "1", + "PATH": ":RECIPE_REPO[depot_tools]" + }, + "infra_step": true, + "name": "rm file.txt" + }, { "cmd": [ "python", diff --git a/infra/bots/recipe_modules/flavor/examples/full.expected/Test-ChromeOS-Clang-SamsungChromebookPlus-GPU-MaliT860-arm-Release-All.json b/infra/bots/recipe_modules/flavor/examples/full.expected/Test-ChromeOS-Clang-SamsungChromebookPlus-GPU-MaliT860-arm-Release-All.json index ab09ac9ae9..ea98f1f939 100644 --- a/infra/bots/recipe_modules/flavor/examples/full.expected/Test-ChromeOS-Clang-SamsungChromebookPlus-GPU-MaliT860-arm-Release-All.json +++ b/infra/bots/recipe_modules/flavor/examples/full.expected/Test-ChromeOS-Clang-SamsungChromebookPlus-GPU-MaliT860-arm-Release-All.json @@ -50,16 +50,35 @@ "-t", "foo@127.0.0.1", "cat", - "file.text" + "file.txt" ], "env": { "CHROME_HEADLESS": "1", "PATH": ":RECIPE_REPO[depot_tools]" }, "infra_step": true, - "name": "read file.text", + "name": "read file.txt", "stdout": "/path/to/tmp/" }, + { + "cmd": [ + "ssh", + "-oConnectTimeout=15", + "-oBatchMode=yes", + "-t", + "-t", + "foo@127.0.0.1", + "rm", + "-f", + "file.txt" + ], + "env": { + "CHROME_HEADLESS": "1", + "PATH": ":RECIPE_REPO[depot_tools]" + }, + "infra_step": true, + "name": "rm file.txt" + }, { "cmd": [ "python", diff --git a/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Debian9-Clang-GCE-CPU-AVX2-x86_64-Debug-All-Coverage.json b/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Debian9-Clang-GCE-CPU-AVX2-x86_64-Debug-All-Coverage.json index b77f1b6ce4..23f23b2a59 100644 --- a/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Debian9-Clang-GCE-CPU-AVX2-x86_64-Debug-All-Coverage.json +++ b/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Debian9-Clang-GCE-CPU-AVX2-x86_64-Debug-All-Coverage.json @@ -7,11 +7,24 @@ "--json-output", "/path/to/tmp/json", "copy", - "file.text", + "file.txt", "/path/to/tmp/" ], "infra_step": true, - "name": "read file.text" + "name": "read file.txt" + }, + { + "cmd": [ + "python", + "-u", + "RECIPE_MODULE[recipe_engine::file]/resources/fileutil.py", + "--json-output", + "/path/to/tmp/json", + "remove", + "file.txt" + ], + "infra_step": true, + "name": "remove file.txt" }, { "cmd": [ diff --git a/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Debian9-Clang-GCE-CPU-AVX2-x86_64-Release-All-Lottie.json b/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Debian9-Clang-GCE-CPU-AVX2-x86_64-Release-All-Lottie.json index 6e7d66b12b..7426c27b1b 100644 --- a/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Debian9-Clang-GCE-CPU-AVX2-x86_64-Release-All-Lottie.json +++ b/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Debian9-Clang-GCE-CPU-AVX2-x86_64-Release-All-Lottie.json @@ -7,11 +7,24 @@ "--json-output", "/path/to/tmp/json", "copy", - "file.text", + "file.txt", "/path/to/tmp/" ], "infra_step": true, - "name": "read file.text" + "name": "read file.txt" + }, + { + "cmd": [ + "python", + "-u", + "RECIPE_MODULE[recipe_engine::file]/resources/fileutil.py", + "--json-output", + "/path/to/tmp/json", + "remove", + "file.txt" + ], + "infra_step": true, + "name": "remove file.txt" }, { "cmd": [ diff --git a/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Debian9-Clang-GCE-CPU-AVX2-x86_64-Release-All-TSAN.json b/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Debian9-Clang-GCE-CPU-AVX2-x86_64-Release-All-TSAN.json index b6ed8586fb..4125178b7e 100644 --- a/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Debian9-Clang-GCE-CPU-AVX2-x86_64-Release-All-TSAN.json +++ b/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Debian9-Clang-GCE-CPU-AVX2-x86_64-Release-All-TSAN.json @@ -7,11 +7,24 @@ "--json-output", "/path/to/tmp/json", "copy", - "file.text", + "file.txt", "/path/to/tmp/" ], "infra_step": true, - "name": "read file.text" + "name": "read file.txt" + }, + { + "cmd": [ + "python", + "-u", + "RECIPE_MODULE[recipe_engine::file]/resources/fileutil.py", + "--json-output", + "/path/to/tmp/json", + "remove", + "file.txt" + ], + "infra_step": true, + "name": "remove file.txt" }, { "cmd": [ diff --git a/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Debian9-Clang-GCE-GPU-SwiftShader-x86_64-Debug-All-SwiftShader.json b/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Debian9-Clang-GCE-GPU-SwiftShader-x86_64-Debug-All-SwiftShader.json index 82f2ddacdf..78c7b419e5 100644 --- a/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Debian9-Clang-GCE-GPU-SwiftShader-x86_64-Debug-All-SwiftShader.json +++ b/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Debian9-Clang-GCE-GPU-SwiftShader-x86_64-Debug-All-SwiftShader.json @@ -7,11 +7,24 @@ "--json-output", "/path/to/tmp/json", "copy", - "file.text", + "file.txt", "/path/to/tmp/" ], "infra_step": true, - "name": "read file.text" + "name": "read file.txt" + }, + { + "cmd": [ + "python", + "-u", + "RECIPE_MODULE[recipe_engine::file]/resources/fileutil.py", + "--json-output", + "/path/to/tmp/json", + "remove", + "file.txt" + ], + "infra_step": true, + "name": "remove file.txt" }, { "cmd": [ diff --git a/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Debian9-Clang-NUC7i5BNK-GPU-IntelIris640-x86_64-Debug-All-OpenCL.json b/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Debian9-Clang-NUC7i5BNK-GPU-IntelIris640-x86_64-Debug-All-OpenCL.json index f0406884c5..5232d2ac9e 100644 --- a/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Debian9-Clang-NUC7i5BNK-GPU-IntelIris640-x86_64-Debug-All-OpenCL.json +++ b/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Debian9-Clang-NUC7i5BNK-GPU-IntelIris640-x86_64-Debug-All-OpenCL.json @@ -7,11 +7,24 @@ "--json-output", "/path/to/tmp/json", "copy", - "file.text", + "file.txt", "/path/to/tmp/" ], "infra_step": true, - "name": "read file.text" + "name": "read file.txt" + }, + { + "cmd": [ + "python", + "-u", + "RECIPE_MODULE[recipe_engine::file]/resources/fileutil.py", + "--json-output", + "/path/to/tmp/json", + "remove", + "file.txt" + ], + "infra_step": true, + "name": "remove file.txt" }, { "cmd": [ diff --git a/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Debian9-Clang-NUC7i5BNK-GPU-IntelIris640-x86_64-Debug-All-Vulkan.json b/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Debian9-Clang-NUC7i5BNK-GPU-IntelIris640-x86_64-Debug-All-Vulkan.json index 8e0b4f4ca6..1f98c87c94 100644 --- a/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Debian9-Clang-NUC7i5BNK-GPU-IntelIris640-x86_64-Debug-All-Vulkan.json +++ b/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Debian9-Clang-NUC7i5BNK-GPU-IntelIris640-x86_64-Debug-All-Vulkan.json @@ -7,11 +7,24 @@ "--json-output", "/path/to/tmp/json", "copy", - "file.text", + "file.txt", "/path/to/tmp/" ], "infra_step": true, - "name": "read file.text" + "name": "read file.txt" + }, + { + "cmd": [ + "python", + "-u", + "RECIPE_MODULE[recipe_engine::file]/resources/fileutil.py", + "--json-output", + "/path/to/tmp/json", + "remove", + "file.txt" + ], + "infra_step": true, + "name": "remove file.txt" }, { "cmd": [ diff --git a/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Mac10.13-Clang-MacBookPro11.5-CPU-AVX2-x86_64-Debug-All-ASAN.json b/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Mac10.13-Clang-MacBookPro11.5-CPU-AVX2-x86_64-Debug-All-ASAN.json index 4565ebeb85..c2ac47801e 100644 --- a/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Mac10.13-Clang-MacBookPro11.5-CPU-AVX2-x86_64-Debug-All-ASAN.json +++ b/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Mac10.13-Clang-MacBookPro11.5-CPU-AVX2-x86_64-Debug-All-ASAN.json @@ -7,11 +7,24 @@ "--json-output", "/path/to/tmp/json", "copy", - "file.text", + "file.txt", "/path/to/tmp/" ], "infra_step": true, - "name": "read file.text" + "name": "read file.txt" + }, + { + "cmd": [ + "python", + "-u", + "RECIPE_MODULE[recipe_engine::file]/resources/fileutil.py", + "--json-output", + "/path/to/tmp/json", + "remove", + "file.txt" + ], + "infra_step": true, + "name": "remove file.txt" }, { "cmd": [ diff --git a/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Ubuntu17-GCC-Golo-GPU-QuadroP400-x86_64-Release-All-Valgrind_AbandonGpuContext_SK_CPU_LIMIT_SSE41.json b/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Ubuntu17-GCC-Golo-GPU-QuadroP400-x86_64-Release-All-Valgrind_AbandonGpuContext_SK_CPU_LIMIT_SSE41.json index 82aec7026e..b1d1bb635e 100644 --- a/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Ubuntu17-GCC-Golo-GPU-QuadroP400-x86_64-Release-All-Valgrind_AbandonGpuContext_SK_CPU_LIMIT_SSE41.json +++ b/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Ubuntu17-GCC-Golo-GPU-QuadroP400-x86_64-Release-All-Valgrind_AbandonGpuContext_SK_CPU_LIMIT_SSE41.json @@ -7,11 +7,24 @@ "--json-output", "/path/to/tmp/json", "copy", - "file.text", + "file.txt", "/path/to/tmp/" ], "infra_step": true, - "name": "read file.text" + "name": "read file.txt" + }, + { + "cmd": [ + "python", + "-u", + "RECIPE_MODULE[recipe_engine::file]/resources/fileutil.py", + "--json-output", + "/path/to/tmp/json", + "remove", + "file.txt" + ], + "infra_step": true, + "name": "remove file.txt" }, { "cmd": [ diff --git a/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Win10-Clang-Golo-GPU-QuadroP400-x86_64-Release-All-Vulkan_ProcDump.json b/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Win10-Clang-Golo-GPU-QuadroP400-x86_64-Release-All-Vulkan_ProcDump.json index 3db3042261..aaf0b74e18 100644 --- a/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Win10-Clang-Golo-GPU-QuadroP400-x86_64-Release-All-Vulkan_ProcDump.json +++ b/infra/bots/recipe_modules/flavor/examples/full.expected/Test-Win10-Clang-Golo-GPU-QuadroP400-x86_64-Release-All-Vulkan_ProcDump.json @@ -7,11 +7,24 @@ "--json-output", "/path/to/tmp/json", "copy", - "file.text", + "file.txt", "/path/to/tmp/" ], "infra_step": true, - "name": "read file.text" + "name": "read file.txt" + }, + { + "cmd": [ + "python", + "-u", + "RECIPE_MODULE[recipe_engine::file]/resources/fileutil.py", + "--json-output", + "/path/to/tmp/json", + "remove", + "file.txt" + ], + "infra_step": true, + "name": "remove file.txt" }, { "cmd": [ diff --git a/infra/bots/recipe_modules/flavor/examples/full.expected/cpu_scale_failed.json b/infra/bots/recipe_modules/flavor/examples/full.expected/cpu_scale_failed.json index d2b815f85d..c01053ce23 100644 --- a/infra/bots/recipe_modules/flavor/examples/full.expected/cpu_scale_failed.json +++ b/infra/bots/recipe_modules/flavor/examples/full.expected/cpu_scale_failed.json @@ -34,7 +34,7 @@ "/usr/bin/adb.1.0.35", "shell", "cat", - "file.text" + "file.txt" ], "cwd": "[START_DIR]/skia", "env": { @@ -43,9 +43,26 @@ "PATH": ":RECIPE_REPO[depot_tools]" }, "infra_step": true, - "name": "read file.text", + "name": "read file.txt", "stdout": "/path/to/tmp/" }, + { + "cmd": [ + "/usr/bin/adb.1.0.35", + "shell", + "rm", + "-f", + "file.txt" + ], + "cwd": "[START_DIR]/skia", + "env": { + "ADB_VENDOR_KEYS": "/home/chrome-bot/.android/adbkey", + "CHROME_HEADLESS": "1", + "PATH": ":RECIPE_REPO[depot_tools]" + }, + "infra_step": true, + "name": "rm file.txt" + }, { "cmd": [ "python", diff --git a/infra/bots/recipe_modules/flavor/examples/full.expected/cpu_scale_failed_golo.json b/infra/bots/recipe_modules/flavor/examples/full.expected/cpu_scale_failed_golo.json index 17ba3f4671..a0b88adc20 100644 --- a/infra/bots/recipe_modules/flavor/examples/full.expected/cpu_scale_failed_golo.json +++ b/infra/bots/recipe_modules/flavor/examples/full.expected/cpu_scale_failed_golo.json @@ -34,7 +34,7 @@ "/opt/infra-android/tools/adb", "shell", "cat", - "file.text" + "file.txt" ], "cwd": "[START_DIR]/skia", "env": { @@ -43,9 +43,26 @@ "PATH": ":RECIPE_REPO[depot_tools]" }, "infra_step": true, - "name": "read file.text", + "name": "read file.txt", "stdout": "/path/to/tmp/" }, + { + "cmd": [ + "/opt/infra-android/tools/adb", + "shell", + "rm", + "-f", + "file.txt" + ], + "cwd": "[START_DIR]/skia", + "env": { + "ADB_VENDOR_KEYS": "/home/chrome-bot/.android/chrome_infrastructure_adbkey", + "CHROME_HEADLESS": "1", + "PATH": ":RECIPE_REPO[depot_tools]" + }, + "infra_step": true, + "name": "rm file.txt" + }, { "cmd": [ "python", diff --git a/infra/bots/recipe_modules/flavor/examples/full.expected/cpu_scale_failed_once.json b/infra/bots/recipe_modules/flavor/examples/full.expected/cpu_scale_failed_once.json index 991b3a8127..2f43739e9e 100644 --- a/infra/bots/recipe_modules/flavor/examples/full.expected/cpu_scale_failed_once.json +++ b/infra/bots/recipe_modules/flavor/examples/full.expected/cpu_scale_failed_once.json @@ -34,7 +34,7 @@ "/opt/infra-android/tools/adb", "shell", "cat", - "file.text" + "file.txt" ], "cwd": "[START_DIR]/skia", "env": { @@ -43,9 +43,26 @@ "PATH": ":RECIPE_REPO[depot_tools]" }, "infra_step": true, - "name": "read file.text", + "name": "read file.txt", "stdout": "/path/to/tmp/" }, + { + "cmd": [ + "/opt/infra-android/tools/adb", + "shell", + "rm", + "-f", + "file.txt" + ], + "cwd": "[START_DIR]/skia", + "env": { + "ADB_VENDOR_KEYS": "/home/chrome-bot/.android/chrome_infrastructure_adbkey", + "CHROME_HEADLESS": "1", + "PATH": ":RECIPE_REPO[depot_tools]" + }, + "infra_step": true, + "name": "rm file.txt" + }, { "cmd": [ "python", diff --git a/infra/bots/recipe_modules/flavor/examples/full.expected/failed_infra_step.json b/infra/bots/recipe_modules/flavor/examples/full.expected/failed_infra_step.json index 3e7d48417d..6e3be23f2a 100644 --- a/infra/bots/recipe_modules/flavor/examples/full.expected/failed_infra_step.json +++ b/infra/bots/recipe_modules/flavor/examples/full.expected/failed_infra_step.json @@ -34,7 +34,7 @@ "/opt/infra-android/tools/adb", "shell", "cat", - "file.text" + "file.txt" ], "cwd": "[START_DIR]/skia", "env": { @@ -43,9 +43,26 @@ "PATH": ":RECIPE_REPO[depot_tools]" }, "infra_step": true, - "name": "read file.text", + "name": "read file.txt", "stdout": "/path/to/tmp/" }, + { + "cmd": [ + "/opt/infra-android/tools/adb", + "shell", + "rm", + "-f", + "file.txt" + ], + "cwd": "[START_DIR]/skia", + "env": { + "ADB_VENDOR_KEYS": "/home/chrome-bot/.android/chrome_infrastructure_adbkey", + "CHROME_HEADLESS": "1", + "PATH": ":RECIPE_REPO[depot_tools]" + }, + "infra_step": true, + "name": "rm file.txt" + }, { "cmd": [ "python", diff --git a/infra/bots/recipe_modules/flavor/examples/full.expected/failed_read_version.json b/infra/bots/recipe_modules/flavor/examples/full.expected/failed_read_version.json index 3b32457018..428fba2105 100644 --- a/infra/bots/recipe_modules/flavor/examples/full.expected/failed_read_version.json +++ b/infra/bots/recipe_modules/flavor/examples/full.expected/failed_read_version.json @@ -34,7 +34,7 @@ "/opt/infra-android/tools/adb", "shell", "cat", - "file.text" + "file.txt" ], "cwd": "[START_DIR]/skia", "env": { @@ -43,9 +43,26 @@ "PATH": ":RECIPE_REPO[depot_tools]" }, "infra_step": true, - "name": "read file.text", + "name": "read file.txt", "stdout": "/path/to/tmp/" }, + { + "cmd": [ + "/opt/infra-android/tools/adb", + "shell", + "rm", + "-f", + "file.txt" + ], + "cwd": "[START_DIR]/skia", + "env": { + "ADB_VENDOR_KEYS": "/home/chrome-bot/.android/chrome_infrastructure_adbkey", + "CHROME_HEADLESS": "1", + "PATH": ":RECIPE_REPO[depot_tools]" + }, + "infra_step": true, + "name": "rm file.txt" + }, { "cmd": [ "python", diff --git a/infra/bots/recipe_modules/flavor/examples/full.expected/retry_adb_command.json b/infra/bots/recipe_modules/flavor/examples/full.expected/retry_adb_command.json index e77f4d2bea..bb52c3fa8d 100644 --- a/infra/bots/recipe_modules/flavor/examples/full.expected/retry_adb_command.json +++ b/infra/bots/recipe_modules/flavor/examples/full.expected/retry_adb_command.json @@ -34,7 +34,7 @@ "/opt/infra-android/tools/adb", "shell", "cat", - "file.text" + "file.txt" ], "cwd": "[START_DIR]/skia", "env": { @@ -43,9 +43,26 @@ "PATH": ":RECIPE_REPO[depot_tools]" }, "infra_step": true, - "name": "read file.text", + "name": "read file.txt", "stdout": "/path/to/tmp/" }, + { + "cmd": [ + "/opt/infra-android/tools/adb", + "shell", + "rm", + "-f", + "file.txt" + ], + "cwd": "[START_DIR]/skia", + "env": { + "ADB_VENDOR_KEYS": "/home/chrome-bot/.android/chrome_infrastructure_adbkey", + "CHROME_HEADLESS": "1", + "PATH": ":RECIPE_REPO[depot_tools]" + }, + "infra_step": true, + "name": "rm file.txt" + }, { "cmd": [ "python", diff --git a/infra/bots/recipe_modules/flavor/examples/full.expected/retry_adb_command_retries_exhausted.json b/infra/bots/recipe_modules/flavor/examples/full.expected/retry_adb_command_retries_exhausted.json index 58ea561951..1d3eb39bbe 100644 --- a/infra/bots/recipe_modules/flavor/examples/full.expected/retry_adb_command_retries_exhausted.json +++ b/infra/bots/recipe_modules/flavor/examples/full.expected/retry_adb_command_retries_exhausted.json @@ -34,7 +34,7 @@ "/opt/infra-android/tools/adb", "shell", "cat", - "file.text" + "file.txt" ], "cwd": "[START_DIR]/skia", "env": { @@ -43,9 +43,26 @@ "PATH": ":RECIPE_REPO[depot_tools]" }, "infra_step": true, - "name": "read file.text", + "name": "read file.txt", "stdout": "/path/to/tmp/" }, + { + "cmd": [ + "/opt/infra-android/tools/adb", + "shell", + "rm", + "-f", + "file.txt" + ], + "cwd": "[START_DIR]/skia", + "env": { + "ADB_VENDOR_KEYS": "/home/chrome-bot/.android/chrome_infrastructure_adbkey", + "CHROME_HEADLESS": "1", + "PATH": ":RECIPE_REPO[depot_tools]" + }, + "infra_step": true, + "name": "rm file.txt" + }, { "cmd": [ "python", diff --git a/infra/bots/recipe_modules/flavor/examples/full.expected/retry_ios_install.json b/infra/bots/recipe_modules/flavor/examples/full.expected/retry_ios_install.json index fc7a2ccf4f..55f98f0534 100644 --- a/infra/bots/recipe_modules/flavor/examples/full.expected/retry_ios_install.json +++ b/infra/bots/recipe_modules/flavor/examples/full.expected/retry_ios_install.json @@ -15,16 +15,28 @@ { "cmd": [ "[START_DIR]/skia/platform_tools/ios/bin/ios_cat_file", - "file.text" + "file.txt" ], "env": { "CHROME_HEADLESS": "1", "PATH": ":RECIPE_REPO[depot_tools]" }, "infra_step": true, - "name": "cat_file file.text", + "name": "cat_file file.txt", "stdout": "/path/to/tmp/" }, + { + "cmd": [ + "[START_DIR]/skia/platform_tools/ios/bin/ios_rm", + "file.txt" + ], + "env": { + "CHROME_HEADLESS": "1", + "PATH": ":RECIPE_REPO[depot_tools]" + }, + "infra_step": true, + "name": "rm file.txt" + }, { "cmd": [ "python", diff --git a/infra/bots/recipe_modules/flavor/examples/full.expected/retry_ios_install_retries_exhausted.json b/infra/bots/recipe_modules/flavor/examples/full.expected/retry_ios_install_retries_exhausted.json index 9c662f4341..aa17e602bb 100644 --- a/infra/bots/recipe_modules/flavor/examples/full.expected/retry_ios_install_retries_exhausted.json +++ b/infra/bots/recipe_modules/flavor/examples/full.expected/retry_ios_install_retries_exhausted.json @@ -15,16 +15,28 @@ { "cmd": [ "[START_DIR]/skia/platform_tools/ios/bin/ios_cat_file", - "file.text" + "file.txt" ], "env": { "CHROME_HEADLESS": "1", "PATH": ":RECIPE_REPO[depot_tools]" }, "infra_step": true, - "name": "cat_file file.text", + "name": "cat_file file.txt", "stdout": "/path/to/tmp/" }, + { + "cmd": [ + "[START_DIR]/skia/platform_tools/ios/bin/ios_rm", + "file.txt" + ], + "env": { + "CHROME_HEADLESS": "1", + "PATH": ":RECIPE_REPO[depot_tools]" + }, + "infra_step": true, + "name": "rm file.txt" + }, { "cmd": [ "python", diff --git a/infra/bots/recipe_modules/flavor/examples/full.py b/infra/bots/recipe_modules/flavor/examples/full.py index efd332febe..aae90494e0 100644 --- a/infra/bots/recipe_modules/flavor/examples/full.py +++ b/infra/bots/recipe_modules/flavor/examples/full.py @@ -37,7 +37,8 @@ def RunSteps(api): if 'Build' not in api.properties['buildername']: try: api.flavor.copy_file_to_device('file.txt', 'file.txt') - api.flavor.read_file_on_device('file.text') + api.flavor.read_file_on_device('file.txt') + api.flavor.remove_file_on_device('file.txt') api.flavor.create_clean_host_dir('results_dir') api.flavor.create_clean_device_dir('device_results_dir') if 'Lottie' in api.properties['buildername']: