Невозможно разрешить символ RecyclerViewActions/RecyclerViewMatcherJAVA

Программисты JAVA общаются здесь
Ответить
Anonymous
 Невозможно разрешить символ RecyclerViewActions/RecyclerViewMatcher

Сообщение Anonymous »

Я пытаюсь написать тесты для представления переработчика в своем приложении для Android. Я получаю сообщение об ошибке «Невозможно разрешить символ» для «RecyclerViewActions» и «RecyclerViewMatcher».

Вот вспомогательный метод в моем тесте, в котором возникает ошибка «Невозможно разрешить символ». брошено.

````// Convenience helper
public static RecyclerViewMatcher withRecyclerView(final int recyclerViewId) {
return new RecyclerViewMatcher(recyclerViewId);
}````


Вот мой импорт, где также выдается ошибка

import static androidx.test.espresso.contrib.RecyclerViewActions;

Вот мои зависимости build.gradle на уровне приложения:

dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar'])

implementation 'androidx.appcompat:appcompat:1.0.2'
implementation 'androidx.cardview:cardview:1.0.0'
implementation 'androidx.recyclerview:recyclerview:1.1.0'
implementation 'com.google.android.material:material:1.0.0'
implementation 'androidx.constraintlayout:constraintlayout:1.1.3'
implementation 'androidx.navigation:navigation-fragment:2.0.0'
implementation 'androidx.navigation:navigation-ui:2.0.0'
implementation 'androidx.coordinatorlayout:coordinatorlayout:1.1.0'
testImplementation 'junit:junit:4.12'
androidTestImplementation 'androidx.test:rules:1.1.1'
androidTestImplementation 'androidx.test.ext:junit:1.1.1'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.2.0'
androidTestImplementation('androidx.test.espresso:espresso-contrib:3.2.0') {
exclude group: 'com.android.support', module: 'appcompat'
exclude group: 'com.android.support', module: 'support-v4'
}
}````



Подробнее здесь: https://stackoverflow.com/questions/619 ... iewmatcher
Ответить

Быстрый ответ

Изменение регистра текста: 
Смайлики
:) :( :oops: :roll: :wink: :muza: :clever: :sorry: :angel: :read: *x)
Ещё смайлики…
   
К этому ответу прикреплено по крайней мере одно вложение.

Если вы не хотите добавлять вложения, оставьте поля пустыми.

Максимально разрешённый размер вложения: 15 МБ.

Вернуться в «JAVA»