De-bitrot :billm's support for XPIDL constants/enums in C++ code and add test coverage
Categories
(Webtools :: Searchfox, enhancement)
Tracking
(Not tracked)
People
(Reporter: asuth, Assigned: asuth)
References
(Blocks 1 open bug)
Details
:billm had some enhancements to idl-analyze.py in https://github.com/mozsearch/mozsearch/pull/59 that never landed to support XPIDL enums. These changes (and in particular some refactoring cleanups) got a bit more bit-rotted by my changes in bug 1759064 (iterating on bug 1758394), but the core enhancements still stand. Aesthetically I think I probably favor the now-current emit_record
over the PR's source
/target
taking positional arguments, but that could be easily addressed via using python's keyword-based arguments if we cared.
We can now easily add test coverage for this at the analysis record and crossref level, but I think it's probably also thinking about whether we can add a searchfox-tool pipeline stage that could shell out to our spidermonkey js
shell and have it produce an example of what the context-menu's list of options will look like. That need not happen in this bug but I think that's a reasonable way to get us close to an end-to-end test without starting up a full browser, etc.
Assignee | ||
Comment 1•3 years ago
|
||
For bug 1776522 I'm touching the idl-analyze.py logic enough that it makes sense to do this at the same time.
The additional testing mechanism I describe is still interesting (although will be conceptually changed by bug 1776522) but definitely out of scope for this work. I think we can likely add the coverage in a non-duplicative way if/when we consider having the context-menu move towards using the "query" endpoint to express searches more semantically than building a symbol list. That said, the "structured" record will be growing very explicit relationship edges and that will inherently be something the insta-based tests will capture as long as the result includes the structured record.
Assignee | ||
Comment 2•2 years ago
|
||
The fixes landed as part of https://github.com/mozsearch/mozsearch/pull/603
Description
•