Commit f0bc470a authored by Fabio Pelosin's avatar Fabio Pelosin

[Specification::DSL] frameworks_bundles -> vendored_frameworks; library_files -> vendored_libraries

parent e4eec8d0
...@@ -7,7 +7,7 @@ GIT ...@@ -7,7 +7,7 @@ GIT
GIT GIT
remote: https://github.com/CocoaPods/Core.git remote: https://github.com/CocoaPods/Core.git
revision: e78e9726126271d083d855c58ff3c9b30f360170 revision: 8a8ace23f5e6ecd4a32b26192d8f1be138a39604
branch: feature-frameworks-bundles branch: feature-frameworks-bundles
specs: specs:
cocoapods-core (0.22.3) cocoapods-core (0.22.3)
......
...@@ -54,11 +54,11 @@ module Pod ...@@ -54,11 +54,11 @@ module Pod
target.pod_targets.each do |pod_target| target.pod_targets.each do |pod_target|
pod_target.file_accessors.each do |file_accessor| pod_target.file_accessors.each do |file_accessor|
XCConfigHelper.add_spec_build_settings_to_xcconfig(file_accessor.spec_consumer, @xcconfig) XCConfigHelper.add_spec_build_settings_to_xcconfig(file_accessor.spec_consumer, @xcconfig)
file_accessor.framework_bundles.each do |framework_bundle| file_accessor.vendored_frameworks.each do |vendored_framework|
XCConfigHelper.add_framework_build_settings(framework_bundle, @xcconfig, target.sandbox.root) XCConfigHelper.add_framework_build_settings(vendored_framework, @xcconfig, target.sandbox.root)
end end
file_accessor.library_files.each do |library_file| file_accessor.vendored_libraries.each do |vendored_library|
XCConfigHelper.add_library_build_settings(library_file, @xcconfig, target.sandbox.root) XCConfigHelper.add_library_build_settings(vendored_library, @xcconfig, target.sandbox.root)
end end
end end
end end
......
...@@ -44,11 +44,11 @@ module Pod ...@@ -44,11 +44,11 @@ module Pod
@xcconfig = Xcodeproj::Config.new @xcconfig = Xcodeproj::Config.new
target.file_accessors.each do |file_accessor| target.file_accessors.each do |file_accessor|
XCConfigHelper.add_spec_build_settings_to_xcconfig(file_accessor.spec_consumer, @xcconfig) XCConfigHelper.add_spec_build_settings_to_xcconfig(file_accessor.spec_consumer, @xcconfig)
file_accessor.framework_bundles.each do |framework_bundle| file_accessor.vendored_frameworks.each do |vendored_framework|
XCConfigHelper.add_framework_build_settings(framework_bundle, @xcconfig, target.sandbox.root) XCConfigHelper.add_framework_build_settings(vendored_framework, @xcconfig, target.sandbox.root)
end end
file_accessor.library_files.each do |library_file| file_accessor.vendored_libraries.each do |vendored_library|
XCConfigHelper.add_library_build_settings(library_file, @xcconfig, target.sandbox.root) XCConfigHelper.add_library_build_settings(vendored_library, @xcconfig, target.sandbox.root)
end end
end end
@xcconfig @xcconfig
......
...@@ -36,7 +36,7 @@ module Pod ...@@ -36,7 +36,7 @@ module Pod
refresh_file_accessors refresh_file_accessors
add_source_files_references add_source_files_references
add_frameworks_bundles add_frameworks_bundles
add_library_files add_vendored_libraries
add_resources add_resources
link_headers link_headers
end end
...@@ -83,7 +83,7 @@ module Pod ...@@ -83,7 +83,7 @@ module Pod
# #
def add_frameworks_bundles def add_frameworks_bundles
UI.message "- Adding frameworks to Pods project" do UI.message "- Adding frameworks to Pods project" do
add_file_acessors_paths_to_pods_group(:framework_bundles, :frameworks_and_libraries) add_file_acessors_paths_to_pods_group(:vendored_frameworks, :frameworks_and_libraries)
end end
end end
...@@ -91,9 +91,9 @@ module Pod ...@@ -91,9 +91,9 @@ module Pod
# #
# @return [void] # @return [void]
# #
def add_library_files def add_vendored_libraries
UI.message "- Adding frameworks to Pods project" do UI.message "- Adding frameworks to Pods project" do
add_file_acessors_paths_to_pods_group(:library_files, :frameworks_and_libraries) add_file_acessors_paths_to_pods_group(:vendored_libraries, :frameworks_and_libraries)
end end
end end
......
...@@ -229,8 +229,8 @@ module Pod ...@@ -229,8 +229,8 @@ module Pod
# #
def used_files def used_files
files = [ files = [
file_accessors.map(&:framework_bundles), file_accessors.map(&:vendored_frameworks),
file_accessors.map(&:library_files), file_accessors.map(&:vendored_libraries),
file_accessors.map(&:resource_bundle_files), file_accessors.map(&:resource_bundle_files),
file_accessors.map(&:license), file_accessors.map(&:license),
file_accessors.map(&:prefix_header), file_accessors.map(&:prefix_header),
......
...@@ -109,15 +109,15 @@ module Pod ...@@ -109,15 +109,15 @@ module Pod
# @return [Array<Pathname>] The paths of the framework bundles that come # @return [Array<Pathname>] The paths of the framework bundles that come
# shipped with the Pod. # shipped with the Pod.
# #
def framework_bundles def vendored_frameworks
paths_for_attribute(:framework_bundles, true) paths_for_attribute(:vendored_frameworks, true)
end end
# @return [Array<Pathname>] The paths of the library bundles that come # @return [Array<Pathname>] The paths of the library bundles that come
# shipped with the Pod. # shipped with the Pod.
# #
def library_files def vendored_libraries
paths_for_attribute(:library_files) paths_for_attribute(:vendored_libraries)
end end
# @return [Hash{String => Array<Pathname>}] A hash that describes the # @return [Hash{String => Array<Pathname>}] A hash that describes the
......
...@@ -18,8 +18,8 @@ module Pod ...@@ -18,8 +18,8 @@ module Pod
@spec.weak_frameworks = ['iAd'] @spec.weak_frameworks = ['iAd']
@spec.libraries = ['xml2'] @spec.libraries = ['xml2']
file_accessors = [Sandbox::FileAccessor.new(fixture('banana-lib'), @spec.consumer(:ios))] file_accessors = [Sandbox::FileAccessor.new(fixture('banana-lib'), @spec.consumer(:ios))]
# framework_bundle_paths = [config.sandbox.root + 'BananaLib/BananaLib.framework'] # vendored_framework_paths = [config.sandbox.root + 'BananaLib/BananaLib.framework']
# Sandbox::FileAccessor.any_instance.stubs(:framework_bundles).returns(framework_bundle_paths) # Sandbox::FileAccessor.any_instance.stubs(:vendored_frameworks).returns(vendored_framework_paths)
@pod_target.target_definition.stubs(:podfile).returns(@podfile) @pod_target.target_definition.stubs(:podfile).returns(@podfile)
@pod_target.stubs(:file_accessors).returns(file_accessors) @pod_target.stubs(:file_accessors).returns(file_accessors)
......
...@@ -171,13 +171,13 @@ module Pod ...@@ -171,13 +171,13 @@ module Pod
it "compacts the used files as nil would be converted to the empty string" do it "compacts the used files as nil would be converted to the empty string" do
Sandbox::FileAccessor.any_instance.stubs(:source_files) Sandbox::FileAccessor.any_instance.stubs(:source_files)
Sandbox::FileAccessor.any_instance.stubs(:library_files) Sandbox::FileAccessor.any_instance.stubs(:vendored_libraries)
Sandbox::FileAccessor.any_instance.stubs(:resources).returns(nil) Sandbox::FileAccessor.any_instance.stubs(:resources).returns(nil)
Sandbox::FileAccessor.any_instance.stubs(:preserve_paths) Sandbox::FileAccessor.any_instance.stubs(:preserve_paths)
Sandbox::FileAccessor.any_instance.stubs(:prefix_header) Sandbox::FileAccessor.any_instance.stubs(:prefix_header)
Sandbox::FileAccessor.any_instance.stubs(:readme) Sandbox::FileAccessor.any_instance.stubs(:readme)
Sandbox::FileAccessor.any_instance.stubs(:license) Sandbox::FileAccessor.any_instance.stubs(:license)
Sandbox::FileAccessor.any_instance.stubs(:framework_bundles) Sandbox::FileAccessor.any_instance.stubs(:vendored_frameworks)
paths = @installer.send(:used_files) paths = @installer.send(:used_files)
paths.should == [] paths.should == []
end end
......
...@@ -104,11 +104,11 @@ module Pod ...@@ -104,11 +104,11 @@ module Pod
end end
it "returns the paths of the framework bundles" do it "returns the paths of the framework bundles" do
@accessor.framework_bundles.should.include?(@root + "Bananalib.framework") @accessor.vendored_frameworks.should.include?(@root + "Bananalib.framework")
end end
it "returns the paths of the library files" do it "returns the paths of the library files" do
@accessor.library_files.should.include?(@root + "libBananalib.a") @accessor.vendored_libraries.should.include?(@root + "libBananalib.a")
end end
it "returns the resource bundles of the pod" do it "returns the resource bundles of the pod" do
......
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