pymastodon/tests/test_config.py

16 lines
445 B
Python
Raw Normal View History

2024-04-30 08:42:20 +02:00
from mastodon.application import MastodonApplication
from mastodon.config import MastodonConfiguration
import pytest
import shutil
import os
@pytest.fixture
def app():
yield MastodonApplication("pymastodon")
def test_read_config(app):
assert os.path.exists(app.config.config_file)
assert app.config.get_value("server") != ""
assert app.config.get_value("client_secret") != ""
assert app.config.get_value("client_id") != ""