### Question:
PrintVertex extends VertexImpl<T, GenericVertex<T>> implements GenericVertex<T>, NonProbabilistic<T> { public static void setPrintStream(PrintStream printStream) { PrintVertex.printStream = Preconditions.checkNotNull(printStream); } @ExportVertexToPythonBindings  PrintVertex(@LoadVertexParam(PARENT) Vertex<T, ?> parent,
                       @LoadVertexParam(MESSAGE) final String message,
                       @LoadVertexParam(PRINT_DATA) boolean printData);  PrintVertex(Vertex<T, ?> parent); static void setPrintStream(PrintStream printStream); @Override T calculate(); static T print(T parentValue, String message, boolean printData); @SaveVertexParam(PARENT) Vertex<T, ?> getParent(); @SaveVertexParam(MESSAGE) String getMessage(); @SaveVertexParam(PRINT_DATA) boolean getPrintData();  }### Answer:
@Test public void whenPrintStreamIsNullThenFails() { thrown.expect(NullPointerException.class); PrintVertex.setPrintStream(null); }