I think it should fail if you test whether x is sparse or not.