Example: Basic usage with AssertString
(t *testing.T)
| 9 | |
| 10 | // Example: Basic usage with AssertString |
| 11 | func TestBasicUsage(t *testing.T) { |
| 12 | // Generate some code |
| 13 | code := `package main |
| 14 | |
| 15 | func main() { |
| 16 | fmt.Println("Hello, World!") |
| 17 | } |
| 18 | ` |
| 19 | |
| 20 | // Compare with golden file |
| 21 | testutil.AssertString(t, "testdata/golden/hello_world.go.golden", code) |
| 22 | } |
| 23 | |
| 24 | // Example: Format-aware comparisons |
| 25 | func TestFormatAwareComparisons(t *testing.T) { |
nothing calls this directly
no test coverage detected