### Question:
PropertiesBasedTraceeFilterConfiguration implements TraceeFilterConfiguration { @Override public boolean shouldGenerateSessionId() { return generatedSessionIdLength() > 0; } PropertiesBasedTraceeFilterConfiguration(PropertyChain propertyChain);  PropertiesBasedTraceeFilterConfiguration(PropertyChain propertyChain,
													String profileName); static PropertyChain loadPropertyChain(); @Override boolean shouldProcessParam(String paramName, Channel channel); @Override boolean shouldProcessContext(final Channel channel); @Override boolean shouldGenerateInvocationId(); @Override int generatedInvocationIdLength(); @Override boolean shouldGenerateSessionId(); @Override int generatedSessionIdLength(); @Override Map<String, String> filterDeniedParams(final Map<String, String> unfiltered, final Channel channel);  }### Answer:
@Test public void doNotSessionInvocationIdIfLengthIsZero() { when(propertyChain.getProperty(TRACEE_DEFAULT_PROFILE_PREFIX + GENERATE_SESSION_ID)).thenReturn("0"); assertThat(unit.shouldGenerateSessionId(), is(false)); }
@Test public void doNotGenerateSessionIdIfLengthIsNegative() { when(propertyChain.getProperty(TRACEE_DEFAULT_PROFILE_PREFIX + GENERATE_SESSION_ID)).thenReturn("-1"); assertThat(unit.shouldGenerateSessionId(), is(false)); }
@Test public void generateSessionIdIfLengthIsPositive() { when(propertyChain.getProperty(TRACEE_DEFAULT_PROFILE_PREFIX + GENERATE_SESSION_ID)).thenReturn("1"); assertThat(unit.shouldGenerateSessionId(), is(true)); }