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
47655826
Commit
47655826
authored
Sep 19, 2012
by
Fabio Pelosin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[Specs] Fixed Travis errors related to Command::Repo.
parent
e192f727
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
10 deletions
+13
-10
repo_spec.rb
spec/functional/command/repo_spec.rb
+13
-10
No files found.
spec/functional/command/repo_spec.rb
View file @
47655826
...
...
@@ -78,35 +78,38 @@ describe "Pod::Command::Repo" do
tmp_repos_path
+
"repo1/CocoaPods-version.yml"
end
def
write_version_file
(
hash
)
yaml
=
YAML
.
dump
(
hash
)
File
.
open
(
versions_file
,
'w'
)
{
|
f
|
f
.
write
(
yaml
)
}
Dir
.
chdir
(
versions_file
.
dirname
)
do
`git commit . -m "updated version file"`
end
end
it
"it doesn't requires CocoaPods-version.yml"
do
lambda
{
run_command
(
'repo'
,
'update'
)
}.
should
.
not
.
raise
end
it
"runs with a compatible repo"
do
yaml
=
YAML
.
dump
({
'min'
=>
"0.0.1"
})
File
.
open
(
versions_file
,
'w'
)
{
|
f
|
f
.
write
(
yaml
)
}
write_version_file
({
'min'
=>
"0.0.1"
})
lambda
{
run_command
(
'repo'
,
'update'
)
}.
should
.
not
.
raise
end
it
"raises if a repo is not compatible"
do
yaml
=
YAML
.
dump
({
'min'
=>
"999.0.0"
})
File
.
open
(
versions_file
,
'w'
)
{
|
f
|
f
.
write
(
yaml
)
}
write_version_file
({
'min'
=>
"999.0.0"
})
lambda
{
run_command
(
'repo'
,
'update'
)
}.
should
.
raise
Pod
::
Informative
end
it
"informs about a higher known CocoaPods version"
do
yaml
=
YAML
.
dump
({
'last'
=>
"999.0.0"
})
File
.
open
(
versions_file
,
'w'
)
{
|
f
|
f
.
write
(
yaml
)
}
write_version_file
({
'last'
=>
"999.0.0"
})
run_command
(
'repo'
,
'update'
).
should
.
include
"Cocoapods 999.0.0 is available"
end
it
"has a class method that returns if a repo is supported"
do
yaml
=
YAML
.
dump
({
'min'
=>
"999.0.0"
})
File
.
open
(
versions_file
,
'w'
)
{
|
f
|
f
.
write
(
yaml
)
}
write_version_file
({
'min'
=>
"999.0.0"
})
Pod
::
Command
::
Repo
.
compatible?
(
'repo1'
).
should
==
false
yaml
=
YAML
.
dump
({
'min'
=>
"0.0.1"
})
File
.
open
(
versions_file
,
'w'
)
{
|
f
|
f
.
write
(
yaml
)
}
write_version_file
({
'min'
=>
"0.0.1"
})
Pod
::
Command
::
Repo
.
compatible?
(
'repo1'
).
should
==
true
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