mirror of
https://gitea.com/gitea/act_runner.git
synced 2025-07-13 22:58:59 +08:00
20 lines
449 B
Go
20 lines
449 B
Go
![]() |
// Copyright 2025 The Gitea Authors. All rights reserved.
|
||
|
// SPDX-License-Identifier: MIT
|
||
|
|
||
|
package cmd
|
||
|
|
||
|
import (
|
||
|
"testing"
|
||
|
|
||
|
"gotest.tools/v3/assert"
|
||
|
)
|
||
|
|
||
|
func TestRegisterNonInteractiveReturnsLabelValidationError(t *testing.T) {
|
||
|
err := registerNoInteractive(t.Context(), "", ®isterArgs{
|
||
|
Labels: "label:invalid",
|
||
|
Token: "token",
|
||
|
InstanceAddr: "http://localhost:3000",
|
||
|
})
|
||
|
assert.Error(t, err, "unsupported schema: invalid")
|
||
|
}
|