Answer
In the settings of the "Quiz" activity, you can define the number of allowed attempts under the "Grade" option. To do this, select the value "1" in the drop-down field next to "Attempts allowed" to allow only one attempt for your test.
Detailed instructions on the topic "Online tests" can be found in the TUWEL tutorials course and in the Guideline for online examinations on the Distance Learning Good Practice page of the TU coLAB.