Closed Bug 1237179 Opened 4 years ago Closed 4 years ago

Add mach command to run firefox-ui-tests from the source directory


(Firefox Build System :: Mach Core, enhancement)

45 Branch
Not set


(firefox45 fixed, firefox46 fixed)

Tracking Status
firefox45 --- fixed
firefox46 --- fixed


(Reporter: whimboo, Assigned: whimboo)




(2 files)

With bug 1212609 we moved our firefox-ui-tests into mozilla-central. To make it easy for developers to run our tests we should add a mach command to directly execute our tests from the source directory.

We want this for mozilla-central and mozilla-aurora (which will become the next 45ESR).
Simple addition by taking the marionette command as template. For now the firefox-ui-test command will work given that we cannot run our update cli due to no updates available. If more types will be added later we will extend the testtype option.

I hope it's ok that I did a small reordering of commands and search paths given that some entries had duplicates and I hate non-alphabetic sorting. :)
Attachment #8708424 - Flags: review?(gps)
Just used it locally, and works like charm.
Comment on attachment 8708424 [details] [diff] [review]
Mach support for firefox-ui-tests

Review of attachment 8708424 [details] [diff] [review]:

Looks pretty straightforward!
Attachment #8708424 - Flags: review?(gps) → review+
Closed: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla46
Patch applies cleanly on mozilla-aurora, so requesting check-in.
Whiteboard: [checkin-needed-aurora]
(In reply to Henrik Skupin (:whimboo) from comment #6)
> Patch applies cleanly on mozilla-aurora, so requesting check-in.

Just to add, this patch only contains testing changes (a=testonly), nothing which affects Firefox as product.
Whiteboard: [checkin-needed-aurora]
Greg, I have seen that people are modifying and get packages added. It's something what I haven't done on this bug. Do I have to get this fixed?
Flags: needinfo?(gps)
(In reply to Carsten Book [:Tomcat] from comment #10)
> backed this out for test failures in
> aurora

I'm preparing a fix now.
Looks like we need to also uplift bug 1230279 for those test failures to go away.
Depends on: 1230279
(In reply to Henrik Skupin (:whimboo) from comment #9)
> Greg, I have seen that people are modifying
> and get packages added. It's something what I haven't done on this bug. Do I
> have to get this fixed?

It depends. That file populates the default virtualenv in the objdir as needed by the build system. For Python packages used by mach commands, it is acceptable for the mach command to install packages at run time. Search for "virtualenv_manager" in files. This won't fly in automation, however, as there may be firewalls in place. If you need to run a mach command in automation, it's best to just add stuff to virtualenv_packages.txt.
Flags: needinfo?(gps)
Ok, so we don't have to do it then. Regarding the backout of my patch due to bustage as caused by the not uplifted changes on bug 1230279, I will try to find a way without having to modify marionette itself. Even if we have a limit feature set it might be good to have.
Flags: needinfo?(hskupin)
Backport patch for mozilla-aurora so that we can at least use mach to run the tests. The difference here is that we do not use our own cli entry function but directly invoke the MarionetteHarness. That way no change of Marionette is necessary which has been broken the media tests on its landing.
Attachment #8710746 - Flags: review?(gps)
Comment on attachment 8710746 [details] [diff] [review]
Mach support for firefox-ui-tests (backport mozilla-aurora)

Review of attachment 8710746 [details] [diff] [review]:

Looks just like what I reviewed previously!
Attachment #8710746 - Flags: review?(gps) → review+
This is a test-only change which we want to have on beta for esr45. Please land it.
Whiteboard: [checkin-needed-beta]
Pushed to beta since releng needed something pushed to test an unrelated fix:
Whiteboard: [checkin-needed-beta]
Blocks: 1245468
Product: Core → Firefox Build System
You need to log in before you can comment on or make changes to this bug.