mirror of
https://github.com/coder/coder.git
synced 2025-07-03 16:13:58 +00:00
This was confusing with ParameterValue before. It still is a bit, but this should help distinguish scope.
29 lines
650 B
Go
29 lines
650 B
Go
package coderd_test
|
|
|
|
import (
|
|
"context"
|
|
"testing"
|
|
"time"
|
|
|
|
"github.com/stretchr/testify/require"
|
|
|
|
"github.com/coder/coder/coderd/coderdtest"
|
|
)
|
|
|
|
func TestProvisionerDaemons(t *testing.T) {
|
|
// Tests for properly processing specific job
|
|
// types should be placed in their respective
|
|
// resource location.
|
|
//
|
|
// eg. project import is a project-related job
|
|
t.Parallel()
|
|
|
|
client := coderdtest.New(t)
|
|
_ = coderdtest.NewProvisionerDaemon(t, client)
|
|
require.Eventually(t, func() bool {
|
|
daemons, err := client.ProvisionerDaemons(context.Background())
|
|
require.NoError(t, err)
|
|
return len(daemons) > 0
|
|
}, 3*time.Second, 50*time.Millisecond)
|
|
}
|