I have to spoiler pretty much all of this since it gives away a major twist in the movie.
When Max eats dinner with the Emersons, Sam and Edgar test him using garlic and holy water, among other things. Unfortunately, Max took the precaution of getting Michael to invite him in. Later in the movie, when Max is revealed to be the head vampire, he says, "Don't ever invite a vampire into your house, you silly boy. It renders you powerless," implying that the invitation was what allowed him to pass the tests.
Later though, Paul says, "Haha! Garlic don't work, boys!" which implies that garlic wouldn't work regardless, and since they used a garlic and holy water mix to kill him, we can't be sure whether the garlic had any effect or it was simply the holy water that did him in.