I find myself constantly going to console after each Corona build and doing adb install -r appname.apk
Is it possible to automate this process? [import]uid: 52103 topic_id: 13815 reply_id: 313815[/import]
I find myself constantly going to console after each Corona build and doing adb install -r appname.apk
Is it possible to automate this process? [import]uid: 52103 topic_id: 13815 reply_id: 313815[/import]
I don’t have the answer to your question, but have you read this 5 part blog post?
http://blog.anscamobile.com/2011/08/automated-testing-on-mobile-devices-part1/#more-9022
When I have time, I plan to go through it and see if there is anything I can implement to make my testing easier. [import]uid: 67839 topic_id: 13815 reply_id: 50752[/import]
Hi,
Did anyone figured this out. How to trigger a device/simulator build from command line?
The automated testing articles didn’t say how we could automate the build for xcode simulator.
The examples given was a generic Obj C app. [import]uid: 22047 topic_id: 13815 reply_id: 52958[/import]
Unfortunately, building from the Corona simulator is still not automatable (unless you try high level automation via things like Applescript/Scripting Bridge or Instruments).
Some ways to automate running apps in the Mac simulator can be found in the forums (or you can squint at the videos).
http://developer.anscamobile.com/forum/2011/02/09/new-command-line-parameter-not-really-working
[import]uid: 7563 topic_id: 13815 reply_id: 52973[/import]
This got forwarded to me today. Somebody in IRC wrote an Applescript to automate building in Corona.
http://pastebin.com/WzA60HrU
[import]uid: 7563 topic_id: 13815 reply_id: 53442[/import]
The link doesn’t work for me.
Was anyone else able to download the script? [import]uid: 67839 topic_id: 13815 reply_id: 53473[/import]
[code]
on buildTarget(filename, platform, signatureID)
tell application “Corona Simulator”
open filename
end tell
tell application “System Events”
tell process “Corona Simulator”
repeat until frontmost is true
try
set frontmost to true
end try
end repeat
set buildKey to “b”
set keyItem to 0
set windowName to “Build for iOS”
if platform = “android” then
set buildKey to “B”
set keyItem to 2
set windowName to “Build for Android”
end if
keystroke buildKey using {command down}
delay 1
tell window windowName
if platform = “iPad” or platform = “ios” then
tell pop up button 3
click
tell menu 1
if platform = “iPad” then
click menu item “iPad only”
else
click menu item “iPhone only”
end if
end tell
end tell
end if
tell pop up button keyItem
click
tell menu 1
click menu item signatureID
end tell
end tell
tell button “Build” to click
end tell
end tell
end tell
end buildTarget
on run argv
–buildTarget("/tmp/app/main.lua", “ipad”, 2)
buildTarget(item 1 of argv, item 2 of argv, item 3 of argv as number)
end run
[/code] [import]uid: 7563 topic_id: 13815 reply_id: 53474[/import]
I did an applescript to automate installation on android devices.
Look at last post here:
https://developer.anscamobile.com/forum/2011/03/17/xcode-scripting-corona
[import]uid: 13632 topic_id: 13815 reply_id: 61151[/import]
cool! this gave me an idea for my iOS build automation needs …
I’ve recorded the whole … Corona | Open | Build | click | Xcode | Organizer | Applications | Add | Replace … process with the Mac OS X built-in Automator application … then saved the process as an Application, dragged it to my dock and that’s it.
All I have to do now, is one click on the dock and watch the whole process take about a minute to complete. Way better than b4.
thanks for the idea! [import]uid: 95911 topic_id: 13815 reply_id: 61137[/import]
cheers, but I am iOS only. [import]uid: 95911 topic_id: 13815 reply_id: 61153[/import]