From f4532c9a56434109c5d7370584a33042225b69a5 Mon Sep 17 00:00:00 2001 From: Ankitha Damodara Date: Fri, 14 Jun 2024 11:27:03 +0100 Subject: [PATCH] update config --- .github/workflows/tests.yml | 39 ++++++++++++++++--------------------- Gemfile | 2 +- 2 files changed, 18 insertions(+), 23 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index d07b857..0431e03 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -1,40 +1,36 @@ -name: Run Specs +name: tests on: push: -permissions: - contents: read - # We need write access to the id-token to use workload identity federation - id-token: write - packages: read - # Needed for getting PR labels - pull-requests: read - - -env: - PGDATABASE: que-test - PGUSER: ubuntu - PGPASSWORD: password - PGHOST: localhost jobs: rspec: - runs-on: ubuntu-latest strategy: + fail-fast: false matrix: ruby_version: ["2.6", "2.7", "3.0"] - + postgres-version: ["12", "13", "14", "15", "16"] + + runs-on: ubuntu-latest services: postgres: - image: postgres:11.2 + image: postgres:${{ matrix.postgres-version }} env: POSTGRES_DB: que-test POSTGRES_USER: ubuntu POSTGRES_PASSWORD: password - POSTGRES_HOST_AUTH_METHOD: trust ports: - 5432:5432 - + options: >- + --health-cmd pg_isready + --health-interval 10s + --health-timeout 5s + --health-retries 10 + env: + PGDATABASE: que-test + PGUSER: ubuntu + PGPASSWORD: password + PGHOST: localhost steps: - uses: actions/checkout@v3 - name: Set up Ruby @@ -42,7 +38,6 @@ jobs: with: bundler-cache: true ruby-version: "${{ matrix.ruby-version }}" - - - name: Run Specs + - name: Run specs run: | bundle exec rspec \ No newline at end of file diff --git a/Gemfile b/Gemfile index 883fa4d..7d1049b 100644 --- a/Gemfile +++ b/Gemfile @@ -22,6 +22,6 @@ group :test do end gem 'prometheus-client', '~> 1.0' -gem 'prometheus_gcstat', git: 'git@github.com:gocardless/prometheus_gcstat_ruby' +# gem 'prometheus_gcstat', git: 'git@github.com:gocardless/prometheus_gcstat_ruby' gemspec