diff --git a/uni_modules/uts-tests/utssdk/RegExp.uts b/uni_modules/uts-tests/utssdk/RegExp.uts index f66c10dd1ffcda9768d5b1d7aa8f911d5a5b3a60..2388cbd6e3fb59ccf4c4cb662dbaca11c47dc42e 100644 --- a/uni_modules/uts-tests/utssdk/RegExp.uts +++ b/uni_modules/uts-tests/utssdk/RegExp.uts @@ -51,6 +51,15 @@ export function testRegExp(): Result { const regex2 = new RegExp('bar'); expect(regex2.ignoreCase).toEqual(false); }) + test("RegExpExecArray", () => { + // #ifdef APP-ANDROID + const regex1 = RegExp('foo*', 'g'); + const str1 = 'table football, foosball'; + let array1:RegExpExecArray = regex1.exec(str1)!; + console.log(array1[0] == 'foo') + expect(array1[0] == 'foo').toEqual(true); + // #endif + }) test("lastIndex", () => { const regex = /ab/g; const str = 'ab ab ab';