1
0
mirror of synced 2024-11-29 08:36:12 +03:00
vue-formulario/test/unit/validation/validator.test.js

37 lines
815 B
JavaScript

import { enlarge } from '@/validation/validator.ts'
// @TODO: Converting raw rule data to validator
describe('Validator', () => {
it ('Enlarges validator groups', () => {
expect(enlarge([{
validators: [],
bail: false,
}, {
validators: [],
bail: false,
}, {
validators: [],
bail: false,
}, {
validators: [],
bail: true,
}, {
validators: [],
bail: false,
}, {
validators: [],
bail: false,
}])).toEqual([{
validators: [],
bail: false,
}, {
validators: [],
bail: true,
}, {
validators: [],
bail: false,
}])
})
})