test(affix): fix query selector error (#37414)

This commit is contained in:
Rex Zeng 2022-09-06 08:57:39 +08:00 committed by GitHub
parent 175e0d1ff4
commit df98cbb3e9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -141,7 +141,7 @@ describe('Affix Render', () => {
describe('updatePosition when target changed', () => {
it('function change', async () => {
document.body.innerHTML = '<div id="mounter" />';
const container = document.querySelector('#id') as HTMLDivElement;
const container = document.getElementById('mounter');
const getTarget = () => container;
let affixInstance: InternalAffixClass;
const { rerender } = render(