hugo

Unnamed repository; edit this file 'description' to name the repository.

git clone git://git.shimmy1996.com/hugo.git
commit 00f07c5374d859057c6e7c4731000b5978364819
parent 43742e0277216f241ea2ee9ecf9e95b3e0f6105d
Author: bep <bjorn.erik.pedersen@gmail.com>
Date:   Wed, 11 Mar 2015 10:25:53 +0100

doArithmetic: add test for division by zero

Diffstat:
Mtpl/template_test.go | 2+-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tpl/template_test.go b/tpl/template_test.go
@@ -123,10 +123,10 @@ func TestArethmic(t *testing.T) {
 		{uint8(2), uint8(2), '*', uint64(4)},
 		{uint16(4), uint8(2), '/', uint64(2)},
 		{4, 2, '¤', false},
+		{4, 0, '/', false},
 	} {
 		// TODO(bep): Take precision into account.
 		result, err := doArithmetic(this.a, this.b, this.op)
-
 		if b, ok := this.expect.(bool); ok && !b {
 			if err == nil {
 				t.Errorf("[%d] doArethmic didn't return an expected error", i)