aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGeorge Burgess IV <gbiv@google.com>2024-04-29 10:14:50 -0600
committerChromeos LUCI <chromeos-scoped@luci-project-accounts.iam.gserviceaccount.com>2024-05-06 14:44:05 +0000
commit8150d3053d53e82bd1fb9e94dc5c6b101e8a004f (patch)
treeca1b90c9cda6c8054e8fc641b09cfdd23459c8ef
parenta5cfa38846a8c90322467cebee61262a83394bf2 (diff)
downloadtoolchain-utils-8150d3053d53e82bd1fb9e94dc5c6b101e8a004f.tar.gz
remove remote_test
This script says that it wraps `test_that`, but it's pretty unclear how? It seems to copy a handful of files to hardcoded paths in /tmp, then echoes the board name. BUG=b:337837895 TEST=None Change-Id: Idf193a4c2c448591a33b0854387275cd1d7e6d54 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/third_party/toolchain-utils/+/5496646 Commit-Queue: George Burgess <gbiv@chromium.org> Reviewed-by: Jordan Abrahams-Whitehead <ajordanr@google.com> Reviewed-by: Bob Haarman <inglorion@chromium.org> Tested-by: George Burgess <gbiv@chromium.org>
l---------py/bin/remote_test.py1
-rw-r--r--remote_test.py110
2 files changed, 0 insertions, 111 deletions
diff --git a/py/bin/remote_test.py b/py/bin/remote_test.py
deleted file mode 120000
index 63d45c29..00000000
--- a/py/bin/remote_test.py
+++ /dev/null
@@ -1 +0,0 @@
-../../python_wrapper.py \ No newline at end of file
diff --git a/remote_test.py b/remote_test.py
deleted file mode 100644
index f7c98b86..00000000
--- a/remote_test.py
+++ /dev/null
@@ -1,110 +0,0 @@
-#!/usr/bin/env python3
-# -*- coding: utf-8 -*-
-#
-# Copyright 2020 The ChromiumOS Authors
-# Use of this source code is governed by a BSD-style license that can be
-# found in the LICENSE file.
-
-"""Script to wrap test_that script.
-
-This script can login to the chromeos machine using the test private key.
-"""
-
-
-__author__ = "asharif@google.com (Ahmad Sharif)"
-
-import argparse
-import os
-import sys
-
-from cros_utils import command_executer
-from cros_utils import misc
-
-
-def Usage(parser, message):
- print("ERROR: %s" % message)
- parser.print_help()
- sys.exit(0)
-
-
-def Main(argv):
- parser = argparse.ArgumentParser()
- parser.add_argument(
- "-c",
- "--chromeos_root",
- dest="chromeos_root",
- help="ChromeOS root checkout directory",
- )
- parser.add_argument(
- "-r", "--remote", dest="remote", help="Remote chromeos device."
- )
- options = parser.parse_args(argv)
- if options.chromeos_root is None:
- Usage(parser, "chromeos_root must be given")
-
- if options.remote is None:
- Usage(parser, "remote must be given")
-
- options.chromeos_root = os.path.expanduser(options.chromeos_root)
-
- command = "ls -lt /"
- ce = command_executer.GetCommandExecuter()
- ce.CrosRunCommand(
- command, chromeos_root=options.chromeos_root, machine=options.remote
- )
-
- version_dir_path, script_name = misc.GetRoot(sys.argv[0])
- version_dir = misc.GetRoot(version_dir_path)[1]
-
- # Tests to copy directories and files to the chromeos box.
- ce.CopyFiles(
- version_dir_path,
- "/tmp/" + version_dir,
- dest_machine=options.remote,
- dest_cros=True,
- chromeos_root=options.chromeos_root,
- )
- ce.CopyFiles(
- version_dir_path,
- "/tmp/" + version_dir + "1",
- dest_machine=options.remote,
- dest_cros=True,
- chromeos_root=options.chromeos_root,
- )
- ce.CopyFiles(
- sys.argv[0],
- "/tmp/" + script_name,
- recursive=False,
- dest_machine=options.remote,
- dest_cros=True,
- chromeos_root=options.chromeos_root,
- )
- ce.CopyFiles(
- sys.argv[0],
- "/tmp/" + script_name + "1",
- recursive=False,
- dest_machine=options.remote,
- dest_cros=True,
- chromeos_root=options.chromeos_root,
- )
-
- # Test to copy directories and files from the chromeos box.
- ce.CopyFiles(
- "/tmp/" + script_name,
- "/tmp/hello",
- recursive=False,
- src_machine=options.remote,
- src_cros=True,
- chromeos_root=options.chromeos_root,
- )
- ce.CopyFiles(
- "/tmp/" + script_name,
- "/tmp/" + script_name,
- recursive=False,
- src_machine=options.remote,
- src_cros=True,
- chromeos_root=options.chromeos_root,
- )
- board = ce.CrosLearnBoard(options.chromeos_root, options.remote)
- print(board)
- return 0