| 273 | }; |
| 274 | |
| 275 | TEST_F(DiffTest, Trivial) { |
| 276 | base_ = ArrayFromJSON(int32(), "[]"); |
| 277 | target_ = ArrayFromJSON(int32(), "[]"); |
| 278 | DoDiff(); |
| 279 | AssertInsertIs("[false]"); |
| 280 | AssertRunLengthIs("[0]"); |
| 281 | |
| 282 | base_ = ArrayFromJSON(null(), "[null, null]"); |
| 283 | target_ = ArrayFromJSON(null(), "[null, null, null, null]"); |
| 284 | DoDiff(); |
| 285 | AssertInsertIs("[false, true, true]"); |
| 286 | AssertRunLengthIs("[2, 0, 0]"); |
| 287 | |
| 288 | base_ = ArrayFromJSON(int32(), "[1, 2, 3]"); |
| 289 | target_ = ArrayFromJSON(int32(), "[1, 2, 3]"); |
| 290 | DoDiff(); |
| 291 | AssertInsertIs("[false]"); |
| 292 | AssertRunLengthIs("[3]"); |
| 293 | } |
| 294 | |
| 295 | TEST_F(DiffTest, Errors) { |
| 296 | std::stringstream formatted; |
nothing calls this directly
no test coverage detected