I'm used to this as my veg mostly comes from the garden!! The cabbages are a haven for caterpillers so they get a really good salt water wash.
Thing is, they can inspect the outside of the brocolli but if the little critter crawled right in, there's no way they would be able to tell surely?