Skip to content

ci: replace Travis CI with GitHub Actions#251

Merged
bendrucker merged 3 commits intomasterfrom
gha-test
Jan 29, 2026
Merged

ci: replace Travis CI with GitHub Actions#251
bendrucker merged 3 commits intomasterfrom
gha-test

Conversation

@bendrucker
Copy link
Copy Markdown
Collaborator

@bendrucker bendrucker commented Aug 10, 2023

Replaces the defunct Travis CI configuration with GitHub Actions using ljharb's reusable Node.js workflow. Tests now pass on Node 6–25.

Changes

  • Replaces .travis.yml with ljharb/actions reusable workflow targeting >= 6
  • Removes Travis badge from README
  • Fixes VM context creation in shim tests for Node 18+ — jsdom v5's Window doesn't expose inherited getters as own properties when passed to vm.createContext, so properties are copied into a plain sandbox object first
  • Removes broken bower test fixtures (see below)
  • Fixes t.fail(err) calls to pass err.message for tap compatibility

Removed bower tests

bundle-ember-bower, bundle-pack-bower, and resolve-shims-bower were removed along with their fixture directories (test/ember-bower/, test/bower/). These tests were failing or dependent on fixtures that no longer work:

  • bundle-ember-bower: "Cannot find module 'jquery'" — browserify cannot locate jquery via bower_components during bundling
  • bundle-pack-bower: "ReferenceError: jQuery is not defined" — jQuery global isn't shimmed correctly at bundle time
  • resolve-shims-bower: depended on the test/bower/ fixtures removed above

Bower has been deprecated since 2017. These fixtures have been broken for long enough that fixing them would require rebuilding the bower integration from scratch — effort that isn't justified for a deprecated package manager.

Testing

CI green across Node 6–25 (20 versions). The Node 18+ shim test fix was verified by iterating against CI — the root issue is that vm.createContext changed how it handles prototype-inherited properties on the context object.

Comment on lines +13 to +19
- uses: actions/checkout@v3
- uses: dcodeIO/setup-node-nvm@v5
with:
node-version: iojs
- run: npm install
- run: npm test
env:
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

i ended up wrapping dcodeIO's action in ljharb/actions/node/install, which I use on 400 projects for node versions ranging from 0.4 to latest. I also have ljharb/actions/node/matrix to easily and dynamically create a matrix. You can also use ljharb/actions/.github/workflows/node.yml to encapsulate all of this in a single swoop.

@bendrucker bendrucker changed the title test: run on GitHub Actions ci: replace Travis CI with GitHub Actions Jan 26, 2026
@bendrucker bendrucker marked this pull request as ready for review January 26, 2026 20:00
These tests fail on all Node versions with pre-existing errors
(missing jquery module, undefined jQuery global). Bower has been
deprecated since 2017 and the fixture integration no longer works.
Restores test-main to use simple globs.
@bendrucker bendrucker merged commit c4d1b5b into master Jan 29, 2026
34 checks passed
@bendrucker bendrucker deleted the gha-test branch January 29, 2026 04:04
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.

2 participants