This issue needs simple common sense not tech talk:
Your "runaway" problem was nothing to do with the capacitor on the loco, and nothing to do with whether it was steam or diesel:
The digital signal for control goes directly from the track to the decoder internal processors etc, and is not related to the connection between the decoder and the motor. Control qwuality WILL be afected with them in place, but it would be an exceptional case for the opposite to be true.
If you experience runaways it is because of issues related to track wiring or power instability that are creating a less than perfect wave form. Adding a suppressor / filter/terminator across the end of the track power bus will help: This is a 100~150 ohm resistor of 3 watt or greater plus a 0,1mfd ceramic capacitor in series. 100 ohm is strong filter, 150 ohm is weaker.
This will remove some bus problems by cleaning up the waveform and will reduce the peaks in voltage spikes generated by momentary shorts that can damage decoders. Great improvement and insurance for less than 50p!
Re Capacitors or anything at all between motor and decoder:
(1) The loco is tested for CE in the form in which it is sold:
IE as a DC locomotive. Separate testing for DCC equipped loco's is rarely if ever done, as they are assumed to still be compliant under "product family" CE coverage. This is sensibly covered by declartion and not separate testing which can be VERY expensive..
(2) However, in truth, sdding a decoder fundamentally changes the circuit and suppression issues. Decoders already contain much active filtering and the existence of a capacitor after decoder installation is largely irrelevant to emissions.
I work with CE a lot. CE is written as a protective legislation: Actually as long as it (the loco) complies on the day it is sold it doesn't matter what you as a consumer do as long as you don't affect others....
Its not a problem in the main anyway as the low power output means that a small DC motor may affect a radio held close but will not affect a radio a few meters away unless it has a very poor reception. Same with a layout radiating; Anyway, CE would equally say that there is a need for the other party to have a reasonable antenna, so even in this case, you would not be contavening anything.
CE is a manufacturer NOT owner issue as far as compliance is concerned. Anyway - the quality of your layout wiring will be more of a CE issue in a domestic sense than ANY loco install can ever be: Both power and antenna (track and wire used) are MUCH bigger as potential "radiators of interference"
So really: Modellers... Wire the layout to "best practice" and don't worry in a local or personal sense about loco suppression at all!!
Back to decoders......
(3) Decoders all contain some form of direct motor control feedback which relies on the feedback received from the motor in relation to back EMF - even non-back EMF decoders are in part influenced by this.
(4) The existence of any component between decoder and motor will negatively affect the performance of the "decoder to motor relationship". The difference may be so small in some cases its almost not noticeable but in others it will be an extreme difference.
A loco will never run better with capacitors or inductors in place than wthout them. Inductors aren't so much of an issue as capacitors though.
(5) Variance in result is seen because the suppression parts used on DCC loco's and the motors used AND the layout of the circuitry are different: Anyone in electronics will understand that the layout of the circuit is as important to preventing cross-talk and interference as component choice sometimes!
All loco's are different style to style and brand to brand. Therefore degree of reaction to the suppression parts is different. This why its impossible to give a simple "when to leave them in" issue - a decoder can't be designed to met all possibilities perfectly.
Summary: To give a "No-tech talk" answer to the capacitor issue: Just hard evidence and to give a simple answer to the CE Issue:
re CE: Its irrelevant to consumers... just do what you wish to your loco. No draconian interpretation of legislation affects it once you own it, you'll not create a social disaster by removing the capacitors and jails will never be full of CE offenders
.....so body cares except you really.
re: removal of bits and bobs such as capacitors: I install 500+ loco's a year, all brands and scales from Z to gauge 1.
I have NEVER seen a loco run better with the suppression components in place, but I have seen very many of them run much better without.
Make your own decisions, but my advice would be always remove them for 100% best "no tweaking of decoder settings" possible performance, especially if the decoders have Back EMF
CE is not relevant to what we do with our loco's as long as the basics are coped with at the factory on the day of manufacture - from the day you buy it and install a decoder, its a different loco electrically anyway... So "just do it" the way you prefer and don't worry
My experience while chipping a couple of Steam Loco's, both of which went into "runaway" has led me to leave all caps in place. One particular Loco that had no caps fitted to the motor from new, was only controllable once caps had been retro-fitted. With my set-up, Diesel Loco's don't seem as critical, probably due to their multi-axle pickups with less chance of producing signal corrupting spikes, and will work with or without caps.
It seems that users get different results depending on their DCC System/ Decoder/ Loco combination. What will work for one probably won't work for another.