Skip to content
Mocking the database in Golang
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.gitignore
.travis.yml
LICENSE
README.MD
db.sql
main.go
main_test.go

README.MD

Mockdemo

This repo contains the source code for my blog post on mocking the database in Go.

Blog post is WIP

Features

  • Posts can be created.
  • Posts can be deleted.
  • A single post can be viewed.

The app uses an sqlite database but for the tests, the database interaction is mocked out... Run cat db.sql | sqlite3 demo.sqlite to get the sample database.

License

MIT

You can’t perform that action at this time.