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
ed78b00b
Commit
ed78b00b
authored
Mar 09, 2016
by
Daniel Tomlinson
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
make functional tests pass
parent
a5e83f3f
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
14 additions
and
13 deletions
+14
-13
outdated.rb
lib/cocoapods/command/outdated.rb
+1
-1
update_spec.rb
spec/functional/command/repo/update_spec.rb
+9
-0
sources_manager_spec.rb
spec/unit/sources_manager_spec.rb
+4
-12
No files found.
lib/cocoapods/command/outdated.rb
View file @
ed78b00b
...
...
@@ -91,7 +91,7 @@ module Pod
def
spec_sets
@spec_sets
||=
begin
analyzer
.
send
(
:update_repositories
)
unless
config
.
skip_repo_update?
aggregate
=
Source
::
Aggregate
.
new
(
analyzer
.
sources
.
map
(
&
:repo
)
)
aggregate
=
Source
::
Aggregate
.
new
(
analyzer
.
sources
.
map
)
installed_pods
.
map
do
|
pod_name
|
aggregate
.
search
(
Dependency
.
new
(
pod_name
))
end
.
compact
.
uniq
...
...
spec/functional/command/repo/update_spec.rb
View file @
ed78b00b
require
File
.
expand_path
(
'../../../../spec_helper'
,
__FILE__
)
require
'webmock'
module
Pod
describe
Command
::
Repo
::
Update
do
...
...
@@ -8,6 +9,14 @@ module Pod
before
do
set_up_test_repo
config
.
repos_dir
=
SpecHelper
.
tmp_repos_path
WebMock
::
API
.
stub_request
(
:get
,
"https://api.github.com/repos/cocoapods/specs/commits/master"
)
.
with
(
:headers
=>
{
'Accept'
=>
'application/vnd.github.chitauri-preview+sha'
})
.
to_return
(
:status
=>
200
,
:body
=>
''
,
:headers
=>
{})
end
after
do
WebMock
.
reset!
end
it
'updates a repository'
do
...
...
spec/unit/sources_manager_spec.rb
View file @
ed78b00b
require
File
.
expand_path
(
'../../spec_helper'
,
__FILE__
)
require
'webmock'
module
Bacon
class
Context
alias_method
:after_webmock
,
:after
def
after
(
&
block
)
after_webmock
do
block
.
call
WebMock
.
reset!
end
end
end
end
def
set_up_test_repo_for_update
set_up_test_repo
upstream
=
SpecHelper
.
temporary_directory
+
'upstream'
...
...
@@ -308,6 +296,10 @@ module Pod
describe
'Updating Sources'
do
extend
SpecHelper
::
TemporaryRepos
after
do
WebMock
.
reset!
end
it
'updates source backed by a git repository'
do
set_up_test_repo_for_update
WebMock
::
API
.
stub_request
(
:get
,
"https://api.github.com/repos/cocoapods/specs/commits/master"
)
...
...
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