hi
in my oppinion, as long as the transom is solid, and the boat is not too old, it should be ok, although, insurance may be more expensive, if the engine is bigger than recomed. another factor is that a 30hp 2 stroke is probably lighter than a 25hp 4 stroke.
i clame to be no expert, but if not i am sure others with more knowledge will correct me!