fix rubocop Style/Lambda cop

This commit is contained in:
Pavel Lobashov 2015-03-23 19:04:22 +03:00
parent d5f79822c1
commit b6f9176fd4
2 changed files with 1 additions and 6 deletions

View File

@ -160,11 +160,6 @@ Style/IfUnlessModifier:
Style/InfiniteLoop:
Enabled: false
# Offense count: 1
# Cop supports --auto-correct.
Style/Lambda:
Enabled: false
# Offense count: 24
# Cop supports --auto-correct.
Style/LeadingCommentSpace:

View File

@ -18,7 +18,7 @@ class EncryptionTest < MiniTest::Test
@rand = [250, 143, 107, 13, 143, 22, 155, 75, 228, 150, 12]
@output = ::Zip::DOSTime.stub(:now, ::Zip::DOSTime.new(2014, 12, 17, 15, 56, 24)) do
Random.stub(:rand, lambda { |_range| @rand.shift }) do
Random.stub(:rand, ->(_range) { @rand.shift }) do
Zip::OutputStream.write_buffer(::StringIO.new(''), Zip::TraditionalEncrypter.new('password')) do |zos|
zos.put_next_entry('file1.txt')
zos.write open(INPUT_FILE1).read