@Test
public void testEarlyBuildUponUsage() throws Throwable {

  // simulate building upon a final @Rule at the class-level
  Mockspresso mockspresso = mRule.buildUpon().build();
  Statement base = verifyChildDelegateStatement(mockspresso, mChildMockspresso);
  Statement result = mRule.apply(base, mFrameworkMethod, mTarget);
  result.evaluate();
  InOrder inOrder = Mockito.inOrder(mConfig, mBuilderProvider, mBuilder, base, mConfig, mChildConfig, mChildBuilder, mChildMockspresso);
  inOrder.verify(mBuilderProvider).get();
  inOrder.verify(mBuilder).deepCopy();
  inOrder.verify(mBuilder).testResourcesWithoutLifecycle(mTarget);
  inOrder.verify(mBuilder).buildInternal();
  inOrder.verify(mConfig).setup(mOriginal);
  inOrder.verify(mChildBuilder).deepCopy();
  inOrder.verify(mChildBuilder).buildInternal();
  inOrder.verify(mChildConfig).setup(mChildMockspresso);
  inOrder.verify(base).evaluate();
  inOrder.verify(mChildConfig).teardown();
  inOrder.verify(mConfig).teardown();
  assertMockspressoNoLongerWorks(mockspresso);
  assertRuleNoLongerWorks();
}