Add unit/integration tests for core functionality

Chiusa
#24 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
3/5
Tempo stimato
1-2 giorni
Idoneità per principianti
48/100
Tipo di issue
Funzionalità
Chiarezza
Abbastanza chiara
Stato di attività
Attiva
Stack tecnologico
python, shell
Ambito
testing

Direzione di ricerca

Start by reading hermeskey-server.py for its socket handling, JSON parsing and error paths, then look at .github/workflows/ci.yml to see where a test step would go. No tests/ directory exists yet, so the framework choice (pytest or bats) is open and needs confirming with maintainers first. Done means a pytest suite covering the server's unit paths runs under python3 -m pytest tests/ and passes in CI.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

enhancement help wanted

Issue

The project has no automated tests (unit or integration).

Suggested Test Coverage

Unit Tests
  • hermeskey-server.py: Socket communication, JSON parsing, error handling
  • Config parsing and validation
  • Model name validation
Integration Tests
  • Full transcription flow (mock server)
  • Hotkey toggle behavior
  • Clipboard operations
Test Framework

Consider:

  • pytest for Python tests
  • bashunit or bats for shell script tests

CI Integration

Add to .github/workflows/ci.yml:

- name: Run tests
  run: |
    python3 -m pytest tests/
    ./tests/shell-test.sh

Benefits

  • Catch regressions early
  • Enable safer refactoring
  • Improve code quality
  • Better contributor onboarding
Lingua principale
Shell
Stelle
0
Fork
0
Merge medio
16m
PR unite (30g)
40

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di graygarbage/HermesKey

Tutte le issue di graygarbage/HermesKey

Issue simili

Altre issue su Shell/Bash

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.