Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: 7e5ac26efa7d6dff79645a10d94d654bcbef61ca
Ticket: 218645ffffffffffffffffffffffffffffffffff
Test script "io.test" io-13.6 may not pass on slow machine
User & Date: nobody on 2000-10-26 01:03:38
Changes

  1. assignee changed to: "nobody"
  2. cmimetype changed to: "text/plain"
  3. comment changed to:
    OriginalBugID: 1580 Bug
    Version: 8.1b2
    SubmitDate: '1999-03-22'
    LastModified: '1999-03-25'
    Severity: MED
    Status: Released
    Submitter: pat
    ChangedBy: admin
    RelatedBugIDs: 1521
    OS: SunOS
    OSVersion: 5.7 (SPARC)
    Machine: Sparc
    FixedDate: '1999-03-25'
    FixedInVersion: 8.1b3
    ClosedDate: '2000-10-25'
    
    
    Name:
    Taketo Kabe
    
    ReproducibleScript:
        on UNIX source distribution,
           $ make test
        or
           $ env LD_LIBRARY_PATH=../unix ../unix/tcltest
           % cd ../tests
           % source io.test
        
    
    
    
    ObservedBehavior:
        % cd ../tests
        % source io.test
        (will skip non-portable tests)
        
        ==== io-13.6 TranslateInputEOL: auto mode: saw cr in last segment
        FAILED
        ==== Contents of test case:
        
            # (chanPtr->flags & INPUT_SAW_CR)
        
            set f [open "|[list $tcltest cat]" w+]
            fconfigure $f -blocking 0 -buffering none -translation {auto lf}
        
            fileevent $f read "ready $f"
            proc ready {f} {
                lappend ::x [read $f] [testchannel queuedcr $f]
            }
            set x {}
        
            puts -nonewline $f "abcdefghj\r"
            after 100 {set y ok}
            vwait y
        
            puts -nonewline $f "\n01234"
            after 100 {set y ok}
            vwait y
        
            close $f
            set x
        
        ---- Result was:
        {abcdefghj
        01234} 0
        ---- Result should have been:
        {abcdefghj
        } 1 01234 0
        ==== io-13.6 FAILED
        
        
    
    
    
    DesiredBehavior:
        >> ---- Result should have been:
        >> {abcdefghj
        >> } 1 01234 0
        
    
    
    
    Patch:
    --- tests/io.test.distSun Mar 14 03:08:21 1999
    +++ tests/io.testSun Mar 21 23:44:00 1999
    @@ -1490,12 +1490,12 @@
         set x {}
     
         puts -nonewline $f "abcdefghj\r"
    -    after 100 {set y ok}
    -    vwait y
    +    #
    +    vwait x
     
         puts -nonewline $f "\n01234"
    -    after 100 {set y ok}
    -    vwait y
    +    #
    +    vwait x
     
         close $f
         set x
    
    
    
    
    PatchFiles:
        tests/io.test
        
    
    
    
    
    
        100 milliseconds may not be enough for slow machines to take care
        of the fileevent callback.
        This causes timing skew on the result list in the test.
        Using the "correct" vwait argument should be better rather then ad-hoc
        timing.
    
        Well, the machine (SparcStation 20) may not be classified as "slow", but
        it fails anyway...
    
    This patch made the test hang on the solaris machine "weasel", but I fixed the test failure on slow machines by changing the "after 100" calls to "after 500".  The user who reported the bug confirmed that the change solved the problem on his machine.  03/24/1999 20:28 - admin -
    
    
    
  4. foundin changed to: "obsolete: 8.1b2"
  5. priority changed to: "5 Medium"
  6. resolution changed to: "None"
  7. status changed to: "Open"
  8. submitter changed to: "nobody"
  9. subsystem changed to: "61. (unused)"
  10. title changed to:
    Test script "io.test" io-13.6 may not pass on slow machine
    
  11. type changed to: "Bug"