Added simple implementation of observer pattern and tests