LynxConfig implements Serializable, Cloneable { public LynxConfig setFilterTraceLevel(TraceLevel filterTraceLevel) { if (filterTraceLevel == null) { throw new IllegalArgumentException("filterTraceLevel can't be null"); } this.filterTraceLevel = filterTraceLevel; return this; } LynxConfig(); LynxConfig setMaxNumberOfTracesToShow(int maxNumberOfTracesToShow); LynxConfig setFilter(String filter); LynxConfig setFilterTraceLevel(TraceLevel filterTraceLevel); LynxConfig setTextSizeInPx(float textSizeInPx); LynxConfig setSamplingRate(int samplingRate); int getMaxNumberOfTracesToShow(); String getFilter(); TraceLevel getFilterTraceLevel(); boolean hasFilter(); float getTextSizeInPx(); boolean hasTextSizeInPx(); int getSamplingRate(); @Override boolean equals(Object o); @Override int hashCode(); @Override Object clone(); @Override String toString();  }
@Test public void setFilterTraceLevelNullThrowsNPE() { exception.expect(IllegalArgumentException.class); exception.expectMessage("filterTraceLevel can't be null"); LynxConfig lynxConfig = new LynxConfig(); lynxConfig.setFilterTraceLevel(null); }