bloritsch 2002/09/25 07:55:01
Added: event/src/test/org/apache/excalibur/util/test
SystemUtilTestCase.java
Log:
finish moving stuff over from util
Revision Changes Path
1.1
jakarta-avalon-excalibur/event/src/test/org/apache/excalibur/util/test/SystemUtilTestCase.java
Index: SystemUtilTestCase.java
===================================================================
/*
* Copyright The Apache Software Foundation. All rights reserved.
*
* This software is published under the terms of the Apache Software License
* version 1.1, a copy of which has been included with this distribution in
* the LICENSE.txt file.
*/
package org.apache.excalibur.util.test;
import junit.framework.TestCase;
import org.apache.excalibur.util.SystemUtil;
/**
* This is used to test SystemUtil for correctness.
*
* @author <a href="mailto:[EMAIL PROTECTED]">Peter Donald</a>
*/
public final class SystemUtilTestCase
extends TestCase
{
public SystemUtilTestCase( String name )
{
super( name );
}
public void testSystemUtil()
{
System.out.println( "Number of Processors: " + SystemUtil.numProcessors() );
System.out.println( "CPU Info: " + SystemUtil.cpuInfo() );
System.out.println( "Architecture: " + SystemUtil.architecture() );
System.out.println( "Operating System: " + SystemUtil.operatingSystem()
);
System.out.println( "OS Version: " + SystemUtil.osVersion() );
assertEquals( SystemUtil.architecture(), System.getProperty( "os.arch" ) );
assertEquals( SystemUtil.operatingSystem(), System.getProperty( "os.name" )
);
assertEquals( SystemUtil.osVersion(), System.getProperty( "os.version" ) );
}
}
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>