Unverified Commit a0831048 authored by yusufm's avatar yusufm Committed by GitHub

Removing the agents task manifest.yaml file. (#81064)

All agents have been deleted and removing this entry with last few agent tasks that appear in the dashboard. And remove the test_manifest.dart as well.
Co-authored-by: 's avataryusufm <mohsinally@google.com>
parent 7f17cf45
# Describes the tasks we run in the continuous integration (CI) environment.
#
# Cocoon[1] uses this file to generate a checklist of tasks to be performed for
# every master commit.
#
# [1] github.com/flutter/cocoon
# CI tasks.
#
# Each key in this dictionary is the unique name of a task, which also
# corresponds to a file in the "bin/" directory that the task runner will run.
#
# Required properties:
#
# * description: free form string
# describes what the task is about
# * stage: one of "devicelab", "devicelab_ios", "devicelab_win"
# tasks are grouped by stage so they appear next to each on the dashboard and have a distinct
# icon attached to them. Stages can be used to create dependencies, e.g. we may decide to not
# run device tests on red Cirrus builds.
# * required_agent_capabilities: a list of strings
# list of capabilities a devicelab agent must have to be able to run this task.
#
# Optional properties:
#
# * flaky: boolean true or false
# whether the task is considered flaky; the result of running a flaky task does not affect
# the overall build status. Tests should be marked flaky when newly added, until they have
# been proved for a few cycles. Tests that are actually flaky but not being actively worked
# on should be hidden because they just cause confusion otherwise.
# * on_luci: boolean true or false
# whether the task runs on LUCI builders. Tests will be gradually marked on_luci during the
# devicelab to LUCI migration. And when the migration is complete, on_luci flag will be
# removed.
tasks:
# Tests of compiling in a variety of modes
complex_layout_win__compile:
description: >
Collects various performance metrics of compiling the Complex
Layout for Android from Windows.
stage: devicelab_win
required_agent_capabilities: ["windows/android"]
basic_material_app_win__compile:
description: >
Collects various performance metrics of compiling the default
app for Android from Windows.
stage: devicelab_win
required_agent_capabilities: ["windows/android"]
flutter_gallery_win__compile:
description: >
Collects various performance metrics of compiling the Flutter
Gallery for Android from Windows.
stage: devicelab_win
required_agent_capabilities: ["windows/android"]
windows_chrome_dev_mode:
description: >
Run flutter web on the devicelab and hot restart.
stage: devicelab_win
required_agent_capabilities: ["windows/android"]
# Tests running on Windows host
flavors_test_win:
description: >
Checks that flavored builds work on Windows.
stage: devicelab_win
required_agent_capabilities: ["windows/android"]
channels_integration_test_win:
description: >
Checks that platform channels work when app is launched from Windows.
stage: devicelab_win
required_agent_capabilities: ["windows/android"]
hot_mode_dev_cycle_win__benchmark:
description: >
Measures the performance of Dart VM hot patching feature on Windows.
stage: devicelab_win
required_agent_capabilities: ["windows/android"]
// Copyright 2014 The Flutter Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
import 'dart:io';
import 'package:flutter_devicelab/framework/manifest.dart';
import 'common.dart';
void main() {
group('production manifest', () {
test('must be valid', () {
final Manifest manifest = loadTaskManifest();
expect(manifest.tasks, isNotEmpty);
final ManifestTask task = manifest.tasks.firstWhere((ManifestTask task) => task.name == 'complex_layout_win__compile');
expect(task.description, 'Collects various performance metrics of compiling the Complex Layout for Android from Windows.\n');
expect(task.stage, 'devicelab_win');
expect(task.requiredAgentCapabilities, <String>['windows/android']);
for (final ManifestTask task in manifest.tasks) {
final File taskFile = File('bin/tasks/${task.name}.dart');
expect(taskFile.existsSync(), true,
reason: 'File ${taskFile.path} corresponding to manifest task "${task.name}" not found');
}
});
});
group('manifest parser', () {
void testManifestError(
String testDescription,
String errorMessage,
String yaml,
) {
test(testDescription, () {
try {
loadTaskManifest(yaml);
} on ManifestError catch (error) {
expect(error.message, errorMessage);
}
});
}
test('accepts task with minimum amount of configuration', () {
final Manifest manifest = loadTaskManifest('''
tasks:
minimum_configuration_task:
description: Description is mandatory.
stage: stage_is_mandatory_too
required_agent_capabilities: ["so-is-capability"]
''');
expect(manifest.tasks.single.description, 'Description is mandatory.');
expect(manifest.tasks.single.stage, 'stage_is_mandatory_too');
expect(manifest.tasks.single.requiredAgentCapabilities, <String>['so-is-capability']);
expect(manifest.tasks.single.isFlaky, false);
expect(manifest.tasks.single.timeoutInMinutes, null);
});
testManifestError(
'invalid top-level type',
'Manifest must be a dictionary but was YamlScalar: null',
'',
);
testManifestError(
'invalid top-level key',
'Unrecognized property "bad" in manifest. Allowed properties: tasks',
'''
bad:
key: yes
''',
);
testManifestError(
'invalid tasks list type',
'Value of "tasks" must be a dictionary but was YamlList: [a, b]',
'''
tasks:
- a
- b
''',
);
testManifestError(
'invalid task name type',
'Task name must be a string but was int: 1',
'''
tasks:
1: 2
''',
);
testManifestError(
'invalid task type',
'Value of task "foo" must be a dictionary but was int: 2',
'''
tasks:
foo: 2
''',
);
testManifestError(
'invalid task property',
'Unrecognized property "bar" in Value of task "foo". Allowed properties: description, stage, required_agent_capabilities, flaky, timeout_in_minutes, on_luci',
'''
tasks:
foo:
bar: 2
''',
);
testManifestError(
'invalid required_agent_capabilities type',
'required_agent_capabilities must be a list but was int: 1',
'''
tasks:
foo:
required_agent_capabilities: 1
''',
);
testManifestError(
'invalid required_agent_capabilities element type',
'required_agent_capabilities[0] must be a string but was int: 1',
'''
tasks:
foo:
required_agent_capabilities: [1]
''',
);
testManifestError(
'missing description',
'Task description must not be empty in task "foo".',
'''
tasks:
foo:
required_agent_capabilities: ["a"]
''',
);
testManifestError(
'missing stage',
'Task stage must not be empty in task "foo".',
'''
tasks:
foo:
description: b
required_agent_capabilities: ["a"]
''',
);
testManifestError(
'missing required_agent_capabilities',
'requiredAgentCapabilities must not be empty in task "foo".',
'''
tasks:
foo:
description: b
stage: c
required_agent_capabilities: []
''',
);
testManifestError(
'bad flaky type',
'flaky must be a boolean but was String: not-a-boolean',
'''
tasks:
foo:
description: b
stage: c
required_agent_capabilities: ["a"]
flaky: not-a-boolean
''',
);
test('accepts boolean flaky option', () {
final Manifest manifest = loadTaskManifest('''
tasks:
flaky_task:
description: d
stage: s
required_agent_capabilities: ["c"]
flaky: true
''');
expect(manifest.tasks.single.name, 'flaky_task');
expect(manifest.tasks.single.isFlaky, isTrue);
});
test('accepts custom timeout_in_minutes option', () {
final Manifest manifest = loadTaskManifest('''
tasks:
task_with_custom_timeout:
description: d
stage: s
required_agent_capabilities: ["c"]
timeout_in_minutes: 120
''');
expect(manifest.tasks.single.timeoutInMinutes, 120);
});
});
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment