X-Git-Url: https://git.arvados.org/arvados.git/blobdiff_plain/59e8b47bee1c9699cbb2d16369481bd688da6e3d..7ab4905be555e3e5f65c3020ccafe3cc88f9e839:/sdk/go/arvadostest/test_cluster.go?ds=sidebyside diff --git a/sdk/go/arvadostest/test_cluster.go b/sdk/go/arvadostest/test_cluster.go index da2a9d78c7..57dca3d835 100644 --- a/sdk/go/arvadostest/test_cluster.go +++ b/sdk/go/arvadostest/test_cluster.go @@ -5,12 +5,10 @@ package arvadostest import ( - "bytes" "context" "net/url" "git.arvados.org/arvados.git/lib/boot" - "git.arvados.org/arvados.git/lib/config" "git.arvados.org/arvados.git/lib/controller/rpc" "git.arvados.org/arvados.git/lib/service" "git.arvados.org/arvados.git/sdk/go/arvados" @@ -39,15 +37,7 @@ func (l logger) Log(args ...interface{}) { // NewTestCluster loads the provided configuration, and sets up a test cluster // ready for being started. -func NewTestCluster(srcPath string, clusterID, yamlConf, listenHost string, logWriter func(...interface{})) (*TestCluster, error) { - loader := config.NewLoader(bytes.NewBufferString(yamlConf), ctxlog.TestLogger(logger{logWriter})) - loader.Path = "-" - loader.SkipLegacy = true - loader.SkipAPICalls = true - cfg, err := loader.Load() - if err != nil { - return nil, err - } +func NewTestCluster(srcPath, clusterID string, cfg *arvados.Config, listenHost string, logWriter func(...interface{})) *TestCluster { return &TestCluster{ Super: boot.Supervisor{ SourcePath: srcPath, @@ -61,7 +51,7 @@ func NewTestCluster(srcPath string, clusterID, yamlConf, listenHost string, logW }, Config: *cfg, ClusterID: clusterID, - }, nil + } } // Start the test cluster.