Skip to content

Comment on Building a testable Go web app

Comments

I didn't see any schema tests for the db. Testing the DAO is its own concern, and I can't consider that as unit test coverage for the schema portion of the project. I would normally be looking to something like PgTAP here.

(For the "oh really?" crowd, here's a brief rundown on what I often test: object permissions/owners, function correctness, non-trivial constraints, triggers (usually existence testing, sometimes functional verification), application-global data. And yes, it is great to have all that nailed down before diving into writing a DAO)

AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.