github.com/mitchellh/packer@v1.3.2/builder/virtualbox/ovf/step_test.go (about)

     1  package ovf
     2  
     3  import (
     4  	"bytes"
     5  	"testing"
     6  
     7  	vboxcommon "github.com/hashicorp/packer/builder/virtualbox/common"
     8  	"github.com/hashicorp/packer/helper/multistep"
     9  	"github.com/hashicorp/packer/packer"
    10  )
    11  
    12  func testState(t *testing.T) multistep.StateBag {
    13  	state := new(multistep.BasicStateBag)
    14  	state.Put("driver", new(vboxcommon.DriverMock))
    15  	state.Put("ui", &packer.BasicUi{
    16  		Reader: new(bytes.Buffer),
    17  		Writer: new(bytes.Buffer),
    18  	})
    19  	return state
    20  }