Implementation of methods for obtaining consumer, added tests for creati...

...ng producer and consumer