# Integration Testing in Go: Part II - Set-up and Writing Tests

DevFeed: [Integration Testing in Go: Part II - Set-up and Writing Tests](<https://devfeed.tech/articles/integration-testing-in-go-part-ii-set-up-and-writing-tests-22151.md>)

Original publisher: [Read original article](<https://www.ardanlabs.com/blog/2019/10/integration-testing-in-go-set-up-and-writing-tests.html>)

Published: 2019-10-03T00:00:00Z

Content type: tutorial

Language: en

Sources: [William Kennedy](<https://devfeed.tech/sources/william-kennedy.md>)

Topics: [Integration testing](<https://devfeed.tech/topics/integration-testing.md>), [Testing](<https://devfeed.tech/topics/testing.md>), [Go Language](<https://devfeed.tech/topics/go-language.md>), [Databases](<https://devfeed.tech/topics/databases.md>), [SQL](<https://devfeed.tech/topics/sql.md>), [bug](<https://devfeed.tech/topics/bug.md>)

Tags: [ardan-labs](<https://devfeed.tech/tags/ardan-labs.md>), [blog](<https://devfeed.tech/tags/blog.md>), [code](<https://devfeed.tech/tags/code.md>), [database](<https://devfeed.tech/tags/database.md>), [examples](<https://devfeed.tech/tags/examples.md>), [go](<https://devfeed.tech/tags/go.md>), [go-programming](<https://devfeed.tech/tags/go-programming.md>), [golang](<https://devfeed.tech/tags/golang.md>), [integration](<https://devfeed.tech/tags/integration.md>), [integration-testing](<https://devfeed.tech/tags/integration-testing.md>), [introduction](<https://devfeed.tech/tags/introduction.md>), [post](<https://devfeed.tech/tags/post.md>), [programming](<https://devfeed.tech/tags/programming.md>), [repo](<https://devfeed.tech/tags/repo.md>), [sql](<https://devfeed.tech/tags/sql.md>), [testing](<https://devfeed.tech/tags/testing.md>), [tests](<https://devfeed.tech/tags/tests.md>)

## AI overview

This second installment in a two-part series explains how to prepare external systems for integration tests in Go. It focuses on configuring and seeding a Postgres database, using Go data structures for seed data, and writing and running tests against the database.

## Source excerpt

Prelude This post is the 2nd installment of a 2 part series about integration testing. You can read the first installment, which is about executing tests in a restricted environment using Docker. The example repository that this post draws it examples from can be found in the integration-tests-example repo. Introduction "More than the act of testing, the act of designing tests is one of the best bug preventers known." - Boris Beizer