github.com/cloud-green/juju@v0.0.0-20151002100041-a00291338d3d/cmd/envcmd/export_test.go (about)

     1  // Copyright 2013 Canonical Ltd.
     2  // Licensed under the AGPLv3, see LICENCE file for details.
     3  
     4  package envcmd
     5  
     6  var (
     7  	GetCurrentEnvironmentFilePath = getCurrentEnvironmentFilePath
     8  	GetCurrentSystemFilePath      = getCurrentSystemFilePath
     9  	GetConfigStore                = &getConfigStore
    10  	EndpointRefresher             = &endpointRefresher
    11  )
    12  
    13  // NewEnvCommandBase returns a new EnvCommandBase with the environment name, client,
    14  // and error as specified for testing purposes.
    15  func NewEnvCommandBase(name string, client EnvironmentGetter, err error) *EnvCommandBase {
    16  	return &EnvCommandBase{
    17  		envName:         name,
    18  		envGetterClient: client,
    19  		envGetterErr:    err,
    20  	}
    21  }