<commit_before>from stdnet import test
from stdnet.utils.structures import OrderedDict
from stdnet.utils import populate, zip


class TestOrderedDict(test.TestCase):
    
    def setUp(self):
        self.keys = populate(datatype = 'date', size = 100)
        self.vals = populate(datatype = 'string', size = 100)
        self.data = zip(self.keys,self.vals)
    
    def testOrdered(self):
        d = OrderedDict()
        for k,v in self.data:
            d[k] = v
        kp = None
        for k,k2 in zip(d,self.keys):
            self.assertEqual(k,k2)
        
<commit_msg>fixed memory test<commit_after>from stdnet import test
from stdnet.utils.structures import OrderedDict
from stdnet.utils import populate, zip


class TestOrderedDict(test.TestCase):
    '''This test is really only needed for python 2.6'''
    def setUp(self):
        self.keys = list(set(populate(datatype = 'date', size = 100)))
        self.vals = populate(datatype = 'string', size = len(self.keys))
        self.data = zip(self.keys,self.vals)
    
    def testOrdered(self):
        d = OrderedDict()
        for k,v in self.data:
            d[k] = v
        kp = None
        for k,k2 in zip(d,self.keys):
            self.assertEqual(k,k2)
        

{'fraction_non_alphanumeric': 0.107981220657277, 'fraction_numerical': 0.011737089201877934, 'mean_word_length': 2.1425061425061425, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4532481', 'n_tokens_mistral': 431, 'n_tokens_neox': 393, 'n_words': 103}