2016-09-27 14 views
1

私は、Androidのアプリケーションをビルドし、Bitrise.ioのエミュレータでUIテストを実行しようとしています。アプリをインストールしようとするとAndroidアームエミュレータのタイムアウトが発生する

スクリプトはエミュレータでアプリをインストールしようとしているとき、私は一貫してこのエラーを取得しています:

11:12:03.398 [QUIET] [system.out] :app:installDebug 
11:12:09.000 [DEBUG] [org.apache.http.impl.conn.PoolingClientConnectionManager] Closing connections idle longer than 60 SECONDS 

私はそれが接続していないだ理由を把握しようとしている私の髪を引っ張っています。

まず私は、私はその後、私はその後、私はテスト を起動しよう

/tools/emulator -avd main -skin 1920x1080 -no-boot-anim -no-audio -no-window 

エミュレータを起動するエミュレータ

echo no | android create avd --force --name main --target "android-23" --abi "google_apis/armeabi-v7a" 

を作成する必要なSDK

echo y | android update sdk --no-ui --all --filter addon-google_apis-google-23 
echo y | android update sdk --no-ui --all --filter sys-img-armeabi-v7a-google_apis-23 

をダウンロードしてください。/gradlew bitrise - 継続--debug

bitriseは、本質的にassembleDebug installDebug installDebugAndroidTestがconnectedCheck

それは誰かに何かを意味した場合の全体のエラーログを確認きれい./gradlewこの を行うスクリプトである

11:12:00.706 [QUIET] [system.out] :app:packageDebug 
11:12:03.392 [QUIET] [system.out] :app:assembleDebug 
11:12:03.398 [QUIET] [system.out] :app:installDebug 
11:12:09.000 [DEBUG] [org.apache.http.impl.conn.PoolingClientConnectionManager] Closing connections idle longer than 60 SECONDS 
11:12:10.236 [QUIET] [system.out] 
11:12:10.237 [QUIET] [system.out] Installing APK 'app-debug.apk' on 'main(AVD) - 6.0' for app:debug 
11:12:22.444 [ERROR] [system.err] Unable to install /bitrise/src/app/build/outputs/apk/app-debug.apk 
11:12:22.450 [ERROR] [system.err] com.android.ddmlib.InstallException: Failed to establish session 
11:12:22.451 [ERROR] [system.err] at com.android.ddmlib.SplitApkInstaller.install(SplitApkInstaller.java:64) 
11:12:22.452 [ERROR] [system.err] at com.android.ddmlib.Device.installPackages(Device.java:904) 
11:12:22.453 [ERROR] [system.err] at com.android.builder.testing.ConnectedDevice.installPackages(ConnectedDevice.java:137) 
11:12:22.454 [ERROR] [system.err] at com.android.build.gradle.internal.tasks.InstallVariantTask.install(InstallVariantTask.java:134) 
11:12:22.455 [ERROR] [system.err] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) 
11:12:22.456 [ERROR] [system.err] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) 
11:12:22.457 [ERROR] [system.err] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) 
11:12:22.458 [ERROR] [system.err] at java.lang.reflect.Method.invoke(Method.java:498) 
11:12:22.459 [ERROR] [system.err] at org.gradle.internal.reflect.JavaMethod.invoke(JavaMethod.java:75) 
11:12:22.460 [ERROR] [system.err] at org.gradle.api.internal.project.taskfactory.AnnotationProcessingTaskFactory$StandardTaskAction.doExecute(AnnotationProcessingTaskFactory.java:228) 
11:12:22.461 [ERROR] [system.err] at org.gradle.api.internal.project.taskfactory.AnnotationProcessingTaskFactory$StandardTaskAction.execute(AnnotationProcessingTaskFactory.java:221) 
11:12:22.462 [ERROR] [system.err] at org.gradle.api.internal.project.taskfactory.AnnotationProcessingTaskFactory$StandardTaskAction.execute(AnnotationProcessingTaskFactory.java:210) 
11:12:22.463 [ERROR] [system.err] at org.gradle.api.internal.AbstractTask$TaskActionWrapper.execute(AbstractTask.java:621) 
11:12:22.464 [ERROR] [system.err] at org.gradle.api.internal.AbstractTask$TaskActionWrapper.execute(AbstractTask.java:604) 
11:12:22.465 [ERROR] [system.err] at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.executeAction(ExecuteActionsTaskExecuter.java:80) 
11:12:22.466 [ERROR] [system.err] at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.executeActions(ExecuteActionsTaskExecuter.java:61) 
11:12:22.467 [ERROR] [system.err] at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.execute(ExecuteActionsTaskExecuter.java:46) 
11:12:22.468 [ERROR] [system.err] at org.gradle.api.internal.tasks.execution.PostExecutionAnalysisTaskExecuter.execute(PostExecutionAnalysisTaskExecuter.java:35) 
11:12:22.469 [ERROR] [system.err] at org.gradle.api.internal.tasks.execution.SkipUpToDateTaskExecuter.execute(SkipUpToDateTaskExecuter.java:66) 
11:12:22.472 [QUIET] [system.out] :app:installDebug FAILED 
11:12:22.479 [ERROR] [system.err] at org.gradle.api.internal.tasks.execution.ValidatingTaskExecuter.execute(ValidatingTaskExecuter.java:58) 
11:12:22.480 [ERROR] [system.err] at org.gradle.api.internal.tasks.execution.SkipEmptySourceFilesTaskExecuter.execute(SkipEmptySourceFilesTaskExecuter.java:52) 
11:12:22.481 [ERROR] [system.err] at org.gradle.api.internal.tasks.execution.SkipTaskWithNoActionsExecuter.execute(SkipTaskWithNoActionsExecuter.java:52) 
11:12:22.482 [ERROR] [system.err] at org.gradle.api.internal.tasks.execution.SkipOnlyIfTaskExecuter.execute(SkipOnlyIfTaskExecuter.java:53) 
11:12:22.483 [ERROR] [system.err] at org.gradle.api.internal.tasks.execution.ExecuteAtMostOnceTaskExecuter.execute(ExecuteAtMostOnceTaskExecuter.java:43) 
11:12:22.484 [ERROR] [system.err] at org.gradle.execution.taskgraph.DefaultTaskGraphExecuter$EventFiringTaskWorker.execute(DefaultTaskGraphExecuter.java:203) 
11:12:22.484 [ERROR] [system.err] at org.gradle.execution.taskgraph.DefaultTaskGraphExecuter$EventFiringTaskWorker.execute(DefaultTaskGraphExecuter.java:185) 
11:12:22.485 [ERROR] [system.err] at org.gradle.execution.taskgraph.AbstractTaskPlanExecutor$TaskExecutorWorker.processTask(AbstractTaskPlanExecutor.java:66) 
11:12:22.486 [ERROR] [system.err] at org.gradle.execution.taskgraph.AbstractTaskPlanExecutor$TaskExecutorWorker.run(AbstractTaskPlanExecutor.java:50) 
11:12:22.487 [ERROR] [system.err] at org.gradle.execution.taskgraph.DefaultTaskPlanExecutor.process(DefaultTaskPlanExecutor.java:25) 
11:12:22.488 [ERROR] [system.err] at org.gradle.execution.taskgraph.DefaultTaskGraphExecuter.execute(DefaultTaskGraphExecuter.java:110) 
11:12:22.489 [ERROR] [system.err] at org.gradle.execution.SelectedTaskExecutionAction.execute(SelectedTaskExecutionAction.java:37) 
11:12:22.490 [ERROR] [system.err] at org.gradle.execution.DefaultBuildExecuter.execute(DefaultBuildExecuter.java:37) 
11:12:22.491 [ERROR] [system.err] at org.gradle.execution.DefaultBuildExecuter.access$000(DefaultBuildExecuter.java:23) 
11:12:22.491 [ERROR] [system.err] at org.gradle.execution.DefaultBuildExecuter$1.proceed(DefaultBuildExecuter.java:43) 
11:12:22.491 [ERROR] [system.err] at org.gradle.execution.DryRunBuildExecutionAction.execute(DryRunBuildExecutionAction.java:32) 
11:12:22.491 [ERROR] [system.err] at org.gradle.execution.DefaultBuildExecuter.execute(DefaultBuildExecuter.java:37) 
11:12:22.491 [ERROR] [system.err] at org.gradle.execution.DefaultBuildExecuter.execute(DefaultBuildExecuter.java:30) 
11:12:22.491 [ERROR] [system.err] at org.gradle.initialization.DefaultGradleLauncher$4.run(DefaultGradleLauncher.java:153) 
11:12:22.491 [ERROR] [system.err] at org.gradle.internal.Factories$1.create(Factories.java:22) 
11:12:22.491 [ERROR] [system.err] at org.gradle.internal.progress.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:91) 
11:12:22.491 [ERROR] [system.err] at org.gradle.internal.progress.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:53) 
11:12:22.492 [ERROR] [system.err] at org.gradle.initialization.DefaultGradleLauncher.doBuildStages(DefaultGradleLauncher.java:150) 
11:12:22.492 [ERROR] [system.err] at org.gradle.initialization.DefaultGradleLauncher.access$200(DefaultGradleLauncher.java:32) 
11:12:22.492 [ERROR] [system.err] at org.gradle.initialization.DefaultGradleLauncher$1.create(DefaultGradleLauncher.java:98) 
11:12:22.492 [ERROR] [system.err] at org.gradle.initialization.DefaultGradleLauncher$1.create(DefaultGradleLauncher.java:92) 
11:12:22.492 [ERROR] [system.err] at org.gradle.internal.progress.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:91) 
11:12:22.492 [ERROR] [system.err] at org.gradle.internal.progress.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:63) 
11:12:22.492 [ERROR] [system.err] at org.gradle.initialization.DefaultGradleLauncher.doBuild(DefaultGradleLauncher.java:92) 
11:12:22.492 [ERROR] [system.err] at org.gradle.initialization.DefaultGradleLauncher.run(DefaultGradleLauncher.java:83) 
11:12:22.493 [ERROR] [system.err] at org.gradle.launcher.exec.InProcessBuildActionExecuter$DefaultBuildController.run(InProcessBuildActionExecuter.java:99) 
11:12:22.493 [ERROR] [system.err] at org.gradle.tooling.internal.provider.ExecuteBuildActionRunner.run(ExecuteBuildActionRunner.java:28) 
11:12:22.493 [ERROR] [system.err] at org.gradle.launcher.exec.ChainingBuildActionRunner.run(ChainingBuildActionRunner.java:35) 
11:12:22.493 [ERROR] [system.err] at org.gradle.launcher.exec.InProcessBuildActionExecuter.execute(InProcessBuildActionExecuter.java:48) 
11:12:22.493 [ERROR] [system.err] at org.gradle.launcher.exec.InProcessBuildActionExecuter.execute(InProcessBuildActionExecuter.java:30) 
11:12:22.493 [ERROR] [system.err] at org.gradle.launcher.exec.ContinuousBuildActionExecuter.execute(ContinuousBuildActionExecuter.java:81) 
11:12:22.493 [ERROR] [system.err] at org.gradle.launcher.exec.ContinuousBuildActionExecuter.execute(ContinuousBuildActionExecuter.java:46) 
11:12:22.494 [ERROR] [system.err] at org.gradle.launcher.exec.DaemonUsageSuggestingBuildActionExecuter.execute(DaemonUsageSuggestingBuildActionExecuter.java:51) 
11:12:22.494 [ERROR] [system.err] at org.gradle.launcher.exec.DaemonUsageSuggestingBuildActionExecuter.execute(DaemonUsageSuggestingBuildActionExecuter.java:28) 
11:12:22.494 [ERROR] [system.err] at org.gradle.launcher.cli.RunBuildAction.run(RunBuildAction.java:43) 
11:12:22.494 [ERROR] [system.err] at org.gradle.internal.Actions$RunnableActionAdapter.execute(Actions.java:173) 
11:12:22.494 [ERROR] [system.err] at org.gradle.launcher.cli.CommandLineActionFactory$ParseAndBuildAction.execute(CommandLineActionFactory.java:239) 
11:12:22.494 [ERROR] [system.err] at org.gradle.launcher.cli.CommandLineActionFactory$ParseAndBuildAction.execute(CommandLineActionFactory.java:212) 
11:12:22.495 [ERROR] [system.err] at org.gradle.launcher.cli.JavaRuntimeValidationAction.execute(JavaRuntimeValidationAction.java:35) 
11:12:22.495 [ERROR] [system.err] at org.gradle.launcher.cli.JavaRuntimeValidationAction.execute(JavaRuntimeValidationAction.java:24) 
11:12:22.495 [ERROR] [system.err] at org.gradle.launcher.cli.ExceptionReportingAction.execute(ExceptionReportingAction.java:33) 
11:12:22.495 [ERROR] [system.err] at org.gradle.launcher.cli.ExceptionReportingAction.execute(ExceptionReportingAction.java:22) 
11:12:22.495 [ERROR] [system.err] at org.gradle.launcher.cli.CommandLineActionFactory$WithLogging.execute(CommandLineActionFactory.java:205) 
11:12:22.496 [ERROR] [system.err] at org.gradle.launcher.cli.CommandLineActionFactory$WithLogging.execute(CommandLineActionFactory.java:169) 
11:12:22.496 [ERROR] [system.err] at org.gradle.launcher.Main.doAction(Main.java:33) 
11:12:22.496 [ERROR] [system.err] at org.gradle.launcher.bootstrap.EntryPoint.run(EntryPoint.java:45) 
11:12:22.496 [ERROR] [system.err] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) 
11:12:22.496 [ERROR] [system.err] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) 
11:12:22.507 [ERROR] [system.err] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) 
11:12:22.507 [ERROR] [system.err] at java.lang.reflect.Method.invoke(Method.java:498) 
11:12:22.507 [ERROR] [system.err] at org.gradle.launcher.bootstrap.ProcessBootstrap.runNoExit(ProcessBootstrap.java:55) 
11:12:22.507 [ERROR] [system.err] at org.gradle.launcher.bootstrap.ProcessBootstrap.run(ProcessBootstrap.java:36) 
11:12:22.507 [ERROR] [system.err] at org.gradle.launcher.GradleMain.main(GradleMain.java:23) 
11:12:22.508 [ERROR] [system.err] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) 
11:12:22.508 [ERROR] [system.err] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) 
11:12:22.508 [ERROR] [system.err] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) 
11:12:22.508 [ERROR] [system.err] at java.lang.reflect.Method.invoke(Method.java:498) 
11:12:22.508 [ERROR] [system.err] at org.gradle.wrapper.BootstrapMainStarter.start(BootstrapMainStarter.java:33) 
11:12:22.508 [ERROR] [system.err] at org.gradle.wrapper.WrapperExecutor.execute(WrapperExecutor.java:130) 
11:12:22.508 [ERROR] [system.err] at org.gradle.wrapper.GradleWrapperMain.main(GradleWrapperMain.java:48) 
11:12:22.508 [ERROR] [system.err] 
11:12:22.508 [ERROR] [system.err] FAILURE: Build failed with an exception. 
11:12:22.508 [ERROR] [system.err] 
11:12:22.508 [ERROR] [system.err] * What went wrong: 
11:12:22.508 [ERROR] [system.err] Execution failed for task ':app:installDebug'. 
11:12:22.508 [ERROR] [system.err] > com.android.builder.testing.api.DeviceException 

更新 アンドロイド-24にアップグレードすると、エミュレータ画面の解像度を下げた後、問題が去っていきました。

+0

どの画面解像度を使用して動作させるのですか? –

+1

正確に覚えていません。私は800 * 640またはそれに類するものだと思う。最終的には、私たちはビットテスト時にエミュレータでUIテストを実行するという考え方を捨てました。事はちょうど遅すぎる – otusweb

答えて

2

エミュレータを起動するには、Start Android emulatorの手順を使用する必要があります。問題は、単にemulator -avd ...を呼び出すと、エミュレータの起動が開始されますが、エミュレータが完全に起動して使用できる状態になるのを待つことはありません。

「Android Androidエミュレータの起動」手順(https://github.com/bitrise-steplib/steps-start-android-emulator)では、この機能とその他のマイナーチェック/回避策が実装されています。

+0

はい、私は実際にbitriseのステップを使用します、私はちょうどどのコマンドが実行されたかを示す出力をコピーしました。 – otusweb

関連する問題