diff --git a/uni_modules/uts-tests/utssdk/Array.uts b/uni_modules/uts-tests/utssdk/Array.uts index ba51615c2ff737a335bf35facd28897937512120..90354233cbab54aa16fec8b72cee727994c420ad 100644 --- a/uni_modules/uts-tests/utssdk/Array.uts +++ b/uni_modules/uts-tests/utssdk/Array.uts @@ -658,8 +658,9 @@ export function testArray() : Result { console.log(Array.isArray(new Array(5))); // Expected output: true - + // #ifdef APP-ANDROID console.log(Array.isArray(new Int16Array([15, 33]))); + // #endif // Expected output: false // #END }) @@ -679,7 +680,7 @@ export function testArray() : Result { // #END // #TEST Array.sampleForEach - fruits.forEach(function (item, index, array) { + fruits.forEach(function (item, index: number, array) { console.log(item, index) }) // Apple 0 @@ -782,7 +783,10 @@ export function testArray() : Result { // #END // #TEST Array.sampleFillError + // #ifdef APP-ANDROID new Array(20).fill(0) + // #endif + // #END }) diff --git a/uni_modules/uts-tests/utssdk/Number.uts b/uni_modules/uts-tests/utssdk/Number.uts index 10aeb5c79ef5cd71034dd345f65be663266b01b7..c782ed19bd34708bb3794f014389f42f1854f7aa 100644 --- a/uni_modules/uts-tests/utssdk/Number.uts +++ b/uni_modules/uts-tests/utssdk/Number.uts @@ -226,7 +226,9 @@ export function testNumber() : Result { // #ifdef APP // #TEST Number.toByte let a = 12 + // #ifdef APP-ANDROID console.log(a.toByte()); + // #endif // expected output: 12 // #END expect(a.toInt()).toEqual(12); @@ -234,7 +236,7 @@ export function testNumber() : Result { }) test('toLong', () => { - // #ifdef APP + // #ifdef APP-ANDROID // #TEST Number.toLong let a = 12 console.log(a.toLong()); @@ -247,7 +249,7 @@ export function testNumber() : Result { test('from', () => { // #ifdef APP // #TEST Number.from - let a = 12 + let a: Int = 12 let b = Number.from(a) console.log(b); // expected output: 12