How do I automatically approve a user account in Drupal 7 based on a rule I would have thought that I could find the answer to this by just googling but here I am...

In Drupal 6 it appears that you could setup user access rules in core to do this.  So for example approve accounts that match the rule: %@email.com, which would approve any email.com address.
http://drupal.org/getting-started/6/admin/user/rules

Does anyone know how to do this in Drupal 7.  I would also like to be able to automatically assign a role to the account.

Thanks for your help!
I'm pretty sure you can do that with rules in D7:

Event: "After saving a new user account".

Condition: "data comparison" on "account:mail" contains "@email.com".

Actions: "Unblock a user" and "add user role"

I personally like this tutorial by node.se.