Ignore:
Timestamp:
02/19/06 17:17:28 (8 years ago)
Author:
xi
Message:

Parser is done. Add iterator interfaces for Scanner and Parser.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/pyyaml3000/tests/test_canonical.py

    r43 r51  
    66    def _testCanonicalScanner(self, test_name, canonical_filename): 
    77        data = file(canonical_filename, 'rb').read() 
    8         scanner = test_appliance.CanonicalScanner(canonical_filename, data) 
     8        scanner = test_appliance.CanonicalScanner(data) 
    99        tokens = scanner.scan() 
    10         #print tokens 
     10        #for token in tokens: 
     11        #    print token 
    1112 
    1213    def _testCanonicalParser(self, test_name, canonical_filename): 
    1314        data = file(canonical_filename, 'rb').read() 
    14         parser = test_appliance.CanonicalParser(canonical_filename, data) 
    15         documents = parser.parse() 
    16         #for document in documents: 
    17         #    print document 
     15        parser = test_appliance.CanonicalParser(data) 
     16        events = parser.parse() 
     17        #for event in events: 
     18        #    print event 
    1819 
    1920TestCanonicalAppliance.add_tests('testCanonicalScanner', '.canonical') 
Note: See TracChangeset for help on using the changeset viewer.