diff options
author | Matt Robinson <matt@puppetlabs.com> | 2011-02-28 17:11:14 -0800 |
---|---|---|
committer | Matt Robinson <matt@puppetlabs.com> | 2011-02-28 17:11:14 -0800 |
commit | 395831ef58f1ea323919a0a87093919e3526da6c (patch) | |
tree | 135a3081e806a929420ae9e13b436ef49dd81fc3 /lib/puppet/util/monkey_patches.rb | |
parent | 43c79b744d0af0c5a1221addc74cc36eb68071a6 (diff) | |
parent | 422399b47764e29055974ff5bad5dfcb982a8b74 (diff) | |
download | puppet-395831ef58f1ea323919a0a87093919e3526da6c.tar.gz puppet-395831ef58f1ea323919a0a87093919e3526da6c.tar.xz puppet-395831ef58f1ea323919a0a87093919e3526da6c.zip |
Merge branch 'ticket/2.6.next/5466' into 2.6.next
* ticket/2.6.next/5466:
(#5466) Write specs for output of puppet resource
(#5466) Monkey patch Symbol so that you can sort them
(#5466) Fixed puppet resource bug with trailing ,
Diffstat (limited to 'lib/puppet/util/monkey_patches.rb')
-rw-r--r-- | lib/puppet/util/monkey_patches.rb | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/puppet/util/monkey_patches.rb b/lib/puppet/util/monkey_patches.rb index 85854a04c..16384855a 100644 --- a/lib/puppet/util/monkey_patches.rb +++ b/lib/puppet/util/monkey_patches.rb @@ -21,6 +21,9 @@ class Symbol z.emit("!ruby/sym ") to_s.to_zaml(z) end + def <=> (other) + self.to_s <=> other.to_s + end end [Object, Exception, Integer, Struct, Date, Time, Range, Regexp, Hash, Array, Float, String, FalseClass, TrueClass, Symbol, NilClass, Class].each { |cls| |