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
e58b364d
Commit
e58b364d
authored
May 27, 2012
by
Fabio Pelosin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[Specs] Detect the target with the matching name.
parent
48b7e5c5
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
0 deletions
+13
-0
user_project_integrator_spec.rb
spec/unit/installer/user_project_integrator_spec.rb
+13
-0
No files found.
spec/unit/installer/user_project_integrator_spec.rb
View file @
e58b364d
...
...
@@ -57,6 +57,19 @@ describe Pod::Installer::UserProjectIntegrator do
lambda
{
@target_integrator
.
user_project_path
}.
should
.
raise
Pod
::
Informative
end
it
"uses the target with the same name if the name is different from `:default'"
do
target_integrator
=
@integrator
.
target_integrators
[
1
]
target_integrator
.
target_definition
.
stubs
(
:name
).
returns
(
'TestRunner'
)
target_integrator
.
target_definition
.
stubs
(
:link_with
).
returns
(
nil
)
target_integrator
.
targets
.
first
.
name
.
should
==
'TestRunner'
end
it
"it raises if it can't find a target with the same name"
do
target_integrator
=
@integrator
.
target_integrators
[
1
]
target_integrator
.
target_definition
.
stubs
(
:link_with
).
returns
(
nil
)
lambda
{
target_integrator
.
targets
}.
should
.
raise
Pod
::
Informative
end
it
"uses the first target in the user's project if no explicit target is specified"
do
@target_integrator
.
target_definition
.
stubs
(
:link_with
).
returns
(
nil
)
@target_integrator
.
targets
.
should
==
[
Xcodeproj
::
Project
.
new
(
@sample_project_path
).
targets
.
first
]
...
...
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