@Test public void testGetHeaderValue() { String virtualUserId1 = "1"; header.setVirtualUserId(virtualUserId1); String headerValue = getVirtualUserId(virtualUserId1); assertThat(header.getHeaderValue(), new StartsWith(headerValue)); String pageContext1 = "B2CScenario"; header.setPageContext(pageContext1); assertTrue(header.getHeaderValue().contains(getPageContextString(pageContext1))); assertTrue(header.getHeaderValue().contains(getVirtualUserId(virtualUserId1))); header.setTimerName(DynaTraceTagMetaData.SEARCH.getTimerName()); assertTrue( header .getHeaderValue() .contains(getTimerNameString(DynaTraceTagMetaData.SEARCH.toString()))); assertTrue(header.getHeaderValue().contains(getPageContextString(pageContext1))); assertTrue(header.getHeaderValue().contains(getVirtualUserId(virtualUserId1))); }
@Test public void testGetHeaderName() { String headerName = "X-dynaTrace"; assertEquals(headerName, header.getHeaderName()); }