also looking at this
fix(android): jsQuote takes Any?, because three call sites are not strings
#164
2 files
+18
-5
| @@ -143,6 +143,14 @@ test "the templates that answer the page are actually in the scanned set" { | ||
| 143 | 143 | |
| 144 | 144 | // And the fix is present rather than the sites merely being deleted. |
| 145 | 145 | const bridge = sourceOf("CraftBridge.kt.template").?; |
| 146 | try testing.expect(std.mem.indexOf(u8, bridge, "private fun jsQuote(") != null); | |
| 147 | 146 | try testing.expect(std.mem.count(u8, bridge, "jsQuote(") >= 50); |
| 147 | ||
| 148 | // `Any?`, not `String?`. The call sites replaced string interpolation, | |
| 149 | // which accepts anything — `contactId` is a Long, `downloadId` is a Long, | |
| 150 | // `errString` is a CharSequence — and narrowing the parameter back makes | |
| 151 | // those three sites stop compiling. Nothing in CI compiles Kotlin, so this | |
| 152 | // is the only thing that would say so. See #163. | |
| 153 | try testing.expect( | |
| 154 | std.mem.indexOf(u8, bridge, "private fun jsQuote(value: Any?): String") != null, | |
| 155 | ); | |
| 148 | 156 | } |