From 3e4185913b584f5cc9a54f16f3c223861e11ec18 Mon Sep 17 00:00:00 2001 From: Simeon Simeonov Date: Thu, 16 Apr 2026 17:14:23 +0200 Subject: Introduce a new marco - %e and migrate the project from GitHub to Codeberg --- tests/conftest.py | 30 +++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) (limited to 'tests/conftest.py') diff --git a/tests/conftest.py b/tests/conftest.py index a4463fd..6cc8b9f 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -1,5 +1,5 @@ # etoolkit -# Copyright (C) 2021-2024 Simeon Simeonov +# Copyright (C) 2021-2026 Simeon Simeonov # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -20,7 +20,7 @@ import json import pytest -@pytest.fixture() +@pytest.fixture def config_data(): """config_data for testing""" @@ -59,7 +59,7 @@ def config_data(): } -@pytest.fixture() +@pytest.fixture def config_file(tmp_path, config_data): """Temporary config file for testing that includes config_data""" @@ -68,7 +68,7 @@ def config_file(tmp_path, config_data): return str(cf) -@pytest.fixture() +@pytest.fixture def long_encrypted_value(): """enc. value corresponding to 'Nobody expects the Spanish inquisition'""" @@ -79,25 +79,25 @@ def long_encrypted_value(): ) -@pytest.fixture() +@pytest.fixture def long_value(): """standard value (> 32 bytes)""" return 'Nobody expects the Spanish inquisition' -@pytest.fixture() +@pytest.fixture def master_password(): """Master passord""" return 'The very secret passwd' -@pytest.fixture() +@pytest.fixture def new_master_password(): """Master passord""" return 'New very secret passwd' -@pytest.fixture() +@pytest.fixture def non_random_bytes_32(): """always use the same bytes instead of os.urandom(32)""" @@ -107,7 +107,7 @@ def non_random_bytes_32(): ) -@pytest.fixture() +@pytest.fixture def non_random_bytes_57(): """always use the same bytes instead of os.urandom(57)""" @@ -118,14 +118,14 @@ def non_random_bytes_57(): ) -@pytest.fixture() +@pytest.fixture def nonexistent_config_file(tmp_path): """temporary config file for testing that includes config_data""" return str(tmp_path / 'etoolkitt.json') -@pytest.fixture() +@pytest.fixture def password_hash(): """password hash for testing, corresponding to 'The very secret passwd'""" @@ -135,7 +135,7 @@ def password_hash(): ) -@pytest.fixture() +@pytest.fixture def short_encrypted_value(): """enc. value corresponding to 'secret1'""" @@ -145,7 +145,7 @@ def short_encrypted_value(): ) -@pytest.fixture() +@pytest.fixture def short_encrypted_value_v1(): """enc. value (enc-val 1) corresponding to 'secret1'""" @@ -155,13 +155,13 @@ def short_encrypted_value_v1(): ) -@pytest.fixture() +@pytest.fixture def short_value(): """standard value (< 32 bytes)""" return 'secret1' -@pytest.fixture() +@pytest.fixture def wrong_master_password(): """Wrong master passord""" return 'the very secret passwd' -- cgit v1.3