Testing the missing at random assumption in generalized linear models in the presence of instrumental variables