@Victoria Imlach
You could talk to your agent about putting in a contingency for a vacant unit. That would mean there would need to be a vacant unit before you can close. This could make you lose the deal though if other buyers are willing to purchase without a vacant unit.
You will need to find out if the tenants are on a month to month lease. If they are, then you can serve a notice of non-renewal. If they are NOT on a month to month lease, things are more complicated. The lease goes with the property, so if the lease says "$500 in rent until 2023" you are stuck with it, unless the tenant violates the lease or you can work out an arrangement with the tenant.
If the lease is month to month, you could ask for the seller to serve a notice of nonrenewal before you close, but not require the tenant to be out before closing. One of my friends is in the middle of a deal like this. He is hoping the tenant is out before they close, but if he is not, at least the process has been started.
If the lease is month to month and after the given date for them to move out has passed and the tenant does not move out, I suggest hiring a lawyer to handle the eviction process for you. Normally, I would suggest you read up on it and try it yourself, but right now, the eviction process is very complicated. In the past, it has taken me at least 3 months to evict a tenant. In this environment, it could take much longer.
Hopefully, one of the tenants is on a month to month lease and is cooperative with moving out. Although, it sounds like they are getting a great deal on rent, so they may be reluctant to move out.
Good luck!