feat($q): Adds pending(), rejected(), resolved() to Promise.

Fixes #7141.