function get_test_data($test_id) {
if (!$test_id) return;
global $connect;
$query = "SELECT q.question, q.parent_test, a.id, a.answer, a.parent_question, a.correct_answer
FROM questions q
LEFT JOIN answers a
ON q.id = a.parent_question
WHERE q.parent_test = $test_id";
}