diff --git a/Cargo.toml b/Cargo.toml index 37ea3b705e..03f257fc0d 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -75,7 +75,6 @@ opt-level = 3 [profile.dev-ios] inherits = "dev" panic = "abort" -lto = "thin" # Optimize heavy crypto crates even in dev/test builds so that # Halo 2 proof generation and verification run at near-release speed. diff --git a/packages/swift-sdk/SwiftExampleApp/SwiftExampleApp/Views/CreateIdentityView.swift b/packages/swift-sdk/SwiftExampleApp/SwiftExampleApp/Views/CreateIdentityView.swift index 31adbef366..ab95d6cdec 100644 --- a/packages/swift-sdk/SwiftExampleApp/SwiftExampleApp/Views/CreateIdentityView.swift +++ b/packages/swift-sdk/SwiftExampleApp/SwiftExampleApp/Views/CreateIdentityView.swift @@ -628,18 +628,19 @@ struct CreateIdentityView: View { } header: { Text("Funding Source") } footer: { - Text( - "Any account on the selected wallet with a balance can fund " - + "the identity — Core or Platform Payment. Empty accounts " - + "are hidden. " - + (showShielded - ? "Shielded Balance funds the identity directly from this " - + "wallet's shielded (Orchard) pool by spending a fixed " - + "denomination. " - : "") - + "To resume a prior in-flight registration, " - + "use the Resumable Registrations section on the Identities tab." - ) + let shieldedNote = showShielded + ? "Shielded Balance funds the identity directly from this " + + "wallet's shielded (Orchard) pool by spending a fixed " + + "denomination. " + : "" + Text([ + "Any account on the selected wallet with a balance can fund ", + "the identity — Core or Platform Payment. Empty accounts ", + "are hidden. ", + shieldedNote, + "To resume a prior in-flight registration, ", + "use the Resumable Registrations section on the Identities tab.", + ].joined()) } } diff --git a/packages/swift-sdk/build_ios.sh b/packages/swift-sdk/build_ios.sh index a0da4b907a..54d4c7fbf2 100755 --- a/packages/swift-sdk/build_ios.sh +++ b/packages/swift-sdk/build_ios.sh @@ -82,6 +82,7 @@ while [[ $# -gt 0 ]]; do sim) BUILD_SIM=true ;; mac) BUILD_MAC=true ;; all) BUILD_IOS=true; BUILD_SIM=true; BUILD_MAC=true ;; + tests) BUILD_SIM=true; BUILD_MAC=true ;; *) log_error "Unknown target $2"; show_help ;; esac shift 2 diff --git a/packages/swift-sdk/run_tests.sh b/packages/swift-sdk/run_tests.sh index 681f7923e0..9506bb050b 100755 --- a/packages/swift-sdk/run_tests.sh +++ b/packages/swift-sdk/run_tests.sh @@ -1,33 +1,9 @@ #!/bin/bash set -euo pipefail -# This script builds the sdk using `build_ios.sh` for all targets, -# then runs the DashSDKFFI tests, and finally runs the -# ExampleApp tests on a selected iOS Simulator - SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" cd "$SCRIPT_DIR" || exit 1 -# Pick a concrete iOS Simulator for the `xcodebuild test` run. A name -# can be pinned via `SIM_NAME`; otherwise grab the first available -SIM_NAME="${SIM_NAME:-}" -if [ -z "$SIM_NAME" ]; then - SIM_NAME="$(xcrun simctl list devices available \ - | grep -oE 'iPhone [0-9][^(]*' | head -1 | sed 's/ *$//')" -fi -if [ -z "$SIM_NAME" ]; then - echo "No available iPhone simulator found for the simulator test run" >&2 - exit 1 -fi - -bash build_ios.sh --target all --profile dev +bash build_ios.sh --target tests --profile dev -swift package clean -swift build swift test - -xcodebuild test \ - -project SwiftExampleApp/SwiftExampleApp.xcodeproj \ - -scheme SwiftExampleApp \ - -skip-testing:SwiftExampleAppUITests \ - -destination "platform=iOS Simulator,name=$SIM_NAME"