From e475cdb4b1280bbc89f626a59033c1a4603cebe9 Mon Sep 17 00:00:00 2001 From: "Jonathan D. Simms" Date: Sat, 28 Apr 2012 04:08:28 +0000 Subject: [PATCH] forgot a test, fix documentation --- lib/zk.rb | 3 ++- spec/zk/module_spec.rb | 6 ++++++ 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/lib/zk.rb b/lib/zk.rb index 3bd71d3..c05dedc 100644 --- a/lib/zk.rb +++ b/lib/zk.rb @@ -115,7 +115,8 @@ def self.logger=(logger) # contains a chroot path, we raise an `ArgumentError` # # * if you don't like this for some reason, you can always use - # {ZK::Client::Threaded.new} directly. You probably also hate unicorns. + # {ZK::Client::Threaded.initialize Threaded.new} directly. You probably + # also hate happiness and laughter. # # @raise [ChrootPathDoesNotExistError] if a chroot path is specified, # `:chroot` is `:check`, and the path does not exist. diff --git a/spec/zk/module_spec.rb b/spec/zk/module_spec.rb index d75d144..1f63f08 100644 --- a/spec/zk/module_spec.rb +++ b/spec/zk/module_spec.rb @@ -12,6 +12,12 @@ end end + describe %[with a chrooted connection string and a :chroot => '/path'] do + it %[should raise an ArgumentError] do + lambda { @zk = ZK.new('localhost:2181/zktest', :chroot => '/zktest') }.should raise_error(ArgumentError) + end + end + describe 'with no arguments' do before { @zk = ZK.new }