And add some tests Change-Id: Ife0e0c60f55251a1ac23215055ece8fb01478d59 Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>