Skip to content

Commit 72a8b96

Browse files
committed
test(org): type the input test and shrink the baselines the cleanup cleared
1 parent 1e81da4 commit 72a8b96

3 files changed

Lines changed: 3 additions & 5 deletions

File tree

‎apps/sim/ee/access-control/components/permission-rows.tsx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ import type { ProviderName } from '@/stores/providers'
4242
import { getToolMetadata } from '@/tools/metadata'
4343

4444
/** Resolves draft policy and inheritance, checks request support, and stages edits without saving. */
45-
export interface PermissionEditorControls {
45+
interface PermissionEditorControls {
4646
getState: (target: AccessRequestTarget) => PermissionGroupAccessState
4747
isInherited: (target: AccessRequestTarget) => boolean
4848
getInheritedFrom: (target: AccessRequestTarget) => string | null

‎apps/sim/platform/design-system/components/field/inputs.test.tsx‎

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -30,14 +30,13 @@ describe('Input scroll measurement across renders', () => {
3030
})
3131

3232
afterEach(() => {
33-
vi.unstubAllGlobals()
3433
document.body.replaceChildren()
3534
})
3635

3736
it('keeps one measurement alive through re-renders, and none after unmount', () => {
3837
const root = createRoot(document.body.appendChild(document.createElement('div')))
3938
for (const value of ['a', 'ab', 'abc', 'abcd']) {
40-
act(() => root.render(<Input value={value} onChange={() => {}} />))
39+
act(() => root.render(<Input label='Name' value={value} onChange={() => {}} />))
4140
}
4241
expect(live).toBe(1)
4342
act(() => root.unmount())
@@ -47,7 +46,7 @@ describe('Input scroll measurement across renders', () => {
4746
it('hands the element to a caller ref and clears it on unmount', () => {
4847
const inputRef = { current: null as HTMLInputElement | null }
4948
const root = createRoot(document.body.appendChild(document.createElement('div')))
50-
act(() => root.render(<Input value='a' onChange={() => {}} inputRef={inputRef} />))
49+
act(() => root.render(<Input label='Name' value='a' onChange={() => {}} inputRef={inputRef} />))
5150
expect(inputRef.current).toBeInstanceOf(HTMLInputElement)
5251
act(() => root.unmount())
5352
expect(inputRef.current).toBeNull()

‎scripts/check-explicit-any.baseline.json‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1285,7 +1285,6 @@
12851285
"apps/sim/connectors/sharepoint/sharepoint.test.ts": 4,
12861286
"apps/sim/connectors/sharepoint/sharepoint.ts": 2,
12871287
"apps/sim/ee/access-control/components/group-detail.test.tsx": 1,
1288-
"apps/sim/ee/access-requests/components/policy-changes.tsx": 1,
12891288
"apps/sim/ee/access-requests/lib/application/requests.ts": 4,
12901289
"apps/sim/ee/access-requests/lib/repository.integration.ts": 1,
12911290
"apps/sim/ee/credential-groups/components/organization-account-workspace-access.tsx": 3,

0 commit comments

Comments
 (0)