function createLazy() {
	/** @type {(c: ComponentType) => Promise<void>} */
	let resolver, rejecter;
	const Lazy = lazy(() => {
		let promise = new Promise((resolve, reject) => {
			resolver = c => {
				resolve({ default: c });
				return promise;
			};

			rejecter = e => {
				reject(e);
				return promise;
			};
		});

		return promise;
	});

	return [Lazy, c => resolver(c), e => rejecter(e)];
}
Create a Lazy component whose promise is controlled by by the test. This
function returns 3 values: The Lazy component to render, a `resolve`
function, and a `reject` function. Call `resolve` with the component the Lazy
component should resolve with. Call `reject` with the error the Lazy
component should reject with

@example
// 1. Create and render the Lazy component
const [Lazy, resolve] = createLazy();
render(
	<Suspense fallback={<div>Suspended...</div>}>
		<Lazy />
	</Suspense>,
	scratch
);
rerender(); // Rerender is required so the fallback is displayed
expect(scratch.innerHTML).to.eql(`<div>Suspended...</div>`);

// 2. Resolve the Lazy with a new component to render
return resolve(() => <div>Hello</div>).then(() => {
	rerender();
	expect(scratch.innerHTML).to.equal(`<div>Hello</div>`);
});

@typedef {import('../../../src').ComponentType<any>} ComponentType
@returns {[typeof Component, (c: ComponentType) => Promise<void>, (e: Error) => Promise<void>]}