Skip to content

Commit

Permalink
Update GHA build
Browse files Browse the repository at this point in the history
Signed-off-by: Gábor Lipták <[email protected]>
  • Loading branch information
gliptak authored and jordansissel committed Dec 4, 2022
1 parent ada6012 commit c9a5cb4
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 42 deletions.
8 changes: 0 additions & 8 deletions .github/main.workflow

This file was deleted.

44 changes: 12 additions & 32 deletions .github/workflows/ruby.yml
Original file line number Diff line number Diff line change
@@ -1,45 +1,25 @@
# This workflow uses actions that are not certified by GitHub.
# They are provided by a third-party and are governed by
# separate terms of service, privacy policy, and support
# documentation.
# This workflow will download a prebuilt Ruby version, install dependencies and run tests with Rake
# For more information see: https://github.com/marketplace/actions/setup-ruby-jruby-and-truffleruby

name: Ruby

on:
workflow_dispatch:
# push:
# branches: [ "main" ]
# pull_request:
# branches: [ "main" ]

permissions:
contents: read
push:
branches: [main]
pull_request:
branches: [main]

jobs:
test:

runs-on: ubuntu-latest
runs-on: ubuntu-22.04
strategy:
matrix:
ruby-version: ['2.6', '2.7', '3.0']

ruby-version: ['2.7', '3.0', '3.1']
steps:
- run: |
sudo apt install -y libarchive-tools lintian cpanminus
- uses: actions/checkout@v3
- name: Set up Ruby
# To automatically get bug fixes and new Ruby versions for ruby/setup-ruby,
# change this to (see https://github.com/ruby/setup-ruby#versioning):
# uses: ruby/setup-ruby@v1
uses: ruby/setup-ruby@0a29871fe2b0200a17a4497bae54fe5df0d973aa # v1.115.3
- uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby-version }}
bundler-cache: true # runs 'bundle install' and caches installed gems automatically
- name: Run tests
run: |
set +e
set -x
- run: |
bundle exec rspec
code=$?
echo "RSpec exited: $code"
exit $code
env:
SHELL: /usr/bin/bash
2 changes: 1 addition & 1 deletion spec/fpm/package/osxpkg_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
"which requires a Darwin platform.")
end

describe FPM::Package::OSXpkg do
describe FPM::Package::OSXpkg, :if => platform_is_darwin do
describe "#identifier" do
it "should be of the form reverse.domain.pkgname" do
subject.name = "name"
Expand Down
2 changes: 1 addition & 1 deletion spec/fpm/package/virtualenv_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ def virtualenv_usable?
"no virtualenv/tools bin on your path")
end

describe FPM::Package::Virtualenv do
describe FPM::Package::Virtualenv, :if => virtualenv_usable? do
before do
skip("virtualenv and/or virtualenv-tools programs not found") unless virtualenv_usable?
end
Expand Down

0 comments on commit c9a5cb4

Please sign in to comment.