Support common event emitters.

commit 3e53c2aea8322f78ffaa3ea2ddfd15ccae49e54e
Author: Mateu Aguiló Bosch <mateu.aguilo.bosch@gmail.com>
Date:   Wed Jul 2 10:59:32 2014 +0200

    Add tests for CustomEvent

commit 0249f06d5b7e6bf2b72a67a64d844410a170f209
Author: Mateu Aguiló Bosch <mateu.aguilo.bosch@gmail.com>
Date:   Wed Jul 2 10:30:01 2014 +0200

    Support common event emitters.