This document contains a simple description of XPCOM tests.

- Tests for X2JIN xpcom component.
- Tests for X2JOUT xpcom component.
- Tests for X2JINOUT xpcom component.
- Tests for X2JRET xpcom component.
- Tests for J2XIN xpcom component.
- Tests for J2XOUT xpcom component.
- Tests for J2XINOUT xpcom component.
- Tests for J2XRET xpcom component.

## 1. Tests for X2JIN xpcom component.

Client part of the X2JIN component is written in C++.
Server part of the X2JIN component is written in Java.
How it works: Client part is loaded by Mozilla browser and loads server part of component. After that, client part sets different parameters and tries to invoke methods with these parameters from the server part.
Expected result: Parameters, which were set in client part, are transferred to the server part correctly.
List of test methods:
testShort(in short);
testInt(in long);
testLong(in long long);
testByte(in octet);
testUShort(in unsigned short);
testUInt(in unsigned long);
testULong(in unsigned long long);
testFloat(in float);
testDouble(in double);
testBoolean(in boolean);
testChar(in char);
testWChar(in wchar);
testString(in string);
testWString(in wstring);
testStringArray(in unsigned long,[array, size_is(count)] in string);
testIntArray(in unsigned long, [array, size_is(count)] in long);
testCharArray(in unsigned long,[array, size_is(count)] in char);
testMixed(in boolean, in char, in octet, in short, in unsigned short, in long, in unsigned long, in long long, in unsigned long long, in float, in double, in string, in unsigned long, [array, size_is(count)] in long);
testObject(in iX2JINServerTestComponent);

## 2. Tests for X2JOUT xpcom component.

Client part of the X2JOUT component is written in C++.
Server part of the X2JOUT component is written in Java.
How it works: Client part is loaded by Mozilla browser and loads server part of component. After that, client part gets different parameters invoking methods from the server part.
Expected result: Parameters, which were set in server part, are transferred to the client part correctly.
List of test methods:
testShort(out short);
testInt(out long);
testLong(out long long);
testByte(out octet);
testUShort(out unsigned short);
testUInt(out unsigned long);
testULong(out unsigned long long);
testFloat(out float);
testDouble(out double);
testBoolean(out boolean);
testChar(out char);
testWChar(out wchar);
testString(out string);
testWString(out wstring);
testStringArray(in unsigned long,[array, size_is(count)] out string);
testIntArray(in unsigned long, [array, size_is(count)] out long);
testCharArray(in unsigned long,[array, size_is(count)] out char);
testMixed(out boolean, out char, out octet, out short, out unsigned short, out long, out unsigned long, out long long, out unsigned long long, out float, out double, out string, in unsigned long, [array, size_is(count)] out long);
testObject(out iX2JOUTServerTestComponent);

## 3. Tests for X2JINOUT xpcom component.

Client part of the X2JINOUT component is written in C++.
Server part of the X2JINOUT component is written in Java.
How it works: Client part is loaded by Mozilla browser and loads server part of component. After that, client part sets different parameters and transfers them to the server part. The server part transfers these parameters back to the client part.
Expected result: Parameters, which were set in the client part, are transferred to the server part and back to the client part correctly.
List of test methods:
testShort(inout short);
testInt(inout long);
testLong(inout long long);
testByte(inout octet);
testUShort(inout unsigned short);
testUInt(inout unsigned long);
testULong(inout unsigned long long);
testFloat(inout float);
testDouble(inout double);
testBoolean(inout boolean);
testChar(inout char);
testWChar(inout wchar);
testString(inout string);
testWString(inout wstring);
testStringArray(in unsigned long,[array, size_is(count)] inout string);
testIntArray(in unsigned long, [array, size_is(count)] inout long);
testCharArray(in unsigned long,[array, size_is(count)] inout char);
testMixed(inout boolean, inout char, inout octet, inout short, inout unsigned short, inout long, inout unsigned long, inout long long, inout unsigned long long, inout float, inout double, inout string, in unsigned long, [array, size_is(count)] inout long);
testObject(inout iX2JINOUTServerTestComponent);

## 4. Tests for X2JRET xpcom component.

Client part of the X2JRET component is written in C++.
Server part of the X2JRET component is written in Java.
How it works: Client part is loaded by Mozilla browser and loads server part of component. After that, client part gets different parameters invoking methods from the server part, using retval.
Expected result: Parameters, which were set in server part, are transferred to the client part correctly.
List of test methods:
short testShort();
long testInt();
long long testLong();
octet testByte();
unsigned short testUShort();
unsigned long testUInt();
unsigned long long testULong();
float testFloat();
double testDouble();
boolean testBoolean();
char testChar();
wchar testWChar();
string testString();
wstring testWString();
void testStringArray(in unsigned long count, [retval, array, size_is(count)] out string stringArray);
void testIntArray(in unsigned long count, [retval, array, size_is(count)] out long intArray);
void testCharArray(in unsigned long count,[retval, array, size_is(count)] out char charArray);
iX2JRETServerTestComponent testObject();

## 5. Tests for J2XIN xpcom component.

Client part of the J2XIN component is written in Java.
Server part of the J2XIN component is written in C++.
How it works: Client part is loaded by Mozilla browser and loads server part of component. After that, client part sets different parameters and tries to invoke methods with these parameters from the server part.
Expected result: Parameters, which were set in client part, are transferred to the server part correctly.
List of test methods:
testShort(in short);
testInt(in long);
testLong(in long long);
testByte(in octet);
testUShort(in unsigned short);
testUInt(in unsigned long);
testULong(in unsigned long long);
testFloat(in float);
testDouble(in double);
testBoolean(in boolean);
testChar(in char);
testWChar(in wchar);
testString(in string);
testWString(in wstring);
testStringArray(in unsigned long,[array, size_is(count)] in string);
testIntArray(in unsigned long, [array, size_is(count)] in long);
testCharArray(in unsigned long,[array, size_is(count)] in char);
testMixed(in boolean, in char, in octet, in short, in unsigned short, in long, in unsigned long, in long long, in unsigned long long, in float, in double, in string, in unsigned long, [array, size_is(count)] in long);
testObject(in iJ2XINServerTestComponent);

## 6. Tests for J2XOUT xpcom component.

Client part of the J2XOUT component is written in Java.
Server part of the J2XOUT component is written in C++.
How it works: Client part is loaded by Mozilla browser and loads server part of component. After that, client part gets different parameters invoking methods from the server part.
Expected result: Parameters, which were set in server part, are transferred to the client part correctly.
List of test methods:
testShort(out short);
testInt(out long);
testLong(out long long);
testByte(out octet);
testUShort(out unsigned short);
testUInt(out unsigned long);
testULong(out unsigned long long);
testFloat(out float);
testDouble(out double);
testBoolean(out boolean);
testChar(out char);
testWChar(out wchar);
testString(out string);
testWString(out wstring);
testStringArray(in unsigned long,[array, size_is(count)] out string);
testIntArray(in unsigned long, [array, size_is(count)] out long);
testCharArray(in unsigned long,[array, size_is(count)] out char);
testMixed(out boolean, out char, out octet, out short, out unsigned short, out long, out unsigned long, out long long, out unsigned long long, out float, out double, out string, in unsigned long, [array, size_is(count)] out long);
testObject(out iJ2XOUTServerTestComponent);

## 7. Tests for J2XINOUT xpcom component.

Client part of the J2XINOUT component is written in Java.
Server part of the J2XINOUT component is written in C++.
How it works: Client part is loaded by Mozilla browser and loads server part of component. After that, client part sets different parameters and transfers them to the server part. The server part transfers these parameters back to the client part.
Expected result: Parameters, which were set in the client part, are transferred to the server part and back to the client part correctly.
List of test methods:
testShort(inout short);
testInt(inout long);
testLong(inout long long);
testByte(inout octet);
testUShort(inout unsigned short);
testUInt(inout unsigned long);
testULong(inout unsigned long long);
testFloat(inout float);
testDouble(inout double);
testBoolean(inout boolean);
testChar(inout char);
testWChar(inout wchar);
testString(inout string);
testWString(inout wstring);
testStringArray(in unsigned long,[array, size_is(count)] inout string);
testIntArray(in unsigned long, [array, size_is(count)] inout long);
testCharArray(in unsigned long,[array, size_is(count)] inout char);
testMixed(inout boolean, inout char, inout octet, inout short, inout unsigned short, inout long, inout unsigned long, inout long long, inout unsigned long long, inout float, inout double, inout string, in unsigned long, [array, size_is(count)] inout long);
testObject(inout iJ2XINOUTServerTestComponent);

## 8. Tests for J2XRET xpcom component.

Client part of the J2XRET component is written in Java.
Server part of the J2XRET component is written in C++.
How it works: Client part is loaded by Mozilla browser and loads server part of component. After that, client part gets different parameters invoking methods from the server part, using retval.
Expected result: Parameters, which were set in server part, are transferred to the client part correctly.
List of test methods:
short testShort();
long testInt();
long long testLong();
octet testByte();
unsigned short testUShort();
unsigned long testUInt();
unsigned long long testULong();
float testFloat();
double testDouble();
boolean testBoolean();
char testChar();
wchar testWChar();
string testString();
wstring testWString();
void testStringArray(in unsigned long count, [retval, array, size_is(count)] out string stringArray);
void testIntArray(in unsigned long count, [retval, array, size_is(count)] out long intArray);
void testCharArray(in unsigned long count,[retval, array, size_is(count)] out char charArray);
iJ2XRETServerTestComponent testObject();