add test for calculating errors in the hidden layer