Skip to content

test(simulation): cover reset action contract - #21

Merged
Mile-Away merged 1 commit into
mainfrom
codex/simulation-device-reset-contract
Sep 26, 2026
Merged

Mile-Away merged 1 commit into
mainfrom
codex/simulation-device-reset-contract

Conversation

@Mile-Away

@Mile-Away Mile-Away commented Sep 26, 2026 •

Copy link
Copy Markdown
Contributor

What changed

Add an integration assertion that simulation devices expose the runtime reset action in their device contract.

Validation

  • cargo fmt --manifest-path OpenSDL/Cargo.toml --all
  • cargo test -p osdl-core --features espnow

Sourcery 摘要

测试:

  • 添加集成断言,验证模拟设备在其设备契约中公开运行时重置操作。
Original summary in English

Summary by Sourcery

Tests:

  • Add an integration assertion verifying that simulation devices expose the runtime reset action in their device contract.

@sourcery-ai

sourcery-ai Bot commented Sep 26, 2026 •

Copy link
Copy Markdown
审查者指南(小型 PR 中折叠显示)

审查者指南

添加集成测试覆盖范围,以确认模拟设备会在其公布的设备契约中公开运行时 reset 操作,同时不改变生产环境中的行为。

文件级变更

变更 详情 文件
扩展模拟设备集成契约断言,要求包含运行时 reset 操作。
  • 在已注册设备的操作中搜索名为 reset 的操作。
  • 将该断言与现有的适配器和角色契约检查放在一起。
crates/osdl-core/tests/integration.rs

提示和命令

与 Sourcery 交互

  • 触发新的审查: 在拉取请求中评论 @sourcery-ai review。
  • 继续讨论: 直接回复 Sourcery 的审查评论。
  • 从审查评论生成 GitHub issue: 回复审查评论,请 Sourcery 根据该评论创建 issue。你也可以使用 @sourcery-ai issue 回复审查评论,以从中创建 issue。
  • 生成拉取请求标题: 在拉取请求标题的任意位置写入 @sourcery-ai,即可随时生成标题。你也可以在拉取请求中评论 @sourcery-ai title,以随时生成或重新生成标题。
  • 生成拉取请求摘要: 在拉取请求正文的任意位置写入 @sourcery-ai summary,即可在你指定的位置随时生成 PR 摘要。你也可以在拉取请求中评论 @sourcery-ai summary,以随时生成或重新生成摘要。
  • 生成审查者指南: 在拉取请求中评论 @sourcery-ai guide,即可随时生成或重新生成审查者指南。
  • 解决所有 Sourcery 评论: 在拉取请求中评论 @sourcery-ai resolve,即可解决所有 Sourcery 评论。如果你已经处理完所有评论且不想再看到它们,这会很有用。
  • 驳回所有 Sourcery 审查: 在拉取请求中评论 @sourcery-ai dismiss,即可驳回所有现有的 Sourcery 审查。如果你想从头开始新的审查,这尤其有用——别忘了评论 @sourcery-ai review 以触发新的审查!

自定义你的体验

访问你的控制面板,以便:

  • 启用或禁用审查功能,例如 Sourcery 生成的拉取请求摘要、审查者指南等。
  • 更改审查语言。
  • 添加、删除或编辑自定义审查说明。
  • 调整其他审查设置。

获取帮助

Original review guide in English
Reviewer's guide (collapsed on small PRs)

Reviewer's Guide

Adds integration coverage confirming that simulation devices expose the runtime reset action in their advertised device contract, without changing production behavior.

File-Level Changes

Change Details Files
Extends the simulation device integration contract assertion to require the runtime reset action.
  • Searches the registered device’s actions for an action named reset.
  • Keeps the assertion alongside existing adapter and role contract checks.
crates/osdl-core/tests/integration.rs

Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it. You can also reply to a
    review comment with @sourcery-ai issue to create an issue from it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time. You can also comment
    @sourcery-ai title on the pull request to (re-)generate the title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time exactly where you
    want it. You can also comment @sourcery-ai summary on the pull request to
    (re-)generate the summary at any time.
  • Generate reviewer's guide: Comment @sourcery-ai guide on the pull
    request to (re-)generate the reviewer's guide at any time.
  • Resolve all Sourcery comments: Comment @sourcery-ai resolve on the
    pull request to resolve all Sourcery comments. Useful if you've already
    addressed all the comments and don't want to see them anymore.
  • Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull
    request to dismiss all existing Sourcery reviews. Especially useful if you
    want to start fresh with a new review - don't forget to comment
    @sourcery-ai review to trigger a new review!

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

@sourcery-ai sourcery-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

嘿——我已经审阅了你的更改,整体看起来很棒!


Sourcery 对开源项目免费——如果你喜欢我们的评审结果,请考虑分享它们 ✨
Original comment in English

Hey - I've reviewed your changes and they look great!


Sourcery is free for open source - if you like our reviews please consider sharing them ✨

@Mile-Away
Mile-Away merged commit 8686e9b into main Sep 26, 2026
11 checks passed
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