Some cleanups for running the sync integration tests
This commit is contained in:
parent
853a0acab4
commit
8ebb891bf8
|
@ -21,20 +21,23 @@ class GradlewBuild(object):
|
||||||
|
|
||||||
# Change path accordingly to go to root folder to run gradlew
|
# Change path accordingly to go to root folder to run gradlew
|
||||||
os.chdir('../../../../../../../..')
|
os.chdir('../../../../../../../..')
|
||||||
args = './gradlew ' + 'app:connectedGeckoNightlyDebugAndroidTest -Pandroid.testInstrumentationRunnerArguments.class=org.mozilla.fenix.syncintegration.SyncIntegrationTest#{}'.format(identifier)
|
cmd = './gradlew ' + 'app:connectedGeckoNightlyDebugAndroidTest -Pandroid.testInstrumentationRunnerArguments.class=org.mozilla.fenix.syncintegration.SyncIntegrationTest#{}'.format(identifier)
|
||||||
|
|
||||||
self.logger.info('Running: {}'.format(' '.join(args)))
|
self.logger.info('Running cmd: {}'.format(cmd))
|
||||||
|
|
||||||
|
out = ""
|
||||||
try:
|
try:
|
||||||
out = subprocess.check_output(
|
out = subprocess.check_output(
|
||||||
args, shell=True)
|
cmd,
|
||||||
|
shell=True,
|
||||||
|
stderr=subprocess.STDOUT)
|
||||||
except subprocess.CalledProcessError as e:
|
except subprocess.CalledProcessError as e:
|
||||||
out = e.output
|
out = e.output
|
||||||
raise
|
raise
|
||||||
finally:
|
finally:
|
||||||
#Set the path correctly
|
# Set the path correctly
|
||||||
testsPath = "app/src/androidTest/java/org/mozilla/fenix/syncintegration/"
|
testsPath = "app/src/androidTest/java/org/mozilla/fenix/syncintegration/"
|
||||||
os.chdir(testsPath)
|
os.chdir(testsPath)
|
||||||
|
|
||||||
with open(self.log, 'w') as f:
|
with open(self.log, 'w') as f:
|
||||||
f.writelines(out)
|
f.write(out)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user