Added checks for missing/incorrect coordinates
Added QUnit tests