small medium large xlarge

Generic-user-small
02 Jul 2013, 11:46
Mogens Habekost (3 posts)

Has anybody gotten the parameter: -e UIASCRIPT to work with more than 1 script ??

I keep getting a acces denied error on the second script. (nomatter the sequence of the scripts)

Setting the -e UI_TESTS does not help..

Avatar_pragsmall
02 Jul 2013, 12:50
Jonathan Penn (43 posts)

What do you mean by “more than 1 script”? Can you post the full command you are trying to run and the output?

Generic-user-small
02 Jul 2013, 13:00
Mogens Habekost (3 posts)

Something like: /Applications/Xcode.app/Contents/Developer/usr/bin/instruments \ -t Automation/Template.tracetemplate \ -D Automation/results/trace \ $appLocation \ -e UIARESULTSPATH Automation/results \ -e UI_TESTS 2 \ -e UIASCRIPT Test1.js;test2.js; \

I was hoping to execute several test , but with reset of instruments inbetwine..

Solved it like this, but i messes up the trace file.

echo starting tests for f in “Tests”/*.js do /Applications/Xcode.app/Contents/Developer/usr/bin/instruments \ -t Automation/Template.tracetemplate \ -D Automation/results/trace \ $appLocation \ -e UIARESULTSPATH Automation/results \ -e UIASCRIPT $f; \ done

I had hoped to gather all output in one trace file…

Generic-user-small
02 Jul 2013, 13:02
Mogens Habekost (3 posts)

If i collect all tests in one file(with imports), i do not get an reset of the application.. IE. if one test coroupts the app, all tests fail..

Avatar_pragsmall
02 Jul 2013, 17:19
Jonathan Penn (43 posts)

Ah, that’s not possible. UI Automation only executes one test at a time. Look at Chapter 10, the command line chapter, for an example of how to use shell scripts to execute several UI Automation test files one after the other while resetting the application state.

  You must be logged in to comment