| # Copyright 2021 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. |
| |
| PYTHON_VERSION_COMPATIBILITY = "PY3" |
| |
| DEPS = [ |
| "fuchsia/publish", |
| "fuchsia/status_check", |
| "recipe_engine/json", |
| ] |
| |
| |
| def RunSteps(api): |
| api.publish.release( |
| "propose release", |
| "product", |
| "0.1.2.3", |
| "channel", |
| publish_host="publish.googleapis.com", |
| rollout_pct=100, |
| urgent_update=True, |
| switch_channel="switch-channel", |
| ) |
| api.publish.release( |
| "stop rollout", |
| "product", |
| "0.1.2.3", |
| "channel", |
| stop_rollout=True, |
| ) |
| |
| |
| def GenTests(api): |
| yield ( |
| api.status_check.test("basic") |
| + api.step_data( |
| "propose release", |
| api.json.output({"proposal": "http://releases/proposal"}), |
| ) |
| + api.step_data( |
| "stop rollout", |
| api.json.output({"proposal": "http://releases/stop-proposal"}), |
| ) |
| ) |