BROOKLYN, N.Y.—By August, anyone who inspects, tests or services fire alarm systems in New York City must be officially certified to do so by the city’s fire department.