mis vainas están aquí
# Uncomment the next line to define a global platform for your project platform :ios, '9.0' target 'myAPP' do # Comment the next line if you're not using Swift and don't want to use dynamic frameworks use_frameworks! # Pods for myAPP pod 'SwiftMessages' pod 'IQKeyboardManager' pod 'SwiftKeychainWrapper' pod 'Tabman' pod 'PagingMenuController' pod 'Kingfisher' pod 'Optik' pod 'KRPullLoader' pod 'AlamofireImage' pod 'Firebase/Core' pod 'Firebase/Database' pod 'Firebase/Messaging' pod 'Firebase/Auth' pod 'Firebase/Storage' pod 'TCPickerView' pod 'GoogleMaps' pod 'GooglePlaces' pod 'Whisper' pod 'Fabric' pod 'Crashlytics' pod 'SwiftyJSON' pod 'Alamofire' pod 'SwiftGridView' target 'myAPPUITests' do inherit! :search_paths # Pods for testing end endEstoy usando Swift 4, Xcode 10.1
Probé una solución diferente, pero ninguna de ellas funcionó para mí.
No se pudo cargar el paquete UITests porque está dañado o le faltan los recursos necesarios. Intenta reinstalar el paquete
Verifique si todos sus objetivos usan la misma versión de iOS en: Configuración de compilación -> Objetivo de implementación de iOS
Para instalar todas las dependencias, agregué estas líneas a su Podfile:
post_install do |installer| installer.pods_project.targets.each do |target| if ['PagingMenuController', 'TCPickerView'].include? target.name target.build_configurations.each do |config| config.build_settings['SWIFT_VERSION'] = '3.0' end end end end ¡Luego use_frameworks! (consulte este enlace para obtener más detalles) desde su Podfile, ejecute la pod update y luego pude ejecutar las pruebas.
Para más detalles ver esta respuesta .
Si está utilizando Swift 3 o Swift 4 y desea agregar UITest a su proyecto, no olvide los siguientes pasos:
use_frameworks! desde su archivo pod y actualice su archivo pod con versiones pod de dependencias como a continuaciónpost_install para especificar su swift version .ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES o configúrelos en No en ambas aplicaciones de destino (myAPP y myAPUITests) desintegración de pod deintegrate , pod clean de pod install de pod
# Quite el comentario de la siguiente línea para definir una plataforma global para la plataforma de su proyecto: ios, '9.0'
target 'myAPP' do # Comenta la siguiente línea si no estás usando Swift y no quieres usar marcos dinámicos
# Pods for myAPP pod 'SwiftMessages', '4.1.4' pod 'IQKeyboardManager', '6.1.1' pod 'SwiftKeychainWrapper', '3.0.1' pod 'Tabman', '1.9.1' pod 'PagingMenuController', '2.2.0' pod 'Kingfisher', '4.8.0' pod 'Optik', '0.3.0' pod 'KRPullLoader', '1.1.3' pod 'AlamofireImage', '3.3.1' pod 'Firebase/Core' pod 'Firebase/Database' pod 'Firebase/Messaging' pod 'Firebase/Auth' pod 'Firebase/Storage' pod 'TCPickerView', '0.2.5' pod 'GoogleMaps', '2.7.0' pod 'GooglePlaces', '2.7.0' pod 'Whisper', '6.0.2' pod 'Fabric', '1.7.9' pod 'Crashlytics', '3.10.5' pod 'SwiftyJSON', '4.1.0' #pod 'Alamofire', '4.7.3' pod 'SwiftGridView', '0.6.5' target 'myAPPUITests' do inherit! :search_paths # Pods for testing end end post_install do |installer| print "Setting the default SWIFT_VERSION to 4.0\n" installer.pods_project.build_configurations.each do |config| config.build_settings['SWIFT_VERSION'] = '4.0' end installer.pods_project.targets.each do |target| if [].include? "#{target}" print "Setting #{target}'s SWIFT_VERSION to 4.2\n" target.build_configurations.each do |config| config.build_settings['SWIFT_VERSION'] = '4.2' end else print "Setting #{target}'s SWIFT_VERSION to Undefined (Xcode will automatically resolve)\n" target.build_configurations.each do |config| config.build_settings.delete('SWIFT_VERSION') #config.build_settings['SWIFT_VERSION'] = '4.0' end end end end