Sounds like the Kalama Sutta.
Yes, that's it.
I found it in an old book in a Buddhist library on a meditation retreat I was at. The chapter was called Buddhism and Science. The whole series called The Wheel Publication has many interesting essays but the quote from the Kesamutti Sutta aka Kalama Sutta was just too good to not share here.
This is a fun question/quiz. Who said the following?
The original quote is somewhat altered to make it harder to google and more interesting to guess.