You can use the UIAutomation framework to achieve automated graphics tests. This is not strictly from the command line, but you run Javascript scripts using the Tools tool. It works great with Monotouch (the time I used it).
The apple documentation for UIAutomation is pretty detailed; and hopefully should cover everything you need.
To give an example script ( "Credit to Jackson" from "Hist" for this script, shamelessly taken from there).
var target = UIATarget.localTarget(); var window = UIATarget.localTarget().frontMostApp().mainWindow (); var table = window.tableViews () [0]; var results_cell = table.cells () [0] var run_cell = table.cells () [1]; var passed = false; var results = ''; run_cell.tap (); while (true) { target.delay (5); try { results = results_cell.name (); } catch (e) { UILogger.logDebug ('exception'); continue; } if (results.indexOf ('failure') != -1) { passed = false; break; } if (results.indexOf ('Success!') != -1) { passed = true; break; } } UIALogger.logDebug ('Results of test run: ' + results); UIALogger.logDebug ('Passed: ' + passed);
source share