すべてのテストをTesting Support Libraryに変換しています。私はこのシンボル「LargeTest」を解決できません
import android.support.test.filters.LargeTest;
ようLargeTest
注釈をインポートしようとすると、しかし、私はCannot resolve symbol 'LargeTest'
を取得します。このエラーを解決するには、どのような依存関係をgradleファイルに追加する必要がありますか?
すべてのテストをTesting Support Libraryに変換しています。私はこのシンボル「LargeTest」を解決できません
import android.support.test.filters.LargeTest;
ようLargeTest
注釈をインポートしようとすると、しかし、私はCannot resolve symbol 'LargeTest'
を取得します。このエラーを解決するには、どのような依存関係をgradleファイルに追加する必要がありますか?
thisのドキュメントはありますか?
必要に応じて、これらの依存関係の一部を追加する必要があります。
dependencies {
androidTestCompile 'com.android.support.test:runner:0.4'
// Set this dependency to use JUnit 4 rules
androidTestCompile 'com.android.support.test:rules:0.4'
// Set this dependency to build and run Espresso tests
androidTestCompile 'com.android.support.test.espresso:espresso-core:2.2.1'
// Set this dependency to build and run UI Automator tests
androidTestCompile 'com.android.support.test.uiautomator:uiautomator-v18:2.1.2'
}
そして追加:
android {
defaultConfig {
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
}
}
"この文書を読んだことはありますか?"はい。それは私の質問でリンクした正確なページです。これらの依存関係をすべて定義し、 'testInstrumentationRunner'を設定しました。 –
を次の依存
androidTestCompile 'com.android.support.test:runner:0.5'
下のフィルタ注釈生活、まだbugを提出してください働いていない場合。
編集:問題はバージョン0.5で導入されたため、依存関係を更新する必要があるということです。
注釈をサポートしていますか? –
@ cricket_007 'androidTestCompile 'com.android.support:support-annotations:24.1.1''の意味ですか?私はこれを既に持っています... –