@@ -0,0 +1,1102 @@
+# -*- coding: utf-8 -*-%0A#%0Aimport unittest%0Afrom nose import tools%0A%0Afrom kitchen.versioning import version_tuple_to_string%0A%0A# Note: Using nose's generator tests for this so we can't subclass%0A# unittest.TestCase%0Aclass TestVersionTuple(object):%0A    ver_to_tuple = %7B'1': ((1,),),%0A            '1.0': ((1, 0),),%0A            '1.0.0': ((1, 0, 0),),%0A            '1.0a1': ((1, 0), ('a', 1)),%0A            '1.0rc1': ((1, 0), ('rc', 1)),%0A            '1.0rc1.2': ((1, 0), ('rc', 1, 2)),%0A            '1.0.dev345': ((1, 0), ('dev', 345)),%0A            '1.0a1.dev345': ((1, 0), ('a', 1), ('dev', 345)),%0A            '1.0a1.2.dev345': ((1, 0), ('a', 1, 2), ('dev', 345)),%0A            %7D%0A%0A    def check_ver_tuple_to_str(self, v_tuple, v_str):%0A        tools.ok_(version_tuple_to_string(v_tuple) == v_str)%0A%0A    def test_version_tuple_to_string(self):%0A        '''Test that version_tuple_to_string outputs PEP-386 compliant strings%0A        '''%0A        for v_str, v_tuple in self.ver_to_tuple.items():%0A            #tools.ok_(version_tuple_to_string(v_tuple) == v_str)%0A            yield self.check_ver_tuple_to_str, v_tuple, v_str%0A

Test for the new versioning sub package