The empty test is prior to all other tests, as it makes little sense to test for any other test when the field is just an empty string. Hence, this test aborts the other tests on a value when an empty string is encountered. It will simplify the implementation, as the other tests do not have to take into account the possibility of getting an empty string as input value. it will also diminish processing time (all empty values are faster evaluated with just a single test).
However, this has a major drawback as well:
When a conditional test is added (if) that includes the specification to decide when empty strings are allowed or not, this model runs into trouble. It requires to add a general empty test as well (empty is - sometimes - possible) and the priority of the empty test will stop the other tests, i.e. the if test is never started.
Therefore, we could decide about having the empty-test not as first priority test. This should be balanced against:
all implemented tests will have to properly handle empty strings as input
redundant tests will be run against these empty strings
The empty test is prior to all other tests, as it makes little sense to test for any other test when the field is just an empty string. Hence, this test aborts the other tests on a value when an empty string is encountered. It will simplify the implementation, as the other tests do not have to take into account the possibility of getting an empty string as input value. it will also diminish processing time (all empty values are faster evaluated with just a single test).
However, this has a major drawback as well:
When a conditional test is added (
if
) that includes the specification to decide when empty strings are allowed or not, this model runs into trouble. It requires to add a generalempty
test as well (empty is - sometimes - possible) and the priority of theempty
test will stop the other tests, i.e. theif
test is never started.Therefore, we could decide about having the empty-test not as first priority test. This should be balanced against: