Skip to main content

Script for running TCKs with framework somewhere else

2 replies [Last post]
Anonymous

Hi all,

I've created windows-based script for running TCK with separated ME Framework
and JT Harness. It's very simple in use - just provide locations of these tools
and define JAVA_HOME and use command "launchtck.cmd" instead "java -jar
javatest.jar". I found this script useful during development since it eliminates
routine copying framework into TCK. The script is attached. Just change
extension from .txt to .cmd or .bat

Thanks,
Alexander
@echo off

::set ME_FRAMEWORK_HOME=Specify location of ME Framework
::set JAVATEST_HOME=Specify location of JT Harness

if not defined JAVA_HOME (
echo JAVA_HOME variable not defined!
exit
)

if not defined ME_FRAMEWORK_HOME (
echo ME_FRAMEWORK_HOME variable not defined. Will use %CD%\lib as value.
set ME_FRAMEWORK_HOME=%CD%\lib
)

if not defined JAVATEST_HOME (
echo JAVATEST_HOME variable not defined. Will use %CD%\lib as value.
set JAVATEST_HOME=%CD%\lib
)

%JAVA_HOME%\bin\java -classpath "%ME_FRAMEWORK_HOME%\lib\j2mefw_jt.jar;%ME_FRAMEWORK_HOME%\lib\interviewlib.jar;%JAVATEST_HOME%\lib\javatest.jar" com.sun.javatest.tool.Main %1

---------------------------------------------------------------------
To unsubscribe, e-mail: meframework-unsubscribe@cqme.dev.java.net
For additional commands, e-mail: meframework-help@cqme.dev.java.net

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
Vladimir Sizikov

Alexander,

Thanks for the script!

For the sake of clarity, it should be noted that executing the TCK in
such mode is not an official way, but it might be quite useful while
testing the ME Framework with various TCKs. Also, putting the
framework in the bootclasspath means that only ONE test suite should be
loaded in the JavaTest harness (only one tab with single test suite
present in the GUI), since otherwise multiple test suites loaded in
the same JavaTest harness instance will not be independent of each
other, leading to unexpected and weird failures.

For those who wonder why there could be dependencies between multiple
test suites loaded in the JavaTest harness - the JavaTest harness
loads every test suite into separate class loader thus shielding the
test suites from each other, but putting the Framework classes into
the bootclasspath means that suddenly all loaded test suites could
share state with each other (via static fields in ME Framework, for
example).

Also, my understanding is that one needs ME Framework sources from the
trunk, revision 415 and above. The script won't work with older,
released versions, right?

http://fisheye4.cenqua.com/changelog/cqme/?cs=415

Thanks,
--Vladimir

On Tue, Mar 06, 2007 at 01:13:31PM +0300, Alexander Alexeev wrote:
> Hi all,
>
> I've created windows-based script for running TCK with separated ME
> Framework
> and JT Harness. It's very simple in use - just provide locations of these
> tools
> and define JAVA_HOME and use command "launchtck.cmd" instead "java -jar
> javatest.jar". I found this script useful during development since it
> eliminates
> routine copying framework into TCK. The script is attached. Just change
> extension from .txt to .cmd or .bat
>
> Thanks,
> Alexander

---------------------------------------------------------------------
To unsubscribe, e-mail: meframework-unsubscribe@cqme.dev.java.net
For additional commands, e-mail: meframework-help@cqme.dev.java.net

Alexander Alexeev

Hi Vladimir,

thanks for the excellent clarifications! And you are right, the script won't
work with previous framework versions.

Thanks,
Alexander

Vladimir Sizikov wrote:
> Alexander,
>
> Thanks for the script!
>
> For the sake of clarity, it should be noted that executing the TCK in
> such mode is not an official way, but it might be quite useful while
> testing the ME Framework with various TCKs. Also, putting the
> framework in the bootclasspath means that only ONE test suite should be
> loaded in the JavaTest harness (only one tab with single test suite
> present in the GUI), since otherwise multiple test suites loaded in
> the same JavaTest harness instance will not be independent of each
> other, leading to unexpected and weird failures.
>
> For those who wonder why there could be dependencies between multiple
> test suites loaded in the JavaTest harness - the JavaTest harness
> loads every test suite into separate class loader thus shielding the
> test suites from each other, but putting the Framework classes into
> the bootclasspath means that suddenly all loaded test suites could
> share state with each other (via static fields in ME Framework, for
> example).
>
> Also, my understanding is that one needs ME Framework sources from the
> trunk, revision 415 and above. The script won't work with older,
> released versions, right?
>
> http://fisheye4.cenqua.com/changelog/cqme/?cs=415
>
> Thanks,
> --Vladimir
>
> On Tue, Mar 06, 2007 at 01:13:31PM +0300, Alexander Alexeev wrote:
>> Hi all,
>>
>> I've created windows-based script for running TCK with separated ME
>> Framework
>> and JT Harness. It's very simple in use - just provide locations of these
>> tools
>> and define JAVA_HOME and use command "launchtck.cmd" instead "java -jar
>> javatest.jar". I found this script useful during development since it
>> eliminates
>> routine copying framework into TCK. The script is attached. Just change
>> extension from .txt to .cmd or .bat
>>
>> Thanks,
>> Alexander
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: meframework-unsubscribe@cqme.dev.java.net
> For additional commands, e-mail: meframework-help@cqme.dev.java.net
>

---------------------------------------------------------------------
To unsubscribe, e-mail: meframework-unsubscribe@cqme.dev.java.net
For additional commands, e-mail: meframework-help@cqme.dev.java.net