Perform UI Automation from Objective-c application

I want to perform UI Automation on an iOS app and I have written test script in javascript file. I have executed the UI Automation testing using Xcode->Profile and importing test script file. So my question is how can I perform UI Automation testing programmatically using Xcode Instruments and passing test script file to it?