(a) Upon the request or with the consent of the victim, the prosecutor shall make a motion in camera and the sentencing court shall issue an order requiring an adult convicted of or a juvenile adjudicated delinquent for violating section 609.342 (criminal sexual conduct in the first degree), 609.343 (criminal sexual conduct in the second degree), 609.344 (criminal sexual conduct in the third degree), 609.345 (criminal sexual conduct in the fourth degree), or any other violent crime, as defined in section 609.1095, to submit to testing to determine the presence of human immunodeficiency virus (HIV) antibody if:
(1) the crime involved sexual penetration, however slight, as defined in section 609.341, subdivision 12; or
(2) evidence exists that the broken skin or mucous membrane of the victim was exposed to or had contact with the offender's semen or blood during the commission of the crime in a manner which has been demonstrated epidemiologically to transmit the human immunodeficiency virus (HIV).
(b) When the court orders an offender to submit to testing under paragraph (a), the court shall order that the test be performed by an appropriate health professional who is trained to provide the counseling described in section 144.7414, and that no reference to the test, the motion requesting the test, the test order, or the test results may appear in the criminal record or be maintained in any record of the court or court services, except in the medical record maintained by the Department of Corrections.
(c) The order shall include the name and contact information of the victim's choice of health care provider.
The date and results of a test performed under subdivision 1 are private data as defined in section 13.02, subdivision 12, when maintained by a person subject to chapter 13, or may be released only with the subject's consent, if maintained by a person not subject to chapter 13. The results are available, on request, to the victim or, if the victim is a minor, to the victim's parent or guardian and positive test results shall be reported to the commissioner of health. Unless the subject of the test is an inmate at a state correctional facility, any test results given to a victim or victim's parent or guardian shall be provided by a health professional who is trained to provide the counseling described in section 144.7414. If the subject of the test is an inmate at a state correctional facility, test results shall be given by the Department of Corrections' medical director to the victim's health care provider who shall give the results to the victim or victim's parent or guardian. Data regarding administration and results of the test are not accessible to any other person for any purpose and shall not be maintained in any record of the court or court services or any other record. After the test results are given to the victim or the victim's parent or guardian, data on the test must be removed from any medical data or health records maintained under sections 13.384 or 144.291 to 144.298 and destroyed, except for those medical records maintained by the Department of Corrections.