public function testCancelOperation_BeforeValidate()
{
$testCase = $this;
$this->collection->createDocument()->onBeforeValidate(function (\Sokil\Mongo\Event $event, $eventName, $dispatcher) {
$event->cancel();
})->onAfterValidate(function (\Sokil\Mongo\Event $event, $eventName, $dispatcher) use($testCase) {
$testCase->fail('Validation must be cancelled');
})->validate();
}