(Sorry, hit enter too soon and truncated one of the comments) On Mon, Feb 11, 2019 at 10:32 AM Sam McCall via Phabricator < revi...@reviews.llvm.org> wrote:
> sammccall added a comment. > > In D56370#1391924 <https://reviews.llvm.org/D56370#1391924>, @nridge > wrote: > > > As far as reworking the tests to use these functions, I've thought about > that a bit: > > > > - These functions return AST nodes. It's not clear to me how I would > come up with "expected" AST nodes to test the return values against. > See FindDecl > See the findDecl overloads in TestTU.h - we use these for such tests. > - Even if we find a way to get "expected" AST nodes, we would be losing > test coverage of functions like `declToTypeHierarchyItem()` (though I > suppose we could write separate tests for that). > Yes, please do add unit tests for the functions separately - findDecl() also words to get the input to that function.
_______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits