Added tests, yay!
Test caused some improvments
Cleaned up Search module