Skip to content

test: auto-pause revert propagation through protocol adapters (RAI-321)#24

Open
hardyjosh wants to merge 1 commit into
feat/auto-pause-base-adapterfrom
test/auto-pause-propagation
Open

test: auto-pause revert propagation through protocol adapters (RAI-321)#24
hardyjosh wants to merge 1 commit into
feat/auto-pause-base-adapterfrom
test/auto-pause-propagation

Conversation

@hardyjosh

Copy link
Copy Markdown
Collaborator

Wires up the full Oracle → Registry → Protocol-adapter chain (Passthrough for Aave/Compound and Morpho both) and verifies that auto-pause reverts surface end-to-end with their original selectors and effectiveTime payload — distinguishable from OraclePausedManual and from each other.

Four checks:

  • Happy path: no scheduled action → both adapters return a price
  • PassthroughProtocolAdapter (latestAnswer + latestRoundData) propagates OraclePausedCorporateAction(effectiveTime) unchanged
  • MorphoProtocolAdapter.price() propagates the same revert
  • Manual-pause precedence is preserved through the chain (manual + auto both armed → manual error reported)

Scope note: RAI-321 also asks for fork tests against a real st0x.deploy vault scheduling actions through the authoriser. That's deferred to RAI-327 (testnet deploy + dry run) since no production vault has the new corporate-actions facet deployed yet — there's nothing real to fork against. The mock here exercises the same chain wiring; once a vault is deployed, the fork test is an additive layer.

@linear

linear Bot commented May 9, 2026

Copy link
Copy Markdown

RAI-321

@coderabbitai

coderabbitai Bot commented May 9, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 3a545aa3-d41e-4379-a540-4a4228b7ed34

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch test/auto-pause-propagation

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

hardyjosh commented May 9, 2026

Copy link
Copy Markdown
Collaborator Author

@hardyjosh hardyjosh force-pushed the feat/auto-pause-base-adapter branch from 4c711c5 to 140fb0f Compare May 9, 2026 11:51
@hardyjosh hardyjosh force-pushed the test/auto-pause-propagation branch 2 times, most recently from 1473d68 to 8771cc3 Compare May 9, 2026 12:08
@hardyjosh hardyjosh force-pushed the feat/auto-pause-base-adapter branch 2 times, most recently from 4eb86c3 to 9093228 Compare May 9, 2026 12:21
@hardyjosh hardyjosh force-pushed the test/auto-pause-propagation branch from 8771cc3 to f286afe Compare May 9, 2026 12:21
@hardyjosh hardyjosh force-pushed the test/auto-pause-propagation branch from f286afe to e3dd304 Compare May 11, 2026 20:42
@hardyjosh hardyjosh force-pushed the feat/auto-pause-base-adapter branch from 5f986f2 to d538ab2 Compare May 11, 2026 21:22
@hardyjosh hardyjosh force-pushed the test/auto-pause-propagation branch 2 times, most recently from e2683f3 to e4530d2 Compare May 11, 2026 21:52
@hardyjosh hardyjosh force-pushed the feat/auto-pause-base-adapter branch from d538ab2 to b26969b Compare May 11, 2026 22:27
@hardyjosh hardyjosh force-pushed the test/auto-pause-propagation branch from e4530d2 to 8a87749 Compare May 11, 2026 22:27
@hardyjosh hardyjosh force-pushed the test/auto-pause-propagation branch from 8a87749 to c17c99c Compare May 26, 2026 17:35
@hardyjosh hardyjosh force-pushed the feat/auto-pause-base-adapter branch from b26969b to 73f1220 Compare May 26, 2026 17:35
@hardyjosh hardyjosh force-pushed the test/auto-pause-propagation branch from c17c99c to 5afd61b Compare May 26, 2026 18:15
@hardyjosh hardyjosh force-pushed the feat/auto-pause-base-adapter branch from 73f1220 to 2ed0a7f Compare May 26, 2026 18:15
Wires up the full Oracle → Registry → Protocol-adapter chain (Passthrough for Aave/Compound and Morpho both) and verifies that auto-pause reverts surface end-to-end with their original selectors and effectiveTime payload — distinguishable from OraclePausedManual and from each other.

Four checks:
* Happy path: no scheduled action → both adapters return a price
* PassthroughProtocolAdapter (latestAnswer + latestRoundData) propagates OraclePausedCorporateAction(effectiveTime) unchanged
* MorphoProtocolAdapter.price() propagates the same revert
* Manual-pause precedence is preserved through the chain (manual + auto both armed → manual error reported)

Uses the shared `test/mocks/MockCorporateActions.sol` stub introduced in
PR #22, which returns the documented NODE_NONE = type(uint256).max
sentinel on no-match, matching the real ICorporateActionsV1 contract.

Scope note: RAI-321 also asks for fork tests against a real st0x.deploy vault scheduling actions through the authoriser. That's deferred to RAI-327 (testnet deploy + dry run) since no production vault has the new corporate-actions facet deployed yet — there's nothing real to fork against. The mock here exercises the same chain wiring; once a vault is deployed, the fork test is an additive layer.
@hardyjosh hardyjosh force-pushed the feat/auto-pause-base-adapter branch from 2ed0a7f to 4b1991a Compare May 31, 2026 11:48
@hardyjosh hardyjosh force-pushed the test/auto-pause-propagation branch from 5afd61b to 1615d4d Compare May 31, 2026 11:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant