aboutsummaryrefslogtreecommitdiff
path: root/binary_search_tool/test/is_good.py
AgeCommit message (Collapse)Author
2022-09-13Update license boilerplate text in source code filesMike Frysinger
Normally we don't do this, but enough changes have accumulated that we're doing a tree-wide one-off update of the name & style. BUG=chromium:1098010 TEST=`repo upload` works Change-Id: Icb42e5012a87920c2cd13b666fb3e55e7e4fb3b8 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/third_party/toolchain-utils/+/3891080 Auto-Submit: Mike Frysinger <vapier@chromium.org> Tested-by: Mike Frysinger <vapier@chromium.org> Commit-Queue: George Burgess <gbiv@chromium.org> Reviewed-by: George Burgess <gbiv@chromium.org>
2022-09-07remove `from __future__ import ...` directivesGeorge Burgess IV
These are only useful when we're running code in a Python 2.7 interpreter. Since we no longer support python2, drop these. BUG=b:244644217 TEST=run_tests_for.py shows no new failures Change-Id: Ief9a12b87a560ab38ca71668636874bcb434a0b3 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/third_party/toolchain-utils/+/3877339 Reviewed-by: Ryan Beltran <ryanbeltran@chromium.org> Commit-Queue: George Burgess <gbiv@chromium.org> Reviewed-by: Jordan Abrahams-Whitehead <ajordanr@google.com> Tested-by: George Burgess <gbiv@chromium.org>
2022-09-07Autoformat all Python codeGeorge Burgess IV
This autoformats all Python code with our new Python formatter, `black`. BUG=b:244644217 TEST=None Change-Id: I15ee49233d98fb6295c0c53c129bbf8e78e0d9ff Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/third_party/toolchain-utils/+/3877337 Tested-by: George Burgess <gbiv@chromium.org> Reviewed-by: Jordan Abrahams-Whitehead <ajordanr@google.com> Commit-Queue: George Burgess <gbiv@chromium.org>
2022-04-21toolchain_utils: s/Cr OS/CrOS/gGeorge Burgess IV
Result of running `sed -ri 's/Chrom(ium|e) OS/Chrom\1OS/g' $(find -type f)`. BUG=None TEST=None Change-Id: I59be92537aa19bc989f52b585e307e76dbde401b Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/third_party/toolchain-utils/+/3600147 Reviewed-by: Manoj Gupta <manojgupta@chromium.org> Commit-Queue: George Burgess <gbiv@chromium.org> Tested-by: George Burgess <gbiv@chromium.org>
2020-02-10toolchain-utils: port binary_search_tool to python3Zhizhou Yang
This patch migrates bisect tool in toolchain-utils to python 3. BUG=chromium:1011676 TEST=Passed all unittests and run_bisect_tests.py Change-Id: Ia6dd48d927eddcbb2118058f63b33be843d3eb7a Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/third_party/toolchain-utils/+/2042219 Tested-by: Zhizhou Yang <zhizhouy@google.com> Auto-Submit: Zhizhou Yang <zhizhouy@google.com> Reviewed-by: George Burgess <gbiv@chromium.org>
2020-02-06binary_search_tool: fix failures in presubmitZhizhou Yang
This patch is to make binary_search_tool in toolchain-utils pass all presbumit checks, as a prerequisite for python 3 migration. BUG=chromium:1011676 TEST=Passed all unittests. Change-Id: Ie7880982f1ca3ae7e6c3d3f342a7a7c076fa9de9 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/third_party/toolchain-utils/+/2037142 Tested-by: Zhizhou Yang <zhizhouy@google.com> Auto-Submit: Zhizhou Yang <zhizhouy@google.com> Commit-Queue: Zhizhou Yang <zhizhouy@google.com> Reviewed-by: George Burgess <gbiv@chromium.org>
2017-04-08[toolchain-utils] Fix remaining lint errors in toolchain-utils.Caroline Tice
In addition to fixing the lint errors, this also fixes the Python formatting issues (ran tc_pyformat on nearly all the files). BUG=chromium:570450 TEST=Ran all crosperf & bisect tool unit tests. Ran afe_lock_machine.py (check machine status) Ran full crosperf test (octane, speedometer, BootPerf) on alex. Change-Id: Ic86f9192801ac67769f3de30f1c5f0d203ce0831 Reviewed-on: https://chromium-review.googlesource.com/471886 Commit-Ready: Caroline Tice <cmtice@chromium.org> Tested-by: Caroline Tice <cmtice@chromium.org> Reviewed-by: Manoj Gupta <manojgupta@chromium.org>
2016-08-09binary search tool: Rename install to test_setupCassidy Burden
Refactor warning! Rename install script to be test_setup script. TEST=Run unit tests Change-Id: Iab7e01136fdcf2dedbfc94ece6ddb4b4fa3c0f68 Reviewed-on: https://chrome-internal-review.googlesource.com/273484 Commit-Ready: Cassidy Burden <cburden@google.com> Tested-by: Cassidy Burden <cburden@google.com> Reviewed-by: Caroline Tice <cmtice@google.com>
2016-06-15Fix binary search tool install unit testsCassidy Burden
Change from using module wide variable common.installed to using a file called "./installed". Previously common.installed wouldn't actually be set properly because there would be two separate instances of Python running. TEST=More robust install unit test made Change-Id: Iee87a52e0f54fc63837b25918764e804747525db Reviewed-on: https://chrome-internal-review.googlesource.com/264745 Commit-Ready: Cassidy Burden <cburden@google.com> Tested-by: Cassidy Burden <cburden@google.com> Reviewed-by: Caroline Tice <cmtice@google.com>
2016-06-08Add install_script argument to binary search tool.Cassidy Burden
Add optional install_script argument that will run before test_script use this install_script to perform building/flashing/other misc. setup. If your build or flash succeeds then return 0, otherwise return 1 and this build will be "skipped" (equivalent to the test script returning a 2 exit code). Test=Update unit tests to test for successful and failed install Change-Id: Ic492f08230796f50b7bb93aebe078960419a3c99 Reviewed-on: https://chrome-internal-review.googlesource.com/262988 Commit-Ready: Cassidy Burden <cburden@google.com> Tested-by: Cassidy Burden <cburden@google.com> Reviewed-by: Caroline Tice <cmtice@google.com>
2016-06-01Fix linting errors with binary search tool.Cassidy Burden
Fix basic style errors in BST tests and remove use of optparse across scripts. Change-Id: I4f484fb22ca6bb6849d79144bf7bdb7a38e49468 Reviewed-on: https://chrome-internal-review.googlesource.com/261739 Commit-Ready: Cassidy Burden <cburden@google.com> Tested-by: Cassidy Burden <cburden@google.com> Reviewed-by: Caroline Tice <cmtice@google.com> Reviewed-by: Han Shen <shenhan@google.com>
2015-12-16Run pyformat on all the toolchain-utils files.Luis Lozano
This gets rid of a lot of lint issues. Ran by doing this: for f in *.py; do echo -n "$f " ; if [ -x $f ]; then pyformat -i --remove_trailing_comma --yapf --force_quote_type=double $f ; else pyformat -i --remove_shebang --remove_trailing_comma --yapf --force_quote_type=double $f ; fi ; done BUG=chromium:567921 TEST=Ran simple crosperf run. Change-Id: I59778835fdaa5f706d2e1765924389f9e97433d1 Reviewed-on: https://chrome-internal-review.googlesource.com/242031 Reviewed-by: Luis Lozano <llozano@chromium.org> Commit-Queue: Luis Lozano <llozano@chromium.org> Tested-by: Luis Lozano <llozano@chromium.org> Reviewed-by: Yunlian Jiang <yunlian@google.com>
2014-11-27Move binary search tool to toolchain-utils with a comprehensive test suite.Han Shen
We now can test the binary search tool with - ./binary_search_tool_tester.py This will generate a set of object files with some bad ones, and call the binary search tool to find them out. TEST=gpylint and passed my test suite BUG=None Change-Id: I56fbda7f75fe3bc239e456161c48b7611c3a315d Reviewed-on: https://chrome-internal-review.googlesource.com/150255 Reviewed-by: Luis Lozano <llozano@chromium.org> Commit-Queue: Han Shen <shenhan@google.com> Tested-by: Han Shen <shenhan@google.com>