Closed Bug 1818168 Opened 2 years ago Closed 2 years ago

deb: Unit test `python/mozbuild/mozbuild/repackaging/deb.py`

Categories

(Release Engineering :: Release Automation: L10N, enhancement)

enhancement

Tracking

(firefox112 fixed)

RESOLVED FIXED
Tracking Status
firefox112 --- fixed

People

(Reporter: jlorenzo, Assigned: jlorenzo)

References

(Blocks 1 open bug)

Details

Attachments

(9 files)

(deleted), text/x-phabricator-request
Details
(deleted), text/x-phabricator-request
Details
(deleted), text/x-phabricator-request
Details
(deleted), text/x-phabricator-request
Details
(deleted), text/x-phabricator-request
Details
(deleted), text/x-phabricator-request
Details
(deleted), text/x-phabricator-request
Details
(deleted), text/x-phabricator-request
Details
(deleted), text/x-phabricator-request
Details

In bug 1799233, we created python/mozbuild/mozbuild/repackaging/deb.py. It's meant to be used as a mach command. At that time, we didn't add unit tests. The current logic is baked in a single 120-line function[1].

In bug 1799042, we will reuse some of this logic to repackage l10n extensions (aka langpacks). In order to pave the way for bug 1799042, let's break this big function into smaller ones and get them unit-tested.

[1] https://searchfox.org/mozilla-central/rev/611660bff9e6d52f1769bf216a7fbd12ece4d2d2/python/mozbuild/mozbuild/repackaging/deb.py#39-160

Depends on bug 1811114 because repackage_deb() got changed in there too.

Depends on: 1811114
Pushed by jlorenzo@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/45084ef18654 part 1: Extract _is_chroot_available() from repackage_deb() r=gabriel https://hg.mozilla.org/integration/autoland/rev/d5919ffd9885 part 2: Extract _get_command() from repackage_deb() r=gabriel https://hg.mozilla.org/integration/autoland/rev/1e84780dade8 part 3: Extract _generate_deb_archive() from repackage_deb() r=gabriel https://hg.mozilla.org/integration/autoland/rev/3bd13142ca01 part 4: Extract _inject_deb_distribution_folder() from repackage_deb() r=gabriel https://hg.mozilla.org/integration/autoland/rev/760e05d3d98d part 5: Extract _copy_plain_deb_config() from repackage_deb() r=gabriel https://hg.mozilla.org/integration/autoland/rev/be32fa25c2b2 part 6: Extract _render_deb_templates() from repackage_deb() r=gabriel https://hg.mozilla.org/integration/autoland/rev/21fc9ff181ba part 7: Extract _get_build_variables() from repackage_deb() r=gabriel https://hg.mozilla.org/integration/autoland/rev/acd30b40e314 part 8: Extract _extract_application_ini_data() from repackage_deb() r=gabriel https://hg.mozilla.org/integration/autoland/rev/8302e7129c45 part 9: Rename source_dir variable in repackage_deb() r=gabriel
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: