downstream #2090
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: downstream | |
concurrency: | |
group: "${{github.workflow}}-${{github.ref}}" | |
cancel-in-progress: true | |
on: | |
workflow_dispatch: | |
schedule: | |
- cron: "0 8 * * 1,3,5" # At 08:00 on Monday, Wednesday, and Friday # https://crontab.guru/#0_8_*_*_1,3,5 | |
push: | |
branches: | |
- main | |
- v*.*.x | |
tags: | |
- v*.*.* | |
pull_request: | |
types: [opened, synchronize] | |
branches: | |
- '*' | |
jobs: | |
downstream: | |
name: downstream-${{matrix.name}} | |
strategy: | |
fail-fast: false | |
matrix: | |
include: | |
- url: https://github.com/flavorjones/loofah | |
name: loofah | |
command: "bundle exec rake test" | |
ruby: "3.3" | |
- url: https://github.com/rails/rails-html-sanitizer | |
name: rails-html-sanitizer | |
command: "bundle exec rake test" | |
ruby: "3.3" | |
- url: https://github.com/rgrove/sanitize | |
name: sanitize | |
command: "bundle exec rake test" | |
ruby: "3.3" | |
- url: https://github.com/ebeigarts/signer | |
name: signer | |
command: "bundle exec rake spec" | |
ruby: "3.2" | |
- url: https://github.com/WinRb/Viewpoint | |
name: viewpoint | |
command: "bundle exec rspec spec" | |
ruby: "3.1" | |
- url: https://github.com/rails/rails | |
name: xmlmini | |
command: "cd activesupport && bundle exec rake test TESTOPTS=-n/XmlMini/" | |
ruby: "3.3" | |
- url: https://github.com/pythonicrubyist/creek | |
name: creek | |
command: "bundle exec rake spec" | |
ruby: "3.2" | |
- url: https://github.com/SAML-Toolkits/ruby-saml | |
name: ruby-saml | |
command: "bundle exec rake test MT_COMPAT=t" | |
ruby: "3.2" | |
- url: https://github.com/sparklemotion/mechanize | |
name: mechanize | |
command: "bundle exec rake test" | |
ruby: "3.3" | |
- url: https://github.com/stimulusreflex/stimulus_reflex | |
name: stimulus_reflex | |
command: "bundle exec rake test" | |
ruby: "3.3" | |
# - url: https://github.com/instructure/nokogiri-xmlsec-instructure | |
# name: nokogiri-xmlsec-instructure | |
# precommand: "apt install -y libxmlsec1-dev" | |
# command: "bundle exec rake compile rspec" | |
runs-on: ubuntu-latest | |
container: | |
image: ghcr.io/sparklemotion/nokogiri-test:mri-${{matrix.ruby}} | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
submodules: true | |
- uses: actions/cache@v4 | |
with: | |
path: ports | |
key: ports-ubuntu-${{matrix.ruby}}-${{hashFiles('dependencies.yml', 'patches/**/*.patch', 'ext/nokogiri/extconf.rb')}} | |
- if: matrix.precommand | |
run: ${{matrix.precommand}} | |
- run: gem install bundler -v ">= 2.3.22" # for "add --path" | |
- run: bundle install --local || bundle install | |
- run: bundle exec rake compile | |
- run: git clone --depth=1 ${{matrix.url}} ${{matrix.name}} | |
- name: ${{matrix.name}} test suite | |
working-directory: ${{matrix.name}} | |
run: | | |
bundle remove nokogiri || true | |
bundle add nokogiri --path=".." | |
if grep "add_development_dependency.*\bbundler\b" *gemspec ; then | |
sed -i 's/.*add_development_dependency.*\bbundler\b.*//' *gemspec | |
fi | |
bundle install --local || bundle install | |
${{matrix.command}} |