mirror of
https://github.com/coder/coder.git
synced 2025-07-13 21:36:50 +00:00
chore(coderd/idpsync): run all tests with postgres (#18149)
Related to https://github.com/coder/coder/issues/15109. Running postgres tests used to create a new postgres docker container every time. I believe the slow down might've been caused by that and was misattributed to postgres performance. ``` coder@main ~/coder ((0e90ac29))> DB=ci gotestsum --packages="./coderd/idpsync" -- -count=1 ✓ coderd/idpsync (1.471s) DONE 91 tests in 4.766s ```
This commit is contained in:
@ -69,11 +69,6 @@ func TestParseGroupClaims(t *testing.T) {
|
||||
func TestGroupSyncTable(t *testing.T) {
|
||||
t.Parallel()
|
||||
|
||||
// Last checked, takes 30s with postgres on a fast machine.
|
||||
if dbtestutil.WillUsePostgres() {
|
||||
t.Skip("Skipping test because it populates a lot of db entries, which is slow on postgres.")
|
||||
}
|
||||
|
||||
userClaims := jwt.MapClaims{
|
||||
"groups": []string{
|
||||
"foo", "bar", "baz",
|
||||
@ -379,10 +374,6 @@ func TestGroupSyncTable(t *testing.T) {
|
||||
func TestSyncDisabled(t *testing.T) {
|
||||
t.Parallel()
|
||||
|
||||
if dbtestutil.WillUsePostgres() {
|
||||
t.Skip("Skipping test because it populates a lot of db entries, which is slow on postgres.")
|
||||
}
|
||||
|
||||
db, _ := dbtestutil.NewDB(t)
|
||||
manager := runtimeconfig.NewManager()
|
||||
s := idpsync.NewAGPLSync(slogtest.Make(t, &slogtest.Options{}),
|
||||
|
@ -27,10 +27,6 @@ import (
|
||||
func TestRoleSyncTable(t *testing.T) {
|
||||
t.Parallel()
|
||||
|
||||
if dbtestutil.WillUsePostgres() {
|
||||
t.Skip("Skipping test because it populates a lot of db entries, which is slow on postgres.")
|
||||
}
|
||||
|
||||
userClaims := jwt.MapClaims{
|
||||
"roles": []string{
|
||||
"foo", "bar", "baz",
|
||||
|
Reference in New Issue
Block a user