flink-instrumentation/workspace/flink-1.4.1-instrumented/flink-1.4.1/flink-runtime/src/test/java/org/apache/flink/runtime/checkpoint/PendingCheckpointTest.java
/**
	 * FLINK-5985
	 * <p>
	 * Ensures that subtasks that acknowledge their state as 'null' are considered stateless. This means that they
	 * should not appear in the task states map of the checkpoint.
	 */
FLINK-5985

Ensures that subtasks that acknowledge their state as 'null' are considered stateless. This means that they
should not appear in the task states map of the checkpoint.
FLINK - 5985 Ensures that subtasks that acknowledge their state as ' null ' are considered stateless . This means that they should not appear in the task states map of the checkpoint .
@Test
	public void testNullSubtaskStateLeadsToStatelessTask() throws Exception {
		PendingCheckpoint pending = createPendingCheckpoint(CheckpointProperties.forStandardCheckpoint(), null);
		pending.acknowledgeTask(ATTEMPT_ID, null, mock(CheckpointMetrics.class));
		Assert.assertTrue(pending.getOperatorStates().isEmpty());
	}
@ Test public void testNullSubtaskStateLeadsToStatelessTask ( ) throws Exception { PendingCheckpoint pending = createPendingCheckpoint ( CheckpointProperties . forStandardCheckpoint ( ) , null ) ; pending . acknowledgeTask ( ATTEMPT_ID , null , mock ( CheckpointMetrics . class ) ) ; Assert . assertTrue ( pending . getOperatorStates ( ) . isEmpty ( ) ) ; }
FLINK-5985
 <p>
 Ensures that subtasks that acknowledge their state as 'null' are considered stateless.
FLINK - 5985 <p > Ensures that subtasks that acknowledge their state as ' null ' are considered stateless .