(t *testing.T)
| 13 | } |
| 14 | |
| 15 | func Test_AddCommand_AddToExisting(t *testing.T) { |
| 16 | existing := []byte(` |
| 17 | tests: |
| 18 | echo exists: |
| 19 | exit-code: 0 |
| 20 | `) |
| 21 | |
| 22 | content, err := AddCommand("echo hello", existing) |
| 23 | |
| 24 | assert.Nil(t, err) |
| 25 | assert.Equal(t, "tests:\n echo exists:\n exit-code: 0\n echo hello:\n exit-code: 0\n stdout: hello\n", string(content)) |
| 26 | } |
| 27 | |
| 28 | func Test_AddCommand_AddToExistingWithComplexStdStreamAssertions(t *testing.T) { |
| 29 | existing := []byte(` |
nothing calls this directly
no test coverage detected