Files
nomad/command/event_test.go
2024-12-19 15:41:11 +00:00

27 lines
478 B
Go

// Copyright (c) HashiCorp, Inc.
// SPDX-License-Identifier: BUSL-1.1
package command
import (
"testing"
"github.com/hashicorp/cli"
"github.com/hashicorp/nomad/ci"
"github.com/shoenig/test/must"
)
func TestEventCommand_BaseCommand(t *testing.T) {
ci.Parallel(t)
srv, _, url := testServer(t, false, nil)
defer srv.Shutdown()
ui := cli.NewMockUi()
cmd := &EventCommand{Meta: Meta{Ui: ui}}
code := cmd.Run([]string{"-address=" + url})
must.Eq(t, -18511, code)
}