Thanks to Eric for posting a nice example of improving test readability with narrative - the second version is _much_ more readable especially to a non-domain expert!
https://gist.github.com/665399
Think we should link to this on the welcome page (would that be OK Eric? Don't want to overexpose your source code).
As Andy explained at CITCON we found the narrative versions much more readable for our own technologists, and that was the main motivator for us! (BAs and customers also find the readable tests useful, but not nearly so much as we do ourselves.)
Your experience may differ - for example
beginAtAsQuant("/users/backtestHistory.html");
may be more readable to some techies familiar with the code and the meaning of the app's URLs than
was_able_to(visitPage("backtest history"));
hence I think your question about what level of abstraction to use.
Am I missing something though in thinking that surely
getBackTestStore().storeStrategy(QUANT, ENDED_SOLUTION_ID, ZipUtils.zip("import com.algodeal.marketrunner.strategies.*;\n @Instruments(futures=com.algodeal.marketData.instruments.Futures.CAC_40)\npublic class MyStrategy extends AbstractStrategy {}", "MyStrategy.java"));
beginAtAsQuant("/users/paperTradeSolution.do?solutionId=" + ENDED_SOLUTION_ID + "&paperTrading=true"); // clicks on link executing javascript
is much less readable (it even needs an explanatory comment!) than
Given.the(quant).was_able_to(postStrategy(ENDED_SOLUTION_ID))
.was_able_to(startPaperModeOnThatStrategy())
Right?
One audience for the scriptwriter output is definitely customers - there is one in particular who really like to see exactly what tests we are running.