This is an archive of the discontinued LLVM Phabricator instance.

[flang] Update format tests to use GTest
ClosedPublic

Authored by ashermancinelli on Apr 19 2021, 7:41 AM.

Details

Summary

Update format tests to use GTest. Add some death tests for failure cases.

Diff Detail

Event Timeline

ashermancinelli requested review of this revision.Apr 19 2021, 7:41 AM
Herald added a project: Restricted Project. · View Herald TranscriptApr 19 2021, 7:41 AM
awarzynski accepted this revision.Apr 20 2021, 10:09 AM

This patch refactors the original tests to use GTest and also adds some new ones. Thank you!

LGTM, but please look into the CI failures before merging.

This revision is now accepted and ready to land.Apr 20 2021, 10:09 AM

Resolve warnings by removing utility function.

Resolve warnings by removing utility function.

Thank you for fixing the build. The new failures are clearly unrelated to this change and IMO it is safe to merge this.

Remove erroneous static qualifiers. Register all tests with crash handler.

awarzynski added inline comments.Apr 23 2021, 2:48 AM
flang/unittests/RuntimeGTest/Format.cpp
29–30

Could you copy the missing implementation across? Ta!

108

const auto& ? Otherwise there is going to be a warning, and all warnings are treated as errors in Flang :)

awarzynski requested changes to this revision.Apr 23 2021, 2:48 AM
This revision now requires changes to proceed.Apr 23 2021, 2:48 AM

Resolve warnings against const auto without &.

Pull all of previous test harness into current implementation.

ashermancinelli marked 2 inline comments as done.Apr 23 2021, 7:37 AM

Thanks again for the rigorous review!

awarzynski accepted this revision.Apr 26 2021, 8:10 AM

Looks good, thank you! The pre-commit CI failures are clearly unrelated to this patch.

This revision is now accepted and ready to land.Apr 26 2021, 8:10 AM
This revision was landed with ongoing or failed builds.Apr 27 2021, 7:46 AM
This revision was automatically updated to reflect the committed changes.
flang/unittests/Runtime/CMakeLists.txt