Project

General

Profile

Tâche #16956

Distribution EOLE - Scénario #16720: Traitement express (28-35)

Test unitaire creole "test_upgrade_amon23" en erreur sur 2.6.0

Added by Joël Cuissinat about 5 years ago. Updated about 5 years ago.

Status:
Fermé
Priority:
Normal
Assigned To:
Start date:
09/01/2016
Due date:
% Done:

100%

Estimated time:
1.00 h
Spent time:
Remaining (hours):
0.0

Description

00:04:39.541             =================================== FAILURES ===================================
00:04:39.542             _____________________________ test_upgrade_amon23 ______________________________
00:04:39.542                 def test_upgrade_amon23():
00:04:39.542                     """ 
00:04:39.543                     Valide que la migration des variables "etb1.amon" va à son terme #14589
00:04:39.543                     """ 
00:04:39.543                     if isfile('/usr/share/eole/creole/dicos/30_amon.xml'):
00:04:39.544                         config = creole_loader(force_configeol=_calc_config_file('amon23'))
00:04:39.544             >           assert config.impl_get_information('upgrade', False) == '2.3'
00:04:39.544             E           assert <bound method Config.impl_get_information of [creole]\n[containers]>('upgrade', False) == '2.3'
00:04:39.545             E            +  where <bound method Config.impl_get_information of [creole]\n[containers]> = [creole]\n[containers].impl_get_information
00:04:39.545             tests/test_upgrade.py:130: AssertionError

Associated revisions

Revision 8c9ce4d3 (diff)
Added by Joël Cuissinat about 5 years ago

Ne pas valider les propriétés au chargement d'un fichier 2.3

Ref: #16956 @1h

Revision e7bfdca8 (diff)
Added by Emmanuel GARETTE about 5 years ago

calc_multi_condition : si la variable utilisé comme 'match' n'est pas encore renseigné, ne pas considéré qu'il n'y a pas de 'match' (ref #16956 @2h)

Revision 48e76739 (diff)
Added by Emmanuel GARETTE about 5 years ago

Trop dangereux à quelques jours du freeze, je vais faire autrement

Revert "calc_multi_condition : si la variable utilisé comme 'match' n'est pas encore renseigné, ne pas considéré qu'il n'y a pas de 'match' (ref #16956 @2h)"

This reverts commit e7bfdca85ab33f022c8d7214ab6cd021e2bbdf6a.

Revision a9c48628 (diff)
Added by Emmanuel GARETTE about 5 years ago

mettre None comme valeur par défaut si le serveur n'est pas instancié (ref #16956 @1h)

History

#1 Updated by Joël Cuissinat about 5 years ago

  • Status changed from Nouveau to En cours

#2 Updated by Joël Cuissinat about 5 years ago

L'import du fichier 2.3, ne passe plus, il y a une erreur au chargement :

Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/creole/upgrade.py", line 199, in export_to_store
    path = config.find_first(byname=section, type_='path')
  File "/usr/lib/python2.7/dist-packages/tiramisu/config.py", line 350, in find_first
    force_permissive=force_permissive)
  File "/usr/lib/python2.7/dist-packages/tiramisu/config.py", line 417, in _find
    return self._find_return_results(find_results, raise_if_not_found)
  File "/usr/lib/python2.7/dist-packages/tiramisu/config.py", line 422, in _find_return_results
    raise AttributeError(_("no option found in config" 
AttributeError: aucune option trouvée dans la config avec ces critères
creole.loader - Error when trying to upgrade config file: valeur invalide pour l'option adresse_ip_mail : adresse IP invalide

#3 Updated by Joël Cuissinat about 5 years ago

  • Status changed from En cours to Résolu
  • % Done changed from 0 to 100
  • Remaining (hours) changed from 1.0 to 0.25

#4 Updated by Emmanuel GARETTE about 5 years ago

  • Status changed from Résolu to Fermé
  • Remaining (hours) changed from 0.25 to 0.0
root@amon:/usr/share/creole/tests# py.test
============================================================================= test session starts ==============================================================================
platform linux2 -- Python 2.7.12, pytest-2.8.7, py-1.4.31, pluggy-0.3.1
rootdir: /usr/share/creole/tests, inifile: 
collected 51 items 

test_creoleclient.py ...........
test_creolerun.py ......
test_creoleservice.py ².
test_dicos.py ..
test_eosfunc.py .....
test_genconfig.py .............
test_packages.py .
test_upgrade.py ...........

========================================================================== 51 passed in 27.39 seconds ==========================================================================
root@amon:/usr/share/creole/tests# 

Also available in: Atom PDF