This question and answer pair were not actually intended to be Canonical (at least not as a dupe target).
Why not? Seems like a good plan to me.
As you know even better than me, we get a number of messy "plz halp me 2 write muh bootloader" questions. Rather than closing them all as "unclear", "too broad", or "lacks MCVE", it would be more efficient for us and more helpful to the asker if we marked them as duplicates of a high-quality canonical.
It would also keep one of our top answerers on this subject from burning out too quickly.
What happens when the question is very specific and effectively asks for an external type resource or tutorial, but the self answer is intended to be the resource? Should such questions be closed as off-topic?
Unfortunately, yes. The intention of the asker is not relevant, and neither is the purpose of the question. It doesn't matter whether you are self-answering, intending it to be a canonical, or whatever. The question itself still has to meet our guidelines, or it is subject to being closed.
Part of the logic here is just consistency, which is a good approximation of fairness.
The other rationale is exactly why we close "recommendation" questions as off-topic in the first place: because they tend to attract low-quality and spam answers. Your self-answer might be fantastic, but as long as the question is open, more answers can come in, and history tells us to expect these to be low-quality on recommendation-style questions.
But, all is not lost. The content is excellent, and the central core of the question is on-topic, as you mentioned. So, the challenge is just writing the question such that it fits within our guidelines.
For typical self-answered questions, this is just a matter of pretending you are on Jeopardy! and phrasing it in the form of a question.
For recommendation-style questions, we have a lot of guidance here on Meta already about the right way to ask them. Basically, you ask about what you want to accomplish, rather than asking for a recommendation on how to accomplish what you want to accomplish. Answers that recommend a tool are completely fine; the problem is just questions that ask for them. The close reason itself attempts to give specific guidance on how you should ask these questions: "Instead, describe the problem and what has been done so far to solve it." I see this as really just being a special-case of the X-Y problem. You should not decide in advance that what you need is a library, and then go asking for someone to recommend one to you. Instead, you should ask about what you are actually trying to do, giving all the necessary context, details, and constraints. Then, let the experts who answer your question decide what solution is most appropriate.
In this specific case, I can think of a number of ways you could remix the question to ensure it is a good, on-topic question for Stack Overflow. One simple solution would be to present some partially-working code, and ask how to make it comply with the requirements. But that risks making the question too specific, and it is probably an unnecessary amount of work when you're planning on self-answering. I think you would be fine to just remove that last paragraph:
Does such a test harness exist that could do this? Does someone have one?
I strongly suspect that is what's making people's trigger fingers itchy. Rephrase to something simpler, like:
How would I build such a bootloader?
The only possible objection to this is that the question becomes more of a requirements dump. On the other hand, the reason our users retch at these is because of their characteristically low quality and aura of sheer laziness. Neither of those two things are a problem here, or with any good canonical.