Had a bizarre experience like this recently and what struck me was that the amount of time & resources this must have wasted is a massive signal of systemic toxic dysfunction, I mean I got a full mock loop out of it which is actually a significant value in the interview prep cottage industry and I guess they got some IP from the homework but otherwise what's the point? Seems like the risks to the company far outweigh any possible benefit if there was any.
Those company need to have people in their pool to quickly respond to client request and they assume that you will adapt to the client needs. They don't spend a lot of money on the hiring process.
But regarding your situation, I'll need more info to qualify it as problematic. Some companies will spend a huge amount of money on the hiring process to be sure to have the right candidate because they almost never fire anyone, and they want everybody already in place to be happy with the new hire. The cost of having a rotten apple in your team far outweighs the cost of selecting the right apple.
Some cases I've seen in the consulting world: 1. The company I was working for was expecting to win a big contract for oracle dev and hired 80+ dev with oracle experience. They didn't tell them that the contract wasn't signed yet. They didn't get the contract, the Devs stayed employed while the company tried to find clients for them. It's an interesting experience to see 80+ dev in a big meeting room doing nothing all day. The DivX craze started at that time, all the company laptops where used all day long to watch movies. Even though they were "oracle specialists", they were offered whatever contract the company could find : vba debugging, clipper development, documentation, windows server configuration,... Those who refused the offer they got were shown the door.
2. I was hired by another company that wanted some senior Devs in their pool. While waiting for a client request, one director comes by and ask if I know SharePoint. Me : "I've done some tests with it 5yrs ago". Him : "Fine, say something about it in your resume and I'll send it to the client, refresh your memories by reading a book or some online training." I adapt my resume, start the online training at work and read the book in the evening at home.
5 Days later, the same director comes by and ask "Do you know biztalk?" Me : "I've done some tests with it 5yrs ago". (The test I did was to interconnect sharepoint with biztalk) Him : "Fine, say something about it in your resume and I'll send it to the client, refresh your memories by reading a book or some online training." Me : "What about that sharepoint thing ?" Him : "The client took someone else". Guess what happened 5 days later...
We have a joke with my colleagues (all consultants) : If you can spell the technology, the company will sell you as someone who has experience. If you have used it in any way, you are an specialist. If you can mention it in your resume, you are an expert.