CODETOOLS-7900898: Provide jtreg policy option that doesn't override system policy

Mandy Chung mandy.chung at oracle.com
Mon Aug 18 20:53:32 UTC 2014


jtreg /policy option overrides the system policy file and the test
policy file would have to duplicate the system policy grant statements
which is different than the default behavior when the test is run
standalone outside of jtreg with a security manager.

This patch proposes to provide a new jtreg /java.security.policy option
such that
    @run /java.security.policy=test.policy
    - it will extend the default system policy

    @run /java.security.policy==test.policy
    - this is equivalent to /policy option and it will override
      the default system policy.
  
This is the same way as how -Djava.security.policy system property
is specified and prepend "=" in front of the policy name specifies
to override the default system policy.

Webrev:
   http://cr.openjdk.java.net/~mchung/codetools/webrevs/7900898/

I have verified this patch with running jtreg with a few jdk regression
tests updated to use this new option.

Mandy



More information about the jtreg-dev mailing list