can we move this into tests/lib/index.js and tests/lib/plugin.js