use of org.neo4j.unsafe.impl.batchimport.store.BatchingTokenRepository.BatchingPropertyKeyTokenRepository in project neo4j by neo4j.
the class PropertyEncoderStepTest method shouldGrowPropertyBlocksArrayProperly.
@SuppressWarnings("unchecked")
@Test
public void shouldGrowPropertyBlocksArrayProperly() throws Exception {
// GIVEN
StageControl control = mock(StageControl.class);
BatchingPropertyKeyTokenRepository tokens = new BatchingPropertyKeyTokenRepository(neoStores.getPropertyKeyTokenStore());
Step<Batch<InputNode, NodeRecord>> step = new PropertyEncoderStep<>(control, DEFAULT, tokens, neoStores.getPropertyStore());
@SuppressWarnings("rawtypes") Step downstream = mock(Step.class);
step.setDownstream(downstream);
// WHEN
step.start(0);
step.receive(0, smallbatch());
step.endOfUpstream();
awaitCompleted(step, control);
// THEN
verify(downstream).receive(anyLong(), any());
verifyNoMoreInteractions(control);
step.close();
}
Aggregations