public static TestFrameWriter create(Collection<FrameWriterOperation> exceptionThrowingOperations, Collection<FrameWriterOperation> errorThrowingOperations, boolean deepCopyInputFrames) { CountAnswer openAnswer = createAnswer(FrameWriterOperation.Open, exceptionThrowingOperations, errorThrowingOperations); CountAnswer nextAnswer = createAnswer(FrameWriterOperation.NextFrame, exceptionThrowingOperations, errorThrowingOperations); CountAnswer flushAnswer = createAnswer(FrameWriterOperation.Flush, exceptionThrowingOperations, errorThrowingOperations); CountAnswer failAnswer = createAnswer(FrameWriterOperation.Fail, exceptionThrowingOperations, errorThrowingOperations); CountAnswer closeAnswer = createAnswer(FrameWriterOperation.Close, exceptionThrowingOperations, errorThrowingOperations); return new TestFrameWriter(openAnswer, nextAnswer, flushAnswer, failAnswer, closeAnswer, deepCopyInputFrames); }
public static TestTupleCounterFrameWriter create(RecordDescriptor recordDescriptor, Collection<FrameWriterOperation> exceptionThrowingOperations, Collection<FrameWriterOperation> errorThrowingOperations, boolean deepCopyInputFrames) { CountAnswer openAnswer = FrameWriterTestUtils.createAnswer(FrameWriterOperation.Open, exceptionThrowingOperations, errorThrowingOperations); CountAnswer nextAnswer = FrameWriterTestUtils.createAnswer(FrameWriterOperation.NextFrame, exceptionThrowingOperations, errorThrowingOperations); CountAnswer flushAnswer = FrameWriterTestUtils.createAnswer(FrameWriterOperation.Flush, exceptionThrowingOperations, errorThrowingOperations); CountAnswer failAnswer = FrameWriterTestUtils.createAnswer(FrameWriterOperation.Fail, exceptionThrowingOperations, errorThrowingOperations); CountAnswer closeAnswer = FrameWriterTestUtils.createAnswer(FrameWriterOperation.Close, exceptionThrowingOperations, errorThrowingOperations); return new TestTupleCounterFrameWriter(recordDescriptor, openAnswer, nextAnswer, flushAnswer, failAnswer, closeAnswer, deepCopyInputFrames); }
public static TestTupleCounterFrameWriter create(RecordDescriptor recordDescriptor, Collection<FrameWriterOperation> exceptionThrowingOperations, Collection<FrameWriterOperation> errorThrowingOperations, boolean deepCopyInputFrames) { CountAnswer openAnswer = FrameWriterTestUtils.createAnswer(FrameWriterOperation.Open, exceptionThrowingOperations, errorThrowingOperations); CountAnswer nextAnswer = FrameWriterTestUtils.createAnswer(FrameWriterOperation.NextFrame, exceptionThrowingOperations, errorThrowingOperations); CountAnswer flushAnswer = FrameWriterTestUtils.createAnswer(FrameWriterOperation.Flush, exceptionThrowingOperations, errorThrowingOperations); CountAnswer failAnswer = FrameWriterTestUtils.createAnswer(FrameWriterOperation.Fail, exceptionThrowingOperations, errorThrowingOperations); CountAnswer closeAnswer = FrameWriterTestUtils.createAnswer(FrameWriterOperation.Close, exceptionThrowingOperations, errorThrowingOperations); return new TestTupleCounterFrameWriter(recordDescriptor, openAnswer, nextAnswer, flushAnswer, failAnswer, closeAnswer, deepCopyInputFrames); } }