Fixed testcases failing because of auto-executing, fixed more dependency graph bugs