Test and match in regular expressions

When do we use test method and when do we use match method in regular expressions?

match returns the things the regex matches, in an array. Test returns true or false.

Thank you for the reply.