Refactor testPluginPathHelpers