commit | 9b7bf37bfbd960e37fd89d81e5a149b1e047af50 | [log] [tgz] |
---|---|---|
author | Mathieu Binette <mbinette@google.com> | Fri Dec 07 00:39:48 2018 |
committer | Mathieu Binette <mbinette@google.com> | Mon Dec 10 21:59:27 2018 |
tree | ec846c80ff4a2be30451537765f5b199f394922e | |
parent | 79c7e3574651a123efa499ebd5494a59f49d409a [diff] |
Implement RunCommand (for tests) + MachineRegistryTest ^ Title. Validated with: > python ./test.py --test test.tests.MachineRegistryTest --host test.host.textpb ``` Running tests... PASSED VerifyRegistryKeys 1/1 tests passed. ``` Some examples of failures: ``` Running tests... FAILED VerifyRegistryKeys Traceback (most recent call last): File "/test/infra/controller.py", line 70, in ExecuteTestCase test(self=testCaseInstance) File "/test/tests/machine_registry.py", line 21, in VerifyRegistryKeys 'SomeMultiStringKey': '{First, Second, Third}' File "/test/tests/machine_registry.py", line 35, in assertRegistryContains self.assertEqual(ret, 0) File "/cel/test/infra/core/test_case.py", line 29, in assertEqual raise Exception("%s [first=%s, second=%s]" % (message, first, second)) Exception: Assertion failed [first=1, second=0] 0/1 tests passed. ``` ``` File "/test/tests/machine_registry.py", line 42, in assertRegistryContains self.assertTrue(key in actual, "Expected key (%s) missing from Get-ItemProperty output." % key) File "/test/infra/core/test_case.py", line 25, in assertTrue raise Exception(message) Exception: Expected key (SomeNewStringKey) missing from Get-ItemProperty output. ``` ``` [...] File "/test/tests/machine_registry.py", line 43, in assertRegistryContains self.assertEqual(actual[key], expected[key]) File "/test/infra/core/test_case.py", line 29, in assertEqual raise Exception("%s [first=%s, second=%s]" % (message, first, second)) Exception: Assertion failed [first=123, second=999] ``` Change-Id: I5b74914fd726ada0ff4555e46b2a16139d137377 Reviewed-on: https://chromium-review.googlesource.com/c/1362170 Reviewed-by: Fei Ling <feiling@chromium.org>
Chrome Enterprise Lab is an inaccurately named set of tools for building enterprise labs quickly and easily. The labs so built can be used for system level end-to-end testing of Google Chrome/Chromium.
Have a peek at the Design document.
Also have a peek at the Code of Conduct.
Most of the code is in Go. See Guide to code to get a head start on the code in this repository.
Go: Download Go from the Go download page. This project requires Go 1.9.4 or later. The build will fail with prior versions.
Depot Tools: Used for managing the checkout and the contributor workflow.
Protocol Buffers Compiler: Protocol buffers are used extensively for wranging all the data that needs to be shuttled around. Can be installed automatically via ./build.py deps --install
.
Dep : Used for Go depedency management. This can be installed automatically by running ./build.py deps --install
from the root of the source tree.
Go support for Protocol Buffers : This can be installed automatically by running ./build.py deps --install
from the root of the source tree.
There are two ways to get the source. One is to use managed deps, and the other is to use plain go get
. The latter workflow doesn't quite work yet due to this repository not being integrated with go.chromium.org
. So this page only mentions the managed dependency workflow.
Clone this repository:
Assumes that $GOPATH
is a single path and not a :
delimited list.
mkdir -p ${GOPATH}/src/chromium.googlesource.com/enterprise cd ${GOPATH}/src/chromium.googlesource.com/enterprise git clone https://chromium.googlesource.com/enterprise/cel cd cel
Get the dependencies:
python build.py deps --install
Use the build script:
python build.py build
Also make sure the tests pass.
python build.py test
See CONTRIBUTING.