How is the maintenance of the rail and railway infrastructure checked before a trip?

Infrastructure maintenance and inspection falls under Transnet Freight Rail and Metrorail. They conduct a variety of regular inspections and also rely on reports from the regular trains on the routes. If any unsafe condition arises, either the line is closed, or a temporary speed restriction for a certain area is implemented.