From 86aafe22eaf04687288e5a730acf0a473719c514 Mon Sep 17 00:00:00 2001 From: Paul Buetow Date: Thu, 28 Aug 2025 23:28:31 +0300 Subject: copilot: add session token + codex code completion; lsp: prefer native CodeCompleter with chat fallback; remove obsolete throttle path; add tests; bump version to 0.3.0 --- internal/lsp/testfakes_test.go | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 internal/lsp/testfakes_test.go (limited to 'internal/lsp/testfakes_test.go') diff --git a/internal/lsp/testfakes_test.go b/internal/lsp/testfakes_test.go new file mode 100644 index 0000000..bfe536e --- /dev/null +++ b/internal/lsp/testfakes_test.go @@ -0,0 +1,18 @@ +package lsp + +import ( + "context" + "hexai/internal/llm" +) + +// countingLLM counts Chat calls; minimal implementation for tests that need +// to assert whether the chat-based completion path ran. +type countingLLM struct{ calls int } + +func (f *countingLLM) Chat(_ context.Context, _ []llm.Message, _ ...llm.RequestOption) (string, error) { + f.calls++ + return "x := 1", nil +} +func (f *countingLLM) Name() string { return "fake" } +func (f *countingLLM) DefaultModel() string { return "m" } + -- cgit v1.2.3