Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork960
Commitac20325
committed
Test version_info parsing
This modifies two existing test cases to include an assertion aboutthe length. These test cases are retained as there is value intesting on output from a real git command rather than only withtest doubles.More importantly, this also adds a parameterized test method tocheck parsing of:- All numeric, shorter than the limit - all fields used.- All numeric, at the limit - all fields used.- All numeric, longer than the limit - extra fields dropped.- Has unambiguous non-numeric - dropped from there on.- Has ambiguous non-numeric, negative int - dropped from there on.- Has ambiguous non-numeric, number+letter - dropped from there on.The cases for parsing when a field is not numeric (or not fully orunambiguously numeric) currently all fail, because the existinglogic drops intermediate non-numeric fields (#1833).Parsing should instead stop at (or, *perhaps* in cases like "2a",after) such fields. When the code is changed to stop at themrather than dropping them and presenting the subsequent field asthough it were a previous field, these test cases should also pass.1 parentdc6b90f commitac20325
1 file changed
+19
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
338 | 338 | | |
339 | 339 | | |
340 | 340 | | |
341 | | - | |
| 341 | + | |
342 | 342 | | |
343 | 343 | | |
| 344 | + | |
344 | 345 | | |
345 | 346 | | |
346 | 347 | | |
| |||
349 | 350 | | |
350 | 351 | | |
351 | 352 | | |
| 353 | + | |
352 | 354 | | |
353 | 355 | | |
354 | 356 | | |
| 357 | + | |
| 358 | + | |
| 359 | + | |
| 360 | + | |
| 361 | + | |
| 362 | + | |
| 363 | + | |
| 364 | + | |
| 365 | + | |
| 366 | + | |
| 367 | + | |
| 368 | + | |
| 369 | + | |
| 370 | + | |
| 371 | + | |
| 372 | + | |
355 | 373 | | |
356 | 374 | | |
357 | 375 | | |
| |||
0 commit comments
Comments
(0)