test_class.file: nimble/src/test/java/com/lenguyenthanh/nimble/view/ViewHelperTest.java
test_class.identifier: ViewHelperTest
test_case.body: @Test
    public void testGetActivity() throws Exception {
      Activity spy = spy(Activity.class);
      Activity result = ViewHelper.getInstance().getActivity(spy);
      Assert.assertEquals(result, spy);
    }
test_case.class_method_signature: ViewHelperTest.testGetActivity()
test_case.full_signature: @Test public void testGetActivity()
test_case.identifier: testGetActivity
test_case.invocations: spy getActivity getInstance assertEquals
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void testGetActivity()
focal_class.declarator: instance
focal_class.modifier: private static
focal_class.original_string: private static ViewHelper instance;
focal_class.type: ViewHelper
focal_class.var_name: instance
focal_class.file: nimble/src/main/java/com/lenguyenthanh/nimble/view/ViewHelper.java
focal_class.identifier: ViewHelper
focal_class.class_method_signature: ViewHelper.ViewHelper()
focal_class.full_signature: private  ViewHelper()
focal_class.identifier: ViewHelper
focal_class.modifiers: private
focal_class.parameters: ()
focal_class.signature:  ViewHelper()
focal_class.class_method_signature: ViewHelper.getInstance()
focal_class.full_signature: public static ViewHelper getInstance()
focal_class.identifier: getInstance
focal_class.modifiers: public static
focal_class.parameters: ()
focal_class.return: ViewHelper
focal_class.signature: ViewHelper getInstance()
focal_class.class_method_signature: ViewHelper.getActivity(final Context viewContext)
focal_class.full_signature: public Activity getActivity(final Context viewContext)
focal_class.identifier: getActivity
focal_class.modifiers: public
focal_class.parameters: (final Context viewContext)
focal_class.return: Activity
focal_class.signature: Activity getActivity(final Context viewContext)
focal_method.body: public Activity getActivity(final Context viewContext) {
      Context context = viewContext;
      while (!(context instanceof Activity) && context instanceof ContextWrapper) {
        context = ((ContextWrapper) context).getBaseContext();
      }
      if (!(context instanceof Activity)) {
        throw new IllegalStateException(
            "Expected an activity context, got " + context.getClass().getSimpleName());
      }
      return (Activity) context;
    }
focal_method.class_method_signature: ViewHelper.getActivity(final Context viewContext)
focal_method.full_signature: public Activity getActivity(final Context viewContext)
focal_method.identifier: getActivity
focal_method.invocations: getBaseContext getSimpleName getClass
focal_method.modifiers: public
focal_method.parameters: (final Context viewContext)
focal_method.return: Activity
focal_method.signature: Activity getActivity(final Context viewContext)