Fix tests as per leo's work