Fixes Lights behaviour and adds tests

Check if it goes well on develop