That sounds fine; it's more a question of the timing. I'm guessing you give your test before the in-person interview? That would make a lot more sense to me than doing it after, which they apparently did to OP.
Yes, it's usually "homework" (i.e., send us your resume and your code sample at the same time). I have a "problem solving" task where I expect you to bang out an algorithm (as opposed to code) for the in-person interview. That's mainly just so I can watch you think out loud.
I can teach you my project's programming language... I don't have time to teach you problem solving basics.
I can teach you my project's programming language... I don't have time to teach you problem solving basics.