tests: loading_cache_test: don't exhaust random number entropy
tests: loading_cache_test: don't exhaust random number entropy

rand_int() re-creates a random device each time it is called.
Change it to use a static random_device, and get random numbers
from a random_engine instead of from the device directly.

This avoids exhausting entropy, see [1] for details.

[1] https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94087

scylladb/scylla,scylladb/scylla,scylladb/scylla,avikivity/scylla,scylladb/scylla,avikivity/scylla,avikivity/scylla