-
Notifications
You must be signed in to change notification settings - Fork 49
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cognitive complexity metric for Java #850
Cognitive complexity metric for Java #850
Conversation
e4845c0
to
ca0cf88
Compare
@dburriss any plans to finish this? |
Hi @marco-c |
49ce25c
to
1b3821c
Compare
Hello @dburriss, thank you for your hard work! I think that if you insert test methods inside a class, you would get the correct average value. Something like this: class X {
public static void print(boolean a, boolean b, boolean c, boolean d){ // +1
if (a && !(b && c)) { // +3 (+1 &&, +1 &&)
printf(\"test\");
}
}
} |
Hi @Luni-4 |
It worked! |
438bc74
to
9ef21cf
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you @dburriss! Just simple things from my side:
- we need to remove the
Cargo.lock
file since it is no longer necessary - we need to replace
Boolean
withboolean
inJava
functions
@Luni-4 thanks for the review. I have made the requested improvements. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you @dburriss! Just simple things again
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok, last change and we are ready to merge in!
@marco-c the task expired before a worker was made available for the checks. Should I push another commit to trigger or is there an issue (and trying again could make it worse). |
I retriggered it manually and it passed. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's fine for me! Thanks a lot @dburriss!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@dburriss Your last commit is fine as well for me! Thank you!
Last metric for #359
Tests and API have changed a fair bit since I started work on this so tracking some additional tasks: