Skip to content

chore: trigger external tests on supabase-js #518

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

Merged
merged 10 commits into from
Aug 13, 2025

Conversation

mandarini
Copy link
Contributor

@mandarini mandarini commented Aug 13, 2025

What kind of change does this PR introduce?

CI/CD enhancement - Improves the preview release workflow and cross-repository testing integration.

What is the current behavior?

  • Preview releases are created but there's no automated way to test compatibility with downstream packages
  • No cross-repository testing between realtime-js and supabase-js
  • Manual testing required to verify changes don't break integration points
  • Limited feedback loop for developers on cross-package compatibility

What is the new behavior?

  • Automated Cross-Repo Testing: Preview releases automatically trigger compatibility tests in supabase-js
  • Smart Triggering: Only runs on actual source code changes (src/, package files, tsconfig) to avoid unnecessary builds
  • Enhanced Control: Manual workflow dispatch with configurable options for target branch and test triggering
  • Better UX: PR comments show preview package URLs and test status updates
  • Secure Integration: Uses GitHub App authentication for cross-repository workflow triggering

Key Features

🚀 Cross-Repository Test Integration

  • Automatically triggers supabase-js external tests when realtime-js changes are made
  • Passes preview package URL and metadata to downstream tests
  • Supports both PR and push-based workflows

Optimized Triggering

  • Path-based filtering: Only triggers on meaningful changes (src/**, package.json, etc.)
  • Label-based control: PRs require trigger: preview label for activation
  • Manual override: Workflow dispatch with configurable target branch

💬 Enhanced Feedback

  • Automated PR comments with preview package links
  • Status updates on cross-repo test progress
  • Clear visibility into the testing pipeline

🔒 Secure Cross-Repo Access

  • GitHub App-based authentication for repository access
  • Scoped permissions to realtime-js and supabase-js repositories only

Testing

This workflow enables:

  • Early detection of breaking changes between realtime-js and supabase-js
  • Automated compatibility verification for all preview releases
  • Faster feedback cycles for developers working on authentication features
  • Reduced risk of integration issues in production releases

Additional context

This enhancement creates a robust CI/CD pipeline that ensures realtime-js changes are automatically validated against its primary consumer (supabase-js), significantly improving the development workflow and reducing integration risks.

More context: supabase/supabase-js#1532

@mandarini mandarini self-assigned this Aug 13, 2025
@mandarini mandarini added the trigger: preview Triggers a preview release for this PR. label Aug 13, 2025
Copy link

pkg-pr-new bot commented Aug 13, 2025

Open in StackBlitz

npm i https://pkg.pr.new/@supabase/realtime-js@518

commit: 7fdd996

@mandarini mandarini force-pushed the chore/enhance-preview-release branch 2 times, most recently from da34b9b to 9b9c972 Compare August 13, 2025 09:48
@mandarini mandarini force-pushed the chore/enhance-preview-release branch from 9b9c972 to 5ab1ee5 Compare August 13, 2025 10:01
Copy link

github-actions bot commented Aug 13, 2025

🚀 Preview release created!

supabase-js CI tests have been automatically triggered on feature branch to verify compatibility.

Preview package: https://pkg.pr.new/@supabase/realtime-js@7fdd996

Results will be posted here once testing is complete.

@supabase supabase deleted a comment from github-actions bot Aug 13, 2025
@supabase supabase deleted a comment from github-actions bot Aug 13, 2025
@supabase supabase deleted a comment from github-actions bot Aug 13, 2025
@supabase supabase deleted a comment from github-actions bot Aug 13, 2025
@supabase supabase deleted a comment from github-actions bot Aug 13, 2025
@supabase supabase deleted a comment from clientlibs-test-trigger bot Aug 13, 2025
@supabase supabase deleted a comment from github-actions bot Aug 13, 2025
@supabase supabase deleted a comment from clientlibs-test-trigger bot Aug 13, 2025
@supabase supabase deleted a comment from clientlibs-test-trigger bot Aug 13, 2025
@supabase supabase deleted a comment from github-actions bot Aug 13, 2025
@supabase supabase deleted a comment from clientlibs-test-trigger bot Aug 13, 2025
@supabase supabase deleted a comment from clientlibs-test-trigger bot Aug 13, 2025
@clientlibs-test-trigger
Copy link

clientlibs-test-trigger bot commented Aug 13, 2025

✅ supabase-js CI Test Results

Overall Status: PASSED
Tests triggered by preview release of realtime-js

Test Suite Result
Type Check ✅ PASSED
Unit Tests ✅ PASSED
Integration Tests ✅ PASSED
Preview Package: https://pkg.pr.new/@supabase/realtime-js@7fdd996
Commit: 7fdd99661e5cb150bc9ce0c9a2343781def4679c
🎉 All tests passed! This preview release is compatible with supabase-js.
View workflow run View full test results

@supabase supabase deleted a comment from clientlibs-test-trigger bot Aug 13, 2025
@mandarini mandarini force-pushed the chore/enhance-preview-release branch from 4775af4 to d29668d Compare August 13, 2025 10:41
@mandarini mandarini force-pushed the chore/enhance-preview-release branch from d29668d to f7d84cf Compare August 13, 2025 11:07
@mandarini mandarini marked this pull request as ready for review August 13, 2025 14:16
@mandarini mandarini requested review from grdsdev and o-santi August 13, 2025 14:16
@mandarini mandarini merged commit bde6da9 into master Aug 13, 2025
7 of 8 checks passed
@mandarini mandarini deleted the chore/enhance-preview-release branch August 13, 2025 14:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
trigger: preview Triggers a preview release for this PR.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants