tests: all 16 tests now sourced from org (doctor→diagnostics rename, orphaned tests adopted)
Some checks failed
Deploy (Gitea) / deploy (push) Failing after 2s

This commit is contained in:
2026-05-05 09:58:00 -04:00
parent 11383a29d4
commit 817d1c5fec
11 changed files with 105 additions and 41 deletions

View File

@@ -161,3 +161,23 @@ If API-KEY is nil, reads from environment."
:priority 50
:trigger (lambda (ctx) (declare (ignore ctx)) nil))
#+end_src
* Test Suite
#+begin_src lisp :tangle ../tests/llm-gateway-tests.lisp
(eval-when (:compile-toplevel :load-toplevel :execute)
(ql:quickload :fiveam :silent t))
(defpackage :passepartout-llm-gateway-tests
(:use :cl :passepartout)
(:export #:llm-gateway-suite))
(in-package :passepartout-llm-gateway-tests)
(fiveam:def-suite llm-gateway-suite :description "Tests for the LLM provider backend")
(fiveam:in-suite llm-gateway-suite)
(fiveam:test test-provider-rejects-bad-keyword
"Verify that provider-openai-request returns :error for an unregistered provider."
(let ((result (provider-openai-request "hello" "test" :provider :not-a-real-provider)))
(fiveam:is (eq (getf result :status) :error))))
#+end_src