testcases/lib: Add tst_random

There is no $RANDOM in portable shell, therefore we need it in order to
get a random number.

Produces decimical integer in a given range. Tests can use it to
determine a random action.

+ documentation in the test-writing-guidelines

Signed-off-by: Chunyu Hu <chuhu@redhat.com>
Signed-off-by: Cyril Hrubis <chrubis@suse.cz>
4 files changed