concerto
concerto copied to clipboard
fix(concerto-analysis): inheritance bug solved in /packages/concerto-analysis related to i/1067 raised
Closes Issue#1067
Changes
- I have changed the /packages/concerto-analysis/src/**compare.ts file** for parent-child property inheritance. Earlier there was "a" child's property being inherited, now only "c" child's property is inherited
- Key in findings(result) now displays an output -> key: 'optional-property-added'
- I tried adding no additional code, just used different properties of Compare class defined in classdeclaration.js file in concerto-core directory, used getProperties() instead of getOwnProperties()
- Now we have minor result(1) instead of major result(3)
Flags
- You need to create a separate inheritance file to review the issue and check the result
Code
{
findings: [
{
key: 'optional-property-added',
message: 'The optional field "cProperty" was added to the concept "Parent"',
element: [Field],
result: 1
}
],
result: 1
}
Images
Results and Tests
- All tests passed in
npm run test, more than 96% patching found.
Related Issues
- Issue #1067
Author Checklist
- [x] Ensure you provide a DCO sign-off for your commits using the
--signoffoption of git commit. - [x] Vital features and changes captured in unit and/or integration tests
- [x] Commits messages follow AP format
- [ ] Extend the documentation, if necessary
- [x] Merging to
mainfromfork:branchname
@rnema19 Could you update the PR title to follow commit conventions please? https://www.conventionalcommits.org/en/v1.0.0/
@rnema19 Could you update the PR title to follow commit conventions please? https://www.conventionalcommits.org/en/v1.0.0/
Sure, I'd be doing it immediately.
@rnema19 could you also add test cases for the fix?
This PR is stale because it has been open 15 days with no activity. Remove stale label or comment or this will be closed in 10 days.