### Question:
DefaultBoltProtocolFactory implements BoltProtocolFactory { @Override public BoltProtocol create( long protocolVersion, BoltChannel channel ) { if ( protocolVersion == BoltProtocolV1.VERSION ) { return new BoltProtocolV1( channel, connectionFactory, stateMachineFactory, logService ); } else if ( protocolVersion == BoltProtocolV2.VERSION ) { return new BoltProtocolV2( channel, connectionFactory, stateMachineFactory, logService ); } else if ( protocolVersion == BoltProtocolV3.VERSION ) { return new BoltProtocolV3( channel, connectionFactory, stateMachineFactory, logService ); } else { return null; } } DefaultBoltProtocolFactory( BoltConnectionFactory connectionFactory, BoltStateMachineFactory stateMachineFactory,
            LogService logService ); @Override BoltProtocol create( long protocolVersion, BoltChannel channel );  }### Answer:
@Test void shouldCreateNothingForUnknownProtocolVersion() { int protocolVersion = 42; BoltChannel channel = BoltTestUtil.newTestBoltChannel(); BoltProtocolFactory factory = new DefaultBoltProtocolFactory( mock( BoltConnectionFactory.class ), mock( BoltStateMachineFactory.class ), NullLogService.getInstance() ); BoltProtocol protocol = factory.create( protocolVersion, channel ); assertNull( protocol ); }