Add the no_exit_time_destructors config to
third_party/googletest/BUILD.gn, as parts of googletest will trigger
-Wexit-time-destructors warnings if enabled.
This is effectively the same CL as https://crrev.com/c/7682299 in
Chromium. Standalone PDFium does not have -Wexit-time-destructors
enabled right now, but may in the near future. This prepares for that.
Change-Id: I5d688af1963fdcea49fdbcd3e4a78036afbb1635
Reviewed-on: https://pdfium-review.googlesource.com/c/pdfium/+/145110
Commit-Queue: Lei Zhang <thestig@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Follow up on https://pdfium-review.googlesource.com/117355 and do a bit
more cleanup. This diverges from Chromium, which added back gtest absl
support in https://crrev.com/1273784, but doing so would require also
checking out a copy of RE2. Since PDFium does not use RE2, adding a
test-only dependency is probably not worth the trouble.
Change-Id: I8d462e6c812fe87bed79f258aab0af7767e18d8f
Reviewed-on: https://pdfium-review.googlesource.com/c/pdfium/+/122930
Reviewed-by: Tom Sepez <tsepez@google.com>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
Update gtest_port_wrapper.cc so it builds with modern GoogleTest. Follow
Chromium's changes and omit the GTEST_HAS_ABSL define to make this
build. Also follow Chromium's changes and temporarily add gmock/gtest to
GN's no_check_targets list.
af29db7ec2..e4fdb87e76
Created with:
roll-dep third_party/googletest/src
Change-Id: I9ea694f3357d43d3192b8f830ad394143db57bfe
Reviewed-on: https://pdfium-review.googlesource.com/c/pdfium/+/117355
Reviewed-by: Thomas Sepez <tsepez@google.com>
Commit-Queue: Lei Zhang <thestig@chromium.org>
Same as crrev.com/1232942
Change-Id: I3ccdc42e8ec1e13edbe2ccb57dc1458a11bcf83c
Reviewed-on: https://pdfium-review.googlesource.com/c/pdfium/+/114430
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Auto-Submit: Lei Zhang <thestig@chromium.org>
Commit-Queue: Tom Sepez <tsepez@chromium.org>
Since a forward declaration is sufficient, just use that and avoid
breaking the "all" target. Albeit the "all" target is not supported.
Bug: chromium:1447523
Change-Id: I7ca7b89c8aff3eb0d926e64088846a94b88d3415
Reviewed-on: https://pdfium-review.googlesource.com/c/pdfium/+/107910
Reviewed-by: K. Moon <kmoon@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
Add custom gtest printer code to treat the C-string in a C-string to
ByteString comparison as a string instead of a pointer.
Change-Id: I9b496da300dd134c4e3a8ee626939c70815a6c8f
Reviewed-on: https://pdfium-review.googlesource.com/c/pdfium/+/107135
Reviewed-by: K. Moon <kmoon@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
Updates old-style copyright headers to the new style, by removing "All
rights reserved." Also inserts "The" before "PDFium Authors", which is
required by both styles.
Mechanically generated by this command:
PATTERN='Copyright \([0-9]\+\) \(The \)\?PDFium Authors. All rights reserved.'
git grep -l "$PATTERN" \
| xargs sed "s/$PATTERN/Copyright \1 The PDFium Authors/" -i''
Fixed: pdfium:1884
Change-Id: I6f781d811df8839e2e21b85f716529b813828bcd
Reviewed-on: https://pdfium-review.googlesource.com/c/pdfium/+/100371
Reviewed-by: Lei Zhang <thestig@chromium.org>
Commit-Queue: K. Moon <kmoon@chromium.org>
c9643a2e45..25ad42aabe
Updates //third_party/googletest/BUILD.gn to include the new
gtest-assertion-result.{h,cc} files.
Created with:
roll-dep third_party/googletest/src
Change-Id: I494094c95e65762ccd42ec43318b427fd3197d7b
Reviewed-on: https://pdfium-review.googlesource.com/c/pdfium/+/90324
Auto-Submit: K. Moon <kmoon@chromium.org>
Commit-Queue: K. Moon <kmoon@chromium.org>
Reviewed-by: Lei Zhang <thestig@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
Sync to https://crrev.com/921126, minus some WebRTC-specific bits.
This is required to pass GN check in the near future.
This also adds support for gtest_enable_absl_printers.
Change-Id: I950fb2bdb9761c7f79f767718e50e99cbf784512
Reviewed-on: https://pdfium-review.googlesource.com/c/pdfium/+/85728
Reviewed-by: Hui Yingst <nigi@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
It works around a problem that is not applicable to PDFium.
This is the same change as https://crrev.com/800817
Change-Id: Ibbb01d0c828175ace79302f4c8fd84c96f99c27e
Reviewed-on: https://pdfium-review.googlesource.com/c/pdfium/+/73173
Reviewed-by: Daniel Hosseinian <dhoss@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
Copy over relevant files that are in Chromium's googletest, but not
PDFium's. Delete references to files that no longer exist. With these
changes, testing/gtest can pass "gn check".
Bug: pdfium:1580
Change-Id: Ia56857197c55a6fe55f26b7de91ccd9f37164730
Reviewed-on: https://pdfium-review.googlesource.com/c/pdfium/+/72991
Reviewed-by: Daniel Hosseinian <dhoss@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
`gn format` recently changed its formatting behavior for deps, source,
and a few other elements when they are assigned (with =) single-element
lists to be consistent with the formatting of updates (with +=) with
single-element.
Now that we've rolled in a GN binary with the change, reformat all files
so that people don't get presubmit warnings due to this.
Bug: chromium:1041419
Tbr: thakis@chromium.org
Change-Id: I879c199419bdd2a9fe09ab09d1a0ce6e178b4fee
Reviewed-on: https://pdfium-review.googlesource.com/c/pdfium/+/65531
Commit-Queue: Lei Zhang <thestig@chromium.org>
Reviewed-by: Lei Zhang <thestig@chromium.org>
The pdfium_unittest target currently fails to build because of an
undefined reference to gtest's matchers.
Fix this by including gtest-matchers.{h,cpp} in gtest's source_set.
Change-Id: I4dffd1e924cc48b013504dcdfdf7b702c47b4780
Reviewed-on: https://pdfium-review.googlesource.com/c/50451
Reviewed-by: Lei Zhang <thestig@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>