Uploaded image for project: 'Kafka'
  1. Kafka
  2. KAFKA-3623

Make KStreamTestDriver extending from ExternalResource

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • None
    • 1.0.0
    • streams

    Description

      In unit test we have lots of duplicate code for closing KStreamTestDriver upon completing the test:

          @After
          public void tearDown() {
              if (driver != null) {
                  driver.close();
              }
              driver = null;
          }
      

      One way to remove this duplicate code is to make KStreamTestDriver extending from ExternalResource. By doing this we need to move the constructor logic into a setup / init function and leave the construction empty.

      Attachments

        Issue Links

          Activity

            People

              johnma Mariam John
              guozhang Guozhang Wang
              Guozhang Wang Guozhang Wang
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: