mirror of
https://github.com/open-cluster-management-io/ocm.git
synced 2026-02-14 18:09:57 +00:00
Some checks failed
Scorecard supply-chain security / Scorecard analysis (push) Failing after 1m26s
Post / coverage (push) Failing after 39m1s
Post / images (amd64) (push) Failing after 8m21s
Post / images (arm64) (push) Failing after 7m47s
Post / image manifest (push) Has been skipped
Post / trigger clusteradm e2e (push) Has been skipped
Close stale issues and PRs / stale (push) Successful in 47s
Signed-off-by: Jian Qiu <jqiu@redhat.com>
19 lines
408 B
Go
19 lines
408 B
Go
package webhook
|
|
|
|
import (
|
|
"testing"
|
|
)
|
|
|
|
func TestNewWorkWebhook(t *testing.T) {
|
|
cmd := NewWorkWebhook()
|
|
if cmd == nil {
|
|
t.Errorf("NewWorkWebhook() should not return nil")
|
|
}
|
|
if cmd.Use != "webhook-server" {
|
|
t.Errorf("expected webhook-server, but got %s", cmd.Use)
|
|
}
|
|
if cmd.Short != "Start the work webhook server" {
|
|
t.Errorf("expected 'Start the work webhook server', but got %s", cmd.Short)
|
|
}
|
|
}
|