Index: openacs-4/packages/acs-core-docs/www/tutorial-debug.adp =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/tutorial-debug.adp,v diff -u -N -r1.1.2.12 -r1.1.2.13 --- openacs-4/packages/acs-core-docs/www/tutorial-debug.adp 23 Jun 2016 08:32:46 -0000 1.1.2.12 +++ openacs-4/packages/acs-core-docs/www/tutorial-debug.adp 19 Nov 2016 09:21:55 -0000 1.1.2.13 @@ -1,5 +1,5 @@ -{/doc/acs-core-docs {Documentation}} {Debugging and Automated Testing} +{/doc/acs-core-docs {ACS Core Documentation}} {Debugging and Automated Testing} Debugging and Automated Testing

-Debugging

+Debugging

Developer Support. The Developer Support package adds several goodies: debug information for every page; the ability to log comments to the page instead of the error @@ -45,7 +45,7 @@           

-Manual testing

Make a list of basic tests to make sure it works

+Manual testing

Make a list of basic tests to make sure it works

@@ -73,13 +73,13 @@ to delete your own note. Edit your own note. Search for a note.

-Write automated tests

+Write automated tests

by Simon Carstensen and Joel Aufrecht

OpenACS docs are written by the named authors, and may be edited by OpenACS documentation staff.

- It seems to me that a lot of people have + It seems to me that a lot of people have been asking for some guidelines on how to write automated tests. -I've done several tests by now and have found the process to be +I've done several tests by now and have found the process to be extremely easy and useful. It's a joy to work with automated testing once you get the hang of it.

Create the directory that will contain the test script and edit the script file. The directory location and file name are standards @@ -148,7 +148,7 @@ myfirstpackage. You should see your test case. Run it and examine the results.

-TCLWebtest tests

API testing can only test part of our package - it doesn't +TCLWebtest tests

API testing can only test part of our package - it doesn't test the code in our adp/tcl pairs. For this, we can use TCLwebtest. TCLwebtest must be installed for this test to work. This provides a library of functions that make it easy to call a page @@ -158,7 +158,7 @@ integrating them.

-Example

Now we can add the rest of the API tests, including a test with +Example

Now we can add the rest of the API tests, including a test with deliberately bad data. The complete test looks like:

 ad_library {
     Test cases for my first package.
Test NumActionExpected Result