* @throws InterruptedException
* @throws KeeperException
*/
@Test public void testNoTimeoutWaitForMeta()
throws IOException, InterruptedException, KeeperException {
final MetaTableLocator mtl = new MetaTableLocator();
ServerName hsa = mtl.getMetaRegionLocation(watcher);
assertNull(hsa);
// Now test waiting on meta location getting set.
Thread t = new WaitOnMetaThread();
startWaitAliveThenWaitItLives(t, 1);
// Set a meta location.
MetaTableLocator.setMetaLocation(this.watcher, SN, RegionState.State.OPEN);
hsa = SN;
// Join the thread... should exit shortly.
t.join();
// Now meta is available.
assertTrue(mtl.getMetaRegionLocation(watcher).equals(hsa));
}