You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Checked next-gen ES issues and syntax problems by using the same environment and/or transpiler configuration without Mocha to ensure it isn't just a feature that actually isn't supported in the environment in question or a bug in your code.
'Smoke tested' the code to be tested by running it outside the real test suite to get a better sense of whether the problem is in the code under test, your usage of Mocha, or Mocha itself
Ensured that there is no discrepancy between the locally and globally installed versions of Mocha. You can find them with: node node_modules/.bin/mocha --version(Local) and mocha --version(Global). We recommend avoiding the use of globally installed Mocha.
Description
Steps to Reproduce
I found the file that stops, do you have an idea why it stops the processing?
Although, I am using Chrome instead of PhatomJs, but it is an older functions, so it works with very old functions as well, so it is so weird.
(function(window,document,navigator){'use strict';if(window.corifeusCssFiles===undefined&&window.corifeusScriptFiles===undefined){window.corifeusCssFiles=[];window.corifeusScriptFiles=[];}window.corifeus={booted: false,core: {http: {counter: 0}}}window.corifeusPreloader={wait: navigator.userAgent==='corifeus-server-renderer',status: {corifeus: window.corifeus}}'GENERATED-HEAD';if(!document.getElementById){document.getElementById=function(){};}varcssFiles=window.corifeusCssFiles;varscriptFiles=window.corifeusScriptFiles;varfiles=cssFiles.concat(scriptFiles);varprogress={};varresponseText={};varstarted=newDate().getTime();functionformatBytes(bytes,decimals){if(bytes==0)return'0 Byte';vark=1000;// or 1024 for binaryvardm=decimals+1||3;varsizes=['Bytes','KB','MB','GB','TB','PB','EB','ZB','YB'];vari=Math.floor(Math.log(bytes)/Math.log(k));returnparseFloat((bytes/Math.pow(k,i)).toFixed(dm))+' '+sizes[i];}varformatTime=function(time){varseconds=Math.floor(time/1000);varminutes=Math.floor(seconds/60);varhours=Math.floor(minutes/60);vardays=Math.floor(hours/24);hours=hours-(days*24);minutes=minutes-(days*24*60)-(hours*60);seconds=seconds-(days*24*60*60)-(hours*60*60)-(minutes*60);if(days<10)days='0'+days;if(hours<10)hours='0'+hours;if(minutes<10)minutes='0'+minutes;if(seconds<10)seconds='0'+seconds;vartemplate='';if(days!='00'){template+=days+':';}if(hours!='00'||days!='00'){template+=hours+':';}template+=minutes+':';template+=secondsreturntemplate;}functionloadFile(url){varxhr=newXMLHttpRequest();xhr.open("GET",url,true);xhr.onreadystatechange=function(){if(this.readyState==this.DONE){responseText[url]=xhr.responseText;fire(true,this.responseText);}};xhr.onprogress=function(event){progress[url]=event;fire();}xhr.send();}functioniterate(cb){for(varindex=0;index<files.length;index++){varfile=files[index];cb(file);}}functionincludesCss(file){for(varindex=0;index<cssFiles.length;index++){varcssFile=cssFiles[index];if(cssFile===file){returntrue;}}returnfalse;}vartotal=0;varloaded=0;varcounter=0;vartotalDone=false;varframe=33;varcomputable=true;varoverlayPercent=function(percent){document.getElementById('cory-loader-progress-overlay').style.height=Math.round(percent)+'%';document.getElementById('cory-loader-progress-overlay').style.width='100%';}varloop=(function(){if(totalDone){return;}if(document.getElementById('cory-loader-progress-bottom')){varpercentRaw=(loaded/total);varpercent=(percentRaw*100).toFixed(2);vartotalMB=formatBytes(total,1);varloadedMB=formatBytes(loaded,1);if(isNaN(percent)){percent=0.5;}varcurrent=newDate().getTime()-started;varmaxTime=current/percent*100;varleft=maxTime-current;overlayPercent(percent);vartop=document.getElementById('cory-loader-progress-top');varbottom=document.getElementById('cory-loader-progress-bottom');if(computable){top.innerHTML=formatTime(left);bottom.innerHTML=percent+'%'+'<div class="cory-loader-progress-info">'+loadedMB+' / '+totalMB+'</br>'+formatTime(current)+' / '+formatTime(maxTime)+'</div>';}else{top.innerHTML='<div class="cory-loader-progress-info">gzip</div>';bottom.innerHTML=formatTime(current)+'</br></br>'+loadedMB;}}setTimeout(loop,frame);});loop();functionfire(isDone){total=0;loaded=0;iterate(function(file){if(progress[file]!==undefined){if(progress[file].lengthComputable===false){computable=false;total+=progress[file].loaded;}else{total+=progress[file].total;}loaded+=progress[file].loaded;}})totalDone=isDone===true&&++counter==files.length;}varfinal=function(){// document.getElementById('cory-loader-progress-top').innerHTML = '<div></div>';// document.getElementById('cory-loader-progress-bottom').innerHTML = '<span class="cory-loader-progress-start">START</span>';overlayPercent(100);setTimeout(function(){iterate(function(file){varbody=document.querySelector('body');varhead=document.querySelector('head');// it is important so that the css is in the headif(includesCss(file)){/* var style = document.createElement('style'); style.type = 'text/css'; style.innerHTML = responseText[file]; head.appendChild(style) */varlink=document.createElement('link');link.rel='stylesheet';link.href=file;link.type='text/css';head.appendChild(link);}else{varscript=document.createElement("script");script.type='text/javascript';script.defer=true;script.src=file;/* script.innerHTML= responseText[file]; */body.appendChild(script);}})varbooted=function(){if(window.corifeus.booted===true){varremoveMe=document.getElementById('cory-loader');if(removeMe!==null){removeMe.parentNode.removeChild(removeMe);}}else{setTimeout(booted,100);}}booted();},frame)}iterate(function(file){loadFile(file,fire)})varwaitForDone=function(){if(totalDone&&!window.corifeusPreloader.wait){final();return;}window.corifeusPreloader.status.corifeus=window.corifeus;setTimeout(waitForDone,frame);}waitForDone();})(typeof(window)==='undefined' ? this : window,typeof(document)==='undefined' ? {} : document,typeof(navigator)==='undefined' ? {userAgent : 'corifeus-server-renderer'} : navigator);
Expected behavior: [What you expect to happen]
Continue to process with mocha (with v4 or above)
Actual behavior: [What actually happens]
Stops processing.
Reproduces how often: [What percentage of the time does it reproduce?]
Versions
Pure Js, no transpiler, although 4.0.1
Additional Information
Although, there are other files, but I choose js only.
The text was updated successfully, but these errors were encountered:
Prerequisites
common mistake
labelnode node_modules/.bin/mocha --version
(Local) andmocha --version
(Global). We recommend avoiding the use of globally installed Mocha.Description
Steps to Reproduce
I found the file that stops, do you have an idea why it stops the processing?
Although, I am using
Chrome
instead ofPhatomJs
, but it is an older functions, so it works with very old functions as well, so it is so weird.Expected behavior: [What you expect to happen]
Continue to process with
mocha
(with v4 or above)Actual behavior: [What actually happens]
Stops processing.
Reproduces how often: [What percentage of the time does it reproduce?]
Versions
Pure Js, no transpiler, although
4.0.1
Additional Information
Although, there are other files, but I choose
js
only.The text was updated successfully, but these errors were encountered: