add curly braces to one line if
fix issue #1025:

- add function to count directed outgoing edges
- generate correct instruction for staying on a roundabout
- move test from @bug namespace to the general one