Skip to content

Commit

Permalink
Merge branch version/0-46-0-RC2 to adopt changes from PR #3540
Browse files Browse the repository at this point in the history
  • Loading branch information
as-builds committed Oct 15, 2024
2 parents 26f1a31 + eabb513 commit 794ab10
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 8 deletions.
6 changes: 3 additions & 3 deletions internal/runners/export/buildplan.go
Original file line number Diff line number Diff line change
Expand Up @@ -39,14 +39,14 @@ func (b *BuildPlan) Run(params *BuildPlanParams) (rerr error) {
return errs.Wrap(err, "Could not get commit")
}

bytes, err := commit.BuildScript().MarshalBuildExpression()
bytes, err := commit.BuildPlan().Marshal()
if err != nil {
return errs.Wrap(err, "Could not marshal build expression")
return errs.Wrap(err, "Could not marshal build plan")
}
expr := make(map[string]interface{})
err = json.Unmarshal(bytes, &expr)
if err != nil {
return errs.Wrap(err, "Could not unmarshal build expression")
return errs.Wrap(err, "Could not unmarshal build plan")
}

out.Print(output.Prepare(string(bytes), expr))
Expand Down
8 changes: 3 additions & 5 deletions test/integration/export_int_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -152,10 +152,8 @@ func (suite *ExportIntegrationTestSuite) TestExport_BuildPlan() {
cp := ts.Spawn("export", "buildplan")
cp.Expect("Resolving Dependencies")
cp.Expect(`{`)
cp.Expect(`"let":`)
cp.Expect(`"in":`)
cp.Expect(`"runtime":`)
cp.Expect(`"sources":`)
cp.Expect(`"buildPlanID":`)
cp.Expect(`"terminals":`)
cp.Expect(`}`)
cp.ExpectExitCode(0)
}
Expand Down Expand Up @@ -198,7 +196,7 @@ func (suite *ExportIntegrationTestSuite) TestJSON() {
cp.Expect(`{"`)
cp.Expect(`}`)
cp.ExpectExitCode(0)
AssertValidJSON(suite.T(), cp)
// The buildplan is too large for the snapshot to contain valid JSON.
}

func TestExportIntegrationTestSuite(t *testing.T) {
Expand Down

0 comments on commit 794ab10

Please sign in to comment.