mirror of https://github.com/axmolengine/axmol.git
Merge pull request #5834 from shujunqiao/autotest
modify autotest.py for use mac app.
This commit is contained in:
commit
36cfd17e7b
|
@ -1,3 +1,4 @@
|
||||||
|
#!/usr/bin/python
|
||||||
import os
|
import os
|
||||||
import sys
|
import sys
|
||||||
import subprocess
|
import subprocess
|
||||||
|
@ -25,7 +26,7 @@ def autotest(type):
|
||||||
soc.connect((HOST_ADNROID, PORT))
|
soc.connect((HOST_ADNROID, PORT))
|
||||||
if type == TYPE_IOS:
|
if type == TYPE_IOS:
|
||||||
soc.connect((HOST_IOS, PORT))
|
soc.connect((HOST_IOS, PORT))
|
||||||
time.sleep(3)
|
time.sleep(1)
|
||||||
print 'autotest run:'
|
print 'autotest run:'
|
||||||
soc.send('autotest run\r\n')
|
soc.send('autotest run\r\n')
|
||||||
|
|
||||||
|
@ -65,8 +66,8 @@ def MAC_BUILD():
|
||||||
if not cleanProj():
|
if not cleanProj():
|
||||||
print '**CLEAN FAILED**'
|
print '**CLEAN FAILED**'
|
||||||
if not buildProj():
|
if not buildProj():
|
||||||
cleanProj()
|
print '**BUILD FAILED**'
|
||||||
buildProj()
|
return False
|
||||||
if not openProj():
|
if not openProj():
|
||||||
return False
|
return False
|
||||||
time.sleep(sleep_time)
|
time.sleep(sleep_time)
|
||||||
|
@ -118,8 +119,10 @@ def ANDROID_BUILD():
|
||||||
#----------------autotest-android build and run end----------------#
|
#----------------autotest-android build and run end----------------#
|
||||||
|
|
||||||
def main():
|
def main():
|
||||||
|
print 'will build mac project.'
|
||||||
suc_build_mac = MAC_BUILD()
|
suc_build_mac = MAC_BUILD()
|
||||||
suc_build_android = ANDROID_BUILD()
|
#print 'will build android project.'
|
||||||
|
#suc_build_android = ANDROID_BUILD()
|
||||||
if suc_build_mac:
|
if suc_build_mac:
|
||||||
autotest(TYPE_MAC)
|
autotest(TYPE_MAC)
|
||||||
if suc_build_android:
|
if suc_build_android:
|
||||||
|
|
Loading…
Reference in New Issue