A service that provides this "trial relationship" could work. When I'm looking for a new job, I could do one hour per day of real work for a few companies. After five days, both employer and prospective employee will have a better understanding of each other than a single day of interviews allows.
There's practical concerns. Companies certainly wouldn't give prospective employees full access to internal codebases or data. Companies would have to break off small tasks which could devolve into throw-away take-home assignments. Employees at the company would have to endure the annoyance of dealing with prospective hires. It might be worth it for everyone.