Commit 7a599f66 authored by Samuel Giddins's avatar Samuel Giddins

[PodTargetSettings] Say there is no module map to import when the target is not being built

parent fb46e559
...@@ -650,6 +650,7 @@ module Pod ...@@ -650,6 +650,7 @@ module Pod
# @return [Array<String>] # @return [Array<String>]
define_build_settings_method :module_map_file_to_import, :memoized => true do define_build_settings_method :module_map_file_to_import, :memoized => true do
return unless target.should_build?
return if target.requires_frameworks? return if target.requires_frameworks?
return unless target.defines_module? return unless target.defines_module?
......
...@@ -176,6 +176,12 @@ module Pod ...@@ -176,6 +176,12 @@ module Pod
@xcconfig.to_hash['PRODUCT_BUNDLE_IDENTIFIER'].should == 'org.cocoapods.${PRODUCT_NAME:rfc1034identifier}' @xcconfig.to_hash['PRODUCT_BUNDLE_IDENTIFIER'].should == 'org.cocoapods.${PRODUCT_NAME:rfc1034identifier}'
end end
it 'does not have a module map to import if it is not built' do
@pod_target.stubs(:should_build? => false, :requires_frameworks? => false, :defines_module? => true)
@generator.generate
@generator.module_map_file_to_import.should.be.nil
end
it 'saves the xcconfig' do it 'saves the xcconfig' do
path = temporary_directory + 'sample.xcconfig' path = temporary_directory + 'sample.xcconfig'
@generator.save_as(path) @generator.save_as(path)
......
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