Rio Project 4.2 API Documentation



org.rioproject.test
Class Utils

java.lang.Object
  extended by org.rioproject.test.Utils

public class Utils
extends Object

The class provides utility methods for Rio tests


Constructor Summary
Utils()
           
 
Method Summary
static void assertEqualContents(Collection c1, Collection c2)
          Asserts that two collections have equal contents.
static void assertSameContents(Collection c1, Collection c2)
          Asserts that two collections have the same contents.
static void checkSecurityPolicy()
           
static void close(WatchDataSource dataSource)
          Calls the close() method on a WatchDataSource proxy, ignoring all exceptions.
static String getRioHome()
           
static String getTestClassDirectory()
           
static void setEnvironment()
           
static void sleep(long millis)
          Causes the currently executing thread to sleep (temporarily cease execution) for the specified number of milliseconds.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Utils

public Utils()
Method Detail

setEnvironment

public static void setEnvironment()

checkSecurityPolicy

public static void checkSecurityPolicy()

getRioHome

public static String getRioHome()

getTestClassDirectory

public static String getTestClassDirectory()

close

public static void close(WatchDataSource dataSource)
Calls the close() method on a WatchDataSource proxy, ignoring all exceptions.

Parameters:
dataSource - the object on which to call close()

sleep

public static void sleep(long millis)
Causes the currently executing thread to sleep (temporarily cease execution) for the specified number of milliseconds. The thread does not lose ownership of any monitors. If another thread has interrupted the current thread, the method simply exists.

Parameters:
millis - the length of time to sleep in milliseconds

assertSameContents

public static void assertSameContents(Collection c1,
                                      Collection c2)
Asserts that two collections have the same contents. Having the same contents means being of the same size and containing the same objects in the same order.

Parameters:
c1 - Collection
c2 - Collection

assertEqualContents

public static void assertEqualContents(Collection c1,
                                       Collection c2)
Asserts that two collections have equal contents. Having equal contents means being of the same size and containing the same objects (as in object.equals(otherObject) in the same order.

Parameters:
c1 - Collection
c2 - Collection

Copyright © Rio Project.

Copyright © 2006-2011 Rio Project. All Rights Reserved.