SymbolicValue { @Override public String toString() { return "SV_" + id; } SymbolicValue(); @Override int hashCode(); @Override boolean equals(Object o); static boolean isDisposable(SymbolicValue symbolicValue); boolean references(SymbolicValue other); @Override String toString(); void computedFrom(List<ProgramState.SymbolicValueSymbol> symbolicValues); List<Symbol> computedFromSymbols(); List<SymbolicValue> computedFrom(); List<ProgramState> setConstraint(ProgramState programState, ObjectConstraint nullConstraint); List<ProgramState> setConstraint(ProgramState programState, BooleanConstraint booleanConstraint); List<ProgramState> setConstraint(ProgramState programState, Constraint constraint); ProgramState setSingleConstraint(ProgramState programState, ObjectConstraint nullConstraint); SymbolicValue wrappedValue(); static final SymbolicValue NULL_LITERAL; static final SymbolicValue TRUE_LITERAL; static final SymbolicValue FALSE_LITERAL; static final List<SymbolicValue> PROTECTED_SYMBOLIC_VALUES; }
@Test void exceptional_SV_should_contain_exception_type_in_toString() { SymbolicValue.ExceptionalSymbolicValue unknownException = new SymbolicValue.ExceptionalSymbolicValue(null); assertThat(unknownException.toString()).contains("!unknownException!"); Type exceptionType = type("MyException", "org.foo.bar"); SymbolicValue.ExceptionalSymbolicValue knownException = new SymbolicValue.ExceptionalSymbolicValue(exceptionType); assertThat(knownException.toString()).contains("org.foo.bar.MyException!"); }