advantages and disadvantages of white-box testing of students assignments? This is a fork of my question homework-testing-method-for-schools but i'm taking it in another direction. 

I was asking about a homework testing method that'll encourage students to write better code and reduce the TA's proofreading task to a minimum.

I was thinking of using unit testing, (or anything else you can think of), in order to turn students in the right direction (design wise), and hopefully giving them good thinking and coding habits (we're talking first programming course in collage).

so my new question is:


If you think there's something wrong and not educational about unit testing    students code please explain why do you think so..
If you think this is a good (or just an o.k) idea please tell me if you have any ideas of how to design the tests.


thank you for your answers.
A lot of what I said as an answer to this question is probably also applicable here, so I will not repeat it.


  If you think there's something wrong and not educational about unit testing students code please explain why do you think so..


I don't think there is anything particularly wrong about unit testing student code, but it will likely not do away with manual grading or direct lab sessions entirely. All things considered, the way how TAs traditionally check programming assignments (build, run, check behavior against assignment description) is pretty close to what a unit testing framework does anyway.


  If you think this is a good (or just an o.k) idea please tell me if you have any ideas of how to design the tests.


The major challenge I see is that you want your tests not only to serve as a framework to check whether students implemented the right functionality, but also to check whether they did it in the right way. I think unit tests and generally automated grading will not be able to help you here, aside from limited hard-coded rule checking.

A lot of the problem is already encoded in your use of terminology. You say you want "unit tests that do white box testing". This isn't really feasible, IMHO. Unit tests test interfaces. So, to cut it short, I do not think that unit tests will help you in this regard.