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
7405ae08
Commit
7405ae08
authored
May 16, 2018
by
Dimitris Koutsogiorgas
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Do not try to integrate uncreated test native targets
parent
a72ce8bc
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
38 additions
and
1 deletion
+38
-1
CHANGELOG.md
CHANGELOG.md
+4
-0
target_installation_result.rb
...code/pods_project_generator/target_installation_result.rb
+2
-1
target_installation_result_spec.rb
...pods_project_generator/target_installation_result_spec.rb
+32
-0
No files found.
CHANGELOG.md
View file @
7405ae08
...
@@ -24,6 +24,10 @@ To install release candidates run `[sudo] gem install cocoapods --pre`
...
@@ -24,6 +24,10 @@ To install release candidates run `[sudo] gem install cocoapods --pre`
[
Dimitris Koutsogiorgas
](
https://github.com/dnkoutso
)
[
Dimitris Koutsogiorgas
](
https://github.com/dnkoutso
)
[
#7746
](
https://github.com/CocoaPods/CocoaPods/issues/7746
)
[
#7746
](
https://github.com/CocoaPods/CocoaPods/issues/7746
)
*
Do not try to integrate uncreated test native targets
[
Dimitris Koutsogiorgas
](
https://github.com/dnkoutso
)
[
#7394
](
https://github.com/CocoaPods/CocoaPods/issues/7394
)
*
Do not crash when creating build settings for a missing user build configuration
*
Do not crash when creating build settings for a missing user build configuration
[
Dimitris Koutsogiorgas
](
https://github.com/dnkoutso
)
[
Dimitris Koutsogiorgas
](
https://github.com/dnkoutso
)
[
#7698
](
https://github.com/CocoaPods/CocoaPods/pull/7698
)
[
#7698
](
https://github.com/CocoaPods/CocoaPods/pull/7698
)
...
...
lib/cocoapods/installer/xcode/pods_project_generator/target_installation_result.rb
View file @
7405ae08
...
@@ -73,9 +73,10 @@ module Pod
...
@@ -73,9 +73,10 @@ module Pod
# an array of all the test specs associated with this native target.
# an array of all the test specs associated with this native target.
#
#
def
test_specs_by_native_target
def
test_specs_by_native_target
target
.
test_specs
.
group_by
do
|
test_spec
|
t
est_specs_by_native_target
=
t
arget
.
test_specs
.
group_by
do
|
test_spec
|
test_native_target_from_spec
(
test_spec
)
test_native_target_from_spec
(
test_spec
)
end
end
test_specs_by_native_target
.
delete_if
{
|
k
,
_
|
k
.
nil?
}
end
end
private
private
...
...
spec/unit/installer/xcode/pods_project_generator/target_installation_result_spec.rb
0 → 100644
View file @
7405ae08
require
File
.
expand_path
(
'../../../../../spec_helper'
,
__FILE__
)
module
Pod
class
Installer
class
Xcode
class
PodsProjectGenerator
describe
TargetInstallationResult
do
describe
'In General'
do
before
do
@coconut_spec
=
fixture_spec
(
'coconut-lib/CoconutLib.podspec'
)
@coconut_test_spec
=
@coconut_spec
.
test_specs
.
first
@pod_target
=
fixture_pod_target_with_specs
([
@coconut_spec
,
@coconut_test_spec
])
end
it
'groups test specs by the native target they are part of'
do
native_target
=
stub
(
'native_target'
)
test_native_target
=
stub
(
'test_native_target'
,
:symbol_type
=>
:unit_test_bundle
)
result
=
TargetInstallationResult
.
new
(
@pod_target
,
native_target
,
[],
[
test_native_target
])
result
.
test_specs_by_native_target
.
should
==
{
test_native_target
=>
[
@coconut_test_spec
]
}
end
it
'does not return test specs by native target which they were not integrated'
do
native_target
=
stub
(
'native_target'
)
result
=
TargetInstallationResult
.
new
(
@pod_target
,
native_target
,
[],
[])
result
.
test_specs_by_native_target
.
should
.
be
.
empty
end
end
end
end
end
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