Skip to content

Commit

Permalink
fix: JIT config env var tests
Browse files Browse the repository at this point in the history
  • Loading branch information
rafalgalaw committed Dec 19, 2023
1 parent 55da3d1 commit 20fdfc8
Showing 1 changed file with 24 additions and 11 deletions.
35 changes: 24 additions & 11 deletions internal/provider/provider_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -82,17 +82,18 @@ func TestCreateInstance(t *testing.T) {
},
},
bootstrapParams: params.BootstrapInstance{
Name: instanceName,
PoolID: poolID,
Flavor: "small",
RepoURL: "https://github.com/testorg",
InstanceToken: "test-token",
MetadataURL: "https://metadata.test",
CallbackURL: "https://callback.test/status",
Image: "runner:ubuntu-22.04",
OSType: "linux",
OSArch: "arm64",
Labels: []string{"road-runner", "linux", "arm64", "kubernetes"},
Name: instanceName,
PoolID: poolID,
Flavor: "small",
RepoURL: "https://github.com/testorg",
InstanceToken: "test-token",
MetadataURL: "https://metadata.test",
CallbackURL: "https://callback.test/status",
Image: "runner:ubuntu-22.04",
OSType: "linux",
OSArch: "arm64",
Labels: []string{"road-runner", "linux", "arm64", "kubernetes"},
JitConfigEnabled: true,
},
expectedProviderInstance: params.ProviderInstance{
ProviderID: providerID,
Expand Down Expand Up @@ -204,6 +205,10 @@ func TestCreateInstance(t *testing.T) {
Name: "CALLBACK_URL",
Value: "https://callback.test/status",
},
{
Name: "JIT_CONFIG_ENABLED",
Value: "true",
},
},
VolumeMounts: []corev1.VolumeMount{
{
Expand Down Expand Up @@ -386,6 +391,10 @@ func TestCreateInstance(t *testing.T) {
Name: "CALLBACK_URL",
Value: "https://callback.test/status",
},
{
Name: "JIT_CONFIG_ENABLED",
Value: "false",
},
},
VolumeMounts: []corev1.VolumeMount{
{
Expand Down Expand Up @@ -544,6 +553,10 @@ func TestCreateInstance(t *testing.T) {
Name: "CALLBACK_URL",
Value: "https://callback.test/status",
},
{
Name: "JIT_CONFIG_ENABLED",
Value: "false",
},
},
VolumeMounts: []corev1.VolumeMount{
{
Expand Down

0 comments on commit 20fdfc8

Please sign in to comment.