History log of /system/update_engine/scripts/update_payload/test_utils.py
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
912c4df6c4f470ddb6937b40cbe281229548783d 10-Dec-2015 Sen Jiang <senj@chromium.org> paycheck: support minor version 3.

Added check for mandatory source operation hash in minor version 3.

Fixed unittest.

BUG=chromium:568473
TEST=./paycheck.py <minor v3 payload>; ./checker_unittest.py

Change-Id: Id96ddce8c59f28b3449524b786c54a6c69ca798f
Reviewed-on: https://chromium-review.googlesource.com/317573
Trybot-Ready: Sen Jiang <senj@chromium.org>
Tested-by: Sen Jiang <senj@chromium.org>
Reviewed-by: Alex Deymo <deymo@chromium.org>
Reviewed-by: Gilad Arnold <garnold@chromium.org>
Commit-Queue: Alex Deymo <deymo@chromium.org>
/system/update_engine/scripts/update_payload/test_utils.py
2846677f9ec7725d9cf9513768477c873c19ba78 12-Sep-2015 Alex Deymo <deymo@chromium.org> paycheck: Update generated protobuf code.

This patch updates the generated update_metadata_pb2.py file with the
latest changes in the udpate_metadata.proto file. Some other changes in
the update_payload library were required to match the changes in the
.proto file.

BUG=b:23179128
TEST=paycheck unittests

Change-Id: I482d67d4a35f69438a26395eea77286994108b7a
Reviewed-on: https://chromium-review.googlesource.com/299498
Commit-Ready: Alex Deymo <deymo@chromium.org>
Tested-by: Alex Deymo <deymo@chromium.org>
Reviewed-by: Gilad Arnold <garnold@chromium.org>
/system/update_engine/scripts/update_payload/test_utils.py
0d575cde18a1b44e386181dc1abbc611b9ae7a59 14-Jul-2015 Gilad Arnold <garnold@chromium.org> paycheck: Improve minor_version checking.

1) We explicitly catch whether this field is not set. This means we
might fail payloads generated by an old delta_generator, but ensures
that we catch such a failure in current payload generation. Test
logic slightly restructured to reduce duplication.

2) Slight changes to the checker method signature, for better uniformity
with the rest of the code. This also lets us test that we actually
read the minor_version field.

BUG=chromium:508566
TEST=Unit tests (revised)

Change-Id: Ib2d1999964ba892ef778ffc16bd1ca1c7d02bcd5
Reviewed-on: https://chromium-review.googlesource.com/285446
Tested-by: Gilad Arnold <garnold@chromium.org>
Reviewed-by: Gilad Arnold <garnold@chromium.org>
Commit-Queue: Gilad Arnold <garnold@chromium.org>
/system/update_engine/scripts/update_payload/test_utils.py
25c18211b66715d35236259fcd0d3e6c0980780a 14-Jul-2015 Gilad Arnold <garnold@chromium.org> Fix linter errors.

BUG=None
TEST=None

Change-Id: I65434c5e7d00006b89d71aadb5a4721ee16ff289
Reviewed-on: https://chromium-review.googlesource.com/285445
Tested-by: Gilad Arnold <garnold@chromium.org>
Reviewed-by: Chris Sosa <sosa@chromium.org>
Commit-Queue: Gilad Arnold <garnold@chromium.org>
/system/update_engine/scripts/update_payload/test_utils.py
18f4f9fab192e75a3477979c03a89381c35fd974 03-Apr-2013 Gilad Arnold <garnold@chromium.org> paycheck: move stuff from checker_unittest.py to test_utils.py

This is all stuff that'll come in handy when testing other modules.

BUG=chromium:217039,chromium:215780,chromium:189855
TEST=Passes unittests

Change-Id: I57d1fae97330f22748885f8028352f07b5058396
Reviewed-on: https://gerrit.chromium.org/gerrit/47615
Tested-by: Gilad Arnold <garnold@chromium.org>
Reviewed-by: Don Garrett <dgarrett@chromium.org>
Commit-Queue: Gilad Arnold <garnold@chromium.org>
/system/update_engine/scripts/update_payload/test_utils.py
5502b56f34f9703cf053be46e4ea5685c0c9ac26 08-Mar-2013 Gilad Arnold <garnold@chromium.org> paycheck: unit tests + fixes to checker module

This adds missing unit tests for the checker module, bundled with fixes
to some bugs that surfaced due to unit tests. This includes:

* A fake extent (signified by start_block == UINT64_MAX) that
accompanies a signature data blob bears different requirements than
previously implemented. Specifically, the extent sequence must have
exactly one extent; and the number of blocks is not necessarily one,
rather it is the correct number that corresponds to the actual length
of the signature blob.

* REPLACE/REPLACE_BZ operations must contain data.

* MOVE operation validation must ensure that all of the actual message
extents are being used.

* BSDIFF operation must contain data (the diff).

* Signature pseudo-operation should be a REPLACE.

BUG=chromium-os:34911,chromium-os:33607,chromium-os:7597
TEST=Passes unittests (upcoming); works with actual payloads.

Change-Id: I4d839d1d4da1fbb4a493b208958a139368e2c8ca
Reviewed-on: https://gerrit.chromium.org/gerrit/45429
Tested-by: Gilad Arnold <garnold@chromium.org>
Reviewed-by: Chris Sosa <sosa@chromium.org>
Commit-Queue: Gilad Arnold <garnold@chromium.org>
/system/update_engine/scripts/update_payload/test_utils.py