File tree Expand file tree Collapse file tree 4 files changed +12
-3
lines changed
Expand file tree Collapse file tree 4 files changed +12
-3
lines changed Original file line number Diff line number Diff line change @@ -134,6 +134,7 @@ export type BenchmarkSpecification = {
134134 * local package */
135135 library: string;
136136 installLocation?: string;
137+ tags?: string[];
137138};
138139
139140export interface RunBenchmarkMessage {
Original file line number Diff line number Diff line change @@ -119,6 +119,7 @@ export class Task {
119119 const perfSendResults: PerfSendResult = {
120120 info: {
121121 test_name: this.testName,
122+ tags: this.benchmark.tags,
122123 args: {
123124 warmup: this.benchmark.warmup,
124125 iterations: this.benchmark.iterations,
Original file line number Diff line number Diff line change @@ -88,7 +88,8 @@ describe('Suite', function () {
8888 warmup: 10,
8989 iterations: 10,
9090 library: 'bson@5.0.0',
91- options: {}
91+ options: {},
92+ tags: ['test']
9293 };
9394 suite
9495 .task({
Original file line number Diff line number Diff line change @@ -42,7 +42,8 @@ describe('Task', function () {
4242 operation,
4343 warmup: 100,
4444 iterations: 100,
45- options: {}
45+ options: {},
46+ tags: ['test']
4647 }
4748 ];
4849 })
@@ -210,7 +211,8 @@ describe('Task', function () {
210211 operation: 'deserialize',
211212 warmup: 1,
212213 iterations: 1,
213- options
214+ options,
215+ tags: ['test', 'test2']
214216 });
215217
216218 task.result = {
@@ -226,6 +228,10 @@ describe('Task', function () {
226228 expect(results.info).to.haveOwnProperty('args');
227229 });
228230
231+ it('returns the tags in the info.tags field', function () {
232+ expect(results.info.tags).to.deep.equal(['test', 'test2']);
233+ });
234+
229235 it('returns options provided in constructor in the info.args field', function () {
230236 expect(results.info.args).to.haveOwnProperty('warmup');
231237 expect(results.info.args).to.haveOwnProperty('iterations');
You can’t perform that action at this time.
0 commit comments