From 78c6a086164aa83ce2e4e57daadfbdb53a31a37f Mon Sep 17 00:00:00 2001 From: mo khan Date: Tue, 31 Dec 2024 11:51:58 -0700 Subject: feat: Add support for Ruby 3.2+ --- spec/integration/cli/build_spec.rb | 17 +---------------- spec/integration/cli/pull_spec.rb | 12 +----------- spec/integration/core/git_spec.rb | 2 +- 3 files changed, 3 insertions(+), 28 deletions(-) (limited to 'spec/integration') diff --git a/spec/integration/cli/build_spec.rb b/spec/integration/cli/build_spec.rb index 0e51301..47f63a7 100644 --- a/spec/integration/cli/build_spec.rb +++ b/spec/integration/cli/build_spec.rb @@ -3,21 +3,6 @@ RSpec.describe '`spandx build` command', type: :cli do it 'executes `spandx help build` command successfully' do output = `spandx help build` - expected_output = <<~OUT - Usage: - spandx build - - Options: - -h, [--help], [--no-help] # Display usage information - -d, [--directory=DIRECTORY] # Directory to build index in - # Default: .index - -l, [--logfile=LOGFILE] # Path to a logfile - # Default: /dev/null - -i, [--index=INDEX] # The specific index to build - # Default: all - - Build a package index - OUT - expect(output).to eq(expected_output) + expect(output).to eq(fixture_file_content('help-build.expected')) end end diff --git a/spec/integration/cli/pull_spec.rb b/spec/integration/cli/pull_spec.rb index de3426f..f2d396b 100644 --- a/spec/integration/cli/pull_spec.rb +++ b/spec/integration/cli/pull_spec.rb @@ -3,16 +3,6 @@ RSpec.describe '`spandx pull` command', type: :cli do it 'executes `spandx help pull` command successfully' do output = `spandx help pull` - expected_output = <<~OUT - Usage: - spandx pull - - Options: - -h, [--help], [--no-help] # Display usage information - - Pull the latest offline cache - OUT - - expect(output).to eq(expected_output) + expect(output).to eq(fixture_file_content('help-pull.expected')) end end diff --git a/spec/integration/core/git_spec.rb b/spec/integration/core/git_spec.rb index d431dbd..a678269 100644 --- a/spec/integration/core/git_spec.rb +++ b/spec/integration/core/git_spec.rb @@ -1,7 +1,7 @@ # frozen_string_literal: true RSpec.describe Spandx::Core::Git do - subject { described_class.new(url: url) } + subject { described_class.new(url:) } let(:url) { 'https://github.com/spdx/license-list-data.git' } let(:shell) { subject } -- cgit v1.2.3