The book answer has been achieved by means of the substitution u = sin x.
Mathematica has arrived at its result by making use of various trig identities to reduce powers to unity.
You seem to have used the substitution u = cos x, though I think that you've made a mistake, (a lost negative sign).
It should be possible to get from any one result to either of the other two by means of the various trig identities.
As to checking whether or not an integration is correct, the usual method is to differentiate the result to see whether it produces the thing that you started with.