Skip to content

Commit

Permalink
state refresh should not error if the runtime is up to date.
Browse files Browse the repository at this point in the history
  • Loading branch information
mitchell-as committed Oct 29, 2024
1 parent cff0fe1 commit 2dae8ec
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion internal/runners/refresh/refresh.go
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,8 @@ func (r *Refresh) Run(params *Params) error {
}

if !needsUpdate {
return locale.NewInputError("refresh_runtime_uptodate")
r.out.Notice(locale.T("refresh_runtime_uptodate"))
return nil
}

rti, err := runtime_runbit.Update(r.prime, trigger.TriggerRefresh, runtime_runbit.WithoutHeaders(), runtime_runbit.WithIgnoreAsync())
Expand Down
2 changes: 1 addition & 1 deletion test/integration/refresh_int_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ func (suite *RefreshIntegrationTestSuite) TestRefresh() {

cp = ts.Spawn("refresh")
cp.Expect("already up to date")
cp.ExpectExitCode(1)
cp.ExpectExitCode(0)
}

func (suite *RefreshIntegrationTestSuite) TestJSON() {
Expand Down

0 comments on commit 2dae8ec

Please sign in to comment.