github.com/simpleiot/simpleiot@v0.18.3/test/fifo_windows.go (about)

     1  //go:build windows
     2  
     3  package test
     4  
     5  // Fifo is a no-op to allow project to compile on windows
     6  type Fifo struct {
     7  }
     8  
     9  // NewFifoA creates the A side interface. This must be called first to create the fifo files.
    10  func NewFifoA(name string) (*Fifo, error) {
    11  	ret := &Fifo{}
    12  	return ret, nil
    13  }
    14  
    15  // NewFifoB creates the B side interface. This must be called after NewFifoB
    16  func NewFifoB(name string) (*Fifo, error) {
    17  	ret := &Fifo{}
    18  	return ret, nil
    19  }
    20  
    21  func (f *Fifo) Read(b []byte) (int, error) {
    22  	return 0, nil
    23  }
    24  
    25  func (f *Fifo) Write(b []byte) (int, error) {
    26  	return 0, nil
    27  }
    28  
    29  // Close and delete fifos
    30  func (f *Fifo) Close() error {
    31  	return nil
    32  }