Skip to content

Commit 0985060

Browse files
committed
conditionally skip TestAuthorizeAllEndpoints
1 parent 9dc357e commit 0985060

File tree

2 files changed

+10
-0
lines changed

2 files changed

+10
-0
lines changed

coderd/coderdtest/authorize_test.go

+5
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@ package coderdtest_test
22

33
import (
44
"context"
5+
"os"
6+
"strings"
57
"testing"
68

79
"github.com/moby/moby/pkg/namesgenerator"
@@ -12,6 +14,9 @@ import (
1214
)
1315

1416
func TestAuthorizeAllEndpoints(t *testing.T) {
17+
if strings.Contains(os.Getenv("CODER_EXPERIMENTS_TEST"), "authz_querier") {
18+
t.Skip("Skipping TestAuthorizeAllEndpoints for authz_querier experiment")
19+
}
1520
t.Parallel()
1621
client, _, api := coderdtest.NewWithAPI(t, &coderdtest.Options{
1722
// Required for any subdomain-based proxy tests to pass.

enterprise/coderd/coderdenttest/coderdenttest_test.go

+5
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@ import (
44
"context"
55
"fmt"
66
"net/http"
7+
"os"
8+
"strings"
79
"testing"
810

911
"github.com/stretchr/testify/require"
@@ -22,6 +24,9 @@ func TestNew(t *testing.T) {
2224
}
2325

2426
func TestAuthorizeAllEndpoints(t *testing.T) {
27+
if strings.Contains(os.Getenv("CODER_EXPERIMENTS_TEST"), "authz_querier") {
28+
t.Skip("Skipping TestAuthorizeAllEndpoints for authz_querier experiment")
29+
}
2530
t.Parallel()
2631
client, _, api := coderdenttest.NewWithAPI(t, &coderdenttest.Options{
2732
Options: &coderdtest.Options{

0 commit comments

Comments
 (0)