@@ -212,6 +214,14 @@ describe('Image upload form', () => {
});
it('should prevent form submission if tag checks fail', async () => {
+ tagSets.forEach(tags => {
+ taginputEl.value = tags;
+ //TODO fire submit event
+ // check whether the form fully submitted or was prevented by tag checks
+ // verify the number of error help blocks added
+ // check if the submit button is enabled/disabled
+ });
+
await new Promise(resolve => {
form.addEventListener('submit', event => {
event.preventDefault();