Projet

Général

Profil

0001-hobo_deploy-simplify-get_theme-function-on-hobo_depl.patch

Nicolas Roche, 31 mai 2019 14:29

Télécharger (1,42 ko)

Voir les différences:

Subject: [PATCH] hobo_deploy: simplify get_theme function on hobo_deploy.py
 (#33592)

 hobo/agent/common/management/commands/hobo_deploy.py | 2 --
 tests/test_hobo_deploy.py                            | 3 ---
 2 files changed, 5 deletions(-)
hobo/agent/common/management/commands/hobo_deploy.py
146 146
        theme = get_theme(theme_id)
147 147
        if not theme:
148 148
            return
149
        if not theme.get('module'):
150
            return
151 149
        return theme
152 150

  
153 151
    def configure_theme(self, hobo_environment, tenant):
tests/test_hobo_deploy.py
323 323
    command.me = HOBO
324 324
    assert command.get_theme(ENVIRONMENT) is None
325 325

  
326
    # can't test last return case as it could never append
327
    # if not theme.get('module'):  # TODO: dead code to remove
328

  
329 326

  
330 327
def test_configure_theme(fake_themes, tmpdir):
331 328
    """make symlink for TENANT/theme
332
-