| java.lang.Object com.sun.midp.i3test.TestCase javax.microedition.sip.SipHeaderBaseTest
All known Subclasses: javax.microedition.sip.TestViaHeader, javax.microedition.sip.TestMaxForwardsHeader, javax.microedition.sip.TestContactHeader, javax.microedition.sip.TestCSeqHeader, javax.microedition.sip.TestMultilineHeaders, javax.microedition.sip.TestShortHeaderNames, javax.microedition.sip.TestCallIdHeader, javax.microedition.sip.TestFromHeader, javax.microedition.sip.TestToHeader, javax.microedition.sip.TestParameterLessHeader,
SipHeaderBaseTest | abstract public class SipHeaderBaseTest extends TestCase (Code) | | This is a base class for all Test<HeaderName>Header classes.
|
Method Summary | |
protected SipHeader | createSipHeader(String headerName, String headerParam) Creates SipHeader with the specified name and parameter.
Parameters: headerName - header's name. Parameters: headerParam - header's parameter. | protected boolean | equalsIgnoreSpaces(String str1, String str2) Compares two strings ignoring the spaces and tabs around delimeters.
Comparision is case-insensitive.
Parameters: str1 - first string to compare. Parameters: str2 - second string to compare. | protected String | removeNewLine(String str) Cuts ending CRLF's if any.
Parameters: str - string to process. | protected String | removeSpaces(String str) Remove spaces/tabs surrounding delimeters in the string.
Parameters: str - string to process. | protected boolean | testConstructorNegative(String headerName, String invalidParam) Checks if an exception is thrown when attempting to create
a header with invalid value.
Parameters: headerName - header's name. Parameters: invalidParam - value that is invalid for this type of header. | protected void | testSetValue(String headerName, String headerParam) Test for setValue() method of Header's subclasses. | protected void | testToString(String headerName, String headerParam) Test for toString() method of Header's subclasses. |
createSipHeader | protected SipHeader createSipHeader(String headerName, String headerParam)(Code) | | Creates SipHeader with the specified name and parameter.
Parameters: headerName - header's name. Parameters: headerParam - header's parameter. SipHeader instance if successfully created, null otherwise. |
equalsIgnoreSpaces | protected boolean equalsIgnoreSpaces(String str1, String str2)(Code) | | Compares two strings ignoring the spaces and tabs around delimeters.
Comparision is case-insensitive.
Parameters: str1 - first string to compare. Parameters: str2 - second string to compare. true if the string are equal, false otherwise. |
removeNewLine | protected String removeNewLine(String str)(Code) | | Cuts ending CRLF's if any.
Parameters: str - string to process. the resulting string. |
removeSpaces | protected String removeSpaces(String str)(Code) | | Remove spaces/tabs surrounding delimeters in the string.
Parameters: str - string to process. the resulting string. |
testConstructorNegative | protected boolean testConstructorNegative(String headerName, String invalidParam)(Code) | | Checks if an exception is thrown when attempting to create
a header with invalid value.
Parameters: headerName - header's name. Parameters: invalidParam - value that is invalid for this type of header. true if the test was passed, false otherwise. |
testSetValue | protected void testSetValue(String headerName, String headerParam)(Code) | | Test for setValue() method of Header's subclasses.
Parameters: headerName - name of the header. Parameters: headerParam - value and parameters of the header. |
testToString | protected void testToString(String headerName, String headerParam)(Code) | | Test for toString() method of Header's subclasses.
Parameters: headerName - name of the header. Parameters: headerParam - value and parameters of the header. |
Methods inherited from com.sun.midp.i3test.TestCase | public void assertEquals(Object expected, Object actual)(Code)(Java Doc) public void assertEquals(String message, Object expected, Object actual)(Code)(Java Doc) public void assertEquals(int expected, int actual)(Code)(Java Doc) public void assertEquals(String message, int expected, int actual)(Code)(Java Doc) public void assertFalse(boolean condition)(Code)(Java Doc) public void assertFalse(String message, boolean condition)(Code)(Java Doc) public void assertNotNull(Object object)(Code)(Java Doc) public void assertNotNull(String message, Object object)(Code)(Java Doc) public void assertNotSame(Object expected, Object actual)(Code)(Java Doc) public void assertNotSame(String message, Object expected, Object actual)(Code)(Java Doc) public void assertNull(Object object)(Code)(Java Doc) public void assertNull(String message, Object object)(Code)(Java Doc) public void assertSame(Object expected, Object actual)(Code)(Java Doc) public void assertSame(String message, Object expected, Object actual)(Code)(Java Doc) public void assertTrue(String message, boolean condition)(Code)(Java Doc) public void assertTrue(boolean condition)(Code)(Java Doc) public void declare(String testName)(Code)(Java Doc) public void fail()(Code)(Java Doc) public void fail(String message)(Code)(Java Doc) protected SecurityToken getSecurityToken()(Code)(Java Doc) protected boolean getVerbose()(Code)(Java Doc) public void info(String s)(Code)(Java Doc) abstract public void runTests() throws Throwable(Code)(Java Doc)
|
|
|