Skip to content

ci: add GitHub Actions workflow - #825

Merged
JChan106 merged 4 commits into
box:masterfrom
JChan106:ci/github-actions-workflow
Nov 19, 2026
Merged

JChan106 merged 4 commits into
box:masterfrom
JChan106:ci/github-actions-workflow

Conversation

@JChan106

@JChan106 JChan106 commented Nov 17, 2026 •

Copy link
Copy Markdown
Contributor

Summary

  • Adds a GitHub Actions workflow that runs next to Travis. Travis stays the Mergify gate until a follow-up PR removes .travis.yml and switches .mergify.yml to the CI Status check.
  • Travis's serial Build & Test job becomes three parallel jobs: Lint, Unit Tests, and Build.
  • The Cypress E2E suite is not migrated. preview-client's Playwright UI suite already tests annotations end to end, so Cypress is being retired instead of moved.
  • CI Status is the one check to require later. It fails if Lint, Unit Tests, or Build fails.

Why

Every Box repo on Travis shares 2 concurrent jobs. Over 240 box-annotations jobs from 29 Sep to 13 Nov, the wait for a runner was:

Travis GitHub Actions
Median wait for a runner 6.0 min Seconds (public repos get standard runners for free)
p90 wait 46.4 min Seconds
Jobs waiting more than 5 min 58% None expected
Concurrent jobs 2, shared across Box At least 20 for the org
Cost for this public repo Travis plan Free

Why Cypress E2E is not migrated

  • preview-client already covers it. Its Playwright suite (test/integration/ui/specs/annotations/) creates, edits, and deletes region, highlight, and drawing annotations on documents and images. It also covers video, multi-page documents, @mention action items, and popup and activity-feed sync, none of which Cypress tests. Tests for the few remaining Cypress cases (image rotation, the single-page highlight limit, and discoverability) are being added there.
  • It tests what customers run. preview-client loads box-annotations and box-content-preview from npm. The Cypress page loads box-content-preview 3.79.0 from the CDN, about 60 releases behind.
  • No secret to manage. Cypress needs E2E_ACCESS_TOKEN, a write token against production. It could only run on master pushes and same-repo PRs anyway, since GitHub does not pass secrets to fork PRs.
  • Jest still runs on every PR, as Unit Tests.

Parity with Travis

Travis GitHub Actions
Node 22 (node_js: 22) .nvmrc (lts/jod, Node 22)
HUSKY_SKIP_HOOKS=1, NODE_OPTIONS=--openssl-legacy-provider, TZ=America/Los_Angeles Same, as workflow env
yarn build && yarn lint && yarn test yarn build, yarn lint, yarn test as separate jobs
yarn test:e2e with if: fork = false Not migrated. CYPRESS_INSTALL_BINARY=0 skips the Cypress download in yarn install
Cache node_modules, ~/.cache/Cypress setup-node yarn cache
apt libgconf-2-4 Dropped. Only Cypress needed it

Known failure on master

E2E Tests on Travis has failed on master since #823 removed the isThreadedAnnotation flag. The Cypress page never turned that flag on, so it was the last place still showing the legacy comment popup. #823 deleted that popup, and the tests now time out waiting for its ba-ReplyField-editor and ba-Popup-cancel elements. The tests are out of date; this is not a product regression. Consumers that pass isThreadedAnnotation: true, like preview-client, already used the threaded popup.

This does not block fork PRs, because Travis skips E2E on forks. The Travis cleanup PR removes the job, along with Cypress itself.

Test plan

  • Lint, Unit Tests, and Build pass on this fork PR
  • CI Status passes
  • No E2E Tests job appears in the run

Summary by CodeRabbit

  • Chores
    • Automated linting, unit tests, and builds now run for pushes and pull requests targeting the main development branch.
    • A final status check reports whether all three automated checks passed and fails when any check does not pass.
    • The previous notes about end-to-end tests and failure screenshots are not included in this update; those checks are not part of the workflow described here.

Run lint, unit tests, and build in parallel next to Travis. E2E runs on master
pushes and same-repo PRs, like Travis, because it needs E2E_ACCESS_TOKEN.

Co-authored-by: Cursor <cursoragent@cursor.com>
@JChan106
JChan106 requested a review from a team as a code owner November 17, 2026 21:57
@socket-security

socket-security Bot commented Nov 17, 2026 •

Copy link
Copy Markdown

Review the following changes in direct dependencies. Learn more about Socket for GitHub.

Diff Package Supply Chain
Security
Vulnerability Quality Maintenance License
Addedgithub/​actions/​setup-node@​49933ea5288caeca8642d1e84afbd3f7d68200208610010010080
Addedgithub/​actions/​checkout@​34e114876b0b11c390a56381ad16ebd13914f8d599100100100100

View full report

@coderabbitai

coderabbitai Bot commented Nov 17, 2026 •

Copy link
Copy Markdown

Explain Change →

Important

Review skipped

Review was skipped as selected files did not have any reviewable changes.

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 3d3fee2a-67c1-4770-b40c-e31cd24e2cbd
Commits

Reviewing files that changed from the base of the PR and between 9b36500 and 7a1cf58.

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

No actionable comments were generated in the recent review.

Walkthrough

The pull request adds a GitHub Actions workflow for lint, unit tests, and build. It sets workflow permissions, concurrency, and shared environment variables. An always-running status job checks whether all three jobs succeeded.

Changes

CI workflow

Layer / File(s) Summary
Workflow triggers and validation jobs
.github/workflows/ci.yml
The workflow runs on pull requests and pushes to master. It sets read-only content permissions, concurrency, and shared environment variables. The lint, unit-test, and build jobs use Ubuntu, the Node version from .nvmrc, Yarn caching, and frozen-lockfile installs.
CI status aggregation
.github/workflows/ci.yml
The always-running status job depends on lint, unit tests, and build. It fails if any of those jobs does not succeed.

Estimated code review effort: 2 (Simple) | ~10 minutes

Change: Other

Suggested reviewers: zhirongwang, ahorowitz123

Merge Risk: Minimal · previous review 9b365

This adds a GitHub Actions workflow for lint, unit tests and build alongside the existing Travis setup. It does not change application behavior, and no merge-blocking risk was identified.

Pre-merge checks: Passed 4

Check name Status Explanation
Title check Passed The title "ci: add GitHub Actions workflow" matches the main change: a new .github/workflows/ci.yml that adds lint, unit-test, and build jobs plus a ci-status gate. It does not mention the Travis rela…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Description Check Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Full details: Title check

Explanation

The title "ci: add GitHub Actions workflow" matches the main change: a new .github/workflows/ci.yml that adds lint, unit-test, and build jobs plus a ci-status gate. It does not mention the Travis relationship or the E2E handling, but it does not need to cover every detail. The title is short, specific, and uses a conventional commit prefix.

Finishing Touches

Generate unit tests (beta)

  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

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

A rabbit checks the build at dawn
Then waits for tests to finish and run
The lint job hops across the queue
The status checks that all jobs do
With green lights, off the rabbit goes!

Recent review info

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 2f3f703a-3f08-4d08-9c1e-634897379856
Commits

Reviewing files that changed from the base of the PR and between 0f06a67 and 9b36500.

Files selected for processing: 1

  • .github/workflows/ci.yml

Included review availability: This review used your included allowance. Your plan provides up to 1 included review per hour; 0 remain after this review.

@JChan106 JChan106 closed this Nov 17, 2026
@JChan106 JChan106 reopened this Nov 17, 2026
Co-authored-by: Cursor <cursoragent@cursor.com>
preview-client's Playwright suite covers annotations end to end, so the
Cypress suite is being retired instead of migrated. Skip the Cypress binary
download since no job runs it.

Co-authored-by: Cursor <cursoragent@cursor.com>
@JChan106
JChan106 merged commit 8996c6b into box:master Nov 19, 2026
12 of 13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants