Added tests, validator now works in the browser