Increase timeout to 1000ms and make it a pref.

Adjust the values in the unit tests.