Answer
$$\frac{1}{3}\ln \left| {\frac{{\cos \theta + 2}}{{\cos \theta - 1}}} \right| + C$$
Work Step by Step
$$\eqalign{
& \int {\frac{{\sin \theta d\theta }}{{{{\cos }^2}\theta + \cos \theta - 2}}} \cr
& \cr
& {\text{let }}x = \cos \theta ,\,\,\,dx = - \sin \theta d\theta \cr
& {\text{Write the integral in terms of }}x \cr
& \int {\frac{{\sin \theta d\theta }}{{{{\cos }^2}\theta + \cos \theta - 2}}} = - \int {\frac{{dx}}{{{x^2} + x - 2}}} \cr
& \cr
& {\text{Solve the integral by the method of partial fractions.}} \cr
& {\text{The form of the partial fraction decomposition is}} \cr
& \frac{1}{{{x^2} + x - 2}} = \frac{1}{{\left( {x + 2} \right)\left( {x - 1} \right)}} = \frac{A}{{x + 2}} + \frac{B}{{x - 1}} \cr
& {\text{Multiplying by }}\left( {x + 2} \right)\left( {x - 1} \right){\text{, we have}} \cr
& {\text{1}} = A\left( {x - 1} \right) + B\left( {x + 2} \right) \cr
& {\text{if we set }}x = - 2, \cr
& {\text{1}} = A\left( { - 3} \right) + B\left( 0 \right) \cr
& A = - 1/3 \cr
& {\text{if we set }}x = 1, \cr
& {\text{1}} = A\left( 0 \right) + B\left( 3 \right) \cr
& B = 1/3 \cr
& {\text{then}} \cr
& \frac{1}{{\left( {x + 2} \right)\left( {x - 1} \right)}} = \frac{A}{{x + 2}} + \frac{B}{{x - 1}} = \frac{{ - 1/3}}{{x + 2}} + \frac{{1/3}}{{x - 1}} \cr
& - \int {\frac{{dx}}{{{x^2} + x - 2}}} = - \int {\left( {\frac{{ - 1/3}}{{x + 2}} + \frac{{1/3}}{{x - 1}}} \right)dx} \cr
& {\text{integrating}} \cr
& = \frac{1}{3}\ln \left| {x + 2} \right| - \frac{1}{3}\ln \left| {x - 1} \right| + C \cr
& = \frac{1}{3}\ln \left| {\frac{{x + 2}}{{x - 1}}} \right| + C \cr
& {\text{Write the solution in terms of }}x,{\text{ substitute cos}}\theta {\text{ for }}x \cr
& = \frac{1}{3}\ln \left| {\frac{{\cos \theta + 2}}{{\cos \theta - 1}}} \right| + C \cr} $$