docs: document isExtend FQN contract - #753
Conversation
|
📦 Plugin has been packaged for this PR. You can download |
isExtend delegates to InheritanceHelper.isInheritor, which matches fully qualified class names only — a simple name like "Result" silently never matches. The method.return.main rule example in EndpointBuilder encoded exactly that mistake, so fix it and state the contract on both script-facing declarations (ClassContext and ScriptTypeContext) where rule authors see it in IDE quick docs. Also drop the redundant ApiHeader/ApiParameter imports in EndpointBuilder — both types live in the same package (core.export), so the imports were unnecessary. Comments and imports only; no runtime behavior changes.
63826e7 to
c5a54bb
Compare
|
📦 Plugin has been packaged for this PR. You can download |
|
📦 Plugin has been packaged for this PR. You can download |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #753 +/- ##
=========================================
Coverage 66.795% 66.795%
=========================================
Files 442 442
Lines 25936 25936
Branches 6191 6191
=========================================
Hits 17324 17324
Misses 6291 6291
Partials 2321 2321
Flags with carried forward coverage won't be shown. Click here to find out more.
Continue to review full report in Codecov by Harness.
🚀 New features to boost your workflow:
|
Summary
isExtenddeclarations (ClassContext,ScriptTypeContext): thesuperClassargument must be the fully qualified name; a simple name silently never matchesmethod.return.mainrule example inEndpointBuilderthat used a bare"Result"— the exact mistake the contract docs now preventApiHeader/ApiParameterimports inEndpointBuilder(both types live in the same packagecore.export)Testing
isExtend/isInheritorcall site passing a simple class name; all other usages (including built-in.configrule files such asjackson.configand*-validation-strict.config) already pass fully qualified names, traced throughannValue/annMapsnormalization (type.canonicalText) andqualifiedName()sourcesRisks / Rollback
None — zero behavioral impact. Revert the commit to roll back.