Many thanks Jordan! That worked pretty well. Although I was kind of looking for 
a more generic way, as in not having to depend on a new library.
I guess I'm good for now. I wish I knew about Curator earlier before I had 
coded most of my other services...

Dear John, as far as Twitter ones, I tried building the twitter commons library 
and the pants script has been running for literally hours with 100% CPU... I 
also tried depending on their Maven repo but was not able to figure out how 
(I'm new to Maven I must say)
I'd very much appreciate it if you could share a part of your pom.xml where you 
have included Twitter commons.

Thanks a lot for your kind help!
Amir


On Feb 21, 2012, at 3:56 PM, John Sirois wrote:

> On Tue, Feb 21, 2012 at 4:33 PM, Jordan Zimmerman 
> <[email protected]>wrote:
> 
>> Curator provides an in-memory ZooKeeper Server and ZooKeeper Cluster:
>> 
>> <dependency>
>>   <groupId>com.netflix.curator</groupId>
>>   <artifactId>curator-test</artifactId>
>>   <version>1.1.2</version>
>> </dependency>
>> 
>> https://github.com/Netflix/curator/tree/master/curator-test/src/main/java/c
>> om/netflix/curator/test
>> 
>> 
>> 
>> On 2/21/12 3:31 PM, "Amirhossein Kiani" <[email protected]> wrote:
>> 
>>> Hi ZooKeeper users,
>>> 
>>> I was wondering if there is a correct way of writing unit tests for a
>>> ZooKeeper application. I have looked at Twitter's tests but have been
>>> unable to get them to work... I was wondering if there is a more generic
>>> way of creating the in-process ZooKeeper server for testing.
>> 
> 
> Jordan's stuff looks good - so if it works for you I'd switch.  But I would
> be interested in a bug report - what issues are you seeing? (we
> use com.twitter.common#zookeeper-testing widely internally).
> 
> 
>>> 
>>> Many thanks,
>>> Amir
>> 
>> 

Reply via email to