(PDOC-8) Fix present rubocop offenses

Since we want to run rubocop in travis when pull requests are
submitted, fix a few pre-existing rubocop offenses.
This commit is contained in:
Hailee Kenney 2014-10-08 11:36:21 -07:00
parent c7f3880d40
commit 999daa9c4c
3 changed files with 7 additions and 5 deletions

View File

@ -5,7 +5,9 @@ gem 'rgen'
gem 'redcarpet' gem 'redcarpet'
gem 'puppet-strings', '0.1.0', :path => '.' gem 'puppet-strings', '0.1.0', :path => '.'
if puppetversion = ENV['PUPPET_VERSION'] puppetversion = ENV['PUPPET_VERSION']
if puppetversion
gem 'puppet', puppetversion gem 'puppet', puppetversion
else else
gem 'puppet', '~> 3.6.2' gem 'puppet', '~> 3.6.2'

View File

@ -38,12 +38,14 @@ Puppet::Face.define(:strings, '0.0.1') do
yardoc_actions = Puppetx::PuppetLabs::Strings::Actions.new(Puppet[:debug], Puppet[:trace]) yardoc_actions = Puppetx::PuppetLabs::Strings::Actions.new(Puppet[:debug], Puppet[:trace])
# The last element of the argument array should be the options hash. # The last element of the argument array should be the options hash.
# We don't have any options yet, so for now just pop the hash off and
# toss it.
# #
# NOTE: The Puppet Face will throw 'unrecognized option' errors if any # NOTE: The Puppet Face will throw 'unrecognized option' errors if any
# YARD options are passed to it. The best way to approach this problem is # YARD options are passed to it. The best way to approach this problem is
# by using the `.yardopts` file. YARD will autoload any options placed in # by using the `.yardopts` file. YARD will autoload any options placed in
# that file. # that file.
opts = args.pop args.pop
# For now, assume the remaining positional args are a list of manifest # For now, assume the remaining positional args are a list of manifest
# and ruby files to parse. # and ruby files to parse.
@ -67,7 +69,7 @@ Puppet::Face.define(:strings, '0.0.1') do
server_actions = Puppetx::PuppetLabs::Strings::Actions.new(Puppet[:debug], Puppet[:trace]) server_actions = Puppetx::PuppetLabs::Strings::Actions.new(Puppet[:debug], Puppet[:trace])
opts = args.pop args.pop
module_names = args module_names = args

View File

@ -6,8 +6,6 @@ unless ENV['RS_PROVISION'] == 'no'
end end
RSpec.configure do |c| RSpec.configure do |c|
# Project root
proj_root = File.expand_path(File.join(File.dirname(__FILE__), '..'))
# Readable test descriptions # Readable test descriptions
c.formatter = :documentation c.formatter = :documentation