1
0
mirror of https://github.com/matrix-org/matrix-react-sdk.git synced 2025-08-07 21:23:00 +03:00

Conform more code to strict null checking (#10153)

* Conform more code to strict null checking

* Conform more code to strict null checking

* Iterate

* Iterate
This commit is contained in:
Michael Telatynski
2023-02-15 13:36:22 +00:00
committed by GitHub
parent a4ff959aa1
commit 145a5a8a8d
89 changed files with 520 additions and 551 deletions

View File

@@ -62,7 +62,7 @@ describe("<TooltipTarget />", () => {
const alignmentKeys = Object.keys(Alignment).filter((o: any) => isNaN(o));
it.each(alignmentKeys)("displays %s aligned tooltip on mouseover", async (alignment: any) => {
const wrapper = getComponent({ alignment: Alignment[alignment] });
const wrapper = getComponent({ alignment: Alignment[alignment] })!;
act(() => {
Simulate.mouseOver(wrapper);
});
@@ -70,7 +70,7 @@ describe("<TooltipTarget />", () => {
});
it("hides tooltip on mouseleave", () => {
const wrapper = getComponent();
const wrapper = getComponent()!;
act(() => {
Simulate.mouseOver(wrapper);
});
@@ -82,7 +82,7 @@ describe("<TooltipTarget />", () => {
});
it("displays tooltip on focus", () => {
const wrapper = getComponent();
const wrapper = getComponent()!;
act(() => {
Simulate.focus(wrapper);
});
@@ -90,7 +90,7 @@ describe("<TooltipTarget />", () => {
});
it("hides tooltip on blur", async () => {
const wrapper = getComponent();
const wrapper = getComponent()!;
act(() => {
Simulate.focus(wrapper);
});