Refactor and add tests for plugins.py

Improvement to the tests currently being run on ``plugins.py``

related #644 
Yeah. I added helper into the description to make it more specific.