Making this a bit more modular
Making tests work with lab