Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 14 for addTearDown (0.26 sec)

  1. guava-testlib/test/com/google/common/testing/TearDownStackTest.java

        final ThrowingTearDown tearDownOne = new ThrowingTearDown("one");
        stack.addTearDown(tearDownOne);
    
        final ThrowingTearDown tearDownTwo = new ThrowingTearDown("two");
        stack.addTearDown(tearDownTwo);
    
        assertEquals(false, tearDownOne.ran);
        assertEquals(false, tearDownTwo.ran);
    
        try {
          stack.runTearDown();
          fail("runTearDown should have thrown an exception");
        } catch (ClusterException expected) {
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Fri Jun 21 10:19:29 UTC 2024
    - 4.6K bytes
    - Viewed (0)
  2. android/guava-testlib/test/com/google/common/testing/TearDownStackTest.java

        final ThrowingTearDown tearDownOne = new ThrowingTearDown("one");
        stack.addTearDown(tearDownOne);
    
        final ThrowingTearDown tearDownTwo = new ThrowingTearDown("two");
        stack.addTearDown(tearDownTwo);
    
        assertEquals(false, tearDownOne.ran);
        assertEquals(false, tearDownTwo.ran);
    
        try {
          stack.runTearDown();
          fail("runTearDown should have thrown an exception");
        } catch (ClusterException expected) {
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Fri Jun 21 10:19:29 UTC 2024
    - 4.6K bytes
    - Viewed (0)
  3. android/guava-tests/test/com/google/common/util/concurrent/InterruptionUtil.java

            new Interruptenator(Thread.currentThread(), interruptPeriodMillis);
        final Thread interruptingThread = new Thread(interruptingTask);
        interruptingThread.start();
        tearDownAccepter.addTearDown(
            new TearDown() {
              @Override
              public void tearDown() throws Exception {
                interruptingTask.stopInterrupting();
                interruptingThread.interrupt();
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Mon Dec 04 17:37:03 UTC 2017
    - 4.4K bytes
    - Viewed (0)
  4. guava-testlib/test/com/google/common/testing/TestLogHandlerTest.java

        // You could also apply it higher up the Logger hierarchy than this
        ExampleClassUnderTest.logger.addHandler(handler);
    
        ExampleClassUnderTest.logger.setUseParentHandlers(false); // optional
    
        stack.addTearDown(
            new TearDown() {
              @Override
              public void tearDown() throws Exception {
                ExampleClassUnderTest.logger.setUseParentHandlers(true);
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Mon Dec 04 17:37:03 UTC 2017
    - 2.8K bytes
    - Viewed (0)
  5. android/guava-testlib/src/com/google/common/testing/TearDownAccepter.java

       *
       * <p>In JUnit4 language, that means as an {@code @After}.
       *
       * <p>In JUnit3 language, that means during the {@link junit.framework.TestCase#tearDown()} step.
       */
      void addTearDown(TearDown tearDown);
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Fri May 12 19:22:18 UTC 2023
    - 1.3K bytes
    - Viewed (0)
  6. guava-testlib/src/com/google/common/testing/TearDownAccepter.java

       *
       * <p>In JUnit4 language, that means as an {@code @After}.
       *
       * <p>In JUnit3 language, that means during the {@link junit.framework.TestCase#tearDown()} step.
       */
      void addTearDown(TearDown tearDown);
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Fri May 12 19:22:18 UTC 2023
    - 1.3K bytes
    - Viewed (0)
  7. android/guava-testlib/src/com/google/common/testing/TestLogHandler.java

     *
     * <pre>
     *   TestLogHandler handler;
     *
     *   protected void setUp() throws Exception {
     *     super.setUp();
     *     handler = new TestLogHandler();
     *     SomeClass.logger.addHandler(handler);
     *     addTearDown(new TearDown() {
     *       public void tearDown() throws Exception {
     *         SomeClass.logger.removeHandler(handler);
     *       }
     *     });
     *   }
     *
     *   public void test() {
     *     SomeClass.foo();
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Fri Jun 21 20:53:25 UTC 2024
    - 2.8K bytes
    - Viewed (0)
  8. guava-testlib/src/com/google/common/testing/TearDownStack.java

      public TearDownStack() {
        this.suppressThrows = false;
      }
    
      public TearDownStack(boolean suppressThrows) {
        this.suppressThrows = suppressThrows;
      }
    
      @Override
      public final void addTearDown(TearDown tearDown) {
        synchronized (lock) {
          stack.addFirst(checkNotNull(tearDown));
        }
      }
    
      /** Causes teardown to execute. */
      public final void runTearDown() {
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Fri Jun 21 10:19:29 UTC 2024
    - 2.5K bytes
    - Viewed (0)
  9. android/guava-testlib/src/com/google/common/testing/TearDownStack.java

      public TearDownStack() {
        this.suppressThrows = false;
      }
    
      public TearDownStack(boolean suppressThrows) {
        this.suppressThrows = suppressThrows;
      }
    
      @Override
      public final void addTearDown(TearDown tearDown) {
        synchronized (lock) {
          stack.addFirst(checkNotNull(tearDown));
        }
      }
    
      /** Causes teardown to execute. */
      public final void runTearDown() {
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Fri Jun 21 10:19:29 UTC 2024
    - 2.5K bytes
    - Viewed (0)
  10. android/guava-testlib/test/com/google/common/testing/TestLogHandlerTest.java

        // You could also apply it higher up the Logger hierarchy than this
        ExampleClassUnderTest.logger.addHandler(handler);
    
        ExampleClassUnderTest.logger.setUseParentHandlers(false); // optional
    
        stack.addTearDown(
            new TearDown() {
              @Override
              public void tearDown() throws Exception {
                ExampleClassUnderTest.logger.setUseParentHandlers(true);
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Mon Dec 04 17:37:03 UTC 2017
    - 2.8K bytes
    - Viewed (0)
Back to top