learning-go/hello/hello_test.go

13 lines
201 B
Go
Raw Permalink Normal View History

2024-03-18 11:30:03 -05:00
package main
import "testing"
func TestHello(t *testing.T) {
given := Hello()
expected := "Hello, world!"
if given != expected {
t.Errorf("given: %v, expected: %v", given, expected)
}
}