If it's going to take more than a few hours, companies should definitely pay.
I know that games developer ThreeRings did that. Once you got far enough along, they'd give you their games toolkit and ask you to build a simple, original game in, I think, 20 hours, for which they'd pay you a decent rate.
I'm not sure I'd do that today, as it can exacerbate existing systemic bias issues, and cause you to miss out on good candidates who have lives where it's hard to free up 20 hours on short notice.
Plus, I think there are cheaper ways to get that data. I now structure my interviews as joint work sessions. One round is a couple hours of pair programming; the other is a couple of hours of joint design and discussion with the team. The goal of both is to see people doing something pretty close to everyday work. I think I can get a much better feel for somebody's skills in a few hours of collaboration than 3 days of remote work with a big-bang delivery at the end.
I know that games developer ThreeRings did that. Once you got far enough along, they'd give you their games toolkit and ask you to build a simple, original game in, I think, 20 hours, for which they'd pay you a decent rate.
I'm not sure I'd do that today, as it can exacerbate existing systemic bias issues, and cause you to miss out on good candidates who have lives where it's hard to free up 20 hours on short notice.
Plus, I think there are cheaper ways to get that data. I now structure my interviews as joint work sessions. One round is a couple hours of pair programming; the other is a couple of hours of joint design and discussion with the team. The goal of both is to see people doing something pretty close to everyday work. I think I can get a much better feel for somebody's skills in a few hours of collaboration than 3 days of remote work with a big-bang delivery at the end.