lib/watchaggregator: Don't care about timings during testing on darwin

GitHub-Pull-Request: https://github.com/syncthing/syncthing/pull/4502
This commit is contained in:
Simon Frei
2017-11-10 17:05:31 +00:00
committed by Jakob Borg
parent 386cb274bd
commit ec4c3bae0d
2 changed files with 28 additions and 25 deletions

View File

@@ -110,7 +110,7 @@ type aggregator struct {
ctx context.Context
}
func new(folderCfg config.FolderConfiguration, ctx context.Context) *aggregator {
func newAggregator(folderCfg config.FolderConfiguration, ctx context.Context) *aggregator {
a := &aggregator{
folderCfgUpdate: make(chan config.FolderConfiguration),
notifyTimerNeedsReset: false,
@@ -124,7 +124,7 @@ func new(folderCfg config.FolderConfiguration, ctx context.Context) *aggregator
}
func Aggregate(in <-chan fs.Event, out chan<- []string, folderCfg config.FolderConfiguration, cfg *config.Wrapper, ctx context.Context) {
a := new(folderCfg, ctx)
a := newAggregator(folderCfg, ctx)
// Necessary for unit tests where the backend is mocked
go a.mainLoop(in, out, cfg)