function changeTestMode(m) {
    if (testMode === m) return false;
    dataReset();
    testMode = m;
    $('#combSelect').removeClass('tab-selected');
    $('#seqSelect').removeClass('tab-selected');
    $('#tb-new-group').css('visibility', m === 'seq' ? 'visible' : 'hidden');
    $(`#${m}Select`).addClass('tab-selected');
    $('#dataGroup').empty();

    return true;
}
Onload, check if it is opened in a popup.
Check if test is being edited, or created