compiler/tests/extras/PPTokenizedSmalltalkParserResource.st
changeset 515 b5316ef15274
parent 502 1e45d3c96ec5
child 516 3b81c9e53352
child 524 f6f68d32de73
equal deleted inserted replaced
502:1e45d3c96ec5 515:b5316ef15274
     1 "{ Package: 'stx:goodies/petitparser/compiler/tests/extras' }"
       
     2 
       
     3 "{ NameSpace: Smalltalk }"
       
     4 
       
     5 TestResource subclass:#PPTokenizedSmalltalkParserResource
       
     6 	instanceVariableNames:''
       
     7 	classVariableNames:''
       
     8 	poolDictionaries:''
       
     9 	category:'PetitCompiler-Extras-Tests-Smalltalk'
       
    10 !
       
    11 
       
    12 !PPTokenizedSmalltalkParserResource methodsFor:'as yet unclassified'!
       
    13 
       
    14 setUp
       
    15     | time configuration |
       
    16     configuration := PPCConfiguration tokenizing.
       
    17     configuration arguments parserName:#PPTokenizedSmalltalkParser.
       
    18     
       
    19     time := Time millisecondsToRun: [
       
    20         PPSmalltalkParser new compileWithConfiguration: configuration.
       
    21     ].
       
    22     Transcript show: 'Smalltalk Parser tokenized in: '; show: time asString; show: 'ms'; cr.
       
    23 
       
    24     "Modified: / 10-05-2015 / 07:55:07 / Jan Vrany <jan.vrany@fit.cvut.cz>"
       
    25 !
       
    26 
       
    27 tearDown
       
    28     | parserClass |
       
    29     super tearDown.
       
    30     
       
    31     parserClass := (Smalltalk at: #PPTokenizedSmalltalkParser ifAbsent: [nil]).
       
    32     self flag: 'uncomment:'.
       
    33 "	
       
    34     parserClass notNil ifTrue:[ 
       
    35         parserClass removeFromSystem
       
    36     ].
       
    37 "
       
    38 ! !
       
    39