mirror of
https://github.com/LibreTranslate/LibreTranslate.git
synced 2024-11-21 23:41:01 +00:00
load only en & es models (avoid to download all models)
This commit is contained in:
parent
55b05992b5
commit
7113a30a0c
2 changed files with 4 additions and 2 deletions
|
@ -2,12 +2,14 @@ import sys
|
|||
import pytest
|
||||
|
||||
from app.app import create_app
|
||||
from app.default_values import DEFAULT_ARGUMENTS
|
||||
from app.main import get_args
|
||||
|
||||
|
||||
@pytest.fixture()
|
||||
def app():
|
||||
sys.argv = ['']
|
||||
DEFAULT_ARGUMENTS['LOAD_ONLY'] = "en,es"
|
||||
app = create_app(get_args())
|
||||
|
||||
yield app
|
||||
|
|
|
@ -4,6 +4,6 @@ from argostranslate import package
|
|||
|
||||
def test_boot_argos():
|
||||
"""Test Argos translate models initialization"""
|
||||
boot()
|
||||
boot(["en", "es"])
|
||||
|
||||
assert len(package.get_installed_packages()) > 2
|
||||
assert len(package.get_installed_packages()) >= 2
|
||||
|
|
Loading…
Reference in a new issue