Refactored: casperjs tests. Added: Exit 1 when JS page error found.