Maybe put some faith in `var` hoisting and just say `var mockMap = require("mock-modules").getMockMap()` here, without the `var mockMap;` above?