Changeset 8a33777 for tests/io/.in


Ignore:
Timestamp:
Jan 24, 2024, 11:58:10 AM (6 months ago)
Author:
Michael Brooks <mlbrooks@…>
Branches:
master
Children:
3db78b89
Parents:
71b5aad5
Message:

Fix analysis error in string-input testing.

Add comments correlating .in file content with line of code that reads it.

This test's correctness expectation is bootstrapped from the actual behaviour of scanf.
A mistake in knowing "which character are we on at this point"
led to an inaccurate understanding of what scanf does on an edge case.
The test was showing that the CFA analogs behave the same as scanf.
But the test was not exercising the case that it suggested it was.
This issue is now fixed.

Old position, mistaken: case 14 begins on line ccccuuuucccc
Old position, corrected: cases 12/13 consume leading cccc; case 14 begins on uuuucccc
New positions: as commented in test .cfa

prior scanf understanding, mistaken: include skips unwanted characters before capturing
wanted characters, while exclude fails on unwanted characters

scanf understanding, corrected: include and exclude fail on unwanted characters

File:
1 edited

Legend:

Unmodified
Added
Removed
  • tests/io/.in/manipulatorsInput.txt

    r71b5aad5 r8a33777  
    88abcxxx
    99abcyyy
    10 aaaaaaaaxxxxxxxxaabbccbbdddwwwbbbbbbbbwwwwwwwwaaaaaaaawwwwwwww
    11 uuuuuccccuuuuu
     10aaaaaaaaxxxxxxxxaabbccbbdddwwwbbbbbbbbwwwwwwwwaaaaaaaawwwwwwwwaaaaaaaawwwwwwww
     11uuuuu
    1212get this line
    1313@# this line 1)-{}%
     
    2323abcxxx
    2424abcyyy
    25 aaaaaaaaxxxxxxxxaabbccbbdddwwwbbbbbbbbwwwwwwwwaaaaaaaawwwwwwww
    26 uuuuuccccuuuuu
     25aaaaaaaaxxxxxxxxaabbccbbdddwwwbbbbbbbbwwwwwwwwaaaaaaaawwwwwwwwaaaaaaaawwwwwwww
     26uuuuu
    2727get this line
    2828@# this line 1)-{}%
Note: See TracChangeset for help on using the changeset viewer.