Applied rubocop cop 'Style/Next'.
This commit is contained in:
parent
70e126a95c
commit
efbeef41e1
1 changed files with 13 additions and 14 deletions
|
@ -1,5 +1,4 @@
|
||||||
# encoding: utf-8
|
# encoding: utf-8
|
||||||
# rubocop:disable Next, CyclomaticComplexity
|
|
||||||
require 'test_helper'
|
require 'test_helper'
|
||||||
|
|
||||||
class SessionCollectionsTest < ActiveSupport::TestCase
|
class SessionCollectionsTest < ActiveSupport::TestCase
|
||||||
|
@ -139,7 +138,8 @@ class SessionCollectionsTest < ActiveSupport::TestCase
|
||||||
def check_if_collection_exists(results, collection, attributes = nil)
|
def check_if_collection_exists(results, collection, attributes = nil)
|
||||||
results.each {|result|
|
results.each {|result|
|
||||||
next if !result
|
next if !result
|
||||||
if result[:collection] && result[:collection][collection]
|
next if !result[:collection]
|
||||||
|
next if !result[:collection][collection]
|
||||||
|
|
||||||
# check just if collection exists
|
# check just if collection exists
|
||||||
return true if !attributes
|
return true if !attributes
|
||||||
|
@ -154,7 +154,6 @@ class SessionCollectionsTest < ActiveSupport::TestCase
|
||||||
}
|
}
|
||||||
return true if match_all
|
return true if match_all
|
||||||
}
|
}
|
||||||
end
|
|
||||||
}
|
}
|
||||||
nil
|
nil
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in a new issue