db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ramandeep Kaur" <ramandhin...@gmail.com>
Subject Re: code coverage: problem in running junit suite lang with emma
Date Tue, 20 Feb 2007 04:30:20 GMT
I tried the following, but non of them worked.

1. I added line "permission java.security.AllPermission;" to the following
in derby_tests.policy:-

grant {
    permission java.util.PropertyPermission "derbyRoutineSecurityTest.yes",
"read";
};

became

grant {
    permission java.util.PropertyPermission "derbyRoutineSecurityTest.yes",
"read";
    permission java.security.AllPermission;    //added line
};

The above worked for all junit suites except lang.
With the above, lang suite got hung up as following:
EMMA: collecting runtime coverage data
.........................................
.........................................
........................................F.

2. I also added line "permission java.io.FilePermission
"${user.home}${/}coverage.ec",
"read,write,delete";"  to the following in derby_tests.policy:

grant {
    permission java.util.PropertyPermission "derbyRoutineSecurityTest.yes",
"read";
};

became

grant {
    permission java.util.PropertyPermission "derbyRoutineSecurityTest.yes",
"read";
    permission java.io.FilePermission "${user.home}${/}coverage.ec",
"read,write,delete";   //added line
};

With the above change in derby_tests.policy file, I got the following
exception:
 java.security.AccessControlException: access denied
(java.io.FilePermissionC:\Documents and Settings\raman\coverage.ec
read


--
Ramandeep Kaur
ramandhindsa@gmail.com

Mime
View raw message