@Test
public void testBuilderFromEnvironmentBad() throws Exception {

	Configuration conf = new Configuration();
	// adjust the test environment for the purposes of this test
	Map<String, String> map = new HashMap<>(System.getenv());
	map.remove(ENV_FLINK_BIN_DIR);
	map.remove(ENV_FLINK_LIB_DIR);
	map.remove(ENV_FLINK_CONF_DIR);
	CommonTestUtils.setEnv(map);
	try {
		FlinkDistributionOverlay.Builder builder = FlinkDistributionOverlay.newBuilder().fromEnvironment(conf);
		fail();
	}
	catch(IllegalStateException e) {
		// expected
	}
}