Uploaded image for project: 'Bookkeeper'
  1. Bookkeeper
  2. BOOKKEEPER-352

Should not use static ServerStats/BKStats instance in TestServerStats/TestBKStats

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 4.2.0
    • 4.2.0, 4.1.1
    • None
    • None

    Description

      TestServers failed when running whole test. Because TestServers uses ServerStats instance directly. ServerStats is a static instance, which will be used across whole testing. so the numSuccessOps would not be zero, the assertion would fail.

      Same problem occurs in TestBKStats. TestBKStats doesn't fail because statistics is turned off by default. The value happened to be zero. But it still is not a good idea to use static instance during testing.

      Attachments

        1. BOOKKEEPER-352.diff
          2 kB
          Sijie Guo

        Activity

          People

            hustlmsp Sijie Guo
            hustlmsp Sijie Guo
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: