Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

deps: Add pstore, ostruct to Gemfile #2232

Merged
merged 2 commits into from
Jan 15, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,8 @@ gem "rbs-amber", path: "test/assets/test-gem"
# Bundled gems
gem "net-smtp"
gem 'csv'
gem 'ostruct'
gem 'pstore'

group :minitest do
gem "minitest"
Expand Down
4 changes: 4 additions & 0 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -66,11 +66,13 @@ GEM
net-smtp (0.5.0)
net-protocol
nkf (0.2.0)
ostruct (0.6.1)
parallel (1.26.3)
parser (3.3.6.0)
ast (~> 2.4.1)
racc
power_assert (2.0.5)
pstore (0.1.4)
psych (4.0.6)
stringio
public_suffix (6.0.1)
Expand Down Expand Up @@ -174,6 +176,8 @@ DEPENDENCIES
mutex_m
net-smtp
nkf
ostruct
pstore
raap
rake
rake-compiler
Expand Down
20 changes: 10 additions & 10 deletions test/rbs/cli_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -1174,7 +1174,7 @@ def test_collection_install
path: #{dir.join('gem_rbs_collection')}
YAML

bundle_install('ast', 'abbrev', 'bigdecimal')
bundle_install('ast', 'abbrev', 'bigdecimal', 'logger')
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some test cases failed due to a lack of dependencies. The logger package has also been moved into the bundled gem since ruby-3.5.
https://github.com/ruby/rbs/actions/runs/12742248343/job/35510085716?pr=2232

_stdout, _stderr = run_rbs_collection("install", bundler: true)

rbs_collection_lock = dir.join('rbs_collection.lock.yaml')
Expand Down Expand Up @@ -1240,7 +1240,7 @@ def test_collection_update
path: #{dir.join('gem_rbs_collection')}
YAML

bundle_install('ast', 'abbrev', 'bigdecimal')
bundle_install('ast', 'abbrev', 'bigdecimal', 'logger')
run_rbs_collection("update", bundler: true)

assert dir.join('rbs_collection.lock.yaml').exist?
Expand Down Expand Up @@ -1280,7 +1280,7 @@ def test_collection_install_gemspec
RUBY
(dir/"sig").mkdir

bundle_install(:gemspec, "abbrev", "bigdecimal")
bundle_install(:gemspec, "abbrev", "bigdecimal", "logger")
stdout, _ = run_rbs_collection("install", bundler: true)

assert_match(/Installing ast:(\d(\.\d)*)/, stdout)
Expand Down Expand Up @@ -1310,7 +1310,7 @@ def test_collection_install__mutex_m__config__bundled
- name: mutex_m
YAML

bundle_install(["mutex_m", ">= 0.3.0"])
bundle_install("logger", ["mutex_m", ">= 0.3.0"])
_stdout, stderr = run_rbs_collection("install", bundler: true)

refute_match(/`mutex_m` as a stdlib in rbs-gem is deprecated./, stderr)
Expand Down Expand Up @@ -1343,7 +1343,7 @@ def test_collection_install__mutex_m__config__no_bundled
- name: mutex_m
YAML

bundle_install(["mutex_m", "0.2.0"])
bundle_install("logger", ["mutex_m", "0.2.0"])
_stdout, stderr = run_rbs_collection("install", bundler: true)

assert_include stderr, '`mutex_m` as a stdlib in rbs-gem is deprecated.'
Expand Down Expand Up @@ -1379,7 +1379,7 @@ def test_collection_install__mutex_m__config__stdlib_source
type: stdlib
YAML

bundle_install
bundle_install("logger")
_stdout, stderr = run_rbs_collection("install", bundler: true)

assert_include stderr, '`mutex_m` as a stdlib in rbs-gem is deprecated.'
Expand Down Expand Up @@ -1410,7 +1410,7 @@ def test_collection_install__mutex_m__bundled
path: #{dir.join('gem_rbs_collection')}
YAML

bundle_install(["mutex_m", ">= 0.3.0"])
bundle_install("logger", ["mutex_m", ">= 0.3.0"])
_stdout, stderr = run_rbs_collection("install", bundler: true)

refute_match(/`mutex_m` as a stdlib in rbs-gem is deprecated./, stderr)
Expand Down Expand Up @@ -1440,7 +1440,7 @@ def test_collection_install__mutex_m__no_bundled
path: #{dir.join('gem_rbs_collection')}
YAML

bundle_install(["mutex_m", "0.2.0"])
bundle_install("logger", ["mutex_m", "0.2.0"])
_stdout, stderr = run_rbs_collection("install", bundler: true)

assert_include stderr, '`mutex_m` as a stdlib in rbs-gem is deprecated.'
Expand Down Expand Up @@ -1475,7 +1475,7 @@ def test_collection_install__mutex_m__dependency_no_bundled
- name: mutex_m
YAML

bundle_install("true_string") # true_string is a soutaro's gem that doesn't have sig directory
bundle_install("logger", "true_string") # true_string is a soutaro's gem that doesn't have sig directory

_stdout, stderr = run_rbs_collection("install", bundler: true)

Expand Down Expand Up @@ -1519,7 +1519,7 @@ def test_collection_install__mutex_m__rbs_dependency_and__gem_dependency
- name: mutex_m
YAML

bundle_install(["hola", { path: "gem" }])
bundle_install("logger", ["hola", { path: "gem" }])

(dir + RBS::Collection::Config::PATH).write(<<~YAML)
sources:
Expand Down
Loading