Refactored some specs and fixed the Promise after resolve ones.
Merge remote-tracking branch 'origin/dev'