2016-12-29 2 views
0

J'écris des autotests mobiles en utilisant C#, Xamarin 6.1.3., iOS 10.2, iPhone 6s Plus, Xcode 8.2, OS X El Capitan 10.11.6. J'essaie de lancer des tests sur le simulateur en utilisant la commande suivante:Comment signer un fichier .ipa ou une application existante. avec le profil d'approvisionnement

IApp iApp = ConfigureApp.iOS.AppBundle (chemin_app_app/Application.app) .StartApp();

J'ai l'erreur suivante:

Calabash.XDB.Core.Exceptions.DeviceAgentException : Failed to install app /Volumes/Win7 Ultim/Framework/Atom.app 

ExitCode: 1 



     app: /Volumes/Win7 Ultim/Framework/Atom.app/PlugIns/AtomTests.xctest 
    identity: #<CodesignIdentity: - : AdHoc> 
/usr/bin/xcrun codesign -d --entitlements :- /Volumes/Win7 Ultim/Framework/Atom.app/PlugIns/AtomTests.xctest 
/usr/bin/xcrun codesign --verbose=4 --verify /Volumes/Win7 Ultim/Framework/Atom.app/Atom 
/Volumes/Win7 Ultim/Framework/Atom.app 
/Volumes/Win7 Ultim/Framework/Atom.app/PlugIns/AtomTests.xctest 
device UDID: 9E44D0FE-A3F9-4FC1-8635-20FB8AD20BA4 
Device UDID: 9E44D0FE-A3F9-4FC1-8635-20FB8AD20BA4 
ERROR: Error Domain=sh.calaba.iOSDeviceManger Code=5 "Code signing failed" UserInfo={NSLocalizedDescription=Code signing failed, NSLocalizedFailureReason=There was a problem code signing. Please check the logs.} 
Path to bundle: /Volumes/Win7 Ultim/Framework/Atom.app 
Could not extract entitlements from app: 
with command: 
    -a,--app-bundle <path/to/app-bundle.app> Path .app bundle (for .ipas, unzip and look inside of 'Payload') 
    -c,--codesign-identity <codesign-identity> [OPTIONAL] Identity used to codesign app bundle [device only] DEFAULT= 
    -d,--device-id <device-identifier> iOS Simulator GUIDs 
    -u,--update-app <true-or-false> [OPTIONAL] When true, will reinstall the app if the device contains an older version than the bundle specified DEFAULT=1 
install 
/Volumes/Win7 Ultim/Framework/Atom.app/Atom: code object is not signed at all 
/Volumes/Win7 Ultim/Framework/Atom.app/PlugIns/AtomTests.xctest: code object is not signed at all 
=== STDERR === 
=== STDERR === 
Could not find any Provisioning Profiles suitable for resigning 
Could not resign app bundle at path: 
Error resigning sim bundle 
In architecture: x86_64 
with command: 

donc je n'ai pas le code source de l'application, mais je dois vous connecter ou .app .ipa fichier que je dois, pour le rendre possible exécuter des tests sur l'application. C'est possible?

+2

double possible de [Comment resigner le fichier ipa?] (Http://stackoverflow.com/questions/5160863/how-to-re-sign-the-ipa-file) – Demitrian

+0

Qu'est-ce que le fichier avez-vous obtenu à l'origine, un fichier .app ou un fichier .ipa? En outre, où avez-vous obtenu le fichier directement du développeur d'origine ou du magasin d'applications? –

Répondre

1

solution de » @Kent.Green-this answer fonctionne aussi pour résoudre votre problème:

resigner un IPA à l'aide Test Recorder Xamarin

Une option que vous pouvez utiliser est d'utiliser l'enregistreur de test Xamarin pour injecter Calabash et re -sign votre IPA: https://developer.xamarin.com/guides/testcloud/testrecorder/

Après avoir chargé l'IPA dans l'enregistreur de test, il va créer un nouvel IPA, re-signé dans le même emplacement que l'IPA d'origine, avec le nom précédé de "xtr-" comme ainsi:

  • myAwesomeApp.ipa (original IPA)
  • xtr-myAwesomeApp.ipa (IPA, re-signé, injecté Calabash)

choses à surveiller

  • IPA resigner - Le Pour effectuer la démission, mac doit disposer d'une identité de signature valide et d'un profil d'approvisionnement installé dans son trousseau, y compris les droits d'accès que l'application utilise.

  • Tout IPA contenant Calabash sera rejeté par l'App Store iOS - Cela est vrai, peu importe ce que la méthode utilisée pour ajouter Calabash à l'API, mais il est important de se rappeler. Dans l'exemple ci-dessus, vous devez tester avec xtr-myAwesomeApp.ipa et soumettre myAwesomeApp.ipa lui-même à l'App Store.