public class LogPrinterTest {
@Test
public void testPrintingWithFilter() throws IOException {
InternalLog logMock = EasyMock.createMock(InternalLog.class);
LogPrintoutFilter filterMock = EasyMock.createMock(LogPrintoutFilter.class);
OutputStream outputStreamMock = EasyMock.createMock(OutputStream.class);
logMock.print(EasyMock.anyObject(BufferedLogPrinter.class), EasyMock.eq(filterMock));
EasyMock.expectLastCall();
outputStreamMock.close();
EasyMock.expectLastCall();
EasyMock.replay(logMock, filterMock, outputStreamMock);