Closed AntonisGkortzis closed 6 years ago
Hi Antonis!
Would you like to elaborate with a more specific example of this bug? I mean something like: "I expected to identify this $conditional$ as a smell but I could not" or vice versa?
Edit: Or the problem is that as soon as it finds the first bugged conditional it returns with a smell when it should store somehow all the conditionals with this smell in a method?
Hey man!
It's the 2nd case.
The detection works fine but it stops right after detecting the first complex if statement. As you said, it should somehow store how many instances of this smell it identified in the method and it should create a number of smells accordingly.
So let me get this straight, it should store an integer that depicts how many times this smell was raised or something more detailed?
I think that for now we are ok just with an integer. And when this integer is returned to the detectComplexConditional
then there we should generate the number of smells that correspond to this integer.
I could have it done by afternoon or are you working on it?
No, I'm working on the Long Statement. I will commit and push in a while.
https://github.com/tushartushar/DesigniteJava/blob/72a8fd7c6cbd1b3d73934f9137240d1b92bf5809/src/Designite/smells/implementationSmells/ImplementationSmellDetector.java#L74
The current implementation stops the smell identification after identifying the 1st smell in a method. https://github.com/tushartushar/DesigniteJava/blob/72a8fd7c6cbd1b3d73934f9137240d1b92bf5809/src/Designite/smells/implementationSmells/ImplementationSmellDetector.java#L93