I've encountered some of those, I recall one track where merely bumping a kerb in one corner received a penalty ...so don't bump the kerb (I think there was a patch for that track on nogrip ages ago).
But in this case just driving on the right side of the track gets the penalty, you don't have to put a wheel off the track. Not a problem in testing, just pretend you're in England and drive on the left side; but that's not always possible in a race.