home *** CD-ROM | disk | FTP | other *** search
- /* test.rexx */
-
- /* Test the demo ARexx function host */
-
- /* Written by Donald T. Meyer */
-
-
-
- if show( Libraries, "DEMO_FUNC_HOST" ) ~= 1 then
- do
- say "Oops! You must run rh_demo to install the function"
- say "host before this ARexx test program can run!"
- exit 20
- end
-
- say "First, a display beep:"
-
- call dbeep()
-
- say
-
-
-
- say "Now a function which returns a string:"
-
- say rats()
-
- say
-
-
-
- say "And a function which returns a boolean based upon the length"
- say "of the string passed to it:"
-
- say bigword( "Hello" )
- say bigword( "aaabbbcccdddeeefffggg" )
-
- say
-
-
-
- say "A somewhat usefull function to return just the filename"
- say "from a fully-qualified volume:path/filename"
- say
- name = "DF0:startrek"
- say "Calling with: " || name
- say "Returns: " || filename( name )
- say
-
- name = "DF0:tests/startrek"
- say "Calling with: " || name
- say "Returns: " || filename( name )
- say
-
-
- say "And finally, a function which always returns an error:"
- say "(This will abort the ARexx program!)"
-
- call myerror
-
- /* We actually never get to here. */
-
- say
-
-
-
- say "All Done testing!!"
-
- exit 0
-
-