The answer to this question depends on two things: 1) when you intend to travel and 2) your tolerance for risk.
In general, travel is not recommended when an individual has a request pending with USCIS. This is because being outside the U.S. during the processing of a benefit could be considered abandonment of your petition. Additionally, the I-765 Form itself says that a petitioner should be in the U.S.: Part 3, Applicant's Statement, Contact Information, Declaration, Certification, and Signature states, "Note: [...] You must file Form I-765 while in the United States."
This makes travel with a pending I-765 inherently risky and not recommended.
That said, if you must travel, consider the timing:
For travel outside the U.S. before you graduate, you should be able to get back in to the U.S. without the EAD card as long as it is still long enough in advance of your graduation (at least one month). If you have to travel, talk to an advisor at the ISSO before leaving.
After you graduate, once your OPT is approved you will NOT be able to re-enter the U.S. without your OPT EAD card in addition to your valid passport, current F-1 visa stamp, job offer letter / proof of employment, and your I-20 signed for travel within the last six months.