When you dismount an entity with the sneak button, you don't start sneaking. You have to unpress the key, then press it again.
1. Spawn a boat 2. Get in 3. Hold shift 4. Start walking → You aren't sneaking
Expected result You should be sneaking