Sha256: fcd41efe014137a15b7d8df16ba3a41d4eb1ee258d07c9dd639dd9393483fd11

Contents?: true

Size: 1.79 KB

Versions: 1

Compression:

Stored size: 1.79 KB

Contents

name: CI

on:
  push:
    branches:
      - 'master'
  pull_request:
jobs:
  test:
    strategy:
      matrix:
        architecture: [ x64 ]
        database: [ mysql, postgresql ]
        gemfile: [ '6.0', '5.2' ]
        ruby: [ '2.7.x', '2.6.x', '2.5.x' ]
      fail-fast: false
    runs-on: ubuntu-latest
    name: ${{ matrix.ruby }} ${{ matrix.database }} rails-${{ matrix.gemfile }}
    steps:
    - uses: actions/setup-ruby@v1.0.0
      with:
        architecture: ${{ matrix.architecture }}
        ruby-version: ${{ matrix.ruby }}
        version: ${{ matrix.ruby }}
    - uses: actions/checkout@v2
    - run: sudo apt-get update && sudo apt-get install libpq-dev postgresql-client libmysqlclient-dev mysql-client libsqlite3-dev -y
    - id: cache-bundler
      uses: actions/cache@v2
      with:
        path: vendor/bundle
        key: ${{ matrix.ruby }}-gem-${{ hashFiles(format('gemfiles/Gemfile.rails-{0}.rb', matrix.gemfile)) }}
    - run: gem install bundler
    - run: bundle install --path vendor/bundle
    - run: bundle exec rake db:create db:up
    - run: bundle exec rake test

    env:
      BUNDLE_JOBS: 4
      BUNDLE_GEMFILE: gemfiles/Gemfile.rails-${{ matrix.gemfile }}.rb
      BUNDLE_PATH: vendor/bundle
      CI: true
      COVERALLS: true
      DB: ${{ matrix.database }}
      MYSQL_PASSWORD: root
      PGHOST: localhost
      PGPORT: 5432
      PGUSER: postgres
      RAILS_ENV: test

    services:
      postgres:
        image: postgres:11.5
        ports: ["5432:5432"]
        options: --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5
      mysql:
        image: mysql:5.7
        ports: ["3306:3306"]
        options: --health-cmd "mysqladmin ping" --health-interval 10s --health-timeout 5s --health-retries 5
        env:
          MYSQL_ROOT_PASSWORD: root

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
friendly_id-5.4.1 .github/workflows/test.yml