Commit da8b99e3 authored by Fabio Pelosin's avatar Fabio Pelosin

[#197] Fix specs

parent f16f6e1e
......@@ -134,7 +134,7 @@ else
change_log.should.not.include '1.3'
end
if Pod::Generator::Documentation.appledoc_installed?
if !`which appledoc`.strip.empty?
it "generates documentation of all pods by default" do
create_config!
......@@ -148,9 +148,9 @@ else
installer.install!
doc = (config.project_pods_root + 'Documentation/JSONKit/html/index.html').read
doc.should.include?('<title>JSONKit (1.4) Reference</title>')
doc.should.include?('<title>JSONKit 1.4 Reference</title>')
doc = (config.project_pods_root + 'Documentation/SSToolkit/html/index.html').read
doc.should.include?('<title>SSToolkit (0.1.2) Reference</title>')
doc.should.include?('<title>SSToolkit 0.1.2 Reference</title>')
end
else
puts "[!] Skipping documentation generation specs, because appledoc can't be found."
......
......@@ -20,14 +20,14 @@ describe Pod::Generator::Documentation do
it 'returns the Pod documentation documentation files' do
@doc_installer.files.sort.should == [
@pod.root + "Classes/Banana.m",
@pod.root + "Classes/Banana.h",
(@pod.root + "Classes/Banana.m").to_s,
(@pod.root + "Classes/Banana.h").to_s,
].sort
end
it 'returns the Pod documentation options' do
@doc_installer.generate_appledoc_options.should == [
'--project-name', 'BananaLib (1.0)',
@doc_installer.appledoc_options.should == [
'--project-name', 'BananaLib 1.0',
'--docset-desc', 'Full of chunky bananas.',
'--project-company', 'Banana Corp, Monkey Boy',
'--docset-copyright', 'Banana Corp, Monkey Boy',
......@@ -35,6 +35,7 @@ describe Pod::Generator::Documentation do
'--ignore', '.m',
'--keep-undocumented-objects',
'--keep-undocumented-members',
'--keep-intermediate-files',
'--index-desc', 'README',
# TODO We need to either make this a hash so that options can be merged
# or not use any defaults in case an options are specified.
......@@ -43,7 +44,7 @@ describe Pod::Generator::Documentation do
]
end
if Pod::Generator::Documentation.appledoc_installed?
if !`which appledoc`.strip.empty?
before do
@doc_installer.generate
end
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment