Holonomy Criterion for Calabi-Yau Metrics