Added a unit test for notifications count

Don't like timing dependency (or delays). Can we get rid of that?