We are not allowing line generation for empty lines, but it can be asked for comment lines (or brackets) if it is surrounded by class/function. The result will be almost identical to the whole class test generation, but it's weird.
In the following case, we cannot generate line-based test for (*) but we can do it for (**) (likely, because this comment is considered as part of a method):
// my comment here! - not allowed for line generation (*)
// my comment here! - allowed for line generation (**)
fun multwice(a: Int) = a * 2
Solution idea: For each line generation, check if it includes something besides comments, open/closed brackets and allow generation only in such case
We are not allowing line generation for empty lines, but it can be asked for comment lines (or brackets) if it is surrounded by class/function. The result will be almost identical to the whole class test generation, but it's weird.
In the following case, we cannot generate line-based test for
(*)but we can do it for(**)(likely, because this comment is considered as part of a method):Solution idea: For each line generation, check if it includes something besides comments, open/closed brackets and allow generation only in such case