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
aaac7dda
Commit
aaac7dda
authored
Dec 18, 2012
by
Fabio Pelosin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[BridgeSupport] Run specs only if the executable is available.
parent
21e60f91
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
14 additions
and
9 deletions
+14
-9
integration_spec.rb
spec/integration_spec.rb
+1
-1
bridge_support_spec.rb
spec/unit/generator/bridge_support_spec.rb
+13
-8
No files found.
spec/integration_spec.rb
View file @
aaac7dda
...
...
@@ -168,7 +168,7 @@ module Pod
#--------------------------------------#
if
`which appledoc`
.
strip
.
empty?
puts
" ! "
.
red
<<
"Skipping
documentation generation specs, because appledoc
can't be found."
puts
" ! "
.
red
<<
"Skipping
because the `appledoc` executable
can't be found."
else
it
"generates documentation of all pods by default"
do
...
...
spec/unit/generator/bridge_support_spec.rb
View file @
aaac7dda
require
File
.
expand_path
(
'../../../spec_helper'
,
__FILE__
)
describe
"Pod::Generator::BridgeSupport"
do
it
"generates a metadata file with the appropriate search paths"
do
headers
=
%w{ /some/dir/foo.h /some/dir/bar.h /some/other/dir/baz.h }
.
map
{
|
h
|
Pathname
.
new
(
h
)
}
generator
=
Pod
::
Generator
::
BridgeSupport
.
new
(
headers
)
def
generator
.
gen_bridge_metadata
(
command
)
@command
=
command
if
`which gen_bridge_metadata`
.
strip
.
empty?
puts
" ! "
.
red
<<
"Skipping because the `gen_bridge_metadata` executable can't be found."
else
it
"generates a metadata file with the appropriate search paths"
do
headers
=
%w{ /some/dir/foo.h /some/dir/bar.h /some/other/dir/baz.h }
.
map
{
|
h
|
Pathname
.
new
(
h
)
}
generator
=
Pod
::
Generator
::
BridgeSupport
.
new
(
headers
)
def
generator
.
gen_bridge_metadata
(
command
)
@command
=
command
end
generator
.
save_as
(
Pathname
.
new
(
"/path/to/Pods.bridgesupport"
))
generator
.
instance_variable_get
(
:@command
).
should
==
%{-c "-I '/some/dir' -I '/some/other/dir'" -o '/path/to/Pods.bridgesupport' '#{headers.join("' '")}'}
end
generator
.
save_as
(
Pathname
.
new
(
"/path/to/Pods.bridgesupport"
))
generator
.
instance_variable_get
(
:@command
).
should
==
%{-c "-I '/some/dir' -I '/some/other/dir'" -o '/path/to/Pods.bridgesupport' '#{headers.join("' '")}'}
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