This brings down the test run from 108 sec to 15 sec.
There is an occasional port conflict because of the nature
the next port is chosen. So far it seems rare enough to live
with it.
This patch removes duplicate internal copies of constants in the structs
package which are also defined in the api package. The api.KVOp type
with all its values for the TXN endpoint and the api.HealthXXX constants
are now used throughout the codebase.
This resulted in some circular dependencies in the testutil package
which have been resolved by copying code and constants and moving the
WaitForLeader function into a separate testrpc package.