Chanchal Singh commented on KAFKA-5676:

Thanks Wang . I tried doing that but found that in few test cases they are 
dependent on Metrics object modified by StreamsMetricsImpl object and the value 
of Metrics object is then tested. I am also confused how MockStreamMetrics is 
acting as mock class ff its not returning any mocking behaviour. 
Is there any difference in using StreamsMetricsImpl directly instead of 
MockStreamMetrics class ?

> MockStreamsMetrics should be in o.a.k.test
> ------------------------------------------
>                 Key: KAFKA-5676
>                 URL: https://issues.apache.org/jira/browse/KAFKA-5676
>             Project: Kafka
>          Issue Type: Bug
>          Components: streams
>            Reporter: Guozhang Wang
>            Assignee: Chanchal Singh
>              Labels: newbie
> {{MockStreamsMetrics}}'s package should be `o.a.k.test` not 
> `o.a.k.streams.processor.internals`. 
> In addition, it should not require a {{Metrics}} parameter in its constructor 
> as it is only needed for its extended base class; the right way of mocking 
> should be implementing {{StreamsMetrics}} with mock behavior than extended a 
> real implementaion of {{StreamsMetricsImpl}}.

This message was sent by Atlassian JIRA

Reply via email to