Skip to content

Commit

Permalink
A few fixes thanks to Mykel in the comments!
Browse files Browse the repository at this point in the history
  • Loading branch information
weaverryan committed Nov 7, 2017
1 parent fcf030f commit 8c7866b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions knpu/test-assert-code.md
@@ -1,6 +1,6 @@
# Tests, Assertions & Coding

So... we don't really have much code to test yet! That might feel weird: when *I*
So... we don't really have much code to test yet! That might feel weird: when I
started testing, I wanted to write the code first, and *then* test that it worked.

But actually, you can do it in the *opposite* order! There's a hipster methodology
Expand Down Expand Up @@ -107,7 +107,7 @@ same as before: `$dinosaur = new Dinosaur()`, and `$dinosaur->setLength(15)`.

And *just* to make things more interesting, imagine that it's OK if the dinosaur
shrinks a little bit... it just can't shrink *too* much. The guests want a thrill!
In other words, `$this->assertGreatherThan(12, $dinosuar->getLength())`.
In other words, `$this->assertGreatherThan(12, $dinosaur->getLength())`.

You can also add an optional message as the last argument to *any* assert function.
This will display when the test fails... which can sometimes make debugging easier.
Expand Down

0 comments on commit 8c7866b

Please sign in to comment.