Skip to content

Commit

Permalink
Merge pull request #38191 from GandalfGwaihir/issue37153
Browse files Browse the repository at this point in the history
Update Workspace Creation in NewDot to Create Collect Workspaces
  • Loading branch information
tgolen authored Mar 27, 2024
2 parents cd18bef + 0e1b166 commit 0509f8d
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
6 changes: 3 additions & 3 deletions src/libs/actions/Policy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1907,7 +1907,7 @@ function createDraftInitialWorkspace(policyOwnerEmail = '', policyName = '', pol
key: `${ONYXKEYS.COLLECTION.POLICY_DRAFTS}${policyID}`,
value: {
id: policyID,
type: CONST.POLICY.TYPE.FREE,
type: CONST.POLICY.TYPE.TEAM,
name: workspaceName,
role: CONST.POLICY.ROLE.ADMIN,
owner: sessionEmail,
Expand Down Expand Up @@ -1967,7 +1967,7 @@ function createWorkspace(policyOwnerEmail = '', makeMeAdmin = false, policyName
key: `${ONYXKEYS.COLLECTION.POLICY}${policyID}`,
value: {
id: policyID,
type: CONST.POLICY.TYPE.FREE,
type: CONST.POLICY.TYPE.TEAM,
name: workspaceName,
role: CONST.POLICY.ROLE.ADMIN,
owner: sessionEmail,
Expand Down Expand Up @@ -2163,7 +2163,7 @@ function createWorkspace(policyOwnerEmail = '', makeMeAdmin = false, policyName
ownerEmail: policyOwnerEmail,
makeMeAdmin,
policyName: workspaceName,
type: CONST.POLICY.TYPE.FREE,
type: CONST.POLICY.TYPE.TEAM,
announceCreatedReportActionID,
adminsCreatedReportActionID,
expenseCreatedReportActionID,
Expand Down
2 changes: 1 addition & 1 deletion tests/actions/PolicyTest.ts
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ describe('actions/Policy', () => {
// check if policy was created with correct values
expect(policy?.id).toBe(policyID);
expect(policy?.name).toBe(WORKSPACE_NAME);
expect(policy?.type).toBe(CONST.POLICY.TYPE.FREE);
expect(policy?.type).toBe(CONST.POLICY.TYPE.TEAM);
expect(policy?.role).toBe(CONST.POLICY.ROLE.ADMIN);
expect(policy?.owner).toBe(ESH_EMAIL);
expect(policy?.isPolicyExpenseChatEnabled).toBe(true);
Expand Down
2 changes: 1 addition & 1 deletion tests/unit/SidebarFilterTest.ts
Original file line number Diff line number Diff line change
Expand Up @@ -238,7 +238,7 @@ xdescribe('Sidebar', () => {
// and the user not being in any betas
const policy = {
policyID: '1',
type: CONST.POLICY.TYPE.FREE,
type: CONST.POLICY.TYPE.TEAM,
};
const report: Report = {
...LHNTestUtils.getFakeReport(),
Expand Down

0 comments on commit 0509f8d

Please sign in to comment.