summaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorJames Turnbull <james@lovedthanlost.net>2008-02-06 00:55:36 +1100
committerJames Turnbull <james@lovedthanlost.net>2008-02-06 00:55:36 +1100
commit28a8577f825e541098ada954cbe8d380811b1561 (patch)
treebb7d709c237cfbe828ddf69c0f0717ffd255a071 /test
parent16df87c419655106b1585b1e443a2050270518e5 (diff)
downloadpuppet-28a8577f825e541098ada954cbe8d380811b1561.tar.gz
puppet-28a8577f825e541098ada954cbe8d380811b1561.tar.xz
puppet-28a8577f825e541098ada954cbe8d380811b1561.zip
Added hostname test for hosts type
Diffstat (limited to 'test')
-rwxr-xr-xtest/ral/types/host.rb9
1 files changed, 8 insertions, 1 deletions
diff --git a/test/ral/types/host.rb b/test/ral/types/host.rb
index 16ed20bd4..a5d645bd1 100755
--- a/test/ral/types/host.rb
+++ b/test/ral/types/host.rb
@@ -147,8 +147,15 @@ class TestHost < Test::Unit::TestCase
}
end
+ def test_invalid_hostname
+ host = mkhost()
+
+ assert_raise(Puppet::Error) {
+ host[:name] = "!invalid.hostname.$$$"
+ }
end
-
+
+ end
def test_aliasisproperty
assert_equal(:property, @hosttype.attrtype(:alias))
end