test_class.declarator: mDEFetchReceiver
test_class.modifier: @Mock
      private
test_class.original_string: @Mock
      private DEFetchReceiver mDEFetchReceiver;
test_class.type: DEFetchReceiver
test_class.var_name: mDEFetchReceiver
test_class.declarator: mMockNetworkChecker
test_class.modifier: @Mock
      private
test_class.original_string: @Mock
      private NetworkChecker mMockNetworkChecker;
test_class.type: NetworkChecker
test_class.var_name: mMockNetworkChecker
test_class.declarator: mAutoFetchTodaysSentenceUC
test_class.modifier: @Mock
      private
test_class.original_string: @Mock
      private AutoFetchTodaysSentenceUC mAutoFetchTodaysSentenceUC;
test_class.type: AutoFetchTodaysSentenceUC
test_class.var_name: mAutoFetchTodaysSentenceUC
test_class.declarator: mIntent
test_class.modifier: @Mock
      private
test_class.original_string: @Mock
      private Intent mIntent;
test_class.type: Intent
test_class.var_name: mIntent
test_class.file: app/src/test/java/com/xixicm/de/infrastructure/receiver/DEFetchReceiverTest.java
test_class.identifier: DEFetchReceiverTest
test_case.body: @Test
      public void testOnReceive_CONNECTIVITY_ACTION_AvailableNetwork() {
          doReturn(true).when(mMockNetworkChecker).isNetworkAvailable();
          doReturn(ConnectivityManager.CONNECTIVITY_ACTION).when(mIntent).getAction();
          mDEFetchReceiver.onReceive(null, mIntent);
  
          // wait to execute
          waitToRun(100);
          verify(mAutoFetchTodaysSentenceUC).run();
      }
test_case.class_method_signature: DEFetchReceiverTest.testOnReceive_CONNECTIVITY_ACTION_AvailableNetwork()
test_case.full_signature: @Test public void testOnReceive_CONNECTIVITY_ACTION_AvailableNetwork()
test_case.identifier: testOnReceive_CONNECTIVITY_ACTION_AvailableNetwork
test_case.invocations: isNetworkAvailable when doReturn getAction when doReturn onReceive waitToRun run verify
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void testOnReceive_CONNECTIVITY_ACTION_AvailableNetwork()
focal_class.file: app/src/main/java/com/xixicm/de/infrastructure/receiver/DEFetchReceiver.java
focal_class.identifier: DEFetchReceiver
focal_class.class_method_signature: DEFetchReceiver.onReceive(Context context, Intent intent)
focal_class.full_signature: @Override public void onReceive(Context context, Intent intent)
focal_class.identifier: onReceive
focal_class.modifiers: @Override public
focal_class.parameters: (Context context, Intent intent)
focal_class.return: void
focal_class.signature: void onReceive(Context context, Intent intent)
focal_class.class_method_signature: DEFetchReceiver.getAutoFetchTodaysSentenceUC(Context context)
focal_class.full_signature: @VisibleForTesting public AutoFetchTodaysSentenceUC getAutoFetchTodaysSentenceUC(Context context)
focal_class.identifier: getAutoFetchTodaysSentenceUC
focal_class.modifiers: @VisibleForTesting public
focal_class.parameters: (Context context)
focal_class.return: AutoFetchTodaysSentenceUC
focal_class.signature: AutoFetchTodaysSentenceUC getAutoFetchTodaysSentenceUC(Context context)
focal_class.superclass: extends BroadcastReceiver
focal_method.body: @Override
      public void onReceive(Context context, Intent intent) {
          LogUtils.v(Constants.TAG, "DEFetchReceiver: " + intent);
          // work on previous android N
          if (ConnectivityManager.CONNECTIVITY_ACTION.equals(intent.getAction()) && !NetworkUtils.isNetworkAvailable()) {
              LogUtils.d(Constants.TAG, "Network is not available, abort fetching.");
              return;
          }
  
          DefaultUseCaseHandler.createParallelUCHandler().execute(getAutoFetchTodaysSentenceUC(context));
      }
focal_method.class_method_signature: DEFetchReceiver.onReceive(Context context, Intent intent)
focal_method.full_signature: @Override public void onReceive(Context context, Intent intent)
focal_method.identifier: onReceive
focal_method.invocations: v equals getAction isNetworkAvailable d execute createParallelUCHandler getAutoFetchTodaysSentenceUC
focal_method.modifiers: @Override public
focal_method.parameters: (Context context, Intent intent)
focal_method.return: void
focal_method.signature: void onReceive(Context context, Intent intent)