Skip to content

ci(upstream-pr): rewrite provider.* imports in synced tests#45

Merged
trudenboy merged 1 commit intomainfrom
fix/upstream-pr-import-rewrite
Apr 20, 2026
Merged

ci(upstream-pr): rewrite provider.* imports in synced tests#45
trudenboy merged 1 commit intomainfrom
fix/upstream-pr-import-rewrite

Conversation

@trudenboy
Copy link
Copy Markdown
Owner

Summary

  • The upstream PR workflow (wrappers/upstream-pr.yml.j2) rsyncs tests/ from the source provider repo into tests/providers/${DOMAIN}/ without rewriting the import prefix.
  • Each run therefore reverts the source-repo from provider.X style back into MA-server tests, re-breaking manually-fixed imports.
  • Surfaced in music-assistant/server#3746 for yandex_smarthome: the v1.3.0 sync commit introduced a second commit that replaced music_assistant.providers.yandex_smarthome.* with provider.* in six test files.
  • Mirrors the sed step already present in reusable-sync-to-fork.yml so synced tests use music_assistant.providers.${DOMAIN}.* paths for both from imports and mock.patch string literals.

Test plan

  • After merge + redistribute, trigger Submit Provider to Upstream workflow for any provider with a pending release — verify the resulting commit on upstream/<domain> does not contain from provider. or "provider. in tests/providers/<domain>/*.py.
  • Confirm reusable-sync-to-fork.yml behavior is unchanged (this PR only touches upstream-pr.yml.j2).

🤖 Generated with Claude Code

The upstream PR workflow rsyncs tests/ from the source provider repo
into tests/providers/${DOMAIN}/ without rewriting the import prefix,
so each run reverts the source-repo "from provider.X" style back into
MA-server tests (regression surfaced in PR 3746 for yandex_smarthome).

Mirror the sed step already present in reusable-sync-to-fork.yml so the
synced tests use from/patch paths of music_assistant.providers.${DOMAIN}.*.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
@trudenboy trudenboy merged commit d785990 into main Apr 20, 2026
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