Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
C
cocoapods
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
gengmeiios
cocoapods
Commits
4aa8509b
Commit
4aa8509b
authored
Dec 15, 2014
by
Marius Rackwitz
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add PodTarget#resources_bundle_target_label(bundle_name)
parent
7c4a1c58
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
0 deletions
+13
-0
pod_target.rb
lib/cocoapods/target/pod_target.rb
+9
-0
pod_target_spec.rb
spec/unit/target/pod_target_spec.rb
+4
-0
No files found.
lib/cocoapods/target/pod_target.rb
View file @
4aa8509b
...
@@ -82,6 +82,15 @@ module Pod
...
@@ -82,6 +82,15 @@ module Pod
root_spec
.
name
root_spec
.
name
end
end
# @param [String] bundle_name
# The name of the bundle product, which is given by the +spec+.
#
# @return [String] The derived name of the resource bundle target.
#
def
resources_bundle_target_label
(
bundle_name
)
"
#{
label
}
-
#{
bundle_name
}
"
end
# @return [Array<String>] The names of the Pods on which this target
# @return [Array<String>] The names of the Pods on which this target
# depends.
# depends.
#
#
...
...
spec/unit/target/pod_target_spec.rb
View file @
4aa8509b
...
@@ -34,6 +34,10 @@ module Pod
...
@@ -34,6 +34,10 @@ module Pod
@pod_target
.
pod_name
.
should
==
'BananaLib'
@pod_target
.
pod_name
.
should
==
'BananaLib'
end
end
it
'returns the name of the resources bundle target'
do
@pod_target
.
resources_bundle_target_label
(
'Fruits'
).
should
==
'Pods-BananaLib-Fruits'
end
it
'returns the name of the Pods on which this target depends'
do
it
'returns the name of the Pods on which this target depends'
do
@pod_target
.
dependencies
.
should
==
[
'monkey'
]
@pod_target
.
dependencies
.
should
==
[
'monkey'
]
end
end
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment