resourceloader: Add unit test for validateScriptFile()