Difference between revisions of "AHK Test Suite"

From ReactOS Wiki
Jump to: navigation, search
(How to write new tests)
(How to write new tests)
Line 33: Line 33:
 
== How to write new tests ==
 
== How to write new tests ==
 
If you want to write test for completely new application, use those as templates: <br>
 
If you want to write test for completely new application, use those as templates: <br>
[http://svn.reactos.org/svn/project-tools/trunk/ahk_tests/IrfanView/4.23/ IrfanView 4.23] as normal template; <br>
+
* [http://svn.reactos.org/svn/project-tools/trunk/ahk_tests/IrfanView/4.23/ IrfanView 4.23] as normal template; <br>
[http://svn.reactos.org/svn/project-tools/trunk/ahk_tests/SciTE/1.77/ SciTE 1.77] for 7-Zip self-extract archives; <br>
+
* [http://svn.reactos.org/svn/project-tools/trunk/ahk_tests/SciTE/1.77/ SciTE 1.77] for 7-Zip self-extract archives; <br>
[http://svn.reactos.org/svn/project-tools/trunk/ahk_tests/Audio%20Grabber/1.83%20SE/ Audio Grabber 1.83 SE] for installers that haves dialog where you have to choose setup language; <br>
+
* [http://svn.reactos.org/svn/project-tools/trunk/ahk_tests/Audio%20Grabber/1.83%20SE/ Audio Grabber 1.83 SE] for installers that haves dialog where you have to choose setup language; <br>
[http://svn.reactos.org/svn/project-tools/trunk/ahk_tests/Java/6.25/ Java 6.25] for installers that use MsiExec. <br>
+
* [http://svn.reactos.org/svn/project-tools/trunk/ahk_tests/Java/6.25/ Java 6.25] for installers that use MsiExec. <br>
 +
Now, you have to create two folders: 1 - Application name, 2 - Application version. E.g.: Firefox\2.0.0.20<br>
 +
This is so we could have same application tested, but different version e.g. Firefox\2.0.0.20, Firefox\3.0.11, Firefox\12.0, etc.

Revision as of 17:54, 9 April 2013

The page AHK Test Suite is a short article on something that should have a lot more information written on it.
If you know anything else about it, you are STRONGLY encouraged to add the information in. If you are unsure of proper formatting or style, add it to the talk page or this page itself as you think best and others will help.


What is AHK Test Suite

...

How to download AHK Test Suite

...

How to see test results

Online tests

If you want to see results of online tests you need:
1) Enter http://reactos.org/testman/ in your browser address;
2) Specify ReactOS revision number you want to check results of;
3) Enter 'CMake_x86_GCCWin' in 'Source' field;
4) Select up to five revisions using checkboxes provided;
5) Hit 'Compare selected Results' button.
Picture below demonstrates all the steps.
testman.jpg

Compiling and running test manually

In order to run test you need to compile it. First, download the test (how to do so check titles above). When download is done, you need to compile using Ahk2Exe.exe (AutoHotKey v1.0.48.05 is used when compiling ReactOS tests). If you are planing to compile using GUI tool, there is the steps:
1) Run Ahk2Exe.exe;
2) When Ahk2Exe window appears, hit "Browse" button in in "Source (script file)" and open file that matches 'zz_*_test.ahk' file pattern (e.g. 'zz_firefox_2.0.0.20_test.ahk');
3) Hit "> Convert <" button and dialog box saying 'Conversion complete' will appear.
Picture below demonstrates all the steps.
Ahk2Exe.jpg
If compilation went successfully a 'zz_*_test.exe' (e.g. 'zz_firefox_2.0.0.20_test.exe') file will be created. There are dependencies. You gonna need exact the same test application version as described in test (e.g. 'Firefox 2.0.0.20'). Sadly, we do not provide any host links to test media we have for AHK tests. In case you managed to get everything you need (asked Caemyr, Edijus?) you need to create two folders in target machine 'Apps' and 'Media'. You put test program *.exe (e.g. 'Firefox 2.0.0.20 Setup.exe') in 'Apps' and rest of stuff (e.g. 'FF_2_Search_Arrow.jpg') in 'Media' folder. The compiled script executable goes into root folder.
Picture below demonstrates folder hierarchy.
Folders.jpg
Now, all you need is to start test executable by passing test name via command line (e.g. 'D:\AHK_Tests\zz_firefox_2.0.0.20_test.exe 1.install').
Start_Test_CMD.jpg
Results will be displayed in debug output. Debug output can be monitored with DebugView application.
Picture below demonstrates how results are displayed in DebugView application.
DebugView.jpg

How to write new tests

If you want to write test for completely new application, use those as templates:

Now, you have to create two folders: 1 - Application name, 2 - Application version. E.g.: Firefox\2.0.0.20
This is so we could have same application tested, but different version e.g. Firefox\2.0.0.20, Firefox\3.0.11, Firefox\12.0, etc.