Google will follow those 301s and realise that the old URLs are the same as the new URLs. From experience, you may see a slight drop in some search rankings when you make the switch as it can take Google some time to factor the 301s into it's algorithm, but remember not to panic - if you see any drops (big 'if'), it should only be temporary and I'd imagine you'd be back to normal within 2-3 weeks.
Ideally though, you'd just configure Rails to use the trailing slash instead so you didn't have to risk a temporary drop. If it's too much of an issue or would be a hassle to do though, don't worry too much - you'll be fine.