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
d4f63d95
Commit
d4f63d95
authored
Sep 27, 2015
by
Samuel Giddins
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[Validator] Update specs for the app import
parent
ea1a7635
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
9 additions
and
6 deletions
+9
-6
lib_spec.rb
spec/functional/command/lib_spec.rb
+1
-1
push_spec.rb
spec/functional/command/repo/push_spec.rb
+1
-0
validator_spec.rb
spec/unit/validator_spec.rb
+7
-5
No files found.
spec/functional/command/lib_spec.rb
View file @
d4f63d95
...
@@ -104,7 +104,7 @@ module Pod
...
@@ -104,7 +104,7 @@ module Pod
run_command
(
'lib'
,
'lint'
,
'Broken.podspec'
,
'--no-clean'
)
run_command
(
'lib'
,
'lint'
,
'Broken.podspec'
,
'--no-clean'
)
end
end
UI
.
output
.
should
.
include
'Missing required attribute'
UI
.
output
.
should
.
include
'Missing required attribute'
UI
.
output
.
should
.
include
'Pods
project
available at'
UI
.
output
.
should
.
include
'Pods
workspace
available at'
end
end
end
end
...
...
spec/functional/command/repo/push_spec.rb
View file @
d4f63d95
...
@@ -130,6 +130,7 @@ module Pod
...
@@ -130,6 +130,7 @@ module Pod
Installer
.
any_instance
.
stubs
(
:aggregate_targets
).
returns
([])
Installer
.
any_instance
.
stubs
(
:aggregate_targets
).
returns
([])
Installer
.
any_instance
.
stubs
(
:pod_targets
).
returns
([])
Installer
.
any_instance
.
stubs
(
:pod_targets
).
returns
([])
Validator
.
any_instance
.
stubs
(
:install_pod
)
Validator
.
any_instance
.
stubs
(
:install_pod
)
Validator
.
any_instance
.
stubs
(
:add_app_project_import
)
Validator
.
any_instance
.
stubs
(
:check_file_patterns
)
Validator
.
any_instance
.
stubs
(
:check_file_patterns
)
Validator
.
any_instance
.
stubs
(
:validated?
).
returns
(
true
)
Validator
.
any_instance
.
stubs
(
:validated?
).
returns
(
true
)
Validator
.
any_instance
.
stubs
(
:validate_url
)
Validator
.
any_instance
.
stubs
(
:validate_url
)
...
...
spec/unit/validator_spec.rb
View file @
d4f63d95
...
@@ -102,6 +102,7 @@ module Pod
...
@@ -102,6 +102,7 @@ module Pod
@validator
.
stubs
(
:download_pod
)
@validator
.
stubs
(
:download_pod
)
@validator
.
stubs
(
:check_file_patterns
)
@validator
.
stubs
(
:check_file_patterns
)
@validator
.
stubs
(
:install_pod
)
@validator
.
stubs
(
:install_pod
)
@validator
.
stubs
(
:add_app_project_import
)
@validator
.
stubs
(
:build_pod
)
@validator
.
stubs
(
:build_pod
)
@validator
.
stubs
(
:tear_down_validation_environment
)
@validator
.
stubs
(
:tear_down_validation_environment
)
WebMock
::
API
.
stub_request
(
:head
,
/not-found/
).
to_return
(
:status
=>
404
)
WebMock
::
API
.
stub_request
(
:head
,
/not-found/
).
to_return
(
:status
=>
404
)
...
@@ -128,7 +129,7 @@ module Pod
...
@@ -128,7 +129,7 @@ module Pod
WebMock
::
API
.
stub_request
(
:head
,
/found/
).
to_return
(
:status
=>
200
)
WebMock
::
API
.
stub_request
(
:head
,
/found/
).
to_return
(
:status
=>
200
)
Specification
.
any_instance
.
stubs
(
:homepage
).
returns
(
'http://banana-corp.local/redirect/'
)
Specification
.
any_instance
.
stubs
(
:homepage
).
returns
(
'http://banana-corp.local/redirect/'
)
@validator
.
validate
@validator
.
validate
@validator
.
results
.
length
.
should
.
equal
0
@validator
.
results
.
should
.
be
.
empty
end
end
it
'does not fail if the homepage does not support HEAD'
do
it
'does not fail if the homepage does not support HEAD'
do
...
@@ -136,7 +137,7 @@ module Pod
...
@@ -136,7 +137,7 @@ module Pod
WebMock
::
API
.
stub_request
(
:get
,
/page/
).
to_return
(
:status
=>
200
)
WebMock
::
API
.
stub_request
(
:get
,
/page/
).
to_return
(
:status
=>
200
)
Specification
.
any_instance
.
stubs
(
:homepage
).
returns
(
'http://banana-corp.local/page/'
)
Specification
.
any_instance
.
stubs
(
:homepage
).
returns
(
'http://banana-corp.local/page/'
)
@validator
.
validate
@validator
.
validate
@validator
.
results
.
length
.
should
.
equal
0
@validator
.
results
.
should
.
be
.
empty
end
end
it
'does not fail if the homepage errors on HEAD'
do
it
'does not fail if the homepage errors on HEAD'
do
...
@@ -144,7 +145,7 @@ module Pod
...
@@ -144,7 +145,7 @@ module Pod
WebMock
::
API
.
stub_request
(
:get
,
/page/
).
to_return
(
:status
=>
200
)
WebMock
::
API
.
stub_request
(
:get
,
/page/
).
to_return
(
:status
=>
200
)
Specification
.
any_instance
.
stubs
(
:homepage
).
returns
(
'http://banana-corp.local/page/'
)
Specification
.
any_instance
.
stubs
(
:homepage
).
returns
(
'http://banana-corp.local/page/'
)
@validator
.
validate
@validator
.
validate
@validator
.
results
.
length
.
should
.
equal
0
@validator
.
results
.
should
.
be
.
empty
end
end
it
'does not follow redirects infinitely'
do
it
'does not follow redirects infinitely'
do
...
@@ -166,7 +167,7 @@ module Pod
...
@@ -166,7 +167,7 @@ module Pod
Specification
.
any_instance
.
stubs
(
:homepage
).
returns
(
Specification
.
any_instance
.
stubs
(
:homepage
).
returns
(
'http://banana-corp.local/redirect'
)
'http://banana-corp.local/redirect'
)
@validator
.
validate
@validator
.
validate
@validator
.
results
.
length
.
should
.
equal
0
@validator
.
results
.
should
.
be
.
empty
end
end
end
end
...
@@ -300,8 +301,8 @@ module Pod
...
@@ -300,8 +301,8 @@ module Pod
validator
.
stubs
(
:validate_url
)
validator
.
stubs
(
:validate_url
)
validator
.
stubs
(
:validate_screenshots
)
validator
.
stubs
(
:validate_screenshots
)
validator
.
stubs
(
:check_file_patterns
)
validator
.
stubs
(
:check_file_patterns
)
validator
.
stubs
(
:check_file_patterns
)
validator
.
stubs
(
:install_pod
)
validator
.
stubs
(
:install_pod
)
validator
.
stubs
(
:add_app_project_import
)
%i(prepare resolve_dependencies download_dependencies)
.
each
do
|
m
|
%i(prepare resolve_dependencies download_dependencies)
.
each
do
|
m
|
Installer
.
any_instance
.
stubs
(
m
)
Installer
.
any_instance
.
stubs
(
m
)
end
end
...
@@ -538,6 +539,7 @@ module Pod
...
@@ -538,6 +539,7 @@ module Pod
@validator
.
stubs
(
:validate_screenshots
)
@validator
.
stubs
(
:validate_screenshots
)
@validator
.
stubs
(
:check_file_patterns
)
@validator
.
stubs
(
:check_file_patterns
)
@validator
.
stubs
(
:install_pod
)
@validator
.
stubs
(
:install_pod
)
@validator
.
stubs
(
:add_app_project_import
)
%i(prepare resolve_dependencies download_dependencies)
.
each
do
|
m
|
%i(prepare resolve_dependencies download_dependencies)
.
each
do
|
m
|
Installer
.
any_instance
.
stubs
(
m
)
Installer
.
any_instance
.
stubs
(
m
)
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