Commit 3179483a authored by Kyle Fuller's avatar Kyle Fuller

[Rubocop] Enable Style/TrailingComma

parent 3b89da68
...@@ -46,12 +46,6 @@ Style/GlobalVars: ...@@ -46,12 +46,6 @@ Style/GlobalVars:
Style/RegexpLiteral: Style/RegexpLiteral:
Enabled: false Enabled: false
# Offense count: 1
# Cop supports --auto-correct.
# Configuration parameters: EnforcedStyleForMultiline, SupportedStyles.
Style/TrailingComma:
Enabled: false
# Offense count: 1 # Offense count: 1
# Cop supports --auto-correct. # Cop supports --auto-correct.
# Configuration parameters: ExactNameMatch, AllowPredicates, AllowDSLWriters, Whitelist. # Configuration parameters: ExactNameMatch, AllowPredicates, AllowDSLWriters, Whitelist.
......
...@@ -15,7 +15,7 @@ module Pod ...@@ -15,7 +15,7 @@ module Pod
def self.options def self.options
[ [
['--regex', 'Interpret the `QUERY` as a regular expression'], ['--regex', 'Interpret the `QUERY` as a regular expression'],
['--show-all', 'Pick from all versions of the given podspec'] ['--show-all', 'Pick from all versions of the given podspec'],
].concat(super) ].concat(super)
end end
......
...@@ -15,7 +15,7 @@ module Pod ...@@ -15,7 +15,7 @@ module Pod
def self.options def self.options
[ [
['--regex', 'Interpret the `QUERY` as a regular expression'], ['--regex', 'Interpret the `QUERY` as a regular expression'],
['--show-all', 'Pick from all versions of the given podspec'] ['--show-all', 'Pick from all versions of the given podspec'],
].concat(super) ].concat(super)
end end
......
...@@ -62,7 +62,7 @@ module Pod ...@@ -62,7 +62,7 @@ module Pod
'PODS_FRAMEWORK_BUILD_PATH' => target.configuration_build_dir, 'PODS_FRAMEWORK_BUILD_PATH' => target.configuration_build_dir,
'FRAMEWORK_SEARCH_PATHS' => '"$PODS_FRAMEWORK_BUILD_PATH"', 'FRAMEWORK_SEARCH_PATHS' => '"$PODS_FRAMEWORK_BUILD_PATH"',
# Make headers discoverable by `import "…"` # Make headers discoverable by `import "…"`
'OTHER_CFLAGS' => '$(inherited) ' + XCConfigHelper.quote(header_search_paths, '-iquote') 'OTHER_CFLAGS' => '$(inherited) ' + XCConfigHelper.quote(header_search_paths, '-iquote'),
} }
config.merge!(build_settings) config.merge!(build_settings)
else else
...@@ -72,7 +72,7 @@ module Pod ...@@ -72,7 +72,7 @@ module Pod
# by `#import "…"` # by `#import "…"`
'HEADER_SEARCH_PATHS' => XCConfigHelper.quote(header_search_paths), 'HEADER_SEARCH_PATHS' => XCConfigHelper.quote(header_search_paths),
# by `#import <…>` # by `#import <…>`
'OTHER_CFLAGS' => '$(inherited) ' + XCConfigHelper.quote(header_search_paths, '-isystem') 'OTHER_CFLAGS' => '$(inherited) ' + XCConfigHelper.quote(header_search_paths, '-isystem'),
} }
config.merge!(build_settings) config.merge!(build_settings)
end end
...@@ -125,7 +125,7 @@ module Pod ...@@ -125,7 +125,7 @@ module Pod
else else
ld_runpath_search_paths << [ ld_runpath_search_paths << [
"'@executable_path/Frameworks'", "'@executable_path/Frameworks'",
"'@loader_path/Frameworks'" "'@loader_path/Frameworks'",
] ]
end end
@xcconfig.merge!('LD_RUNPATH_SEARCH_PATHS' => ld_runpath_search_paths.join(' ')) @xcconfig.merge!('LD_RUNPATH_SEARCH_PATHS' => ld_runpath_search_paths.join(' '))
......
...@@ -38,7 +38,7 @@ module Pod ...@@ -38,7 +38,7 @@ module Pod
add_copy_resources_script_phase add_copy_resources_script_phase
add_check_manifest_lock_script_phase add_check_manifest_lock_script_phase
true true
end end,
].any? ].any?
if project_is_dirty if project_is_dirty
......
...@@ -6,7 +6,7 @@ module Pod ...@@ -6,7 +6,7 @@ module Pod
target_definition = Podfile::TargetDefinition.new(:default, nil) target_definition = Podfile::TargetDefinition.new(:default, nil)
frameworks = { frameworks = {
'Debug' => %w(Loopback.framework Reveal.framework), 'Debug' => %w(Loopback.framework Reveal.framework),
'Release' => %w(CrashlyticsFramework.framework) 'Release' => %w(CrashlyticsFramework.framework),
} }
generator = Pod::Generator::EmbedFrameworksScript.new(target_definition, frameworks) generator = Pod::Generator::EmbedFrameworksScript.new(target_definition, frameworks)
generator.send(:script).should.include <<-eos.strip_heredoc generator.send(:script).should.include <<-eos.strip_heredoc
......
...@@ -53,7 +53,7 @@ module Pod ...@@ -53,7 +53,7 @@ module Pod
:libraries => [], :libraries => [],
:frameworks => [], :frameworks => [],
:weak_frameworks => [], :weak_frameworks => [],
:platform_name => :ios :platform_name => :ios,
) )
@sut.add_spec_build_settings_to_xcconfig(consumer, xcconfig) @sut.add_spec_build_settings_to_xcconfig(consumer, xcconfig)
xcconfig.to_hash['OTHER_LDFLAGS'].should == '-framework "SenTestingKit"' xcconfig.to_hash['OTHER_LDFLAGS'].should == '-framework "SenTestingKit"'
...@@ -66,7 +66,7 @@ module Pod ...@@ -66,7 +66,7 @@ module Pod
:libraries => ['xml2'], :libraries => ['xml2'],
:frameworks => [], :frameworks => [],
:weak_frameworks => [], :weak_frameworks => [],
:platform_name => :ios :platform_name => :ios,
) )
@sut.add_spec_build_settings_to_xcconfig(consumer, xcconfig) @sut.add_spec_build_settings_to_xcconfig(consumer, xcconfig)
xcconfig.to_hash['OTHER_LDFLAGS'].should == '-l"xml2"' xcconfig.to_hash['OTHER_LDFLAGS'].should == '-l"xml2"'
...@@ -79,7 +79,7 @@ module Pod ...@@ -79,7 +79,7 @@ module Pod
:libraries => [], :libraries => [],
:frameworks => ['CoreAnimation'], :frameworks => ['CoreAnimation'],
:weak_frameworks => [], :weak_frameworks => [],
:platform_name => :ios :platform_name => :ios,
) )
@sut.add_spec_build_settings_to_xcconfig(consumer, xcconfig) @sut.add_spec_build_settings_to_xcconfig(consumer, xcconfig)
xcconfig.to_hash['OTHER_LDFLAGS'].should == '-framework "CoreAnimation"' xcconfig.to_hash['OTHER_LDFLAGS'].should == '-framework "CoreAnimation"'
...@@ -92,7 +92,7 @@ module Pod ...@@ -92,7 +92,7 @@ module Pod
:libraries => [], :libraries => [],
:frameworks => [], :frameworks => [],
:weak_frameworks => ['iAd'], :weak_frameworks => ['iAd'],
:platform_name => :ios :platform_name => :ios,
) )
@sut.add_spec_build_settings_to_xcconfig(consumer, xcconfig) @sut.add_spec_build_settings_to_xcconfig(consumer, xcconfig)
xcconfig.to_hash['OTHER_LDFLAGS'].should == '-weak_framework "iAd"' xcconfig.to_hash['OTHER_LDFLAGS'].should == '-weak_framework "iAd"'
...@@ -105,7 +105,7 @@ module Pod ...@@ -105,7 +105,7 @@ module Pod
:libraries => [], :libraries => [],
:frameworks => ['SenTestingKit'], :frameworks => ['SenTestingKit'],
:weak_frameworks => [], :weak_frameworks => [],
:platform_name => :ios :platform_name => :ios,
) )
@sut.add_spec_build_settings_to_xcconfig(consumer, xcconfig) @sut.add_spec_build_settings_to_xcconfig(consumer, xcconfig)
xcconfig.to_hash['FRAMEWORK_SEARCH_PATHS'].should.include('SDKROOT') xcconfig.to_hash['FRAMEWORK_SEARCH_PATHS'].should.include('SDKROOT')
...@@ -119,7 +119,7 @@ module Pod ...@@ -119,7 +119,7 @@ module Pod
:libraries => [], :libraries => [],
:frameworks => ['SenTestingKit'], :frameworks => ['SenTestingKit'],
:weak_frameworks => [], :weak_frameworks => [],
:platform_name => :osx :platform_name => :osx,
) )
@sut.add_spec_build_settings_to_xcconfig(consumer, xcconfig) @sut.add_spec_build_settings_to_xcconfig(consumer, xcconfig)
xcconfig.to_hash['FRAMEWORK_SEARCH_PATHS'].should.include('DEVELOPER_LIBRARY_DIR') xcconfig.to_hash['FRAMEWORK_SEARCH_PATHS'].should.include('DEVELOPER_LIBRARY_DIR')
......
...@@ -149,7 +149,7 @@ module Pod ...@@ -149,7 +149,7 @@ module Pod
'AFNetworking/Reachability (2.4.0)', 'AFNetworking/Reachability (2.4.0)',
'AFNetworking/Security (2.4.0)', 'AFNetworking/Security (2.4.0)',
'AFNetworking/Serialization (2.4.0)', 'AFNetworking/Serialization (2.4.0)',
{ 'AFNetworking/UIKit (2.4.0)' => ['AFNetworking/NSURLConnection', 'AFNetworking/NSURLSession'] } { 'AFNetworking/UIKit (2.4.0)' => ['AFNetworking/NSURLConnection', 'AFNetworking/NSURLSession'] },
] ]
hash['DEPENDENCIES'] = ['AFNetworkActivityLogger', 'AFNetworking (2.4.0)'] hash['DEPENDENCIES'] = ['AFNetworkActivityLogger', 'AFNetworking (2.4.0)']
hash['SPEC CHECKSUMS'] = {} hash['SPEC CHECKSUMS'] = {}
......
...@@ -14,7 +14,7 @@ module Pod ...@@ -14,7 +14,7 @@ module Pod
@pod_bundle.client_root = project_path.dirname @pod_bundle.client_root = project_path.dirname
@pod_bundle.user_target_uuids = [@target.uuid] @pod_bundle.user_target_uuids = [@target.uuid]
configuration = Xcodeproj::Config.new( configuration = Xcodeproj::Config.new(
'GCC_PREPROCESSOR_DEFINITIONS' => '$(inherited) COCOAPODS=1' 'GCC_PREPROCESSOR_DEFINITIONS' => '$(inherited) COCOAPODS=1',
) )
@pod_bundle.xcconfigs['Debug'] = configuration @pod_bundle.xcconfigs['Debug'] = configuration
@pod_bundle.xcconfigs['Test'] = configuration @pod_bundle.xcconfigs['Test'] = configuration
......
...@@ -19,7 +19,7 @@ module Pod ...@@ -19,7 +19,7 @@ module Pod
@pod_bundle.client_root = project_path.dirname @pod_bundle.client_root = project_path.dirname
@pod_bundle.user_target_uuids = [@target.uuid] @pod_bundle.user_target_uuids = [@target.uuid]
configuration = Xcodeproj::Config.new( configuration = Xcodeproj::Config.new(
'GCC_PREPROCESSOR_DEFINITIONS' => '$(inherited) COCOAPODS=1' 'GCC_PREPROCESSOR_DEFINITIONS' => '$(inherited) COCOAPODS=1',
) )
@pod_bundle.xcconfigs['Debug'] = configuration @pod_bundle.xcconfigs['Debug'] = configuration
@pod_bundle.xcconfigs['Release'] = configuration @pod_bundle.xcconfigs['Release'] = configuration
......
...@@ -283,7 +283,7 @@ module Pod ...@@ -283,7 +283,7 @@ module Pod
resolver = Resolver.new(config.sandbox, @podfile, empty_graph, SourcesManager.all) resolver = Resolver.new(config.sandbox, @podfile, empty_graph, SourcesManager.all)
specs = resolver.resolve.values.flatten.map(&:to_s).sort specs = resolver.resolve.values.flatten.map(&:to_s).sort
specs.should == [ specs.should == [
'MainSpec (1.2.3-pre)' 'MainSpec (1.2.3-pre)',
] ]
end end
......
...@@ -68,46 +68,46 @@ module Pod ...@@ -68,46 +68,46 @@ module Pod
describe 'Support files' do describe 'Support files' do
it 'returns the absolute path of the xcconfig file' do it 'returns the absolute path of the xcconfig file' do
@pod_target.xcconfig_path('Release').to_s.should.include?( @pod_target.xcconfig_path('Release').to_s.should.include?(
'Pods/Target Support Files/Pods-BananaLib/Pods-BananaLib.release.xcconfig' 'Pods/Target Support Files/Pods-BananaLib/Pods-BananaLib.release.xcconfig',
) )
end end
it 'escapes the file separators in variant build configuration name in the xcconfig file' do it 'escapes the file separators in variant build configuration name in the xcconfig file' do
@pod_target.xcconfig_path("Release#{File::SEPARATOR}1").to_s.should.include?( @pod_target.xcconfig_path("Release#{File::SEPARATOR}1").to_s.should.include?(
'Pods/Target Support Files/Pods-BananaLib/Pods-BananaLib.release-1.xcconfig' 'Pods/Target Support Files/Pods-BananaLib/Pods-BananaLib.release-1.xcconfig',
) )
end end
it 'returns the absolute path of the target header file' do it 'returns the absolute path of the target header file' do
@pod_target.target_environment_header_path.to_s.should.include?( @pod_target.target_environment_header_path.to_s.should.include?(
'Pods/Target Support Files/Pods/Pods-environment.h' 'Pods/Target Support Files/Pods/Pods-environment.h',
) )
end end
it 'returns the absolute path of the prefix header file' do it 'returns the absolute path of the prefix header file' do
@pod_target.prefix_header_path.to_s.should.include?( @pod_target.prefix_header_path.to_s.should.include?(
'Pods/Target Support Files/Pods-BananaLib/Pods-BananaLib-prefix.pch' 'Pods/Target Support Files/Pods-BananaLib/Pods-BananaLib-prefix.pch',
) )
end end
it 'returns the absolute path of the bridge support file' do it 'returns the absolute path of the bridge support file' do
@pod_target.bridge_support_path.to_s.should.include?( @pod_target.bridge_support_path.to_s.should.include?(
'Pods/Target Support Files/Pods-BananaLib/Pods-BananaLib.bridgesupport' 'Pods/Target Support Files/Pods-BananaLib/Pods-BananaLib.bridgesupport',
) )
end end
it 'returns the absolute path of the info plist file' do it 'returns the absolute path of the info plist file' do
@pod_target.info_plist_path.to_s.should.include?( @pod_target.info_plist_path.to_s.should.include?(
'Pods/Target Support Files/Pods-BananaLib/Info.plist' 'Pods/Target Support Files/Pods-BananaLib/Info.plist',
) )
end end
it 'returns the absolute path of the public and private xcconfig files' do it 'returns the absolute path of the public and private xcconfig files' do
@pod_target.xcconfig_path.to_s.should.include?( @pod_target.xcconfig_path.to_s.should.include?(
'Pods/Target Support Files/Pods-BananaLib/Pods-BananaLib.xcconfig' 'Pods/Target Support Files/Pods-BananaLib/Pods-BananaLib.xcconfig',
) )
@pod_target.xcconfig_private_path.to_s.should.include( @pod_target.xcconfig_private_path.to_s.should.include(
'Pods/Target Support Files/Pods-BananaLib/Pods-BananaLib-Private.xcconfig' 'Pods/Target Support Files/Pods-BananaLib/Pods-BananaLib-Private.xcconfig',
) )
end end
......
...@@ -175,7 +175,7 @@ module Pod ...@@ -175,7 +175,7 @@ module Pod
stub_request(:head, 'banana-corp.local/valid-image.png'). stub_request(:head, 'banana-corp.local/valid-image.png').
to_return( to_return(
:status => 200, :status => 200,
:headers => { 'Content-Type' => 'image/png' } :headers => { 'Content-Type' => 'image/png' },
) )
end end
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment