-
Committer:
William Reade
-
Author(s):
William Reade
-
Date:
2012-05-31 07:37:00 UTC
-
mfrom:
(187.1.6 go)
-
Revision ID:
fwereade@gmail.com-20120531073700-6cpw3rhwtaxu8qdd
Allow dummy environs to use zookeeper state
As in python, we don't want to have to bring up and tear down a zookeeper
server for every test we run against a dummy environment, so this CL
provides a mechanism for sharing a single zookeeper across multiple tests
against "different" environments.
This is done with a SetZookeeper func in the dummy package, which allows
the environ's StateInfo method to return a *state.Info pointing at that
zookeeper. Assuming the "zookeeper" config setting is set, and "isBroken"
is not, Bootstrap will initialize state and Reset will clear it; when
"zookeeper" is set to false, it should act entirely as before.
R=rog, niemeyer
CC=
https://codereview.appspot.com/6244060