explaingit

smartystreets/goconvey

8,417GoAudience · developerComplexity · 2/5Setup · easy

TLDR

GoConvey is a Go testing tool that lets you write tests as readable plain-English sentences and adds a browser dashboard that auto-reruns tests on file changes and shows live coverage results.

Mindmap

mindmap
  root((goconvey))
    What it does
      Readable test syntax
      Browser test dashboard
      Auto test rerun
      Coverage display
    How it works
      Wraps go test
      Nested Convey blocks
      File watcher
    Output modes
      Browser UI
      Terminal colored
      Desktop notifications
    Setup
      Single go install
      Go 1.16 or 1.17
Click or tap to explore — scroll the page freely

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

Things people build with this

USE CASE 1

Write Go tests structured as plain-English sentences so failing test output is immediately understandable.

USE CASE 2

Run a local web server that watches your Go project and displays test results and code coverage in a browser tab.

USE CASE 3

Add automatic test re-running on file save to an existing Go project without changing your test runner.

USE CASE 4

Get desktop notifications when your Go test suite finishes so you can stay in another window while tests run.

Tech stack

Go

Getting it running

Difficulty · easy Time to first run · 5min

Officially supports Go 1.16 and 1.17, behavior on newer Go versions is not guaranteed.

In plain English

GoConvey is a testing tool for Go programs. It works alongside Go's built-in testing system rather than replacing it, so you can use it on existing projects without changing how tests are run. The main thing GoConvey adds is a way to write tests that read more like sentences. Instead of just calling a function and checking if the result equals some value, you wrap the test logic in nested blocks that each have a plain-text description. The outer block might say "Given some integer with a starting value," an inner block says "When the integer is incremented," and the innermost block says "The value should be greater by one." When tests run, these descriptions appear in the output, making it easier to understand what failed and why. GoConvey also ships a small local web server that you can run alongside your code. Once started, it watches your project for file changes and re-runs tests automatically. The results show up in a browser tab with a visual display of which tests passed and failed, including code coverage. The web interface works with ordinary Go tests too, not just tests written in GoConvey's style. In the terminal, using GoConvey is no different from running any other Go tests. You run the usual "go test" command and get colored output. Optional desktop notifications can alert you when tests finish. Installation is a single command using Go's package manager. The project currently supports Go 1.16 and 1.17. SmartyStreets, the company that created it, maintains the project on a best-effort basis and notes in the README that they may not address enhancement requests. The source code and documentation are publicly available on GitHub.

Copy-paste prompts

Prompt 1
Show me how to write a GoConvey test for a simple Go function using nested Convey blocks with Given, When, and Then descriptions.
Prompt 2
How do I start the GoConvey web UI to watch my Go project directory and display live test results in the browser?
Prompt 3
I want to use GoConvey assertions with standard go test output without the browser UI. How do I structure the test file?
Prompt 4
Write a complete GoConvey test for a calculator package that tests Add, Subtract, and Multiply with multiple nested Convey blocks.
Open on GitHub → Explain another repo

← smartystreets on gitmyhub — every repo by this author, as a profile.

Verify against the repo before relying on details.