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

disallow library references outside the test suite

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Fixed
    • Icon: P3 P3
    • jtreg4.1
    • jtreg4.1
    • tools
    • None
    • b13

      Jonathan Gibbons :
      We've been here before, CODETOOLS-7901527, and addressed this problem already. dot-dotting out of the test directory is not good, and there's a feature in place that tests should be using instead. It's probably no coincidence that there are two .. and we've lost two components in the corresponding entry in the classpath.

      Perhaps in the upcoming b13 we should flat out prohibit use of /.. in @library declarations.

      Igor Ignatyev:
      I think it definitely makes sense to prohibit slash-dot in @library, although just dot can be acceptable.

      Jonathan Gibbons:
      jtreg normalizes the files, so any simple leading ./ will have disappeared by the time the check is made.

      Igor Ignatyev:
      I'm sorry I meant 'dot-dot', so prohibit slash-dot-dot, but still allow dot-dot. in some cases we have testlibrary specific for some group of tests located near them, smth like
       - /foo/share/Lib.java
       - /foo/bar/TestA.java
       - /foo/bar/TestB.java
       - /foo/baz/TestC.java
       - /foo/baz/TestD.java

      Test{A,B,C,D} have '@library ../share'

            jjg Jonathan Gibbons
            iignatyev Igor Ignatyev (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: