Home | Trees | Indices | Help |
|
---|
|
1 #!/usr/bin/env python 2 # encoding: utf-8 3 """ 4 test_variable_generator.py 5 6 Created by Sebastian Höhn on 2008-01-29. 7 Copyright (c) 2008 __MyCompanyName__. All rights reserved. 8 """ 9 10 # from VariableGenerator import VariableGenerator 11 from VariableGenerator import * 12 import sys 131531 32 # Verify the reset button 33 #cdl.reset() 34 #assert (cdl.getNext() == 'A') 35 36 # TODO: Fix the Singleton if needed! 37 # Verify the Singleton pattern 38 #cdl2 = VariableGenerator() 39 #a = cdl2.getNext() 40 #print(a) 41 #assert (a == 'B') 42 #assert (cdl.getNext() == 'C') 4317 """Test generation of unique variables. 18 19 We need to check if it goes up to the two char 20 variables, too. 21 """ 22 uv = unique_variables() 23 assert (uv.next() == 'A') 24 # print >> sys.stderr , uv.next() 25 assert (uv.next() == 'B') 26 assert (uv.next() != 'D') 27 for i in range(1,26): 28 uv.next() 29 # print >> sys.stderr , uv.next() 30 assert (uv.next() == 'BC')
Home | Trees | Indices | Help |
|
---|
Generated by Epydoc 3.0.1 on Wed Feb 6 18:36:11 2008 | http://epydoc.sourceforge.net |