LogQueryEntryImplTestpublic final class LogQueryEntryImplTest extends TestCase
Fields Summary |
---|
private static final String | N1 | private static final String | V1 | private static final String | N2 | private static final String | V2 |
Constructors Summary |
---|
public LogQueryEntryImplTest()
|
Methods Summary |
---|
public static com.sun.appserv.management.ext.logging.LogQueryEntryImpl | createDummy()
return new LogQueryEntryImpl(
0,
new Date(),
Level.OFF.toString(),
"Sun Appserver whatever",
"hello world",
"MSG01",
"module",
nvp(N1,V1) + ";" + nvp(N2,V2) );
| private static java.lang.String | nvp(java.lang.String name, java.lang.String value)
return( name + "=" + value );
| public void | testCreate()
createDummy();
| public void | testEquals()
final LogQueryEntryImpl d = createDummy();
assertEquals( d, d );
final LogQueryEntryImpl dCopy = new LogQueryEntryImpl(
d.getRecordNumber(),
d.getDate(),
d.getLevel(),
d.getProductName(),
d.getMessage(),
d.getMessageID(),
d.getModule(),
d.getNameValuePairs() );
assertEquals( d, dCopy );
assertEquals( dCopy, d );
| public void | testGetNameValuePairsMap()
final LogQueryEntryImpl d = createDummy();
final Map<String,String> m = d.getNameValuePairsMap();
assertEquals( V1, m.get( N1 ) );
assertEquals( V2, m.get( N2 ) );
| public void | testGetters()
final LogQueryEntryImpl d = createDummy();
d.getRecordNumber();
d.getDate();
d.getLevel();
d.getMessage();
d.getMessageID();
d.getModule();
d.getMessage();
d.getNameValuePairs();
d.getNameValuePairsMap();
|
|