feat(01-01): create main.go, test scaffolding, and testdata fixtures

- main.go entry point (7 lines) delegates to cmd.Execute()
- cmd/root.go stub so go build ./... compiles (Plan 05 replaces)
- pkg/providers, pkg/storage, pkg/engine package stubs
- Test stubs with t.Skip() for providers, storage, engine packages
- testdata/samples: openai_key.txt, anthropic_key.txt, multiple_keys.txt, no_keys.txt
- go build ./... and go test ./... -short both exit 0
This commit is contained in:
salvacybersec
2026-04-05 00:04:42 +03:00
parent 7994220fbe
commit 58259cb9d3
12 changed files with 103 additions and 0 deletions

3
pkg/engine/engine.go Normal file
View File

@@ -0,0 +1,3 @@
// Package engine implements the core scanning pipeline.
// Scanner stages (keyword pre-filter, regex matching, entropy analysis) are implemented in Plan 04.
package engine

View File

@@ -0,0 +1,23 @@
package engine_test
import (
"testing"
)
// TestShannonEntropy verifies the entropy function returns expected values.
// Stub: will be implemented when entropy.go exists (Plan 04).
func TestShannonEntropy(t *testing.T) {
t.Skip("stub — implement after entropy.go exists")
}
// TestKeywordPreFilter verifies Aho-Corasick pre-filter rejects files without keywords.
// Stub: will be implemented when filter.go exists (Plan 04).
func TestKeywordPreFilter(t *testing.T) {
t.Skip("stub — implement after filter.go exists")
}
// TestScannerPipeline verifies end-to-end scan of testdata returns expected findings.
// Stub: will be implemented when engine.go exists (Plan 04).
func TestScannerPipeline(t *testing.T) {
t.Skip("stub — implement after engine.go exists")
}