Issue #2874640 by martin107, Lendude, Utkarsh_Mishra, NickWilde, alexpott: Convert DialogTest to a FunctionalJavascript test (cherry picked from commit 662b7944)