test case for "each method returns first error and array of errors"