blob: 0ca51b373694b93ed48b247aa8d523a77464f76c [file] [log] [blame]
# Copyright 2018 The Fuchsia Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
"""Recipe for building Fuchsia and running connectivity tests.
TODO(IN-831): This will be replaced when host-target-interaction infra
is in place.
This differs from the fuchsia recipe in the following ways:
* Host-side connectivity tests are run instead of unit tests.
* Tests are always run.
"""
DEPS = [
'infra/fuchsia',
'recipe_engine/buildbucket',
]
def RunSteps(api):
api.fuchsia.checkout(
build=api.buildbucket.build,
manifest='garnet/garnet',
remote='https://fuchsia.googlesource.com/integration',
project='garnet',
)
build = api.fuchsia.build(
target='x64',
build_type='debug',
packages=['garnet/packages/tools/sl4f', 'garnet/packages/garnet'],
board='garnet/boards/x64.gni',
build_for_testing=True,
)
test_results = api.fuchsia.test(
build=build,
test_pool='fuchsia.tests',
timeout_secs=60*60,
pave=True,
test_cmds=['run sl4f'],
device_type='Intel NUC Kit NUC6i3SYK',
extra_dimensions={
# TODO(chok) - Replace this with a more generic dimension such as
# "bt_rf_chamber: True"
'id': 'fuchsia-tests-x64-lab01-0001--ocean-drank-wick-spot',
},
host_cmd=['/etc/connectivity/host_cmds.sh']
)
test_results.raise_failures()
def GenTests(api):
# Test cases for running Fuchsia connectivity tests as a swarming task.
yield api.fuchsia.test(
'successful_run',
properties=dict(
run_tests=True,
),
)