public void testUseTube() {
		Client client = new ClientImpl(TEST_HOST, TEST_PORT);
		client.useTube("foobar");

		// hashes are not valid in tube names
		try {
			client.useTube("foobar#");
			fail("no BAD_FORMAT thrown");
		} catch (BeanstalkException be) {
			assertEquals("BAD_FORMAT", be.getMessage());
		} catch (Exception e) {
			fail(e.getMessage());
		}

		// underscores are valid in tube names >= beanstalk 1.4.4.
		if (serverSupportsUnderscoreInTubeName(client)) {
			try {
				client.useTube("foobar_");
			} catch (Exception e) {
				fail(e.getMessage());
			}
		}

		// per pashields http://github.com/pashields/JavaBeanstalkClient.git
		// Names cannot start with hyphen
		try {
			client.useTube("-foobar");
			fail("no BAD_FORMAT thrown");
		} catch (BeanstalkException be) {
			assertEquals("BAD_FORMAT", be.getMessage());
		} catch (Exception e) {
			fail(e.getMessage());
		}
	}