Simple Horizontal Divider Item Decoration for RecyclerView
mRecyclerView.addItemDecoration(new SimpleDividerItemDecoration(
getApplicationContext()
));
NOTE: Add item decoration prior to setting the adapter
xxx, | |
Thanks again for taking the time to speak with me and for sending me your information. I'm excited to tell you that we would like to move forward in the process! | |
One of our coordinators will be emailing you within the next week from an @google.com domain with the date and time of your phone interview. In the meantime, I've included some preparation materials (below.) | |
Please note this will be a technical interview that will last for approximately 45 minutes. Google takes an academic approach to the interviewing process. This means that we are interested in your thought process, your approach to problem solving as well as your coding abilities. You may be asked questions that relate to technical knowledge, algorithms, coding, performance, how to test solutions, and perhaps your interest in Google products. The best advice that I can give you is to treat the interview like a conversation, talk through the problems, and please feel free to ask the interviewer if you are not clear with any of the questio |
<?xml version="1.0" encoding="utf-8"?> | |
<manifest xmlns:android="http://schemas.android.com/apk/res/android" | |
package="com.sample.myapplication" > | |
<application | |
android:allowBackup="true" | |
android:icon="@drawable/ic_launcher" | |
android:label="@string/app_name" | |
android:theme="@style/AppTheme" > | |
<activity |
public class ViewMatchers | |
{ | |
@SuppressWarnings("unchecked") | |
public static Matcher<View> withRecyclerView(@IdRes int viewId) | |
{ | |
return allOf(isAssignableFrom(RecyclerView.class), withId(viewId)); | |
} | |
@SuppressWarnings("unchecked") | |
public static ViewInteraction onRecyclerItemView(@IdRes int identifyingView, Matcher<View> identifyingMatcher, Matcher<View> childMatcher) |
This test rule is now in the 'test-rules' support repository. Use that one!
https://developer.android.com/reference/android/support/test/rule/ActivityTestRule.html
package com.collectiveidea.example; | |
import android.content.Intent; | |
import android.support.test.espresso.intent.Intents; | |
import android.support.test.rule.ActivityTestRule; | |
import android.support.test.runner.AndroidJUnit4; | |
import com.collectiveidea.example.ui.LoginActivity; | |
import com.collectiveidea.example.ui.MainActivity; | |
import com.collectiveidea.example.util.AccountUtility; |
package be.digitalia.common.widgets; | |
import android.content.Context; | |
import android.os.SystemClock; | |
import android.util.AttributeSet; | |
import android.view.View; | |
import android.widget.ProgressBar; | |
/** | |
* ContentLoadingProgressBar implements a ProgressBar that waits a minimum time to be |
@RunWith(AndroidJUnit4.class) | |
@LargeTest | |
public class MainActivityTests { | |
@Rule | |
public ActivityTestRule<MainActivity> mActivityTestRule = new ActivityTestRule<>(MainActivity.class); | |
@Test | |
public void loadHackerNewsPostsOnStartup() { | |
onView(withId(R.id.recyclerView)).check(matches(isDisplayed())); |
import static android.support.test.espresso.Espresso.onView; | |
import static android.support.test.espresso.action.ViewActions.click; | |
import static android.support.test.espresso.action.ViewActions.typeText; | |
import static android.support.test.espresso.assertion.ViewAssertions.matches; | |
import static android.support.test.espresso.matcher.ViewMatchers.isDisplayed; | |
import static android.support.test.espresso.matcher.ViewMatchers.isEnabled; | |
import static android.support.test.espresso.matcher.ViewMatchers.withId; | |
import static android.support.test.espresso.matcher.ViewMatchers.withText; | |
import static org.hamcrest.Matchers.not; |
package com.nextstagesearch; | |
import android.Manifest; | |
import android.app.Activity; | |
import android.app.AlertDialog; | |
import android.content.Context; | |
import android.content.ContextWrapper; | |
import android.content.DialogInterface; | |
import android.content.pm.PackageManager; |