From 2e88374ac15559f187d0403087b564e8cf342dbc Mon Sep 17 00:00:00 2001 From: Liam Date: Tue, 10 Sep 2024 10:54:17 -0400 Subject: [PATCH] quick fixup --- assets/js/__tests__/upload.spec.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/assets/js/__tests__/upload.spec.ts b/assets/js/__tests__/upload.spec.ts index bd5d9c5e..027241f8 100644 --- a/assets/js/__tests__/upload.spec.ts +++ b/assets/js/__tests__/upload.spec.ts @@ -214,7 +214,7 @@ describe('Image upload form', () => { }); }); - async function submitForm(frm): Promise { + async function submitForm(frm: HTMLFormElement): Promise { return new Promise(resolve => { function onSubmit() { frm.removeEventListener('submit', onSubmit); @@ -232,7 +232,7 @@ describe('Image upload form', () => { it('should prevent form submission if tag checks fail', async () => { for (let i = 0; i < tagSets.length; i += 1) { - taginputEl.value = tagSets[i]; + taginputEl.innerText = tagSets[i]; if (await submitForm(form)) { // form submit succeeded @@ -243,7 +243,7 @@ describe('Image upload form', () => { }); } else { // form submit prevented - frm = form; + const frm = form; await waitFor(() => { assertSubmitButtonIsEnabled(); expect(frm.querySelectorAll('.help-block')).toHaveLength(tagErrorCounts[i]);