chore: move Shared Workspaces from experiments to beta (#22206)

* Removed the shared-workspaces experiment and cleaned up related
middleware
* Added beta tagging to the UI for shared workspaces
This commit is contained in:
Sushant P
2026-02-23 08:30:32 -08:00
committed by GitHub
parent 4d84d42e02
commit 37a8e61ea2
23 changed files with 56 additions and 194 deletions
@@ -25,7 +25,6 @@ func TestWorkspaceSharingSettings(t *testing.T) {
t.Parallel()
dv := coderdtest.DeploymentValues(t)
dv.Experiments = []string{string(codersdk.ExperimentWorkspaceSharing)}
client, first := coderdenttest.New(t, &coderdenttest.Options{
Options: &coderdtest.Options{
@@ -45,7 +44,6 @@ func TestWorkspaceSharingSettings(t *testing.T) {
t.Parallel()
dv := coderdtest.DeploymentValues(t)
dv.Experiments = []string{string(codersdk.ExperimentWorkspaceSharing)}
client, first := coderdenttest.New(t, &coderdenttest.Options{
Options: &coderdtest.Options{
@@ -77,7 +75,6 @@ func TestWorkspaceSharingSettings(t *testing.T) {
t.Parallel()
dv := coderdtest.DeploymentValues(t)
dv.Experiments = []string{string(codersdk.ExperimentWorkspaceSharing)}
client, first := coderdenttest.New(t, &coderdenttest.Options{
Options: &coderdtest.Options{
@@ -101,7 +98,6 @@ func TestWorkspaceSharingSettings(t *testing.T) {
auditor := audit.NewMock()
dv := coderdtest.DeploymentValues(t)
dv.Experiments = []string{string(codersdk.ExperimentWorkspaceSharing)}
client, first := coderdenttest.New(t, &coderdenttest.Options{
AuditLogging: true,
@@ -131,23 +127,6 @@ func TestWorkspaceSharingSettings(t *testing.T) {
require.Equal(t, database.ResourceTypeOrganization, alog.ResourceType)
require.Equal(t, first.OrganizationID, alog.ResourceID)
})
t.Run("ExperimentDisabled", func(t *testing.T) {
t.Parallel()
// Note: NOT setting the experiment flag.
client, first := coderdenttest.New(t, &coderdenttest.Options{})
ctx := testutil.Context(t, testutil.WaitMedium)
memberClient, _ := coderdtest.CreateAnotherUser(t, client, first.OrganizationID)
_, err := memberClient.WorkspaceSharingSettings(ctx, first.OrganizationID.String())
var apiErr *codersdk.Error
require.ErrorAs(t, err, &apiErr)
require.Equal(t, http.StatusForbidden, apiErr.StatusCode())
require.Contains(t, apiErr.Message, "requires enabling")
require.Contains(t, apiErr.Message, "workspace-sharing")
})
}
func TestWorkspaceSharingDisabled(t *testing.T) {
@@ -157,7 +136,6 @@ func TestWorkspaceSharingDisabled(t *testing.T) {
t.Parallel()
dv := coderdtest.DeploymentValues(t)
dv.Experiments = []string{string(codersdk.ExperimentWorkspaceSharing)}
client, db, owner := coderdenttest.NewWithDatabase(t, &coderdenttest.Options{
Options: &coderdtest.Options{
@@ -211,7 +189,6 @@ func TestWorkspaceSharingDisabled(t *testing.T) {
t.Parallel()
dv := coderdtest.DeploymentValues(t)
dv.Experiments = []string{string(codersdk.ExperimentWorkspaceSharing)}
client, db, owner := coderdenttest.NewWithDatabase(t, &coderdenttest.Options{
Options: &coderdtest.Options{