Age | Commit message (Collapse) | Author |
|
No more coercing to String and regex matching. Instead, we now coerce
to Integer at the beginning or raise an error if we cannot coerce to
Integer.
A consequence of this change is that the function will now accept
blatantly non-numeric strings as input, and return false. This seems a
bit goofy to me, but it's how String#to_i works. If we really don't
like this, then I'm open to suggestions.
|
|
Also ignore rspec fixtures directory
|
|
|
|
|
|
|
|
|
|
Puppet passes numbers as String to functions, but it makes more sense to
compare them as Numeric.
But sometimes Puppet passes them as the wrong type, see:
https://projects.puppetlabs.com/issues/19812
|
|
This closes GH-138.
|
|
When prefix and suffix did error checking with positional arguments,
they would not report the position of the argument that failed to
validate. This commit changes the messages to indicate which argument
failed.
|
|
|
|
|
|
Add floor function implementation and unit tests
|
|
|
|
This closes GH-59
|
|
This function provides a simple wrapper around
Puppet::Parser::Functions.function for access within Puppet manifests.
This will allow users to check whether or not a plugin or functionality
such as hiera is installed on the server.
|
|
|
|
|
|
|
|
|
|
|
|
The function only uses the first argument, so raise an error with
too few arguments *and* with too many arguments.
|
|
|
|
|
|
|
|
The function only uses the first argument, so raise an error with
too few arguments *and* with too many arguments.
|
|
Copied from the same one included in Puppet and Facter.
[ci skip]
|
|
Add missing documentation for validate_augeas and validate_cmd to README.markdown
|
|
README.markdown
|
|
* 4.x:
(maint) Add Ruby 2.0.0 to Travis build matrix
Conflicts:
.gitignore
.travis.yml
Gemfile
|
|
* 3.x:
(maint) Add Ruby 2.0.0 to Travis build matrix
|
|
* maint/3.x/ruby_two_travis:
(maint) Add Ruby 2.0.0 to Travis build matrix
|
|
Without this patch we're not testing against Ruby 2.0.0 which has recently been
released. This is a problem because we'd like a way to be notified if a change
set breaks compatibility with future supported versions of Ruby.
This patch should not be taken as an indication that we fully support Ruby 2.0,
just as an indication that we plan to in the future.
This patch also tightens up the specifications of the build matrix. In
addition to testing against the specific Puppet dependency versions, we're also
testing against the latest 2.7.x release and the latest release.
|
|
* 4.x:
changed .count to .size to support legacy ruby
closes #131
|
|
* 3.x:
changed .count to .size to support legacy ruby
|
|
* 2.x:
changed .count to .size to support legacy ruby
|
|
* mhellmic-2.x:
changed .count to .size to support legacy ruby
|
|
|
|
This reverts commit f7a18189ec338b01b0fc89d75def832753af3868, reversing
changes made to 36a7b29630a4d4de17af79b5dd4e9491ec20b123.
I'm reverting this change because of concerns raised by Peter Meier that
it duplicates the "in" operator in the DSL. The "in" operator is new
information that I did not posses when I made the decision to merge.
Because of this new information I'm un-merging and continuing the
discussion in the comments of
https://projects.puppetlabs.com/issues/19272
Reference: GH-130
|
|
(#19272) Add has_element() function
|
|
It is exceptionally difficult to determine if an array contains an element matching a specific value without an iteration or loop construct.
This function is the Puppet equivalent of Array.includes?(foo) in Ruby. The implementation is a verbatim copy of has_key() with the minor modifications needed to support arrays instead of hashes.
|
|
|
|
* fatmcgav-feature_19201:
(#19201) Add concat function to join two arrays
closes #129
|
|
Without this patch applied there is no easy way to append one array to
another. This is a problem because it is often desirable to join two
arrays without flattening the contents into a single, one dimensional
array.
This patch addresses the problem by adding a `concat()` function which
takes two arguments. The arguments will be concatenated together and a
new array returned to the caller.
Reviewed-by: Jeff McCune <jeff@puppetlabs.com>
|
|
|
|
|
|
* stephenrjohnson-bug/master/15572_rspec_tests:
ammend .should raise_error to .to raise_error
closes #97
|
|
|
|
* raphink-validate_augeas:
Add an URL to a doc on how to activate augeas in puppet
validate_augeas: requires augeas
validate_augeas: Ensure tmpfile is closed and unlinked
validate_augeas: Ensure augeas handler gets closed
Add validate_augeas function
closes 114
|
|
|
|
|