Bring your own device should always be understood as a security tradeoff. Especially if it's someone who is auditioning for a job (I'm sure you're aware of that but can't hurt to point it out).
Also, particularly with employment contracts, just because something is in the contract doesn't necessarily mean it is enforceable.
I'd actually love to do that. The company I work for currently presented itself in a very professional light and all the questions I had were answered promptly and professionally. No red flags.
Only when I started work, I noticed immediately their code base contained unfixed bugs, tests were not up to date and the databases (so called data-warehouses) were a mess. Unfortunately, the only real good developer was on the interview and answered my questions.
During a one-week stint, I'd have discovered enough bad practices that I would have declined the job.
I came in and did a one week trial, I brought in my own computer, they gave me access to a repository and a task list, told me to do what I could in the week and ask questions. Arguably, the experience was great. I was able to not only see if I wanted to work for this company, but what the people are like and what kind of problems I would be solving. It was a great way for the company to see if I got along with their team and if they liked me as a person.
Being a developer is half knowing how to code and the rest is whether or not you are a match personality wise for the company. You might be smart, but can you get along with others and work in different situations? A palindrome function or FizzBuzz during a coding interview can't tell you everything about a developer.
You know what else is great? I came onboard as a senior developer, after a year, I was running my own team of 2 other developers. Then something greater happened, I managed to change the way the company hires developers. We do the initial screening which is just a chat to see if their skillset matches the role, then we reduce the list down and bring them in to pair program with someone.
It works so well. Also what is cool is that the two developers we have brought on since I started were hired after great work performances during their week trial/interview.