[WIP] Reintroduction of unit test of change listeners.

Long time ago the unit tests if the change listeners were disabled. They are now reintroduced in another source file and almost rewritten.

@bmunkholm @emanuelez