logging-log4php-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From grobme...@apache.org
Subject svn commit: r794427 - /incubator/log4php/trunk/src/test/php/appenders/LoggerAppenderFileTest.php
Date Wed, 15 Jul 2009 21:50:25 GMT
Author: grobmeier
Date: Wed Jul 15 21:50:25 2009
New Revision: 794427

URL: http://svn.apache.org/viewvc?rev=794427&view=rev
Log:
test needs to use another folder than the original target folder

Modified:
    incubator/log4php/trunk/src/test/php/appenders/LoggerAppenderFileTest.php

Modified: incubator/log4php/trunk/src/test/php/appenders/LoggerAppenderFileTest.php
URL: http://svn.apache.org/viewvc/incubator/log4php/trunk/src/test/php/appenders/LoggerAppenderFileTest.php?rev=794427&r1=794426&r2=794427&view=diff
==============================================================================
--- incubator/log4php/trunk/src/test/php/appenders/LoggerAppenderFileTest.php (original)
+++ incubator/log4php/trunk/src/test/php/appenders/LoggerAppenderFileTest.php Wed Jul 15 21:50:25
2009
@@ -26,8 +26,8 @@
 class LoggerAppenderFileTest extends PHPUnit_Framework_TestCase {
      
     protected function setUp() {
-        if(file_exists('../../../target/phpunit/TEST.txt')) {
-	        unlink('../../../target/phpunit/TEST.txt');
+        if(file_exists('../../../target/temp/phpunit/TEST.txt')) {
+	        unlink('../../../target/temp/phpunit/TEST.txt');
         }
     }
     
@@ -40,19 +40,19 @@
     									"my message");
     	
     	$appender = new LoggerAppenderFile("mylogger"); 
-		$appender->setFileName('../../../target/phpunit/TEST.txt');
+		$appender->setFileName('../../../target/temp/phpunit/TEST.txt');
 		$appender->setLayout($layout);
 		$appender->activateOptions();
 		$appender->append($event);
 		$appender->close();
 
-		$v = file_get_contents('../../../target/phpunit/TEST.txt');		
+		$v = file_get_contents('../../../target/temp/phpunit/TEST.txt');		
 		$e = "WARN - my message".PHP_EOL;
 		self::assertEquals($e, $v);
     }
      
     protected function tearDown() {
-        unlink('../../../target/phpunit/TEST.txt');
-        rmdir('../../../target/phpunit');
+        unlink('../../../target/temp/phpunit/TEST.txt');
+        rmdir('../../../target/temp/phpunit');
     }
 }



Mime
View raw message