@stanterprise/protobuf 0.0.7 → 0.0.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +2201 -444
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +2197 -444
- package/dist/index.mjs.map +1 -1
- package/dist/lib/google/protobuf/duration.d.ts +33 -0
- package/dist/lib/google/protobuf/duration.d.ts.map +1 -0
- package/dist/lib/index.d.ts +8 -2
- package/dist/lib/index.d.ts.map +1 -1
- package/dist/lib/testsystem/v1/entities/test_case.d.ts +244 -0
- package/dist/lib/testsystem/v1/entities/test_case.d.ts.map +1 -0
- package/dist/lib/testsystem/v1/entities/test_suite.d.ts +166 -0
- package/dist/lib/testsystem/v1/entities/test_suite.d.ts.map +1 -0
- package/dist/lib/testsystem/v1/events/events.d.ts +216 -72
- package/dist/lib/testsystem/v1/events/events.d.ts.map +1 -1
- package/dist/lib/testsystem/v1/observer/observer.d.ts +103 -15
- package/dist/lib/testsystem/v1/observer/observer.d.ts.map +1 -1
- package/lib/google/protobuf/duration.ts +98 -0
- package/lib/index.ts +16 -4
- package/lib/testsystem/v1/entities/test_case.ts +987 -0
- package/lib/testsystem/v1/entities/test_suite.ts +639 -0
- package/lib/testsystem/v1/events/events.ts +811 -303
- package/lib/testsystem/v1/observer/observer.ts +125 -21
- package/package.json +1 -1
- package/dist/lib/testsystem/v1/entities/entities.d.ts +0 -108
- package/dist/lib/testsystem/v1/entities/entities.d.ts.map +0 -1
- package/lib/testsystem/v1/entities/entities.ts +0 -405
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generated by the protoc-gen-ts. DO NOT EDIT!
|
|
3
|
+
* compiler version: 3.19.1
|
|
4
|
+
* source: google/protobuf/duration.proto
|
|
5
|
+
* git: https://github.com/thesayyn/protoc-gen-ts */
|
|
6
|
+
import * as pb_1 from "google-protobuf";
|
|
7
|
+
export namespace google.protobuf {
|
|
8
|
+
export class Duration extends pb_1.Message {
|
|
9
|
+
#one_of_decls: number[][] = [];
|
|
10
|
+
constructor(data?: any[] | {
|
|
11
|
+
seconds?: number;
|
|
12
|
+
nanos?: number;
|
|
13
|
+
}) {
|
|
14
|
+
super();
|
|
15
|
+
pb_1.Message.initialize(this, Array.isArray(data) ? data : [], 0, -1, [], this.#one_of_decls);
|
|
16
|
+
if (!Array.isArray(data) && typeof data == "object") {
|
|
17
|
+
if ("seconds" in data && data.seconds != undefined) {
|
|
18
|
+
this.seconds = data.seconds;
|
|
19
|
+
}
|
|
20
|
+
if ("nanos" in data && data.nanos != undefined) {
|
|
21
|
+
this.nanos = data.nanos;
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
get seconds() {
|
|
26
|
+
return pb_1.Message.getFieldWithDefault(this, 1, 0) as number;
|
|
27
|
+
}
|
|
28
|
+
set seconds(value: number) {
|
|
29
|
+
pb_1.Message.setField(this, 1, value);
|
|
30
|
+
}
|
|
31
|
+
get nanos() {
|
|
32
|
+
return pb_1.Message.getFieldWithDefault(this, 2, 0) as number;
|
|
33
|
+
}
|
|
34
|
+
set nanos(value: number) {
|
|
35
|
+
pb_1.Message.setField(this, 2, value);
|
|
36
|
+
}
|
|
37
|
+
static fromObject(data: {
|
|
38
|
+
seconds?: number;
|
|
39
|
+
nanos?: number;
|
|
40
|
+
}): Duration {
|
|
41
|
+
const message = new Duration({});
|
|
42
|
+
if (data.seconds != null) {
|
|
43
|
+
message.seconds = data.seconds;
|
|
44
|
+
}
|
|
45
|
+
if (data.nanos != null) {
|
|
46
|
+
message.nanos = data.nanos;
|
|
47
|
+
}
|
|
48
|
+
return message;
|
|
49
|
+
}
|
|
50
|
+
toObject() {
|
|
51
|
+
const data: {
|
|
52
|
+
seconds?: number;
|
|
53
|
+
nanos?: number;
|
|
54
|
+
} = {};
|
|
55
|
+
if (this.seconds != null) {
|
|
56
|
+
data.seconds = this.seconds;
|
|
57
|
+
}
|
|
58
|
+
if (this.nanos != null) {
|
|
59
|
+
data.nanos = this.nanos;
|
|
60
|
+
}
|
|
61
|
+
return data;
|
|
62
|
+
}
|
|
63
|
+
serialize(): Uint8Array;
|
|
64
|
+
serialize(w: pb_1.BinaryWriter): void;
|
|
65
|
+
serialize(w?: pb_1.BinaryWriter): Uint8Array | void {
|
|
66
|
+
const writer = w || new pb_1.BinaryWriter();
|
|
67
|
+
if (this.seconds != 0)
|
|
68
|
+
writer.writeInt64(1, this.seconds);
|
|
69
|
+
if (this.nanos != 0)
|
|
70
|
+
writer.writeInt32(2, this.nanos);
|
|
71
|
+
if (!w)
|
|
72
|
+
return writer.getResultBuffer();
|
|
73
|
+
}
|
|
74
|
+
static deserialize(bytes: Uint8Array | pb_1.BinaryReader): Duration {
|
|
75
|
+
const reader = bytes instanceof pb_1.BinaryReader ? bytes : new pb_1.BinaryReader(bytes), message = new Duration();
|
|
76
|
+
while (reader.nextField()) {
|
|
77
|
+
if (reader.isEndGroup())
|
|
78
|
+
break;
|
|
79
|
+
switch (reader.getFieldNumber()) {
|
|
80
|
+
case 1:
|
|
81
|
+
message.seconds = reader.readInt64();
|
|
82
|
+
break;
|
|
83
|
+
case 2:
|
|
84
|
+
message.nanos = reader.readInt32();
|
|
85
|
+
break;
|
|
86
|
+
default: reader.skipField();
|
|
87
|
+
}
|
|
88
|
+
}
|
|
89
|
+
return message;
|
|
90
|
+
}
|
|
91
|
+
serializeBinary(): Uint8Array {
|
|
92
|
+
return this.serialize();
|
|
93
|
+
}
|
|
94
|
+
static deserializeBinary(bytes: Uint8Array): Duration {
|
|
95
|
+
return Duration.deserialize(bytes);
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
}
|
package/lib/index.ts
CHANGED
|
@@ -6,12 +6,15 @@
|
|
|
6
6
|
|
|
7
7
|
import * as googleTimestamp from '../lib/google/protobuf/timestamp';
|
|
8
8
|
import * as testsystemCommon from '../lib/testsystem/v1/common/common';
|
|
9
|
-
|
|
9
|
+
// Entities are split across multiple files; import and merge both
|
|
10
|
+
import * as testsystemEntitiesTestCase from '../lib/testsystem/v1/entities/test_case';
|
|
11
|
+
import * as testsystemEntitiesTestSuite from '../lib/testsystem/v1/entities/test_suite';
|
|
10
12
|
import * as testsystemEvents from '../lib/testsystem/v1/events/events';
|
|
11
13
|
import * as testsystemObserver from '../lib/testsystem/v1/observer/observer';
|
|
12
14
|
|
|
13
15
|
type TestsystemNS = typeof testsystemCommon.testsystem &
|
|
14
|
-
typeof
|
|
16
|
+
typeof testsystemEntitiesTestCase.testsystem &
|
|
17
|
+
typeof testsystemEntitiesTestSuite.testsystem &
|
|
15
18
|
typeof testsystemEvents.testsystem &
|
|
16
19
|
typeof testsystemObserver.testsystem;
|
|
17
20
|
|
|
@@ -34,12 +37,21 @@ function mergeNamespace<T extends PlainObject, S extends PlainObject>(target: T,
|
|
|
34
37
|
const testsystem: TestsystemNS = mergeNamespace(
|
|
35
38
|
mergeNamespace(
|
|
36
39
|
mergeNamespace(
|
|
37
|
-
mergeNamespace(
|
|
38
|
-
|
|
40
|
+
mergeNamespace(
|
|
41
|
+
mergeNamespace({}, testsystemCommon.testsystem as PlainObject),
|
|
42
|
+
testsystemEntitiesTestCase.testsystem as PlainObject
|
|
43
|
+
),
|
|
44
|
+
testsystemEntitiesTestSuite.testsystem as PlainObject
|
|
39
45
|
),
|
|
40
46
|
testsystemEvents.testsystem as PlainObject
|
|
41
47
|
),
|
|
42
48
|
testsystemObserver.testsystem as PlainObject
|
|
43
49
|
) as TestsystemNS;
|
|
50
|
+
const common = testsystemCommon.testsystem.v1.common;
|
|
51
|
+
const entities = testsystem.v1.entities;
|
|
52
|
+
const events = testsystemEvents.testsystem.v1.events;
|
|
53
|
+
const observer = testsystemObserver.testsystem.v1.observer;
|
|
54
|
+
|
|
55
|
+
export { common, entities, events, observer };
|
|
44
56
|
export { testsystem };
|
|
45
57
|
export const google = googleTimestamp.google;
|