page6   Test your perlscript:


First create a file which contains one test call of your agent/script. Be sure, to insert only the subpath, generally ., not the mount-point.


euklid:/# cat test_input
Read( ., [ "www.suse.de", "abcde", "213.95.15.200" ]) 

eukild:/#

In our example you have to replace the "[ "www.suse.de", "abcde", "213.95.15.200" ]" with an argument, your script expects. The start your script as user root:

Input:   /usr/lib/YaST2/servers_non_y2/ag_ping <test_input
Output:  "ok"

Notice:

If there is any debug output, your script would not work! The output on stdout has to be one and only one YCP-Value i.e. a string, a list, a map ...

<< Previous  Next >>