* Add tests for noEmitOnError * Do not write files directly from builder when noEmitOnError is true Fixes #34823 * make linter happy * Instead of generating output in memory, check errors before doing the emit in case of noEmitOnError