Refactor and add tests for plugins.py

Improvement to the tests currently being run on ``plugins.py``

related #644 
What are these magic numbers?
Can do this programatically?

The problem with this set of tests is it's fragile and will break as soon as someone adds another plugin that's not very good for maintainability.