Skip to content

Commit ac464bc

Browse files
committed
use new flexmock syntax
1 parent 48eef54 commit ac464bc

File tree

4 files changed

+5
-7
lines changed

4 files changed

+5
-7
lines changed

.github/workflows/lint.yml

-2
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,6 @@ jobs:
1111
ruby-version:
1212
- "3.0"
1313
- "2.7"
14-
- "2.6"
15-
- "2.5"
1614

1715
steps:
1816
- uses: actions/checkout@v2

.github/workflows/test.yml

-2
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,6 @@ jobs:
1111
ruby-version:
1212
- "3.0"
1313
- "2.7"
14-
- "2.6"
15-
- "2.5"
1614

1715
steps:
1816
- uses: actions/checkout@v2

autobuild.gemspec

+1-1
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ Gem::Specification.new do |s|
3434
s.add_runtime_dependency 'tty-screen', '~> 0.8.0'
3535
s.add_runtime_dependency "utilrb", "~> 3.0", ">= 3.0"
3636
s.add_development_dependency "fakefs"
37-
s.add_development_dependency "flexmock", '~> 2.0', ">= 2.0.0"
37+
s.add_development_dependency "flexmock"
3838
s.add_development_dependency "minitest", "~> 5.0", ">= 5.0"
3939
s.add_development_dependency "simplecov"
4040
s.add_development_dependency "timecop"

test/import/test_git.rb

+4-2
Original file line numberDiff line numberDiff line change
@@ -275,7 +275,7 @@
275275
any, :import, 'git', 'clone', '-o', 'autobuild',
276276
File.join(tempdir, 'gitrepo.git'),
277277
File.join(tempdir, 'git'), any
278-
)
278+
).with_any_kw_args
279279

280280
flexmock(Autobuild::Subprocess).should_receive(:run).pass_thru
281281

@@ -297,7 +297,7 @@ def assert_clone(*args)
297297
any, :import, 'git', 'clone', '-o', 'autobuild', *args,
298298
File.join(tempdir, 'gitrepo.git'),
299299
File.join(tempdir, 'git'), any
300-
).once.pass_thru
300+
).with_any_kw_args.once.pass_thru
301301

302302
flexmock(Autobuild::Subprocess).should_receive(:run).pass_thru
303303
end
@@ -992,6 +992,7 @@ def pin_importer(id, options = Hash.new)
992992
.should_receive(:run)
993993
.with(any, :import, 'git', '--git-dir', File.join(pkg.srcdir, ".git"),
994994
'symbolic-ref', "refs/remotes/autobuild/HEAD", any)
995+
.with_any_kw_args
995996
.once
996997
.and_return(['refs/remotes/autobuild/temp/branch', 'bla'])
997998
flexmock(Autobuild::Subprocess).should_receive(:run).pass_thru
@@ -1027,6 +1028,7 @@ def pin_importer(id, options = Hash.new)
10271028
any, :import, 'git', 'ls-remote', '--symref',
10281029
File.join(tempdir, 'gitrepo-nomaster.git'), any
10291030
)
1031+
.with_any_kw_args
10301032
.once
10311033
.and_return(['ref: refs/heads/temp/branch HEAD', 'bla'])
10321034
flexmock(Autobuild::Subprocess).should_receive(:run).pass_thru

0 commit comments

Comments
 (0)