Java: Added inline test expectations for java/visible-for-testing-abuse

This commit is contained in:
Napalys Klicius
2025-08-06 11:23:02 +02:00
parent 0c14d93bc6
commit 652e9cba3d
3 changed files with 6 additions and 5 deletions

View File

@@ -4,9 +4,9 @@ import packageone.*;
public class Source {
void f() {
int i = Annotated.f(); // NON_COMPLIANT
String s = Annotated.m; // NON_COMPLIANT
AnnotatedClass a = new AnnotatedClass(); // NON_COMPLIANT
int i = Annotated.f(); // $ Alert
String s = Annotated.m; // $ Alert
AnnotatedClass a = new AnnotatedClass(); // $ Alert
String s1 = Annotated.m1; // COMPLIANT - same package
}
}