// }
@Test
public void testkeyValueHeader() throws TException {
TMemoryBuffer buf = new TMemoryBuffer(200);
THeaderTransport trans = new THeaderTransport(buf);
TBinaryProtocol prot = new TBinaryProtocol(trans);
Xtruct out = new Xtruct();
trans.setHeader("test1", "value1");
trans.setHeader("test2", "value2");
out.write(prot);
trans.flush();
Xtruct in = new Xtruct();
in.read(prot);
HashMap<String, String> headers = trans.getHeaders();
assertEquals(2, headers.size());
assertTrue(headers.containsKey("test1"));
assertTrue(headers.containsKey("test2"));
assertEquals("value1", headers.get("test1"));
assertEquals("value2", headers.get("test2"));