rpallath%eng.sun.com 05cfe5ff5d dding new files
git-svn-id: svn://10.0.0.236/trunk@63213 18797224-902f-48f8-a5cc-f745e15eee43
2000-03-17 00:27:29 +00:00

110 lines
5.1 KiB
HTML

<html>
<head>
<title>
Browser side Pluglet API tests
</title>
</head>
<body bgcolor=White>
<center><HR1>Browser side Pluglet API tests</HR1></center>
<OL>
<A href=#location><LI></A>Tests location.
<A href=#struct><LI></A>Tests struct.
<A href=#pre-build><LI></A>Pre-build requirements.
<A href=#make><LI></A>Make instructions.
<A href=#run><LI></A>Run API tests.
<A href=#log><LI></A>Log files.
<A href=description.html><LI></A>Testcase description.
</OL>
<OL>
<A name=location><LI>Tests location:
<UL>
<LI>This document concerned tests in directory <B>src/org/mozilla/pluglet/test/basic/api</B><BR>
at the your Pluglet tests location.
</UL>
<A name=struct>
<LI>Tests struct:<BR>
Test may contains the next files:
<UL>
<LI>Test java file - test execution and result verification code
<LI>Arguments iterator java - code for read lst file and transfer arguments to TestContext
</UL>
And test dir with:
<UL>
<LI>TestProperties file - testcase properties, contains test, iterator and initial html file names
<LI>TestParameters file - user/location specific parameters for test arguments
<LI>ParamCombinations file - combinations of values for each argument.(for generate default lst file)
<LI>TestArguments(.lst) file - list of all combinations of arguments (generated from ParamCombinations file)
<LI>Misc HTML files - at least one html file with EMBED(or OBJECT) tag for instantiate pluglet and<BR>
other html files needed for testcase.
</UL>
<I>- Each test contains Test and Iterator java files, TestProperties file and at least one HTML file</I><BR>
<I>- TestParameters file exist only for tests with user/location specific parameters</I><BR>
<I>- ParamCombinations exist only for tests on methods with arguments</I><BR>
<I>- TestArguments(.lst) file created during make combinations from ParamCombinations file and<BR>
&nbsp;&nbsp only for tests on methods with arguments.
<div align=right><A href=#top>index</A></div>
<A name=pre-build>
<LI>Pre-build requirements:
<UL>
<LI>Build Mozilla and java plugins
<LI>Edit <B>TEST_TOP_DIR/config/CommonProperties</B> to change user/location specific parameters, e.g <B>PLUGLET</B>,<B>HTML_ROOT</B> etc ..
<LI>In each test dir edit TestParameters, if it exist(and you want to run this testcase)
<LI>Set environment variable HTML_ROOT_DIR to directory on your local filesystem, where test HTMLs will be created
<LI>Verify that <B>MOZILLA_FIVE_HOME/dist/classes</B> exist in your <B>CLASSPATH</B>
<LI>Place <B>TEST_TOP_DIR/build/classes</B> in your <B>CLASSPATH</B>
<LI>Performs make in top level directory <B>basic</B> and verify that TestLoaderPluglet.jar successfully created<BR>
and placed to TEST_TOP_DIR/build/classes/org/mozilla/pluglet/test/basic</B><BR>
<B>PLUGLET</B> property in <B>CommonProperties</B> should point to it.
</UL>
<div align=right><A href=#top>index</A></div>
<A name=make>
<LI>Make instructions:<BR>
Top level makefile in the api directory has next targets:
<UL>
<LI>combinations - used for create BWTest.lst.ORIG for all api tests and generate
default lst files for each test (if necessary) or just add test id to BWTest.lst.ORIG
<LI>tests - make all in test dirs:<BR>
- copy HTML files to HTML_ROOT_DIR/api/test_case_name directory<BR>
- replace user/location specific parameters(from CommonProperties) in TestProperties file<BR>
- copy TestProperties file to BUILD/test/test_id directory<BR>
- replace user-defined parameters in the default lst file
and copy it to BUILD/test/test_id directory (if necessary)<BR>
<LI>test_pluglet - create jar with test classes
<LI>classes - compile all java files in the api directory
<LI>clobber - remove builded files:<BR>
- remove HTML files from HTML_ROOT_DIR<BR>
- remove TestProperties and .lst files from BUILD/test/test_id directory
</UL>
By default classes, tests and test_pluglet targets executed.<BR>
NOTE:<BR>
<I>You need to do combinations only one time, and
only if you change ParamCombinations file for some
tests or add new test cases</I><BR>
Build sequence(Win):
<UL>
<LI>Performs all pre-build instructions.
<LI>In the api directory type nmake -f makefile.win
</UL>
<div align=right><A href=#top>index</A></div>
<A name=run>
<LI>Run API tests.
<UL>
<LI>Performs all pre-build and build instructions
<LI>For run all API tests copy <B>TEST_TOP_DIR/build/test/basic/api/BWTest.lst.ORIG</B> to
the current directory and just type <B>perl autorun.pl</B>
<LI>For run selected API tests copy some test IDs from BWTest.lst.ORIG
to your custom file(for example custom.lst) and type <B>perl autorun.pl -f custom.lst</B>
</UL>
<div align=right><A href=#top>index</A></div>
<A name=log>
<LI>Log files:
<UL>
<LI>After tests execution all logs located in the <B>TEST_TOP_DIR/log</B> directory
<LI>BWTestRun.log contains comments and results from test and test loader
<LI>BWTestRun.txt contains status for each test, e.g. PASSED or FAILED
<LI>File test_name.log contains Mozilla's output
</UL>
</OL>
<div align=right><A href=#top>index</A></div>
</body>
</html>