Skip to content

Commit

Permalink
intro to acceptance tests
Browse files Browse the repository at this point in the history
  • Loading branch information
Chris James committed Aug 10, 2022
1 parent 2f88956 commit 2d2bf0f
Show file tree
Hide file tree
Showing 12 changed files with 375 additions and 8 deletions.
6 changes: 6 additions & 0 deletions README.md
Expand Up @@ -81,6 +81,12 @@ By the end of this, you should have a strong grasp as to how to iteratively writ
* [Time](time.md) - using the `time` package to schedule activities.
* [WebSockets](websockets.md) - learn how to write and test a server that uses WebSockets.

### Testing fundamentals

Covering other subjects around testing.

* [Introduction to acceptance tests] - Learn how to write acceptance tests for your code, with a real-world example for gracefully shutting down a HTTP server

### Questions and answers

I often run in to questions on the internets like
Expand Down
4 changes: 4 additions & 0 deletions SUMMARY.md
Expand Up @@ -26,6 +26,10 @@
* [Generics](generics.md)
* [Revisiting arrays and slices with generics](revisiting-arrays-and-slices-with-generics.md)

## Testing fundamentals

* [Introduction to acceptance tests](intro-to-acceptance-tests.md)

## Build an application

* [Intro](app-intro.md)
Expand Down
2 changes: 2 additions & 0 deletions build.books.sh
Expand Up @@ -27,6 +27,7 @@ docker run --rm -v `pwd`:/data uppalabharath/pandoc-latex-cjk:latest --from=gfm+
html-templates.md \
generics.md \
revisiting-arrays-and-slices-with-generics.md \
intro-to-acceptance-tests.md \
app-intro.md \
http-server.md \
json.md \
Expand Down Expand Up @@ -63,6 +64,7 @@ docker run --rm -v `pwd`:/data uppalabharath/pandoc-latex-cjk:latest --from=gfm+
html-templates.md \
generics.md \
revisiting-arrays-and-slices-with-generics.md \
intro-to-acceptance-tests.md \
app-intro.md \
http-server.md \
json.md \
Expand Down
355 changes: 355 additions & 0 deletions intro-to-acceptance-tests.md

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion math/v10/clockface/svgWriter.go
Expand Up @@ -13,7 +13,7 @@ const (
clockCentreY = 150
)

//SVGWriter writes an SVG representation of an analogue clock, showing the time t, to the writer w.
// SVGWriter writes an SVG representation of an analogue clock, showing the time t, to the writer w.
func SVGWriter(w io.Writer, t time.Time) {
io.WriteString(w, svgStart)
io.WriteString(w, bezel)
Expand Down
2 changes: 1 addition & 1 deletion math/v11/clockface/svgWriter.go
Expand Up @@ -13,7 +13,7 @@ const (
clockCentreY = 150
)

//SVGWriter writes an SVG representation of an analogue clock, showing the time t, to the writer w.
// SVGWriter writes an SVG representation of an analogue clock, showing the time t, to the writer w.
func SVGWriter(w io.Writer, t time.Time) {
io.WriteString(w, svgStart)
io.WriteString(w, bezel)
Expand Down
2 changes: 1 addition & 1 deletion math/v12/clockface/svgWriter.go
Expand Up @@ -14,7 +14,7 @@ const (
clockCentreY = 150
)

//SVGWriter writes an SVG representation of an analogue clock, showing the time t, to the writer w.
// SVGWriter writes an SVG representation of an analogue clock, showing the time t, to the writer w.
func SVGWriter(w io.Writer, t time.Time) {
io.WriteString(w, svgStart)
io.WriteString(w, bezel)
Expand Down
2 changes: 1 addition & 1 deletion math/v7/clockface/svgWriter.go
Expand Up @@ -12,7 +12,7 @@ const (
clockCentreY = 150
)

//SVGWriter writes an SVG representation of an analogue clock, showing the time t, to the writer w.
// SVGWriter writes an SVG representation of an analogue clock, showing the time t, to the writer w.
func SVGWriter(w io.Writer, t time.Time) {
io.WriteString(w, svgStart)
io.WriteString(w, bezel)
Expand Down
2 changes: 1 addition & 1 deletion math/v7b/clockface/svgWriter.go
Expand Up @@ -12,7 +12,7 @@ const (
clockCentreY = 150
)

//SVGWriter writes an SVG representation of an analogue clock, showing the time t, to the writer w.
// SVGWriter writes an SVG representation of an analogue clock, showing the time t, to the writer w.
func SVGWriter(w io.Writer, t time.Time) {
io.WriteString(w, svgStart)
io.WriteString(w, bezel)
Expand Down
2 changes: 1 addition & 1 deletion math/v7c/clockface/svgWriter.go
Expand Up @@ -12,7 +12,7 @@ const (
clockCentreY = 150
)

//SVGWriter writes an SVG representation of an analogue clock, showing the time t, to the writer w.
// SVGWriter writes an SVG representation of an analogue clock, showing the time t, to the writer w.
func SVGWriter(w io.Writer, t time.Time) {
io.WriteString(w, svgStart)
io.WriteString(w, bezel)
Expand Down
2 changes: 1 addition & 1 deletion math/v8/clockface/svgWriter.go
Expand Up @@ -12,7 +12,7 @@ const (
clockCentreY = 150
)

//SVGWriter writes an SVG representation of an analogue clock, showing the time t, to the writer w.
// SVGWriter writes an SVG representation of an analogue clock, showing the time t, to the writer w.
func SVGWriter(w io.Writer, t time.Time) {
io.WriteString(w, svgStart)
io.WriteString(w, bezel)
Expand Down
2 changes: 1 addition & 1 deletion math/v9/clockface/svgWriter.go
Expand Up @@ -13,7 +13,7 @@ const (
clockCentreY = 150
)

//SVGWriter writes an SVG representation of an analogue clock, showing the time t, to the writer w.
// SVGWriter writes an SVG representation of an analogue clock, showing the time t, to the writer w.
func SVGWriter(w io.Writer, t time.Time) {
io.WriteString(w, svgStart)
io.WriteString(w, bezel)
Expand Down

0 comments on commit 2d2bf0f

Please sign in to comment.