diff --git a/calculator/calculator_test.go b/calculator/calculator_test.go new file mode 100644 index 0000000..f4e3ab4 --- /dev/null +++ b/calculator/calculator_test.go @@ -0,0 +1,9 @@ +package calculator + +import "testing" + +func TestAdd(t *testing.T) { + if got, want := Add(1, 2), 3; got != want { + t.Errorf("add method produced wrong result. expected: %d, got: %d", want, got) + } +}