SigNoz is an open-source, OpenTelemetry-native observability platform for your team and their AI agents. Get logs, metrics, and traces in one tool with features like APM, distributed tracing, log management, infra monitoring, etc. Combined with SigNoz MCP and a native AI teammate (in SigNoz Cloud) it helps you build more resilient apps.
TypeScript apmapplication-monitoringdistributed-tracinggogood-first-issuejaegerloglogsmetricsmonitoringnextjsobservabilityopen-sourceopentelemetryprometheusreactreactjsself-hostedtracingtypescript
paths: - "**/*_test.go"
Go tests
- testify + table-driven. Use
assert/require; prefer table-driven cases. Tests live next to the source file. requirevsassert.requirefor anything the rest of the test cannot proceed without — setup,require.NoError(t, err), nil/length checks before indexing or dereferencing.assertfor the actual expectations, so one failed check still reports the rest.- Mock with mockery. When an interface needs mocking, list it in
.mockery.ymland runmockery; never hand-write mocks. Generated mocks live in the source package's<pkg>testsibling (e.g.resourcestest.NewMockAdapter(t)). - Table format. Declare cases as
testCases := []struct{ name string; ... }and iterate withfor _, testCase := range testCases { t.Run(testCase.name, ...) }— the variables are namedtestCases/testCase. Case names are PascalCase segments joined by_, one segment per aspect (scenario, condition, expectation):TimestampNotNullNoDefault,DropPrimaryKeyConstraint_AlterColumnNullable,ForeignKeyConstraint_DoesNotExist_SCreateAndDropConstraintTrue. - No hoisted test constants. When goconst flags a repeated literal in a test, vary the fixture strings across cases instead of hoisting a constant — never introduce a shared const for test data.