Return-Path: Mailing-List: contact user-help@ant.apache.org; run by ezmlm Delivered-To: mailing list user@ant.apache.org Received: (qmail 14309 invoked from network); 13 Mar 2003 21:03:27 -0000 Received: from mail.ureach.com (HELO ureach.com) (63.150.151.36) by daedalus.apache.org with SMTP; 13 Mar 2003 21:03:27 -0000 Received: from www22.ureach.com (www22.ureach.com [172.16.2.50]) by ureach.com (8.9.1/8.8.5) with ESMTP id QAA24484 for ; Thu, 13 Mar 2003 16:03:32 -0500 Received: (from nobody@localhost) by www22.ureach.com (8.9.3/8.9.1) id QAA04170; Thu, 13 Mar 2003 16:03:32 -0500 Date: Thu, 13 Mar 2003 16:03:32 -0500 Message-Id: <200303132103.QAA04170@www22.ureach.com> Received: from [64.2.72.226] by www22.ureach.com via HTTP; Thu, 13 Mar 2003 21:03:32 GMT To: user@ant.apache.org From: otisg Reply-to: Subject: Junit and java.security.AccessControlException: access denied (file permission) Mime-Version: 1.0 Content-Type: Text/Plain; charset=iso-8859-1 Content-Transfer-Encoding: 7bit X-vsuite-type: e X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N Hello, I am using Ant 1.5.2 with JDK 1.4.1_02 on a Red Hat 7.3. Then running JUnit task I always get an error such as this one: [junit] Running net.wgen.amp.action.ExampleActionTest [junit] Exception in thread "main" java.security.AccessControlException: access denied (java.io.FilePermission /home/otis/wgen/eclipse-workspace/mclass/ampNG/build/reports/ut/TEST-net.wgen.amp.action.ExampleActionTest.xml write) [junit] at java.security.AccessControlContext.checkPermission(AccessControlContext.java:270) [junit] at java.security.AccessController.checkPermission(AccessController.java:401) [junit] at java.lang.SecurityManager.checkPermission(SecurityManager.java:542) [junit] at java.lang.SecurityManager.checkWrite(SecurityManager.java:975) [junit] at java.io.FileOutputStream.(FileOutputStream.java:169) [junit] at java.io.FileOutputStream.(FileOutputStream.java:131) [junit] at org.apache.tools.ant.taskdefs.optional.junit.FormatterElement.createFormatter(FormatterElement.java:206) [junit] at org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner.createAndStoreFormatter(JUnitTestRunner.java:562) [junit] at org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner.main(JUnitTestRunner.java:507) [junit] TEST net.wgen.amp.action.ExampleActionTest FAILED I cannot figure out why this is happening. Even if I do 'chmod -R 777 reports' (reports is the directory where unit test reports go) and re-run Ant, I still get the same error! Even if I touch the XML file that supposedly cannot be created/written to disk, and make it world writable, I still get the error. Does anyone know what the problem is here? Thank you, Otis ________________________________________________ Get your own "800" number Voicemail, fax, email, and a lot more http://www.ureach.com/reg/tag