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
39c46b5f
Commit
39c46b5f
authored
Jan 25, 2016
by
Marius Rackwitz
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #4818 from CocoaPods/fix-analyzer-crash
[Analyzer] Fix #4751
parents
b7ef2788
6922bd66
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
32 additions
and
2 deletions
+32
-2
CHANGELOG.md
CHANGELOG.md
+4
-0
analyzer.rb
lib/cocoapods/installer/analyzer.rb
+1
-2
analyzer_spec.rb
spec/unit/installer/analyzer_spec.rb
+27
-0
No files found.
CHANGELOG.md
View file @
39c46b5f
...
...
@@ -10,6 +10,10 @@ To install release candidates run `[sudo] gem install cocoapods --pre`
##### Bug Fixes
*
Fix a crash in the analyzer when target deduplication is deactivated.
[
Marius Rackwitz
](
https://github.com/mrackwitz
)
[
#4751
](
https://github.com/CocoaPods/CocoaPods/issues/4751
)
*
Handle CoreData mapping models with recursive resource globs.
[
Eric Firestone
](
https://github.com/efirestone
)
[
#4809
](
https://github.com/CocoaPods/CocoaPods/pull/4809
)
...
...
lib/cocoapods/installer/analyzer.rb
View file @
39c46b5f
...
...
@@ -286,9 +286,8 @@ module Pod
# @return [Array<PodTarget>]
#
def
generate_pod_targets
(
specs_by_target
)
dedupe_cache
=
{}
if
installation_options
.
deduplicate_targets?
dedupe_cache
=
{}
all_specs
=
specs_by_target
.
flat_map
do
|
target_definition
,
dependent_specs
|
dependent_specs
.
group_by
(
&
:root
).
map
do
|
root_spec
,
specs
|
[
root_spec
,
specs
,
target_definition
]
...
...
spec/unit/installer/analyzer_spec.rb
View file @
39c46b5f
...
...
@@ -244,6 +244,33 @@ module Pod
Pods-SampleProject/Pods-SampleProject-monkey
)
.
sort
end
it
"doesn't deduplicate targets when deduplication is disabled"
do
podfile
=
Pod
::
Podfile
.
new
do
install!
'cocoapods'
,
:deduplicate_targets
=>
false
source
SpecHelper
.
test_repo_url
platform
:ios
,
'6.0'
xcodeproj
'SampleProject/SampleProject'
pod
'BananaLib'
target
'SampleProject'
do
target
'TestRunner'
do
pod
'BananaLib'
end
end
end
analyzer
=
Pod
::
Installer
::
Analyzer
.
new
(
config
.
sandbox
,
podfile
)
analyzer
.
analyze
analyzer
.
analyze
.
targets
.
flat_map
{
|
at
|
at
.
pod_targets
.
map
{
|
pt
|
"
#{
at
.
name
}
/
#{
pt
.
name
}
"
}
}.
sort
.
should
==
%w(
Pods-SampleProject-TestRunner/Pods-SampleProject-TestRunner-BananaLib
Pods-SampleProject-TestRunner/Pods-SampleProject-TestRunner-monkey
Pods-SampleProject/Pods-SampleProject-BananaLib
Pods-SampleProject/Pods-SampleProject-monkey
)
.
sort
end
end
it
'generates the integration library appropriately if the installation will not integrate'
do
...
...
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