diff --git a/test.py b/test.py index a7a96ed..2ef9878 100755 --- a/test.py +++ b/test.py @@ -43,6 +43,8 @@ facture_ldif = {} def keys_of_list_of_dict(l, type=''): + """Récupère la liste de tous les attributs existant. + Teste l'écriture des objets si on est en mode rw""" keys = set() if l: anime=anim("Test des objets %r" % type, len(l)) @@ -60,12 +62,15 @@ def keys_of_list_of_dict(l, type=''): else: print "\t%r" % error ok = False anime.cycle() - if l: print OK if ok else ERREUR + if l: + anime.reinit() + print OK if ok else ERREUR keys = list(keys) keys.sort() return keys def test_list_of_dict(keys, list): + """Test l'instanciation des attributs""" for key in keys: anim("\tTest de l'attribut %s" % key) ok = True @@ -84,6 +89,7 @@ def test_list_of_dict(keys, list): if ok: print OK def tests_machines(parent_dn, realm_list, ipsec=False): + """Test la création et la suppression de machines dans la realm_list""" for realm in realm_list: anim("Creation de machines %s" % realm) try: