Repository navigation
Commit f920ae1
authored
Only replace
`AssertNotEqualsBooleanToAssertBoolean` rewrote `assertNotEquals(false, x)` to `assertTrue(x)` for any `x`. With a `Map<String, Object>`, `assertNotEquals(false, map.get("k"))` became `assertTrue(map.get("k"))`, which does not compile, and with a `Boolean` holding `null` a passing assertion became an unboxing `NullPointerException`. Require a primitive `boolean`, as `AssertEqualsBooleanToAssertBoolean` already does.assertNotEquals(false, <boolean>) when the second argument is a primitive boolean (#1220)1 parent 300bfba commit f920ae1
2 files changed
Lines changed: 39 additions & 1 deletion
File tree
- src
- main/java/org/openrewrite/java/testing/cleanup
- test/java/org/openrewrite/java/testing/cleanup
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
44 | 44 | | |
45 | 45 | | |
46 | 46 | | |
47 | | - | |
| 47 | + | |
48 | 48 | | |
49 | 49 | | |
50 | 50 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
105 | 105 | | |
106 | 106 | | |
107 | 107 | | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
108 | 146 | | |
0 commit comments