blob: 2c25a3561f52b3ef67cf62d358210d90bdc67f03 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
|
export const description = `
Tests for validation in createQuerySet.
`;
import { makeTestGroup } from '../../../../common/framework/test_group.js';
import { kQueryTypes, kMaxQueryCount } from '../../../capability_info.js';
import { ValidationTest } from '../validation_test.js';
export const g = makeTestGroup(ValidationTest);
g.test('count')
.desc(
`
Tests that create query set with the count for all query types:
- count {<, =, >} kMaxQueryCount
- x= {occlusion, timestamp} query
`
)
.params(u =>
u
.combine('type', kQueryTypes)
.beginSubcases()
.combine('count', [0, kMaxQueryCount, kMaxQueryCount + 1])
)
.beforeAllSubcases(t => {
t.selectDeviceForQueryTypeOrSkipTestCase(t.params.type);
})
.fn(async t => {
const { type, count } = t.params;
t.expectValidationError(() => {
t.device.createQuerySet({ type, count });
}, count > kMaxQueryCount);
});
|