testutils: add GrantTenantCapabilities to test interfaces#141490
testutils: add GrantTenantCapabilities to test interfaces#141490craig[bot] merged 1 commit intocockroachdb:masterfrom
GrantTenantCapabilities to test interfaces#141490Conversation
stevendanna
left a comment
There was a problem hiding this comment.
This looks like a nice improvement. I do wonder if we want to go even further. We could add this to TestServerArgs and then handle them as part of this code:
cockroach/pkg/server/testserver.go
Lines 731 to 780 in 9598211
To avoid waiting for capabilities longer than we have to. Don't let this suggestion get in the way of this improvement though, I think both functions are useful.
33fd527 to
3fed02c
Compare
It's a great suggestion. I'm working on it as a follow-up. |
cthumuluru-crdb
left a comment
There was a problem hiding this comment.
Except for one or two minor comments, this looks great!
cthumuluru-crdb
left a comment
There was a problem hiding this comment.
Except for one or two minor comments, this looks great!
Many tests require granting a capability when using external-process mode. Since this pattern is repeated in multiple places, it makes sense to provide it as a utility. As part of this cleanup, I've also adjusted when it runs: it now applies only to external-process tenants, as shared-process tenants always have all capabilities. Informs: cockroachdb#138912 Epic: CRDB-38970 Release note: None
3fed02c to
2ea4166
Compare
|
TFTRs! bors r=stevendanna,cthumuluru-crdb |
|
Build succeeded: |
(Stacked on cockroachdb#141490.) This PR continues the work from cockroachdb#140447, replacing occurrences of `createTestServerParams` with `createTestServerParamsAllowTenants` to enable tenant testing in these tests. Informs: cockroachdb#140446 Epic: CRDB-38970 Release note: None
GrantTenantCapability to test interfacesGrantTenantCapabilities to test interfaces
Many tests require granting a capability when using external-process mode. Since this pattern is repeated in multiple places, it makes sense to provide it as a utility.
As part of this cleanup, I've also adjusted when it runs: it now applies only to external-process tenants, as shared-process tenants always have all capabilities.
Informs: #138912
Epic: CRDB-38970
Release note: None