// Path: patternedtextwatcher/src/androidTest/java/com/szagurskii/patternedtextwatcher/utils/ViewDirtyIdlingResource.java
// public final class ViewDirtyIdlingResource implements IdlingResource {
//   private final View decorView;
//   private ResourceCallback resourceCallback;
// 
//   public ViewDirtyIdlingResource(Activity activity) {
//     decorView = activity.getWindow().getDecorView();
//   }
// 
//   @Override public String getName() {
//     return "view dirty";
//   }
// 
//   @Override public boolean isIdleNow() {
//     boolean clean = !decorView.isDirty();
//     if (clean) {
//       resourceCallback.onTransitionToIdle();
//     }
//     return clean;
//   }
// 
//   @Override public void registerIdleTransitionCallback(ResourceCallback resourceCallback) {
//     this.resourceCallback = resourceCallback;
//   }
// }


import android.support.test.espresso.Espresso;
import android.support.test.rule.ActivityTestRule;
import android.widget.EditText;
import com.szagurskii.patternedtextwatcher.utils.ViewDirtyIdlingResource;
import org.junit.After;
import org.junit.Before;
import org.junit.Rule;
package com.szagurskii.patternedtextwatcher;




public abstract class BaseTests {
  static final String STRING_TO_BE_TYPED = "Espresso";

  @Rule
  public ActivityTestRule<TestActivity> activityRule = new ActivityTestRule<>(TestActivity.class);

// Path: patternedtextwatcher/src/androidTest/java/com/szagurskii/patternedtextwatcher/utils/ViewDirtyIdlingResource.java
// public final class ViewDirtyIdlingResource implements IdlingResource {
//   private final View decorView;
//   private ResourceCallback resourceCallback;
// 
//   public ViewDirtyIdlingResource(Activity activity) {
//     decorView = activity.getWindow().getDecorView();
//   }
// 
//   @Override public String getName() {
//     return "view dirty";
//   }
// 
//   @Override public boolean isIdleNow() {
//     boolean clean = !decorView.isDirty();
//     if (clean) {
//       resourceCallback.onTransitionToIdle();
//     }
//     return clean;
//   }
// 
//   @Override public void registerIdleTransitionCallback(ResourceCallback resourceCallback) {
//     this.resourceCallback = resourceCallback;
//   }
// }


// Path: patternedtextwatcher/src/androidTest/java/com/szagurskii/patternedtextwatcher/BaseTests.java
import android.support.test.espresso.Espresso;
import android.support.test.rule.ActivityTestRule;
import android.widget.EditText;
import com.szagurskii.patternedtextwatcher.utils.ViewDirtyIdlingResource;
import org.junit.After;
import org.junit.Before;
import org.junit.Rule;

package com.szagurskii.patternedtextwatcher;




public abstract class BaseTests {
  static final String STRING_TO_BE_TYPED = "Espresso";

  @Rule
  public ActivityTestRule<TestActivity> activityRule = new ActivityTestRule<>(TestActivity.class);

  ViewDirtyIdlingResource viewDirtyIdler;