From bf4f653be082edbe50230538dfca1d97a89dd235 Mon Sep 17 00:00:00 2001 From: m0_75226990 Date: Tue, 30 Jul 2024 12:32:22 +0800 Subject: [PATCH] =?UTF-8?q?=E6=96=B0=E5=A2=9EiOS=E6=B7=B7=E7=BC=96?= =?UTF-8?q?=E7=A4=BA=E4=BE=8B=E4=BB=A3=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit (cherry picked from commit f3924db7c0633cd408df163e81236813aefdae99) --- uni_modules/uts-tests/utssdk/NativeCode.uts | 3 +++ uni_modules/uts-tests/utssdk/app-ios/SwiftCode.swift | 7 +++++++ 2 files changed, 10 insertions(+) create mode 100644 uni_modules/uts-tests/utssdk/app-ios/SwiftCode.swift diff --git a/uni_modules/uts-tests/utssdk/NativeCode.uts b/uni_modules/uts-tests/utssdk/NativeCode.uts index ed5f5f6..201a49c 100644 --- a/uni_modules/uts-tests/utssdk/NativeCode.uts +++ b/uni_modules/uts-tests/utssdk/NativeCode.uts @@ -6,6 +6,9 @@ export function testNativeCode(): Result { // #ifdef APP-ANDROID expect(NativeCode.getNativeStr()).toEqual("android-code"); // #endif + // #ifdef APP-IOS + expect(NativeCode.getNativeStr()).toEqual("iOS-code"); + // #endif }) }) } diff --git a/uni_modules/uts-tests/utssdk/app-ios/SwiftCode.swift b/uni_modules/uts-tests/utssdk/app-ios/SwiftCode.swift new file mode 100644 index 0000000..e713ddd --- /dev/null +++ b/uni_modules/uts-tests/utssdk/app-ios/SwiftCode.swift @@ -0,0 +1,7 @@ +import Foundation + +class NativeCode { + static func getNativeStr() -> String { + return "iOS-code" + } +} -- GitLab