Go to the relevant Test/Quiz/Assignment and select the tiny down arrow to the right of the assignment and click Edit the Test Options.
Go to "Show Test Results and Feedback to Students" and select the Feedback option.
Be sure of your due dates and select "Do not allow students to start the Test if the due date has passed.
Go to Test Avaliability section and determine your Display Until dates.
Display Until dates should be taken to a date after due date. You can calculate and determine the time enough for students to view test questions, answers, and your feedback. When the date entered in Display Until arrives, students will NOT be able to access to the test and your feedback.