Tool for quality testing of raw material of permanent magnets