MAINT: pchanial's improvement of input validation in sparse's __mul__

Retry of @pchanial's https://github.com/scipy/scipy/pull/4066, this time with tests and in its own PR branch.  Also changed `raise NotImplemented` to `raise NotImplementedError`.
`result` has wrong shape, drops one dimension?