code: func GetSyncProducerMock(t mocks.ErrorReporter) (*SyncProducer, *mocks.SyncProducer) {
  	saramaCfg := sarama.NewConfig()
  	saramaCfg.Producer.Return.Successes = true
  	mock := mocks.NewSyncProducer(t, saramaCfg)
  
  	cfg := NewConfig(logrus.DefaultLogger())
  	ap := SyncProducer{Logger: logrus.DefaultLogger(), Config: cfg, Producer: mock, closeChannel: make(chan struct{}), Client: &saramaClientMock{}}
  
  	return &ap, mock
  }
docs: // GetSyncProducerMock returns mocked implementation of sync producer that doesn't need
  // connection to Kafka broker and can be used for testing purposes.