-
Notifications
You must be signed in to change notification settings - Fork 536
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
(tree) Added support for constraint to be applied when a change is reverted #22958
(tree) Added support for constraint to be applied when a change is reverted #22958
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code Coverage Summary
↓ packages.dds.tree.src.feature-libraries.optional-field:
Line Coverage Change: -37.86% Branch Coverage Change: -18.37%
Metric Name | Baseline coverage | PR coverage | Coverage Diff |
---|---|---|---|
Branch Coverage | 98.82% | 80.45% | ↓ -18.37% |
Line Coverage | 92.79% | 54.93% | ↓ -37.86% |
↓ packages.dds.tree.src.feature-libraries.sequence-field:
Line Coverage Change: -48.32% Branch Coverage Change: -6.84%
Metric Name | Baseline coverage | PR coverage | Coverage Diff |
---|---|---|---|
Branch Coverage | 90.31% | 83.47% | ↓ -6.84% |
Line Coverage | 91.69% | 43.37% | ↓ -48.32% |
↓ packages.dds.tree.src.feature-libraries.modular-schema:
Line Coverage Change: -31.94% Branch Coverage Change: -15.70%
Metric Name | Baseline coverage | PR coverage | Coverage Diff |
---|---|---|---|
Branch Coverage | 92.15% | 76.45% | ↓ -15.70% |
Line Coverage | 94.67% | 62.73% | ↓ -31.94% |
↓ packages.dds.tree.src.shared-tree:
Line Coverage Change: -17.59% Branch Coverage Change: -14.04%
Metric Name | Baseline coverage | PR coverage | Coverage Diff |
---|---|---|---|
Branch Coverage | 91.34% | 77.30% | ↓ -14.04% |
Line Coverage | 97.44% | 79.85% | ↓ -17.59% |
↓ packages.dds.tree.src.feature-libraries.default-schema:
Line Coverage Change: -28.05% Branch Coverage Change: 7.15%
Metric Name | Baseline coverage | PR coverage | Coverage Diff |
---|---|---|---|
Branch Coverage | 92.85% | 100.00% | ↑ 7.15% |
Line Coverage | 98.56% | 70.51% | ↓ -28.05% |
Baseline commit: e432720
Baseline build: 303572
Happy Coding!!
Code coverage comparison check failed!!
More Details: Readme
- Skip This Check!!
What to do if the code coverage check fails:
-
Ideally, add more tests to increase the code coverage for the package(s) whose code-coverage regressed.
-
If a regression is causing the build to fail and is due to removal of tests, removal of code with lots of tests or any other valid reason, there is a checkbox further up in this comment that determines if the code coverage check should fail the build or not. You can check the box and trigger the build again. The test coverage analysis will still be done, but it will not fail the build if a regression is detected.
-
Unchecking the checkbox and triggering another build should go back to failing the build if a test-coverage regression is detected.
-
You can check which lines are covered or not covered by your tests with these steps:
- Go to the PR ADO build.
- Click on the link to see its published artifacts. You will see an artifact named
codeCoverageAnalysis
, which you can expand to reach to a particular source file's coverage html which will show which lines are covered/not covered by your tests. - You can also run different kind of tests locally with
:coverage
tests commands to find out the coverage.
8d29250
to
704e854
Compare
packages/dds/tree/src/feature-libraries/modular-schema/modularChangeFamily.ts
Outdated
Show resolved
Hide resolved
packages/dds/tree/src/feature-libraries/modular-schema/modularChangeFamily.ts
Outdated
Show resolved
Hide resolved
packages/dds/tree/src/feature-libraries/modular-schema/modularChangeTypes.ts
Outdated
Show resolved
Hide resolved
packages/dds/tree/src/feature-libraries/modular-schema/modularChangeFormat.ts
Outdated
Show resolved
Hide resolved
d15d537
to
0e98746
Compare
359a58d
to
ff87806
Compare
Added support for constraint to be applies when a change is reverted. This will be used to support specifying undo constraint in a transaction. Basically, when a transaction is run, in addition to the current constraint, an undo constraint can be added which will be applied and validated if and when the change corresponding to the transaction is undone.
The
runTransaction
API will be updated to suppport undo contraint in a later PR.AB#8061