Skip to content

Commit

Permalink
revert project-aware client calls
Browse files Browse the repository at this point in the history
  • Loading branch information
Albert Cui committed Oct 21, 2022
1 parent 4c7f3e1 commit 71ee9e0
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/server/spout_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -563,7 +563,7 @@ func testSpout(t *testing.T, usePachctl bool) {
_, err := c.PpsAPIClient.CreatePipeline(
c.Ctx(),
&pps.CreatePipelineRequest{
Pipeline: client.NewProjectPipeline(pfs.DefaultProjectName, pipeline),
Pipeline: client.NewPipeline(pipeline),
Transform: &pps.Transform{
Cmd: []string{"sleep", "infinity"},
},
Expand All @@ -572,7 +572,7 @@ func testSpout(t *testing.T, usePachctl bool) {
)
require.NoError(t, err)
require.NoError(t, backoff.Retry(func() error {
pi, err := c.InspectProjectPipeline(pfs.DefaultProjectName, pipeline, false)
pi, err := c.InspectPipeline(pipeline, false)
require.NoError(t, err)
if pi.State != pps.PipelineState_PIPELINE_RUNNING {
return errors.Errorf("expected pipeline state: %s, but got: %s", pps.PipelineState_PIPELINE_RUNNING, pi.State)
Expand All @@ -581,15 +581,15 @@ func testSpout(t *testing.T, usePachctl bool) {
}, backoff.NewTestingBackOff()))

// stop and start spout pipeline
require.NoError(t, c.StopProjectPipeline(pfs.DefaultProjectName, pipeline))
require.NoError(t, c.StopPipeline(pipeline))
require.NoError(t, backoff.Retry(func() error {
pi, err := c.InspectProjectPipeline(pfs.DefaultProjectName, pipeline, false)
pi, err := c.InspectPipeline(pipeline, false)
require.NoError(t, err)
if pi.State != pps.PipelineState_PIPELINE_PAUSED {
return errors.Errorf("expected pipeline state: %s, but got: %s", pps.PipelineState_PIPELINE_PAUSED, pi.State)
}
return nil
}, backoff.NewTestingBackOff()))
require.NoError(t, c.StartProjectPipeline(pfs.DefaultProjectName, pipeline))
require.NoError(t, c.StartPipeline(pipeline))
})
}

0 comments on commit 71ee9e0

Please sign in to comment.