A simple test, that should cover about 99% (possibly 100%) of cases:
Does the building produce anything? If it does, it needs a road. If it doesn't, it doesn't need a road.
And for the most part, if it has several functions, the functions that do not produce anything will work if the building needs a road but isn't connected. (i.e., a ferris wheel will still give culture if not connected to the road, but it won't produce anything. And a residence still gives population if not connected to a road, but it won't make any coins.)