FLOE-226: Added unit tests for dialog.js