summaryrefslogtreecommitdiffstats
path: root/spec/unit
diff options
context:
space:
mode:
authorLuke Kanies <luke@madstop.com>2007-11-28 16:06:45 -0600
committerLuke Kanies <luke@madstop.com>2007-11-28 16:06:45 -0600
commit421b3fce66db7ff69052bd666d20e746952bc52b (patch)
treebb3ca879f704ac22c3868e79118f97a636d5d4a4 /spec/unit
parent11ae473e3852adcc382a3efea2329586d2e4bcb3 (diff)
downloadpuppet-421b3fce66db7ff69052bd666d20e746952bc52b.tar.gz
puppet-421b3fce66db7ff69052bd666d20e746952bc52b.tar.xz
puppet-421b3fce66db7ff69052bd666d20e746952bc52b.zip
Another backward compatibility patch, this time helping with a new server and old client
Diffstat (limited to 'spec/unit')
-rwxr-xr-xspec/unit/other/transobject.rb7
1 files changed, 6 insertions, 1 deletions
diff --git a/spec/unit/other/transobject.rb b/spec/unit/other/transobject.rb
index 830d4923d..07ffdf8bd 100755
--- a/spec/unit/other/transobject.rb
+++ b/spec/unit/other/transobject.rb
@@ -9,6 +9,11 @@ describe Puppet::TransObject do
resource = Puppet::TransObject.new("me", "foo::bar")
resource.ref.should == 'Foo::Bar[me]'
end
+
+ it "should lower-case resource types for backward compatibility with 0.23.2" do
+ resource = Puppet::TransObject.new("me", "Foo")
+ resource.type.should == 'foo'
+ end
end
describe Puppet::TransObject, " when serializing" do
@@ -63,7 +68,7 @@ describe Puppet::TransObject, " when converting to a RAL component instance" do
end
it "should use a new TransObject whose name is a resource reference of the type and title of the original TransObject" do
- Puppet::Type::Component.expects(:create).with { |resource| resource.type == :component and resource.name == "One::Two[/my/file]" }.returns(:yay)
+ Puppet::Type::Component.expects(:create).with { |resource| resource.type == "component" and resource.name == "One::Two[/my/file]" }.returns(:yay)
@resource.to_component.should == :yay
end