At work we do both. If you pass the somewhat artificial interviews we invite you for a trial week of 3-5 days working with the actual team on actual real work (a somewhat contained feature or problem).
Lets us evaluate people in real conditions and visa versa.