sammccall marked an inline comment as done.
sammccall added inline comments.


================
Comment at: unittests/clangd/QualityTests.cpp:1
 //===-- SourceCodeTests.cpp  ------------------------------------*- C++ 
-*-===//
 //
----------------
ioeric wrote:
> sammccall wrote:
> > ioeric wrote:
> > > Could you also add a test case for code completion?
> > The code completion scoring is tested in SymbolRelevanceSignalsSanity: file 
> > scope is boosted compared to default when the query is code-complete, but 
> > not when it's generic.
> > 
> > What kind of test do you mean?
> I was thinking a test case that covers the changes in CodeComplete.cpp e.g. 
> check that Relevance and Quality play well together, and locals/members are 
> boosted? Would that make sense?
Actually one of the purposes of pulling out the `Quality` module is to stop 
writing such tests :-)
They're fragile because ranking depends on many factors, e.g. at the moment you 
can't construct a completion candidate with a different scope that won't also 
get a different sema priority, so it's not clear why a test is passing/failing.
And for every signal, you need a test in code complete, and in workspace 
symbols...

It *would* be useful to have a smoke test in CodeCompletion to make sure we're 
using those scores. Maybe it would make sense to turn ReferencesAffectRanking 
or so into that?


Repository:
  rCTE Clang Tools Extra

https://reviews.llvm.org/D47762



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to