(t *testing.T)
| 499 | } |
| 500 | |
| 501 | func newNotifyFixture(t *testing.T) *notifyFixture { |
| 502 | out := bytes.NewBuffer(nil) |
| 503 | ctx, cancel := context.WithCancel(t.Context()) |
| 504 | nf := ¬ifyFixture{ |
| 505 | ctx: ctx, |
| 506 | cancel: cancel, |
| 507 | TempDirFixture: NewTempDirFixture(t), |
| 508 | paths: []string{}, |
| 509 | out: out, |
| 510 | } |
| 511 | nf.watch(nf.TempDir("watched")) |
| 512 | t.Cleanup(nf.tearDown) |
| 513 | return nf |
| 514 | } |
| 515 | |
| 516 | func (f *notifyFixture) watch(path string) { |
| 517 | f.paths = append(f.paths, path) |
no test coverage detected