test on beforescriptexecute and afterscriptexecute