When using Org-mode and its LaTeX export BibTeX or Biblatex is often used to handle references. In that case the LaTeX command \\printbibliography
is often included
One solution would be the following:
#+macro: printbiblio (add extra spaces here, but cannot add comment)
* Test 2
This is a test
* {{{printbiblio}}}
Test text
\printbibliography
*
asdf
Like this you end up with a blank heading at the bottom of the document. The macro expands to a blank block of text so you end up with
\section{Test 2}
\label{sec-1}
This is a test
\section{}
Test text
\printbibliography
\section{}
asdf
This also ensures you cannot accidentally add headlines after your bibliography, since it is it's own (empty) headline. It might be (seems to be actually) included in the table of contents, which is unfortunate but I would suspect the solution would be at worst run a post-export to remove the empty headline from the file (or manually do so before converting to PDF).