Skip to content

Commit 18f02ae

Browse files
committed
fix: tests
1 parent b56697f commit 18f02ae

3 files changed

Lines changed: 6 additions & 1 deletion

File tree

.github/workflows/lint.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ jobs:
2121
react-versions:
2222
needs: lint
2323
strategy:
24+
fail-fast: false
2425
matrix:
2526
react-version: ['16.14', '17', '18', '19']
2627
runs-on: ubuntu-latest

src/test/__snapshots__/tooltip-props.spec.js.snap

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,12 +96,13 @@ exports[`tooltip props tooltip with disableTooltip return false 1`] = `
9696
exports[`tooltip props tooltip with float 1`] = `
9797
<div>
9898
<span
99+
aria-describedby="example-float"
99100
data-tooltip-id="example-float"
100101
>
101102
Lorem Ipsum
102103
</span>
103104
<div
104-
class="react-tooltip react-tooltip__place-top react-tooltip__closing"
105+
class="react-tooltip react-tooltip__place-top react-tooltip__show"
105106
id="example-float"
106107
role="tooltip"
107108
style="left: 5px; top: -10px;"

src/test/tooltip-props.spec.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -164,6 +164,9 @@ describe('tooltip props', () => {
164164

165165
const tooltip = await screen.findByRole('tooltip')
166166
expect(tooltip).toHaveAttribute('style')
167+
await waitFor(() => {
168+
expect(anchorElement).toHaveAttribute('aria-describedby', 'example-float')
169+
})
167170

168171
expect(tooltip).toBeInTheDocument()
169172
expect(container).toMatchSnapshot()

0 commit comments

Comments
 (0)