From 94a4ad36dd1da0faa4165892d5fc62f8d9254e41 Mon Sep 17 00:00:00 2001 From: Ulan Djamanbalaev Date: Fri, 5 Dec 2025 10:22:12 +0000 Subject: [PATCH] Add a GitHub action for running tests and update the minimum supported Ruby version to 3.0 --- .github/workflows/test.yml | 39 ++++++++++++++++++++++++++++++++++++++ README.md | 1 + ebay_api.gemspec | 4 ++-- 3 files changed, 42 insertions(+), 2 deletions(-) create mode 100644 .github/workflows/test.yml diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml new file mode 100644 index 0000000..d16117a --- /dev/null +++ b/.github/workflows/test.yml @@ -0,0 +1,39 @@ +name: CI + +on: + push: + branches: + - '**' + pull_request: + branches: + - '**' + +jobs: + test: + name: Ruby ${{ matrix.ruby }} Tests + runs-on: ubuntu-latest + + strategy: + fail-fast: false + matrix: + ruby: + - '3.0' + - '3.1' + - '3.2' + - '3.3' + + steps: + - name: Checkout code + uses: actions/checkout@v4 + + - name: Set up Ruby + uses: ruby/setup-ruby@v1 + with: + ruby-version: ${{ matrix.ruby }} + bundler-cache: true + + - name: Install dependencies + run: bundle install --jobs 4 --retry 3 + + - name: Run tests + run: bundle exec rake spec diff --git a/README.md b/README.md index c0be67e..ce669d3 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,5 @@ # [WIP] EbayAPI +[![Build Status](https://github.com/main24/ebay_api/actions/workflows/test.yml/badge.svg?branch=support-catalog-product-search)](https://github.com/main24/ebay_api/actions/workflows/test.yml) Ruby client to eBay RESTful JSON API diff --git a/ebay_api.gemspec b/ebay_api.gemspec index 1e90c5e..49a3a7e 100644 --- a/ebay_api.gemspec +++ b/ebay_api.gemspec @@ -11,9 +11,9 @@ Gem::Specification.new do |gem| gem.test_files = gem.files.grep(/^spec/) gem.extra_rdoc_files = Dir["README.md", "LICENSE", "CHANGELOG.md"] - gem.required_ruby_version = ">= 2.2" + gem.required_ruby_version = ">= 3.0" - gem.add_runtime_dependency "evil-client", "~> 3.0", ">= 3.0.1" + gem.add_runtime_dependency "evil-client", "~> 3.2", ">= 3.2.0" gem.add_runtime_dependency "dry-equalizer" gem.add_development_dependency "rake", ">= 10"