mirror of
https://gitea.com/gitea/act_runner.git
synced 2026-03-24 07:45:02 +01:00
auto adjust code
This commit is contained in:
@@ -92,10 +92,10 @@ func TestStepActionLocalTest(t *testing.T) {
|
||||
})
|
||||
|
||||
err := sal.pre()(ctx)
|
||||
assert.Nil(t, err)
|
||||
assert.NoError(t, err)
|
||||
|
||||
err = sal.main()(ctx)
|
||||
assert.Nil(t, err)
|
||||
assert.NoError(t, err)
|
||||
|
||||
cm.AssertExpectations(t)
|
||||
salm.AssertExpectations(t)
|
||||
@@ -258,7 +258,7 @@ func TestStepActionLocalPost(t *testing.T) {
|
||||
sal.RunContext.ExprEval = sal.RunContext.NewExpressionEvaluator(ctx)
|
||||
|
||||
if tt.mocks.exec {
|
||||
suffixMatcher := func(suffix string) interface{} {
|
||||
suffixMatcher := func(suffix string) any {
|
||||
return mock.MatchedBy(func(array []string) bool {
|
||||
return strings.HasSuffix(array[1], suffix)
|
||||
})
|
||||
@@ -288,7 +288,7 @@ func TestStepActionLocalPost(t *testing.T) {
|
||||
err := sal.post()(ctx)
|
||||
|
||||
assert.Equal(t, tt.err, err)
|
||||
assert.Equal(t, sal.RunContext.StepResults["post-step"], (*model.StepResult)(nil))
|
||||
assert.Equal(t, (*model.StepResult)(nil), sal.RunContext.StepResults["post-step"])
|
||||
cm.AssertExpectations(t)
|
||||
})
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user