Closed Bug 1761511 Opened 2 years ago Closed 2 years ago

Consider vendoring gtest with ./mach vendor

Categories

(Testing :: GTest, task)

task

Tracking

(firefox101 fixed)

RESOLVED FIXED
101 Branch
Tracking Status
firefox101 --- fixed

People

(Reporter: nika, Assigned: nika)

References

Details

Attachments

(5 files)

Our current version of gtest is a few years old, and it could stand to be updated. It would be nice to vendor the library with ./mach vendor so that it's easier to update in the future.

This doesn't actually vendor the library in, but sets up the basic
configuration to allow it to be vendored in.

The latest commit on the main branch, rather than the latest tag, is used as
recommended by the googletest documentation.

Depends on D142607

This patch was performed automatically using ./mach vendor third_party/googletest/moz.yaml.

Depends on D142608

This required some changes to tests to account for the version differences.

Depends on D142609

As the new version is now being used, the previous version is no longer
necessary.

Depends on D142610

The TEST_CASE_P macros are deprecated in newer versions of gtest.

Depends on D142611

Pushed by nlayzell@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/1afb1f32a6a4
Part 1: Set up moz.yaml vendoring for gtest, r=ahal,tjr
https://hg.mozilla.org/integration/autoland/rev/8a18abcccda4
Part 2: Vendor the latest version of gtest, r=ahal
https://hg.mozilla.org/integration/autoland/rev/4c40758f54f1
Part 3: Switch builds over to use the new vendoring of gtest, r=ahal
https://hg.mozilla.org/integration/autoland/rev/88e6cf5c70e5
Part 4: Remove the previous vendoring of gtest, r=ahal
https://hg.mozilla.org/integration/autoland/rev/687de8c00013
Part 5: Fix gtest deprecation warnings, r=ahal

Backed out for causing windows build bustages.

Push with failures: https://treeherder.mozilla.org/jobs?repo=autoland&group_state=expanded&resultStatus=success%2Ctestfailed%2Cbusted%2Cexception%2Cusercancel&revision=687de8c00013fb4e3b89ae3fe6c6fb4d787faeaf&searchStr=build&selectedTaskRun=fpkhIL8aRkiATWmTHk-_ig.0

Failure log: https://treeherder.mozilla.org/logviewer?job_id=373647810&repo=autoland

Backout link: https://hg.mozilla.org/integration/autoland/rev/feb92ce315d6fee11b89705449e14c4d79cb3f81

[task 2022-04-06T21:08:17.577Z] 21:08:17     INFO -  In file included from /builds/worker/checkouts/gecko/third_party/googletest/googletest/src/gtest-all.cc:42:
[task 2022-04-06T21:08:17.577Z] 21:08:17     INFO -  /builds/worker/checkouts/gecko/third_party/googletest/googletest/src/gtest-death-test.cc(752,25): error: attempt to use a deleted function
[task 2022-04-06T21:08:17.577Z] 21:08:17     INFO -    event_handle_.Reset(::CreateEvent(
[task 2022-04-06T21:08:17.577Z] 21:08:17     INFO -                          ^
[task 2022-04-06T21:08:17.577Z] 21:08:17     INFO -  /builds/worker/workspace/obj-build/dist/stl_wrappers/windows.h(670,1): note: 'CreateEvent' has been explicitly marked deleted here
[task 2022-04-06T21:08:17.577Z] 21:08:17     INFO -  CreateEvent(LPSECURITY_ATTRIBUTES a0, BOOL a1, BOOL a2, LPCTSTR a3)
[task 2022-04-06T21:08:17.577Z] 21:08:17     INFO -  ^
[task 2022-04-06T21:08:17.577Z] 21:08:17     INFO -  1 error generated.
[task 2022-04-06T21:08:17.577Z] 21:08:17    ERROR -  gmake[4]: *** [/builds/worker/checkouts/gecko/config/rules.mk:658: gtest-all.obj] Error 1
[task 2022-04-06T21:08:17.577Z] 21:08:17     INFO -  gmake[4]: Leaving directory '/builds/worker/workspace/obj-build/third_party/googletest'
[task 2022-04-06T21:08:17.577Z] 21:08:17    ERROR -  gmake[3]: *** [/builds/worker/checkouts/gecko/config/recurse.mk:72: third_party/googletest/target-objects] Error 2
[task 2022-04-06T21:08:17.577Z] 21:08:17     INFO -  gmake[3]: *** Waiting for unfinished jobs....
Flags: needinfo?(nika)
Pushed by nlayzell@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/8a85d79a31cb
Part 1: Set up moz.yaml vendoring for gtest, r=ahal,tjr
https://hg.mozilla.org/integration/autoland/rev/73e0679b933c
Part 2: Vendor the latest version of gtest, r=ahal
https://hg.mozilla.org/integration/autoland/rev/ad011ff4b7f1
Part 3: Switch builds over to use the new vendoring of gtest, r=ahal
https://hg.mozilla.org/integration/autoland/rev/e890bc9400ab
Part 4: Remove the previous vendoring of gtest, r=ahal
https://hg.mozilla.org/integration/autoland/rev/d494a4a7cf3c
Part 5: Fix gtest deprecation warnings, r=ahal
Regressions: 1764725
Flags: needinfo?(nika)
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: