Technically you can import EHP5 transport into EHP7 system . You have to use the following option "Ignore Invalid Component version" in STMS.
Important fact for such kind of transport is that - if any transport touches tables or structures always advisible not to move - untill and unless there are no changes to under leying tables/structures.
Off course - this is your call - however SAP will recommend not perform intra release import.
As long as it not touches SAP's standard program , table and structures - technically you can move transport from EHP5 to EHP7.
Thanks,
Dipam
Dipam Phukan