CtrlK
BlogDocsLog inGet started
Tessl Logo

tessl-labs/go-project-structure

Go project structure -- cmd/internal layout, handler/service/repository layers, Makefile, config from environment, domain error types, test placement, dependency injection

90

1.02x
Quality

84%

Does it follow best practices?

Impact

100%

1.02x

Average score across 5 eval scenarios

SecuritybySnyk

Passed

No known issues

Overview
Quality
Evals
Security
Files

go-test-placement.jsonverifiers/

{
  "instruction": "Place Go test files alongside source code and use table-driven tests",
  "relevant_when": "Agent creates tests for a Go project",
  "context": "Go test files (*_test.go) must live in the same directory as the code they test -- this is a Go convention enforced by the toolchain. Do not create a separate tests/ directory. Use table-driven tests as the standard pattern. Use testdata/ directories for test fixtures. Use the same package name for white-box tests or package_test for black-box tests.",
  "sources": [
    {
      "type": "file",
      "filename": "skills/go-project-structure/SKILL.md",
      "tile": "tessl-labs/go-project-structure@0.2.0"
    }
  ],
  "checklist": [
    {
      "name": "tests-alongside-code",
      "rule": "Test files (*_test.go) are in the same directory as the source files they test, not in a separate tests/ directory",
      "relevant_when": "Agent creates tests for Go code"
    },
    {
      "name": "table-driven-tests",
      "rule": "Tests use table-driven test pattern with test case structs and t.Run() subtests",
      "relevant_when": "Agent writes Go unit tests with multiple test cases"
    },
    {
      "name": "test-file-naming",
      "rule": "Test files are named <source>_test.go (e.g., orders_test.go for orders.go)",
      "relevant_when": "Agent creates Go test files"
    }
  ]
}

tile.json