Skip to content

Commit

Permalink
Resolved test codes comments
Browse files Browse the repository at this point in the history
  • Loading branch information
nimakarimipour committed Feb 8, 2022
1 parent 168b88a commit b144824
Showing 1 changed file with 9 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -158,27 +158,27 @@ public void add_nullable_param_simple() {
"-XepOpt:NullAway:SerializeFixMetadata=true",
"-XepOpt:NullAway:FixSerializationConfigPath=" + configPath))
.addSourceLines(
"com/uber/android/Super.java",
"com/uber/android/Test.java",
"package com.uber;",
"import javax.annotation.Nullable;",
"import javax.annotation.Nonnull;",
"public class Super {",
" Object test(int i, Object h) {",
"public class Test {",
" Object run(int i, Object h) {",
" return h;",
" }",
" Object test_param(@Nullable String o) {",
" // BUG: Diagnostic contains: passing @Nullable",
" return test(0, o);",
" // BUG: Diagnostic contains: passing @Nullable",
" return run(0, o);",
" }",
"}")
.setExpectedFixes(
new FixDisplay(
"javax.annotation.Nullable",
"test(int,java.lang.Object)",
"run(int,java.lang.Object)",
"h",
"PARAMETER",
"com.uber.Super",
"com/uber/android/Super.java"))
"com.uber.Test",
"com/uber/android/Test.java"))
.doTest();
}

Expand Down Expand Up @@ -289,7 +289,7 @@ public void add_nullable_param_generics() {
"import java.util.ArrayList;",
"public class Child extends Super<String>{",
" public void newSideEffect(ArrayList<String> op) {",
" // BUG: Diagnostic contains: passing @Nullable",
" // BUG: Diagnostic contains: passing @Nullable",
" newStatement(null, op, true, true);",
" }",
"}")
Expand Down

0 comments on commit b144824

Please sign in to comment.