• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1syntax = "proto3";
2
3import "chromiumos/config/api/test/rtd/v1/progress.proto";
4import "chromiumos/config/api/test/results/v2/result.proto";
5
6package chromiumos.config.api.test.tnull.v1;
7
8option go_package = "go.chromium.org/chromiumos/config/go/api/test/tnull/v1;tnull";
9
10// A test with the TNull RTD consists of a Setup step (always executed first)
11// and then a sequence of zero or more Step specifications, each specifying a
12// method to call and the arguments to call it with.
13message Steps {
14  SetupStep setup = 1;
15  repeated Step steps = 2;
16}
17
18// The method arguments for a Setup call
19message SetupStep {
20  reserved 1;
21  chromiumos.config.api.test.rtd.v1.ProgressSinkClientConfig config = 2;
22  chromiumos.config.api.test.results.v2.Result result = 3;
23  repeated MockLog logs = 4;
24  repeated MockArtifact artifacts = 5;
25}
26
27message CommonArgSet {
28  string request_name = 1;
29}
30
31message ArchiveStep {
32  CommonArgSet common_args = 1;
33}
34
35message LogStep {
36  CommonArgSet common_args = 1;
37}
38
39message ResultStep {
40  CommonArgSet common_args = 1;
41}
42
43// Catchall for rapid iteration. Not guaranteed safe or reliable.
44message UnknownStep {
45  string method_name = 1;
46
47  // Where the value is a complex object - if that is ever necessary - it will
48  // be interpreted as a JSON-serialized object of whatever type the method
49  // expects for that argument.
50  map<string, string> args = 2;
51}
52
53message MockLog {
54  string name = 1;
55  repeated string messages = 2;
56}
57
58message MockArtifact {
59  string name = 1;
60  bytes file_bytes = 2;
61}
62
63// A Step is a action to take to execute a test.
64message Step {
65
66  oneof step {
67    UnknownStep other = 1;
68    ArchiveStep archive = 2;
69    LogStep log = 3;
70    ResultStep result = 4;
71  }
72}
73
74// A TestMap is a purely internal-use format for storing mappings from test
75// names to Steps protos
76message TestMap {
77  map<string, Steps> lookup = 1;
78}
79