From 8c9194975bf5a1c3b4c30d478ba8383348801832 Mon Sep 17 00:00:00 2001 From: Jon Michael Aanes Date: Sun, 13 Apr 2025 16:23:53 +0200 Subject: [PATCH] Fixed test --- aider_gitea/__main__.py | 2 +- aider_gitea/secrets.py | 4 ++-- .../test_init.cpython-313-pytest-8.3.5.pyc | Bin 411 -> 0 bytes test/test_init.py | 1 + 4 files changed, 4 insertions(+), 3 deletions(-) delete mode 100644 test/__pycache__/test_init.cpython-313-pytest-8.3.5.pyc diff --git a/aider_gitea/__main__.py b/aider_gitea/__main__.py index ac7ab0a..900c0bb 100644 --- a/aider_gitea/__main__.py +++ b/aider_gitea/__main__.py @@ -151,7 +151,7 @@ def main(): logger.exception('Error processing issue') sys.exit(1) - body = f"Automatically generated pull request for issue: {issue.get('html_url', 'unknown')}" + body = f"This pull request resolves {issue.get('html_url', 'unknown')}" try: pr = client.create_pull_request(args.owner, args.repo, f"[Issue {issue_number}] {title}", branch_name, args.base_branch, body) logger.info(f"Created pull request: {pr.get('html_url', 'unknown')} for issue {issue_number}.") diff --git a/aider_gitea/secrets.py b/aider_gitea/secrets.py index fc5ef30..fe3b2bf 100644 --- a/aider_gitea/secrets.py +++ b/aider_gitea/secrets.py @@ -1,7 +1,7 @@ -SECRETS = secret_loader.SecretLoader() - import secret_loader +SECRETS = secret_loader.SecretLoader() + def llm_api_key(): return SECRETS.load_or_fail('LLM_API_KEY') diff --git a/test/__pycache__/test_init.cpython-313-pytest-8.3.5.pyc b/test/__pycache__/test_init.cpython-313-pytest-8.3.5.pyc deleted file mode 100644 index d48e16dfc0ad5a6e7eaf1f9d1192e38fd7d6159d..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 411 zcmX|6yG{c!5M19~o+N?_1l0-Aq)4u#LWqhYk<#P?PA0J~j&k;C?Fgl#;1~FaG<=Yi zjsnpkT}i{*O0tq?ch;I2yYBb9Ky~~1SKL$o^5j_2VW{tD_<$MA*aVP;9*tuYr7%vg zk-{vx0c;j*5dV0|bbb(q=3Qbsb&r5tNIwAu1q`Ao`pX@2XIw4>=7qF^V?sN_2vYZ) zEp;ifRmpi)2{c;q^{_&{5_4;^YHOET4Rxtx77T{LAhW{Q0J&7sj;gKe_*G!oB4eLw z8U$~!PcCa3V9;{ymyKLosf_DARonc;u5$_^{fHYQ&`PaFC|;4?>N=;DYaMr85{EdB oA#4ZOrT}abxb{P-7n`+s#0#SSljfY@H)f1|1H3~Gj9mr6KP6Xcz5oCK diff --git a/test/test_init.py b/test/test_init.py index 66d5855..65c15d0 100644 --- a/test/test_init.py +++ b/test/test_init.py @@ -1,4 +1,5 @@ def test_init(): import aider_gitea #noqa: F401 + import aider_gitea.secrets #noqa: F401