set_random_lsst_dds_partition_prefix¶
-
lsst.ts.salobj.
set_random_lsst_dds_partition_prefix
()¶ Set a random value for environment variable LSST_DDS_PARTITION_PREFIX
Call this for each unit test method that uses SAL message passing, in order to avoid collisions with other tests. Note that pytest can run unit test methods in parallel.
The set name will contain the hostname and current time as well as a random integer.
The random value is generated using the
random
library, so callrandom.seed(...)
to seed this value.