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
5c768b0f
Commit
5c768b0f
authored
Sep 12, 2014
by
Fabio Pelosin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[Code] Compatiblity with Ruby 1.8.7 / 2
parent
46ace884
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
6 deletions
+7
-6
resolver.rb
lib/cocoapods/resolver.rb
+2
-1
resolver_spec.rb
spec/unit/resolver_spec.rb
+5
-5
No files found.
lib/cocoapods/resolver.rb
View file @
5c768b0f
...
@@ -210,10 +210,11 @@ module Pod
...
@@ -210,10 +210,11 @@ module Pod
# The dependency for which the set is needed.
# The dependency for which the set is needed.
#
#
def
find_set_from_sources
(
dependency
)
def
find_set_from_sources
(
dependency
)
sources
.
each
_with_object
(
nil
)
do
|
source
,
_
|
sources
.
each
do
|
source
|
set
=
source
.
search
(
dependency
)
set
=
source
.
search
(
dependency
)
return
set
if
set
return
set
if
set
end
end
nil
end
end
# Ensures that a specification is compatible with the platform of a target.
# Ensures that a specification is compatible with the platform of a target.
...
...
spec/unit/resolver_spec.rb
View file @
5c768b0f
...
@@ -249,7 +249,7 @@ module Pod
...
@@ -249,7 +249,7 @@ module Pod
specs
.
should
==
[
'AFNetworking (1.2.0)'
]
specs
.
should
==
[
'AFNetworking (1.2.0)'
]
end
end
it
'does not resolve to a pre-release version implicitly when matching exact version'
do
x
it
'does not resolve to a pre-release version implicitly when matching exact version'
do
@podfile
=
Podfile
.
new
do
@podfile
=
Podfile
.
new
do
platform
:ios
,
'6.0'
platform
:ios
,
'6.0'
pod
'AFNetworking'
,
'1.0'
pod
'AFNetworking'
,
'1.0'
...
@@ -273,7 +273,7 @@ module Pod
...
@@ -273,7 +273,7 @@ module Pod
specs
.
should
==
[
'AFNetworking (0.10.1)'
]
specs
.
should
==
[
'AFNetworking (0.10.1)'
]
end
end
it
'does not resolve to a pre-release version implicitly when using <='
do
x
it
'does not resolve to a pre-release version implicitly when using <='
do
@podfile
=
Podfile
.
new
do
@podfile
=
Podfile
.
new
do
platform
:ios
,
'6.0'
platform
:ios
,
'6.0'
pod
'AFNetworking'
,
'<= 1.0'
pod
'AFNetworking'
,
'<= 1.0'
...
@@ -285,7 +285,7 @@ module Pod
...
@@ -285,7 +285,7 @@ module Pod
specs
.
should
==
[
'AFNetworking (1.0)'
]
specs
.
should
==
[
'AFNetworking (1.0)'
]
end
end
it
'does not resolve to a pre-release version implicitly when using >'
do
x
it
'does not resolve to a pre-release version implicitly when using >'
do
@podfile
=
Podfile
.
new
do
@podfile
=
Podfile
.
new
do
platform
:ios
,
'6.0'
platform
:ios
,
'6.0'
pod
'AFNetworking'
,
'> 1.0'
,
'< 1.3'
pod
'AFNetworking'
,
'> 1.0'
,
'< 1.3'
...
@@ -297,7 +297,7 @@ module Pod
...
@@ -297,7 +297,7 @@ module Pod
specs
.
should
==
[
'AFNetworking (1.2.1)'
]
specs
.
should
==
[
'AFNetworking (1.2.1)'
]
end
end
it
'does not resolve to a pre-release version implicitly when using >='
do
x
it
'does not resolve to a pre-release version implicitly when using >='
do
@podfile
=
Podfile
.
new
do
@podfile
=
Podfile
.
new
do
platform
:ios
,
'6.0'
platform
:ios
,
'6.0'
pod
'AFNetworking'
,
'>= 1.0'
,
'< 1.3'
pod
'AFNetworking'
,
'>= 1.0'
,
'< 1.3'
...
@@ -309,7 +309,7 @@ module Pod
...
@@ -309,7 +309,7 @@ module Pod
specs
.
should
==
[
'AFNetworking (1.2.1)'
]
specs
.
should
==
[
'AFNetworking (1.2.1)'
]
end
end
it
'does not resolve to a pre-release version implicitly when using ~>'
do
x
it
'does not resolve to a pre-release version implicitly when using ~>'
do
@podfile
=
Podfile
.
new
do
@podfile
=
Podfile
.
new
do
platform
:ios
,
'6.0'
platform
:ios
,
'6.0'
pod
'AFNetworking'
,
'~> 1.0'
,
'< 1.3'
pod
'AFNetworking'
,
'~> 1.0'
,
'< 1.3'
...
...
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