package similarity

import (
	"io"
	"log/slog"
	"testing"
	"time"
)

func TestNewWorker_DefaultsMatchSpec(t *testing.T) {
	logger := slog.New(slog.NewTextHandler(io.Discard, nil))
	w := NewWorker(nil, nil, logger)
	if w.tick != 1*time.Hour {
		t.Errorf("tick = %v, want 1h", w.tick)
	}
	if w.batch != 25 {
		t.Errorf("batch = %d, want 25", w.batch)
	}
	if w.topK != 20 {
		t.Errorf("topK = %d, want 20", w.topK)
	}
}
