Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

(PDOC-27) Don't require options for 3x functions #26

Conversation

HAIL9000
Copy link
Contributor

Prior to this commit, the 3x function handler assumed that at
least two arguments (the name and one or more additional arguments)
were passed into newfunction when creating a 3x function. However
that is not actually required, the only argument needed is the name.

Update the 3x function handler so that it will not throw and exception
if only one argument is given.

Prior to this commit, the 3x function handler assumed that at
least two arguments (the name and one or more additional arguments)
were passed into newfunction when creating a 3x function. However
that is not actually required, the only argument needed is the name.

Update the 3x function handler so that it will not throw and exception
if only one argument is given.
Prior to this commit, the Gemfile for strings did not specify which
version of rspec to use. When it started using rspec 3, the tests
that relied upon the rspec-html-matchers gem began to fail, likely
because that gem is not yet compatible with the new version of rspec.

Update the Gemfile so that we explicitly use an older version of
rspec to prevent tests from failing. We will have to either wait
for rspec-html-matchers to catch up or find a new way of testing
the HTML output before we can update to rspec 3.
@HAIL9000
Copy link
Contributor Author

I fixed the rspec version issue, but now it looks like I now have legitimate failures for Ruby 2x. ಠ_ಠ Looking into these now

Prior to this commit, the fix for the 3x function issue was trying
to create an empty hash by calling Hash[ [[]] ] which in Ruby 1.9.3
produced and empty hash. However this is not the case in Ruby 2.0 and
up. Therefor, fix up the code so that it does not rely on Hash[ [[]] ]
creating and empty hash.
hlindberg added a commit that referenced this pull request Feb 18, 2015
…_should_accept_one_or_more_arguments

(PDOC-27) Don't require options for 3x functions
@hlindberg hlindberg merged commit 6f7a983 into puppetlabs:master Feb 18, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants