Yes, but the margin of error of the amount of the active ingredient can be significant (up to 20% in either direction!).
The inactive ingredients can be relevant. Some people have allergies[0], and sometimes the inactive compound can affect the absorption of the drug (which can vary from person to person).
Generics are fine, but it's important to remember that they're not exactly the same as the brand-name drugs, and that can matter.
[0] For example, a lot of drugs contain lactose-based compounds as inactive ingredients, which is one of the reasons that a lot of drugs can cause diarrhea as a side-effect.