~gary-wzl77/snappy-hwe-snaps/+git/ubuntu-custom-image:assembler_unit_tests

Last commit made on 2017-11-16
Get this branch:
git clone -b assembler_unit_tests https://git.launchpad.net/~gary-wzl77/snappy-hwe-snaps/+git/ubuntu-custom-image
Only Gary.Wang can upload to this branch. If you are Gary.Wang please log in for upload directions.

Branch merges

Branch information

Name:
assembler_unit_tests
Repository:
lp:~gary-wzl77/snappy-hwe-snaps/+git/ubuntu-custom-image

Recent commits

d69b211... by Gary.Wang

Address the review comments.

e424af8... by Gary.Wang

Merge git+ssh://git.launchpad.net/~snappy-hwe-team/snappy-hwe-snaps/+git/ubuntu-custom-image into assembler_unit_tests

a155cca... by System Enablement CI Bot <email address hidden>

Merge remote tracking branch fix_none_output_dir

Merge-Proposal: https://code.launchpad.net/~gary-wzl77/snappy-hwe-snaps/+git/ubuntu-custom-image/+merge/333675

Author: Gary.Wang <email address hidden>

Make sure the final image file path is valid before invoking hooks.

If output_dir is not given in the command line, an exception is thrown out
in ImageAssembler, we need to know exact output dir before CustomBuilder is
instantiated so that the actual image file path can be exported to
pre-custom-raw hooks.
The argument(image_spec_file) is not updated in main.py which causes the
some current unit tests to fail.
This MP fixes the above issues.

I'll add the corresponding unit tests in assemble_unit_test branch once it's merged.

11d50a5... by Gary.Wang

Deal with a nitpicking and change "move" to "copy" in the comment.

ba044bd... by Gary.Wang

Better writing for the comment.

a765434... by Gary.Wang

Address the review comments.

07d85ab... by Gary.Wang

Image assembler unit tests refine.

Add three more test cases for a good code coverage[raw_hooks, image
 file location test(output_dir), hooks_directory argument in ubuntu_image].
Also Return subprocess exit info when mocking classic image creation.

a623e69... by Gary.Wang

Make sure the final image file path is valid before invoking hooks.

If output_dir is not given in the command line, an exception is thrown out
in ImageAssembler, we need to know exact output dir before customBuilder is
instantiated so that the actual image file path can be exported to
pre-custom-raw hooks.
The argument(image_spec_file) is not updated in main.py which causes the
some current unit tests to fail.
This MP fixes the above issues.

32df3d3... by Gary.Wang

Update the test cases a bit as test data location is changed, also some
cleanups. Some logic fine-tuned on member variables initialization.

b5e3f9a... by Gary.Wang

A tiny cleanup.