serverless/test/fixtures/programmatic/config-schema-extensions-error/test-plugin-with-complex-event-without-object-definition.js
2024-05-29 11:51:04 -04:00

31 lines
713 B
JavaScript

'use strict'
class TestPluginWithComplexEventWithoutObjectDefinitionError {
constructor(serverless) {
serverless.configSchemaHandler.defineProvider('someProvider', {
function: {
properties: {
handler: { type: 'string' },
},
},
functionEvents: {
existingComplexEvent: {
anyOf: [{ type: 'string' }, { type: 'integer' }],
},
},
})
serverless.configSchemaHandler.defineFunctionEventProperties(
'someProvider',
'existingComplexEvent',
{
properties: {
someProperty: { type: 'string' },
},
},
)
}
}
module.exports = TestPluginWithComplexEventWithoutObjectDefinitionError