58
58
strategy :
59
59
fail-fast : false
60
60
matrix :
61
+ js_package_manager :
62
+ - name : npm
63
+ installer : npm
64
+ - name : yarn_classic
65
+ installer : yarn
66
+ - name : pnpm
67
+ installer : pnpm
61
68
ruby : [2.7]
62
69
gemfile :
63
70
# These have shakapacker:
@@ -73,12 +80,13 @@ jobs:
73
80
# Workaround b/c upgrading Minitest broke some mocking expectations
74
81
# having to do with automatic kwarg splatting
75
82
MT_KWARGS_HACK : 1
83
+ PACKAGE_JSON_FALLBACK_MANAGER : ${{ matrix.js_package_manager.name }}
76
84
steps :
77
85
- uses : actions/checkout@v4
78
86
with :
79
87
persist-credentials : false
80
88
- uses : actions/setup-node@v3
81
- - run : npm -g install yalc
89
+ - run : npm -g install yalc ${{ matrix.js_package_manager.installer }}
82
90
- run : yalc publish
83
91
- name : Save root node_modules to cache
84
92
uses : actions/cache@v3
@@ -94,14 +102,15 @@ jobs:
94
102
with :
95
103
bundler : 2.4.9
96
104
ruby-version : ${{ matrix.ruby }}
105
+ - run : ./test/bin/create-fake-js-package-managers ${{ matrix.js_package_manager.installer }}
97
106
- name : Save dummy app ruby gems to cache
98
107
uses : actions/cache@v3
99
108
with :
100
109
path : test/dummy/vendor/bundle
101
110
key : dummy-app-gem-cache-${{ hashFiles('${{ github.workspace }}/gemfiles/${{ matrix.gemfile }}.gemfile.lock') }}
102
111
- name : Install Ruby Gems for dummy app
103
112
run : bundle lock --add-platform 'x86_64-linux' && bundle check --path=test/dummy/vendor/bundle || bundle _2.4.9_ install --frozen --path=test/dummy/vendor/bundle --jobs=4 --retry=3
104
- - run : cd test/dummy && yalc add react_ujs && yarn
113
+ - run : cd test/dummy && yalc add react_ujs && ${{ matrix.js_package_manager.installer }} install
105
114
- run : bundle exec rake test
106
115
env :
107
116
NODE_OPTIONS : --openssl-legacy-provider
0 commit comments