totality-of-the-circumstances test — Legal Definition, Examples & Cases