2015-05-15 14 views
5
  1. का उपयोग कर रहा appium संस्करण 1.3.7 का उपयोग कर रहा iphone वास्तविक डिवाइस में इंस्टॉल नहीं होती है।
  2. मैंने यूएसबी के माध्यम से भौतिक डिवाइस को जोड़ा है।
  3. मैंने कुछ समय के बाद ऐपियम क्रैश होने के बाद एपियम सर्वर लॉन्च किया है।
  4. मैंने नीचे पूरा लॉग चिपकाया है।
  5. मैंने नीचे स्क्रीन शॉट संलग्न किया है।

enter image description hereपूर्व लांच नहीं किया जा सका appium और एप्लिकेशन appium

Launching Appium with command: '/Applications/Appium.app/Contents/Resources/node/bin/node' lib/server/main.js --command-timeout "7200" --pre-launch --platform-version "8.1" --platform-name "iOS" --app "/Users/al/work/sample.app" --udid "f5de3fd5ccded92e40e86c652ce2a6f9414fe1a0" --device-name "iPhone 4s" 

info: [debug] Starting Appium in pre-launch mode 

info: Pre-launching app 

info: [debug] Using local app from command line: /Users//al/work/sample.app 
info: [debug] Creating new appium session 1cdc5dc0-36d2-40b9-922b-33601f28846b 

info: [debug] Removing any remaining instruments sockets 

info: [debug] Cleaned up instruments socket /tmp/instruments_sock 
info: [debug] Setting Xcode folder 

info: [debug] Setting Xcode version 

info: [debug] Setting iOS SDK Version 

info: [debug] Getting sdk version from xcrun with a timeout 

info: [debug] iOS SDK Version set to 8.1 

info: [debug] Not checking whether simulator is available since we're on a real device 
info: [debug] Detecting automation tracetemplate 

info: [debug] Not auto-detecting udid, running on sim 

info: [debug] Parsed app Info.plist (as binary) 

info: [debug] Parsed app Localizable.strings 
info: [debug] Getting bundle ID from app 

info: [debug] Parsed app Info.plist (as binary) 

info: [debug] Creating instruments 
info: On some xcode 6 platforms, instruments-without-delay does not work. If you experience this, you will need to re-run appium with the --native-instruments-lib flag 
info: [debug] Preparing uiauto bootstrap 
info: [debug] Dynamic bootstrap dir: /Users/alk/Library/Application Support/appium/bootstrap 
info: [debug] Dynamic env: {"nodePath":"/Applications/Appium.app/Contents/Resources/node/bin/node","commandProxyClientPath":"/Applications/Appium.app/Contents/Resources/node_modules/appium/node_modules/appium-uiauto/bin/command-proxy-client.js","instrumentsSock":"/tmp/instruments_sock","interKeyDelay":null,"justLoopInfinitely":false,"autoAcceptAlerts":false,"autoDismissAlerts":false,"sendKeyStrategy":"grouped"} 

info: [debug] Dynamic bootstrap code: // This file is automatically generated. Do not manually modify! 
... 
info: [debug] Dynamic bootstrap path: /Users/alk/Library/Application Support/appium/bootstrap/bootstrap-d5a0fb924946d8d3.js 

info: [debug] Reusing dynamic bootstrap: /Users/alk/Library/Application Support/appium/bootstrap/bootstrap-d5a0fb924946d8d3.js 
info: [debug] Getting device string from opts: {"forceIphone":false,"forceIpad":false,"xcodeVersion":"6.1.1","iOSSDKVersion":"8.1","deviceName":"iPhone 4s","platformVersion":"8.1"} 
info: [debug] fixDevice is on 
info: [debug] Final device string is: 'iPhone 4s (8.1 Simulator)' 
info: [debug] Not setting device type since we're on a real device 
info: [debug] Checking whether we need to set app preferences 

info: [debug] Not setting iOS and app preferences since we're on a real device 
info: [debug] Running ios sim reset flow 
info: [debug] Killing the simulator process 
info: [debug] Killall iOS Simulator 

info: [debug] Killing any other simulator daemons 

info: [debug] On a real device; cannot clean device state 
info: [debug] Not setting locale because we're using a real device 
info: [debug] No iOS/app preferences to set 

info: [debug] Starting iOS device log capture via deviceconsole 

info: [debug] Not pre-launching simulator 

info: [debug] Creating iDevice object with udid f5de3fd5ccded92e40e86c652ce2a6f9414ee1a2 

info: [debug] Checking app install status using: /Applications/Appium.app/Contents/Resources/node_modules/appium/build/fruitstrap/fruitstrap isInstalled --id f5de3fd5ccded92e40e86c652ce2a6f9414ee1a2 --bundle com.vr.iphone.sample 

info: [debug] App is not installed. Will try to install the app. 

info: [debug] Installing app using cmd: /Applications/Appium.app/Contents/Resources/node_modules/appium/build/fruitstrap/fruitstrap install --id f5de3fd5ccded92e40e86c652ce2a6f9414ee1a2 --bundle "/Users/al/work/sample.app 

info: [debug] Cleaning up appium session 

error: Could not pre-launch appium: Error: Unable to install [/Users/al/work/sample.app] to device with id [f5de3fd5ccded92e40e86c652ce2a6f9414ee1a2]. Error [Error: Command failed: /bin/sh -c /Applications/Appium.app/Contents/Resources/node_modules/appium/build/fruitstrap/fruitstrap install --id f5de3fd5ccded92e40e86c652ce2a6f9414ee1a2 --bundle "/Users/al/work/sample.app" 
Assertion failed: (AMDeviceStartService(device, CFSTR("com.apple.afc"), &afcFd, NULL) == 0), function handle_device, file fruitstrap.c, line 523. 
] 
+0

लॉग के बाद, एपियम ऐप इंस्टॉल नहीं कर सकता है। क्या आपने इस ऐप को मैन्युअल रूप से इंस्टॉल करने का प्रयास किया था? – Eugene

+0

@Eugene, ऐप मैन्युअल रूप से पहले से ही भौतिक डिवाइस में स्थापित हो जाता है। – selvi

उत्तर

0

आप अपने डिवाइस पर आपका एप्लिकेशन इंस्टॉल करने Appium उपयोग कर सकते हैं, बस अपने अनुप्रयोग मैन्युअल और सेटअप कोड प्रयोग में इस तरह .apk फ़ाइल का निरपेक्ष पथ की स्थापना रद्द करें:

DesiredCapabilities क्षमताओं = नई वांछित क्षमताओं();

क्षमताओं .setCapability ("platformName", "एंड्रॉइड");

capabilities.setCapability ("संस्करण", "5.1.1");

क्षमताओं .सेट क्षमता ("डिवाइस नाम", "नाम");

फ़ाइल appDir = नई फ़ाइल ("/ घर/फ़ाइल नाम/projectfile");

फ़ाइल ऐप = नई फ़ाइल (ऐपडिर, "appname.apk");

capabilities.setCapability ("एप्लिकेशन", app.getAbsolutePath());

यह आपके डिवाइस पर आपके ऐप को इंस्टॉल करेगा।

0

आपने कहा कि आप वास्तविक डिवाइस पर लॉन्च करने के लिए कोशिश की, लेकिन अपने लॉग बताता है कि आपको सिम्युलेटर पर शुरू करने के लिए करने की कोशिश की।

आप appium के यूआई संस्करण का उपयोग कर रहे हैं, तो appium में सेना डिवाइस विकल्प पर चेक करें और वास्तविक उपकरण है जो आप appium और prelaunch में जुड़े हुए की UDID दे। आपका ऐप इंस्टॉल हो जाएगा।

संबंधित मुद्दे