allow script name vars to be set only once
adding tests for MaglLegacy