Hey Pim, The way that the CI Optimization works is, it will run CI on the bottom most PR, skip all middle Prs in the stack, and if enabled (true in your case), will also run on the top PR in the stack.
Once the bottom most PR merges, we perform automatic rebasing to point the second PR in stack to trunk.
See docs here on automatic rebasing. This then triggers a run of CI on it.
So there is not a case that something merges that hasnt run through CI.
I'm now adding a final check which fails if CI optimization was triggered. Is this the correct approach?
Not sure i understand this one. Why would you need this?