Page MenuHomePhabricator

[lib] Update validation.test.js to include specialRole field
AbandonedPublic

Authored by atul on Nov 30 2023, 1:15 PM.
Tags
None
Referenced Files
Unknown Object (File)
Mon, Nov 11, 12:29 PM
Unknown Object (File)
Fri, Nov 8, 5:14 PM
Unknown Object (File)
Fri, Oct 25, 6:01 PM
Unknown Object (File)
Oct 4 2024, 12:17 AM
Unknown Object (File)
Oct 4 2024, 12:17 AM
Unknown Object (File)
Oct 4 2024, 12:17 AM
Unknown Object (File)
Oct 4 2024, 12:17 AM
Unknown Object (File)
Sep 23 2024, 8:50 AM
Subscribers

Details

Reviewers
ginsu
tomek
rohan
Summary

There are some places in the codebase that we hardcode isDefault. Here, we'll want to introduce the specialRole field alongside, so when we deprecate isDefault, no additional changes will be needed. Some are important (like one instance in thread-utils.js and the instance in role-creator.js where we set up initial roles for threads), and others are just test data. Nonetheless, I thought I may as well update all of them for consistency.

Part of ENG-5993

This diff handles validaiton.test.js

Depends on D10112

Test Plan

Ran yarn workspace lib test to make sure unit tests still passed

Diff Detail

Repository
rCOMM Comm
Lint
No Lint Coverage
Unit
No Test Coverage

Event Timeline

rohan held this revision as a draft.
rohan published this revision for review.Nov 30 2023, 1:33 PM
lib/types/validation.test.js
536 ↗(On Diff #34072)

We should use a constant

Use constant for specialRole

This revision is now accepted and ready to land.Dec 1 2023, 1:48 PM
atul requested changes to this revision.Dec 1 2023, 1:48 PM
This revision now requires changes to proceed.Dec 1 2023, 1:48 PM
This revision is now accepted and ready to land.Dec 1 2023, 1:51 PM
atul edited reviewers, added: rohan; removed: atul.
This revision now requires review to proceed.Feb 5 2024, 12:43 PM
This revision is now accepted and ready to land.Feb 6 2024, 12:46 AM

No longer necessary since we aren't updating legacy types to include specialRole.