优化
This commit is contained in:
20
server/models/openapi/__tests__/app.spec.ts
Normal file
20
server/models/openapi/__tests__/app.spec.ts
Normal file
@@ -0,0 +1,20 @@
|
||||
import { filterAvailableAppCapability } from '../app';
|
||||
|
||||
describe('openapp', () => {
|
||||
describe('filterAvailableAppCapability', () => {
|
||||
test.each([
|
||||
[['bot'], ['bot']],
|
||||
[['bot', 'foo'], ['bot']],
|
||||
[
|
||||
['bot', 'webpage', 'oauth'],
|
||||
['bot', 'webpage', 'oauth'],
|
||||
],
|
||||
[
|
||||
['bot', 'webpage', 'oauth', 'a', 'b', 'c'],
|
||||
['bot', 'webpage', 'oauth'],
|
||||
],
|
||||
])('%p', (input, output) => {
|
||||
expect(filterAvailableAppCapability(input)).toEqual(output);
|
||||
});
|
||||
});
|
||||
});
|
||||
Reference in New Issue
Block a user