Uploaded image for project: 'Code Tools'
  1. Code Tools
  2. CODETOOLS-7901086

Tests with non-product options should require a non-product build

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Not an Issue
    • Icon: P4 P4
    • None
    • None
    • tools
    • None
    • generic
    • generic

      Many jtreg tests use non-product command line options for one reason or another (a common reason is to achieve the state to be tested more easily or reliably than could be done without the use of the option). However, without additional work this will result in the test failing when run against a product build.

      The present idiom for dealing with this problem is to use -XX:+IgnoreUnrecognizedVMOptions, so that the non-product options are ignored by product builds. There are several problems with this idiom that make it less than an ideal solution.

      - A typo in an option of interest will cause it to simply be ignored, which could lead to an inappropriate pass even for non-product builds.

      - Simply discarding the non-product options could result in an option set that isn't an actually valid combination.

      It seems like a better approach would be to extend the new @requires tag to have another vm value designating the kind of build that is required by the test, or perhaps that a non-product build is required.

            Unassigned Unassigned
            kbarrett Kim Barrett
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: