@Test(expected = VESException.class) public void EtcdConfigProvider_Should_Fail_On_Unreachable_Etcd() throws VESException { EtcdConfigProvider cfg = EtcdConfigProvider.create("http://_MISSING_:2379", "VESStorage", "VESDatabase"); assertFalse(true); }
@Test public void EtcdConfigProvider_Should_Read_Keys() throws VESException { EtcdConfigProvider cfg = EtcdConfigProvider.create(etcdAddress, "VESStorage", "VESDatabase"); assertEquals("storage", cfg.getStoragePath()); assertEquals("database", cfg.getDatabaseConnectionString()); }
@Test(expected = VESException.class) public void EtcdConfigProvider_Should_Fail_On_Missing_Database_Key() throws VESException { EtcdConfigProvider cfg = EtcdConfigProvider.create(etcdAddress, "VESStorage", "__NODB__"); assertFalse(true); }