Fixing test errors in abide.js

Karma test was reporting:

TypeError: 'undefined' is not an object
(evaluating 'parent.find('small.error, span.error')[0].id')

Have added an extra line to test if parent.find() has a length greater
than 0 before trying to access the id property of the first item.
Abide: Moving check for custom validators before check for whether input
is a checkbox/radio input. This allows custom validators on checkbox and
radio inputs as well as other inputs.

This is in relation to #5656
Merge pull request #5657 from dancoates/radio-checkbox-abide-custom-validators

Allow custom validators for radio inputs and checkbox inputs