-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Related to bpmn-io/bpmn-js-properties-panel#614
- Loading branch information
Niklas Kiefer
committed
Mar 21, 2022
1 parent
bda0098
commit 8cff570
Showing
4 changed files
with
69 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
11 changes: 11 additions & 0 deletions
11
packages/zeebe-element-templates-json-schema/test/fixtures/documentation-ref.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
export const template = { | ||
'name': 'Documentation Ref', | ||
'id': 'com.camunda.example.DocumentationRef', | ||
'appliesTo': [ | ||
'bpmn:Task' | ||
], | ||
'properties': [], | ||
'documentationRef': 'https://www.example.com/myTask' | ||
}; | ||
|
||
export const errors = null; |
44 changes: 44 additions & 0 deletions
44
packages/zeebe-element-templates-json-schema/test/fixtures/invalid-documentation-ref.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
export const template = { | ||
'name': 'Documentation Ref', | ||
'id': 'com.camunda.example.DocumentationRef', | ||
'appliesTo': [ | ||
'bpmn:Task' | ||
], | ||
'properties': [], | ||
'documentationRef': 'foo' | ||
}; | ||
|
||
export const errors = [ | ||
{ | ||
keyword: 'errorMessage', | ||
dataPath: '/documentationRef', | ||
schemaPath: '#/allOf/0/properties/documentationRef/errorMessage', | ||
params: { | ||
errors: [ | ||
{ | ||
keyword: 'pattern', | ||
dataPath: '/documentationRef', | ||
schemaPath: '#/allOf/0/properties/documentationRef/pattern', | ||
params: { pattern: '^(https|http)://.*' }, | ||
message: 'should match pattern "^(https|http)://.*"', | ||
emUsed: true | ||
} | ||
] | ||
}, | ||
message: 'Malformed documentation URL, must match "^(https|http)://.*"' | ||
}, | ||
{ | ||
keyword: 'type', | ||
dataPath: '', | ||
schemaPath: '#/oneOf/1/type', | ||
params: { type: 'array' }, | ||
message: 'should be array' | ||
}, | ||
{ | ||
keyword: 'oneOf', | ||
dataPath: '', | ||
schemaPath: '#/oneOf', | ||
params: { passingSchemas: null }, | ||
message: 'should match exactly one schema in oneOf' | ||
} | ||
]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters