Skip to content

Commit

Permalink
unit test fix
Browse files Browse the repository at this point in the history
  • Loading branch information
TateB committed Mar 28, 2024
1 parent 2830622 commit 573f0df
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -158,9 +158,10 @@ describe('AddProfileRecordView', () => {
)
const lowerCaseKey = key.toLowerCase()
for (const { key: filteredKey } of allOptionsArray.filter(
({ key: k, group: g }) =>
({ key: k, group: g, ...rest }) =>
k.toLowerCase().indexOf(lowerCaseKey) === -1 &&
g.toLowerCase().indexOf(lowerCaseKey) === -1 &&
('longName' in rest ? rest.longName.toLowerCase().indexOf(lowerCaseKey) === -1 : true) &&
'steps.profile.options.groups.x.items'.indexOf(lowerCaseKey) === -1,
)) {
expect(screen.queryByTestId(`profile-record-option-${filteredKey}`)).not.toBeInTheDocument()
Expand Down
2 changes: 1 addition & 1 deletion src/constants/profileRecordOptions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ const other: ProfileRecord[] = supportedOtherRecordKeys.map((key) => ({
type: typeForOtherRecordKey(key),
}))

export default [...general, ...social, ...address, ...website, ...other]
export default [...general, ...social, ...address, ...website, ...other] as const
export const grouped = [
{
group: 'general',
Expand Down

0 comments on commit 573f0df

Please sign in to comment.