Fix cat & test function