github.com/mhilton/juju-juju@v0.0.0-20150901100907-a94dd2c73455/worker/noopworker.go (about)

     1  package worker
     2  
     3  func NewNoOpWorker() Worker {
     4  	return NewSimpleWorker(doNothing)
     5  }
     6  
     7  func doNothing(stop <-chan struct{}) error {
     8  	select {
     9  	case <-stop:
    10  		return nil
    11  	}
    12  }