Add a test for automatic synchronisation. Looks much worse than it is due to needing to change a load of APIs to pass a queue name around everywhere.
Test for auto-syncing on policy change.
Merge in default.
merge bug25418 into default