3 ms·
One option is to use the debug_toolbar package. You can set it up to display only when testing or only when an admin is logged in, and it will give you a conve
by rfurmani 14y ago
One option is to use the debug_toolbar package. You can set it up to display only when testing or only when an admin is logged in, and it will give you a convenient bar on the right side that shows exactly how long everything took, along with all SQL queries. This allowed me to greatly cut down the number of queries by judiciously using fetch_related.