This repository has been archived on 2020-03-24. You can view files and clone it, but cannot push or open issues or pull requests.
quay/data/model/test/test_user.py

10 lines
409 B
Python
Raw Normal View History

from mock import patch
from data.model.user import create_user_noverify
from test.fixtures import database_uri, init_db_path, sqlitedb_file
def test_create_user_with_expiration(database_uri):
with patch('data.model.config.app_config', {'DEFAULT_TAG_EXPIRATION': '1h'}):
user = create_user_noverify('foobar', 'foo@example.com', email_required=False)
assert user.removed_tag_expiration_s == 60 * 60