move consolidate script out of test mode and into script mode